If mass of a gas is constant then there is variation in density of gas with the variation of temperature and pressure because the molar volume of the gas goes on changing because ρ=VM
We know, from Ideal gas law p=MρRT
For point A , p=Mρ0RT0⇒M=pρ0RT0 ...(i)
For point B , 3p=MρR(2T0)=(ρ)0(RT)0ρR(2T0)×p [By Eq. (i)] ⇒ρ=23ρ0