Ok so this is more of a math question than a unity question but here we go. My problem is I want to squash a rectangular prism (technically represented by a Vector3) without changing its volume. Shrink the height and expand the length and width to keep the volume the same, AND grow the length and width by an equal amount (if width goes up 0.5, length must go up 0.5) .

Additionally I say its a rectangular prism and not a cube because it will not have equal sides to begin with. Were it only that simple! I may be attempting to squash a rectangular prism with dimensions starting at width 2 height 6 and length 4 (with a volume of 48) and then attempting to squash that height to 5 and expand the width and length by X where (2 + X) · (4 + X) · 5 still equals 48.

I have been scouring the internet for a solution but so far I haven’t found anything that isn’t “You can find the volume by multiplying the height width and length!” Thank you internet, but that is not what I asked. “You can find the height with the volume width and length!” still not what I asked. Etc…

It is possible that I was not at all good at math in school, it is possible that its late and/or very early, it is possible I have been at this problem for four hours, it is even conceivable that all three are true so at this point I don’t know if I can’t find an answer to this problem online because it is remarkably simple, because it is impossible, because no one has asked it before, or I didn’t use the right keywords.

Any help solving this and/or explaining why it cant’t be solved would be greatly appreciated.