I know that when modeling incompressible flow in a pipe, it is common practice that when you have a velocity inlet, there should be a zero pressure gradient at the inlet as well. Also, when you have a pressure outlet, you should set the velocity gradient to zero at the outlet. But when you have both a pressure inlet and pressure outlet, should one set the velocity gradients at both inlet and outlet to zero? Would this lead to a stable solution for pipe flow?

  • 1
    $\begingroup$ What would be driving the flow with this configuration? A mean pressure gradient? Buoyancy forces? What Reynolds number are you considering? Do you expect a laminar or turbulent flow? $\endgroup$
    – Charles
    Jun 18, 2016 at 5:42
  • $\begingroup$ @Charlie: it is definitely driven by the mean pressure gradient. I also expect the flow to be turbulent. $\endgroup$
    – Paul
    Jun 18, 2016 at 13:02

2 Answers 2


There are a few things to consider.

  1. I would suggest focusing on which BCs are most appropriate for the velocity since pressure is just a constraint and its BCs will follow.

  2. What is the physical situation you are trying to model? Here are some BC scenarios for duct mean pressure gradient-driven flows along the $x$ direction:

A) Very long duct - Fully periodic BCs with many axial cells

$ u_{ghost,inlet} = u_{interior,outlet}, \quad u_{ghost,outlet} = u_{interior,inlet}, \\ p_{ghost,inlet} = p_{interior,outlet}, \quad p_{ghost,outlet} = p_{interior,inlet} $

This models a very long duct. The flow, laminar or turbulent, leaves the exit and re-enters in the entrance. The only condition on this BC is that the duct must be longer (usually a few times longer) than the largest length scale of the flow.

B) Fully developed duct - several BC options for velocity with 1 axial cell A fully developed duct with 1 axial cell can be simulated using several implementations. Consider the following cases

$\text{B.1)} \qquad u_{ghost,inlet} = u_{interior,outlet}, \qquad u_{ghost,outlet} = u_{interior,inlet} \\ \qquad \qquad p_{ghost,in} = p_{interior,outlet}, \qquad p_{ghost,outlet} = p_{interior,inlet} $

$\text{B.2)} \qquad \left. \frac{\partial u}{\partial x} \right|_{inlet} = 0, \qquad \left. \frac{\partial u}{\partial x} \right|_{outlet} = 0 \qquad \left. \frac{\partial p}{\partial x} \right|_{inlet} = 0, \qquad \left. \frac{\partial p}{\partial x} \right|_{inlet} = 0 $

This models a fully developed duct. Both BCs enforce $\partial_x () = 0$ for all variables except pressure, which varies linearly. The mean pressure gradient enters the momentum equation as a source term. Why are the two BCs equivalent? Because there's only one interior axial cell for ghost points to reference.

C) Developing duct - Dirichlet inlet/Neumann outlet velocity BCs with many axial cells

$ u(inlet) = u_{inlet}, \qquad \left. \frac{\partial u}{\partial x} \right|_{outlet} = 0, \qquad \left. \frac{\partial p}{\partial x} \right|_{inlet} = 0, \qquad p_{outlet} = 0 $

This models a developing duct. The outlet is fully developed, and the length of the duct must be longer than the development length.

D) The duct flow you propose - Neumann inlet/Neumann outlet velocity BCs with many axial cells

$ \left. \frac{\partial u}{\partial x} \right|_{inlet} = 0, \qquad \left. \frac{\partial u}{\partial x} \right|_{outlet} = 0, \qquad p(inlet) = p_{inlet}, \qquad p(outlet) = p_{outlet} $

What does this model? The answer is a bit subtle. If the flow is laminar, we expect the same results as in case B) and unchanging along $x$. If the flow is turbulent however, then we have a problem? The inlet BC appears to come from the outlet of a fully developed duct flow, the outlet appears to head towards a fully developed duct flow, and the interior is turbulent. But how could this be? A laminar fully developed duct flow is not likely to become turbulent and return to a laminar state with no intermediate damping mechanisms. Unless there are additional mechanisms that result in the laminarization of the flow after the flow has reached a turbulent state (far from the fully developed inlet), this model is not physically meaningful.

  1. As far as the convergence of the BCs you suggest. You may see convergence if you're in a laminar or, maybe, a transition regime, however, there is no guarantee that you'll see convergence in a turbulent regime for any Reynolds number.

I hope this helps.

  • $\begingroup$ Actaully, D) is not what i proposed. I proposed pure dirichlet conditions in pressure at the inlet & outlet and pure newmann conditions in velocity at the inlet & outlet. $\endgroup$
    – Paul
    Jun 19, 2016 at 14:43
  • $\begingroup$ My apologies about the pressure condition for D). I'll fix this. But my point is that what matters is the velocity BC, the pressure BCs should follow. Dirichlet BCs for pressure, along with fully developed BCs for velocity, are not going to change my explanation about the physics. $\endgroup$
    – Charles
    Jun 19, 2016 at 15:18

Which method are you using? FEM, FVM, FDM, other?

In FEM, at least, when you impose velocity inlet, you leave pressure field (not the pressure gradient) untouched.

For the pressure outlet, if you only set pressure, you are automatically assuming that the normal component of the velocity gradient at the outlet is zero [1], which is not wrong if the pipe is straight and if your pressure is "well-behaved" (e.g., no backflow, recirculation - otherwise you need extra terms in your variational formulation to handle it [2]).

What do you mean by "stable solution"?

[1] "Efficient Solvers for Incompressible Flow Problems" Turek (1999) has a very interesting discussion about hidden boundary conditions.

[2] e.g. "A comparison of outlet boundary treatments for prevention of backflow divergence with relevance to blood flow simulations" Moghadam et al (2011).

  • $\begingroup$ Not touching the pressure is exactly equivalent to applying a zero Neumann (i.e. normal gradient) condition under most FEM implementations, after all how can you tell if a surface flux term that's equal to zero is there or not? $\endgroup$
    – origimbo
    Jun 17, 2016 at 21:01
  • $\begingroup$ I agree the equivalence holds if your boundary is Neumann, but do you mean it also holds if it is Dirichlet (imposition of velocity inlet, in our case)? $\endgroup$ Jun 18, 2016 at 8:06

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.