Boyle's law

I want to create an illustration of Boyle’s law in which the volume of a balloon changes proportional to depth, (ie y value). Can anyone give me some help on this. thanks moyra

Yes I see but it is the volume that is proportional. The scale would be the diameter

If you are using a 3d modelled balloon ensure the Transform of the object is set to the centre or base, then you could use then as the the depth increase the scale of the ballon would decrease,

you could use the balloon pos for your value of Y, and link the scaling of the balloon to that.