(geometry) height of water in tilted canister? Recently there is a problem online where a rectangular canister with some water in it is tilted and participants are asked to draw what the surface of the water looks like. see the link below.
https://gyazo.com/e909323dc3a832b81da5bce5038d54f0
I understand that the water will be parallel with the earth. what I am more interested in is finding out the final height of the water in terms of the height of the canister (y), length of the base of the canister(b), tilt of the canister(theta), and initial level of the water (L). I tried working through this and here is what I got
https://gyazo.com/8d3ae66df57be70915a7ea9100cc1256
however when I try some of the extreme values things dont end up working out. Can someone help spot some mistakes that I made and give me a better final answer.
 A: AfteLet $B$ denote the base of the canister and $L$ the initial level of the water, so that the total amount of water is $BL$. Suppose for now that the canister is sufficiently high so that the water does not reach the top when tilting it by an angle $\theta$. Then we have the following picture:

The dashed line divides the water into a triangular region and a parallelogram. Some elementary trigonometry shows that the top-right angle of this triangle is $\theta$, and hence that the area of this triangle is
$$\frac12\times B\times\frac{B}{\tan\theta}=\frac{B^2}{2\tan\theta}.$$
It also shows that the length of the dashed line is $\tfrac{B}{\sin\theta}$. Some more elementary trigonometry shows that the height of the dashed line equals $B\cos\theta$. (Hint: Drop a vertical line from the dashed line through the bottom vertex, and use similarty of triangles.)
In particular, the image shows that if the total amount of water $BL$ is less than $\tfrac{B^2}{2\tan\theta}$, then the water does not reach the dashed line. This is the case if and only if $\tan\theta<\frac{B}{2L}$. In this case the water line creates a smaller triangle that is a scaled version of the one defined by the dashed line. If the scaling factor is $\lambda$, then the area of this triangle is
$$BL=\lambda^2\frac{B^2}{2\tan\theta},$$
from which it follows that
$$\lambda=\sqrt{\frac{2L}{B}\tan\theta},$$
and hence that the height of the water equals
$$\lambda B\cos\theta=\sqrt{2BL\sin\theta\cos\theta}=\sqrt{BL\sin(2\theta)}.$$
On the other hand, if the water does reach the dashed line, then the height of the water is
$$B\cos\theta+h,$$
where $h$ is the height of the parallelogram. Then the total amount of water is
$$BL=\left(\frac{1}{2}\times B\times \frac{B}{\tan\theta}\right)
+\left(h\times\frac{B}{\sin\theta}\right),$$
from which it follows that
$$h=\left(L-\frac{B}{2\tan\theta}\right)\sin\theta=L\sin\theta-\frac{B}{2}\cos\theta.$$
Then the total height of the water equals
$$B\cos\theta+h=L\sin\theta+\frac{B}{2}\cos\theta.$$
The cases where the water reaches to top of the canister allow for similar solutions. I leave the details to you.
