Suppose I have a pipe with holes on its top (kind of like a flute, but with different sized holes). One end of the pipe is open and the other is closed. The pipe is submerged in water horizontally, and I start pumping water into the open end at a known flow rate. How can I determine the pairwise ratios of the holes' areas that will ensure the flow rates out of all holes are equal?
Here are my initial thoughts on how to approach the problem. Suppose the pipe has $n$ holes on top, and the cross-sectional area of the $i^{\text{th}}$ hole from the open end is $A_i$. Using continuity and the condition that all holes have equal flow rates, we know that
$$A_i=\frac{Q}{nv_i}$$
where $Q$ is the flow rate from the pump, and $v_i$ is the velocity of water coming out of the $i^{\text{th}}$ hole. This gives the ratio
$$\frac{A_i}{A_j}=\frac{v_j}{v_i}$$
so to find my desired pairwise ratios, I'll need to know $v_i$ for all $i$. Using Bernoulli's equation, I can show that
$$v_i=\sqrt{v^2+\frac{2}{\rho}(p-p_i)}$$
where $v$ is the (known) velocity of water entering the open end of the pipe, $p$ is the pressure at that end, $\rho$ is the density of water, and $p_i$ is the pressure near the $i^{\text{th}}$ hole. If I'm right so far (a big if, as I'm not a physicist and have little intuition for fluid dynamics), this leaves me needing to determine $p$ and $p_i$ for all $i$ to solve my problem. If we suppose the depth of the pipe below the water's surface is $d$, can we express $p$ and $p_i$ solely in terms of $v$, $d$, and $\rho$? Given some idealized assumptions, it seems like this should be the case, or perhaps I'm missing something (or perhaps my whole approach is flawed).
My motivation here is to design a filter for a fish tank that circulates water evenly from the whole length of the tank.