Navier-Stokes Problem: Solving for Pressure Gradient in a 2D Rectangular Cavity

So in summary, the conversation is about a rectangular cavity filled with liquid, where the top plate moves with a velocity V0 and the flow is roughly 1-dimensional. The velocity profile is computed using the Navier-Stokes equation, and the equation for the pressure gradient is reduced to a simpler form. To find the pressure gradient, the net flow rate is assumed to be zero since no flow enters or leaves the cavity. The conversation then discusses the possibility of including the y-velocity component, which would require 5 conditions to be met. It is mentioned that the pressure gradients are significant in this problem and that they play a role in driving the flow. Finally, the question is raised about how to know when to include pressure in the analysis.
  • #1
member 428835
Hi PF!

Assume we have a rectangular cavity (2D) filled with a liquid of dimensions ##L \times H## and that the top plate of the cavity moves with some velocity ##V_0##. Also assume ##L \gg H##. I'll also assume ##L \gg H## implies flow is roughly 1-dimensional, and thus a pressure gradient drives the flow near the still wall in the opposite direction rather than the ##y## component that would "bounce" off the vertical cavity walls. When computing the velocity profile, from the Navier-Stokes equation I get $$v_x \frac{\partial v_x}{\partial x} = -\frac{\partial P}{\partial x} + \mu \frac{\partial^2 v_x}{\partial y^2} + \mu \frac{\partial^2 v_x}{\partial x^2}$$ subject to ##v_x(0) = v_0## and ##v_x(H) = 0##, where I assume the flow is fully developed and steady so ##v_x = f(y)##. Notice now the equation reduces to $$\frac{d P}{d x} = \mu \frac{d^2 v_x}{d y^2}$$

Clearly all we now must do is solve for the pressure gradient since the boundary conditions determine the two integration constants. To find this, I imagine the net flow rate must be zero since no flow enters or leaves. Thus $$\frac{1}{HL} \int_0^L \int_0^H \, v_x dy \, dx = 0$$. Then we should be able to solve for ##\frac{d P}{d x}##.

Does this look right to you? Thanks for your time!
 
Engineering news on Phys.org
  • #2
Do you mind drawing a picture? I am not sure if I follow your description of the geometry completely.
 
  • #3
joshmccraney said:
Hi PF!

Assume we have a rectangular cavity (2D) filled with a liquid of dimensions ##L \times H## and that the top plate of the cavity moves with some velocity ##V_0##. Also assume ##L \gg H##. I'll also assume ##L \gg H## implies flow is roughly 1-dimensional, and thus a pressure gradient drives the flow near the still wall in the opposite direction rather than the ##y## component that would "bounce" off the vertical cavity walls. When computing the velocity profile, from the Navier-Stokes equation I get $$v_x \frac{\partial v_x}{\partial x} = -\frac{\partial P}{\partial x} + \mu \frac{\partial^2 v_x}{\partial y^2} + \mu \frac{\partial^2 v_x}{\partial x^2}$$ subject to ##v_x(0) = v_0## and ##v_x(H) = 0##, where I assume the flow is fully developed and steady so ##v_x = f(y)##. Notice now the equation reduces to $$\frac{d P}{d x} = \mu \frac{d^2 v_x}{d y^2}$$

Clearly all we now must do is solve for the pressure gradient since the boundary conditions determine the two integration constants. To find this, I imagine the net flow rate must be zero since no flow enters or leaves. Thus $$\frac{1}{HL} \int_0^L \int_0^H \, v_x dy \, dx = 0$$. Then we should be able to solve for ##\frac{d P}{d x}##.

Does this look right to you? Thanks for your time!
This looks really good. This is the kind of flow that exists within the flights of screw pumps and screw extruders. See the book Processing of Thermoplastic Materials by Ernest Bernhardt
 
Last edited:
  • #4
boneh3ad said:
Do you mind drawing a picture? I am not sure if I follow your description of the geometry completely.
I've attached a rough sketch. I can add detail if necessary.

Chestermiller said:
This looks really good. This is the kind of flow that exists within the flights of screw pumps and screw extruders. See the book Processing of Thermoplastic Materials by Ernest Bernhardt
Thanks! I'll have to check this out. So you agree with the integral constraint?
 

Attachments

  • cavity.pdf
    23.1 KB · Views: 226
  • #5
joshmccraney said:
I've attached a rough sketch. I can add detail if necessary.Thanks! I'll have to check this out. So you agree with the integral constraint?
Yes.
 
  • #6
Chestermiller said:
Yes.
Cool. So if we weren't to assume that ##y## velocity was negligible, would our equations be $$\rho\left( v_x\frac{\partial v_x}{\partial x} + v_y \frac{\partial v_x}{\partial y} \right) = \mu \frac{\partial^2 v_x}{\partial y^2}\\ \rho\left( v_x\frac{\partial v_y}{\partial x} + v_y \frac{\partial v_y}{\partial y} \right) = \mu \frac{\partial^2 v_y}{\partial y^2} + \rho g$$ where the pressure gradient is gone since it no longer drives flow. Boundary conditions would be all velocities equal zero along all walls except the top moving wall, where ##v_x=v_0##. The integral constraint holds as well, but this time for both velocity components.

But then we have 5 conditions to meet (the four boundaries plus the integral constraint). This now seems over specified. Any ideas?
 
  • #7
joshmccraney said:
Cool. So if we weren't to assume that ##y## velocity was negligible, would our equations be $$\rho\left( v_x\frac{\partial v_x}{\partial x} + v_y \frac{\partial v_x}{\partial y} \right) = \mu \frac{\partial^2 v_x}{\partial y^2}\\ \rho\left( v_x\frac{\partial v_y}{\partial x} + v_y \frac{\partial v_y}{\partial y} \right) = \mu \frac{\partial^2 v_y}{\partial y^2} + \rho g$$ where the pressure gradient is gone since it no longer drives flow. Boundary conditions would be all velocities equal zero along all walls except the top moving wall, where ##v_x=v_0##. The integral constraint holds as well, but this time for both velocity components.

But then we have 5 conditions to meet (the four boundaries plus the integral constraint). This now seems over specified. Any ideas?
The pressure gradients are not zero. They are significant.
 
  • #8
Chestermiller said:
The pressure gradients are not zero. They are significant.
Ok, so then this problem is solvable, since we have the unknown pressure gradient vector and the integral constraint over the velocity vector.

Pressure to me is not intuitive; how would I know to include it in this analysis? I knew it was relevant in the first (simpler) part since something had to drive flow backwards.
 
  • #9
joshmccraney said:
Ok, so then this problem is solvable, since we have the unknown pressure gradient vector and the integral constraint over the velocity vector.
You don't use the integral constraint on this. The velocity components on all 4 boundaries are zero.
Pressure to me is not intuitive; how would I know to include it in this analysis?
You are asking how to solve the equations for the 2D version, including the pressure gradients?
 
  • #10
Chestermiller said:
You don't use the integral constraint on this. The velocity components on all 4 boundaries are zero.
Why wouldn't we use the integral constraint? Also, the velocity is zero everywhere except the moving side, right?

Chestermiller said:
You are asking how to solve the equations for the 2D version, including the pressure gradients?
No, I think I understand how to handle the math once it's there. The difficulty is setting up the equation, and in this instance, why the pressure gradient is even there.
 
  • #11
Hey Chet, did you forget about me? :frown:
 
  • #12
joshmccraney said:
Ok, so then this problem is solvable, since we have the unknown pressure gradient vector and the integral constraint over the velocity vector.

Pressure to me is not intuitive; how would I know to include it in this analysis? I knew it was relevant in the first (simpler) part since something had to drive flow backwards.
The qualitative nature of the solution does not change when you just make the channel deeper.
 
  • #13
joshmccraney said:
Why wouldn't we use the integral constraint?
It is automatically satisfied when you satisfy the boundary conditions on the edge faces.
Also, the velocity is zero everywhere except the moving side, right?
yes.
No, I think I understand how to handle the math once it's there. The difficulty is setting up the equation, and in this instance, why the pressure gradient is even there.
The thing to do on this problem is to first consider the case where the inertial forces are very low, so that they can be neglected. That is, at very low Reynolds number. If you can't solve it for this (linear) case, you'll never be able to solve for the case where inertia is included (non-linear case). What are your equations in the case where inertia is neglected?
 
  • #14
Chestermiller said:
What are your equations in the case where inertia is neglected?
I believe we have two, one for each velocity component. Let's say ##u## is velocity in ##x-##direction and ##v## is velocity in ##y##-direction. Then we have $$\frac{\partial P}{\partial x} = \mu \left( \frac{\partial^2 u}{\partial y^2}+\frac{\partial^2 u}{\partial x^2} \right)\\
\frac{\partial P}{\partial y} = \mu \left( \frac{\partial^2 v}{\partial y^2}+\frac{\partial^2 v}{\partial x^2} \right)$$
I believe both derivatives on the right hand side are relevant since we are not assuming ##y \ll x##, which invalidates the scaling argument. I am neglecting gravity though.

Does this look right to you?
 
  • #15
joshmccraney said:
I believe we have two, one for each velocity component. Let's say ##u## is velocity in ##x-##direction and ##v## is velocity in ##y##-direction. Then we have $$\frac{\partial P}{\partial x} = \mu \left( \frac{\partial^2 u}{\partial y^2}+\frac{\partial^2 u}{\partial x^2} \right)\\
\frac{\partial P}{\partial y} = \mu \left( \frac{\partial^2 v}{\partial y^2}+\frac{\partial^2 v}{\partial x^2} \right)$$
I believe both derivatives on the right hand side are relevant since we are not assuming ##y \ll x##, which invalidates the scaling argument. I am neglecting gravity though.

Does this look right to you?
Yes. Now, in addition to these, you have the continuity equation. Please include that.
 
  • #16
Chestermiller said:
Yes. Now, in addition to these, you have the continuity equation. Please include that.
Of course! That's $$\frac{\partial u}{\partial x}+\frac{\partial v}{\partial y}=0$$Boundary conditions are no slip on the four walls, which implies velocity is zero along the cavity except the top wall, where ##u=U_0## which is the speed of the top shelf.

So we have three equations and three unknowns (##P,u,v##). We have 8 boundary conditions (4 for ##u## and 4 for ##v##, each evaluated along the wall.
 
  • #17
joshmccraney said:
Of course! That's $$\frac{\partial u}{\partial x}+\frac{\partial v}{\partial y}=0$$Boundary conditions are no slip on the four walls, which implies velocity is zero along the cavity except the top wall, where ##u=U_0## which is the speed of the top shelf.

So we have three equations and three unknowns (##P,u,v##). We have 8 boundary conditions (4 for ##u## and 4 for ##v##, each evaluated along the wall.
Here's a way of proceeding further with this problem: Define a stream function ##\psi## for the flow as follows:
$$u=\frac{\partial \psi}{\partial y}$$
$$v=-\frac{\partial \psi}{\partial x}$$
These equations satisfy the continuity equation exactly. What do you get if you substitute them into your two differential equations?

What do you think the streamline pattern looks like for this flow? The streamlines are the lines of constant ##\psi##.
 
  • #18
Chestermiller said:
Here's a way of proceeding further with this problem: Define a stream function ##\psi## for the flow as follows:
$$u=\frac{\partial \psi}{\partial y}$$
$$v=-\frac{\partial \psi}{\partial x}$$
These equations satisfy the continuity equation exactly. What do you get if you substitute them into your two differential equations?

What do you think the streamline pattern looks like for this flow? The streamlines are the lines of constant ##\psi##.

Oh yea, the stream function ##\psi \equiv \nabla \times \vec{v}##. Plugging these in yields third derivatives and mixed partials of ##\psi##.

$$\frac{\partial P}{\partial x} = \mu \left( \frac{\partial^3 \psi}{\partial y^3}+\frac{\partial^3 \psi}{\partial x^2 \partial y} \right)\\
\frac{\partial P}{\partial y} = -\mu \left( \frac{\partial^3 \psi}{\partial y^2 \partial x}+\frac{\partial^3 \psi}{\partial x^3} \right)$$

I have no idea what they look like? Maybe a circle roughly?
 
  • #19
joshmccraney said:
Oh yea, the stream function ##\psi \equiv \nabla \times \vec{v}##. Plugging these in yields third derivatives and mixed partials of ##\psi##.

$$\frac{\partial P}{\partial x} = \mu \left( \frac{\partial^3 \psi}{\partial y^3}+\frac{\partial^3 \psi}{\partial x^2 \partial y} \right)\\
\frac{\partial P}{\partial y} = -\mu \left( \frac{\partial^3 \psi}{\partial y^2 \partial x}+\frac{\partial^3 \psi}{\partial x^3} \right)$$
Good. Now take the partial derivative of the first equation with respect to y and subtract the partial derivative of the second equation with respect to x. What do you get?
I have no idea what they look like? Maybe a circle roughly?
Very good. So you envision that there will be a recirculating flow in the cavity, and the streamlines will each be closed.
 
  • #20
Chestermiller said:
Good. Now take the partial derivative of the first equation with respect to y and subtract the partial derivative of the second equation with respect to x. What do you get?

$$\frac{\partial^4 \psi}{\partial x^4} + \frac{\partial^4 \psi}{\partial y^4}+2\frac{\partial^4 \psi}{\partial x^2 \partial y^2}=0$$

which I believe is separable. I've worked with similar equations before, where separability exists but was unusual. The mixed partial evokes such equations. Letting ##\psi = X(x)Y(y)## implies $$\frac{d_x^4X}{X}+ \frac{d_y^4 Y}{Y}+2 \frac{X''Y''}{XY}=0$$
Hmmmmm tricks that have worked in the past fail now. Any ideas? By inspection sines and cosines would all differentiate back to original functions. Perhaps a good ansatz is to let ##X=\sin(ax)## or ##X=\cos(ax)## and ##Y=\sin(cy)## or ##Y=\cos(cy)##. Then we have an algebraic expression that behaves like ##a^4+c^4+2c^2c^2=0##. Quadratic formula could be used to represent one in terms of the other, but before continuing does this idea look right to you?

Another option is to let ##Y## and ##X## be linear functions. And rethinking the above, exponentials would be easier to work with than trig, but trig stood out first.
 
Last edited by a moderator:
  • #21
joshmccraney said:
$$\frac{\partial^4 \psi}{\partial x^4} + \frac{\partial^4 \psi}{\partial y^4}+2\frac{\partial^4 \psi}{\partial x^2 \partial y^2}=0$$
This is called the biharmonic equation. It can also be expressed as $$\nabla^2 (\nabla^2 \psi )=0$$
which I believe is separable. I've worked with similar equations before, where separability exists but was unusual. The mixed partial evokes such equations. Letting ##\psi = X(x)Y(y)## implies $$\frac{d_x^4X}{X}+ \frac{d_y^4 Y}{Y}+2 \frac{X''Y''}{XY}=0$$
Hmmmmm tricks that have worked in the past fail now. Any ideas? By inspection sines and cosines would all differentiate back to original functions. Perhaps a good ansatz is to let ##X=\sin(ax)## or ##X=\cos(ax)## and ##Y=\sin(cy)## or ##Y=\cos(cy)##. Then we have an algebraic expression that behaves like ##a^4+c^4+2c^2c^2=0##. Quadratic formula could be used to represent one in terms of the other, but before continuing does this idea look right to you?

Another option is to let ##Y## and ##X## be linear functions. And rethinking the above, exponentials would be easier to work with than trig, but trig stood out first.
I haven't thought of how I would try to approach this analytically. My inclination would be to do it numerically. I would consider writing the equation in terms of two variables:
$$\nabla^2 \psi=\omega$$
$$\nabla^2\omega = 0$$
Before trying to figure out a method of solving however, I think you should figure out the boundary conditions on psi or on psi and omega.
 
  • #22
Boundary conditions on ##\psi## are ##\psi_y(x,L) = U_0##, ##\psi_y(x,0) = 0##, ##\psi_y(0,y) = 0##, ##\psi_y(H,y) = 0##
##\psi_x(x,L) = 0##, ##\psi_x(x,0) = 0##, ##\psi_x(0,y) = 0##, ##\psi_x(H,y) = 0##.

I don't know what the boundary conditions on ##\omega## would be. Just because the derivatives are zero at particular locations doesn't mean the second derivatives are, so I'm stumped. Any ideas?
 
  • #23
joshmccraney said:
Boundary conditions on ##\psi## are ##\psi_y(x,L) = U_0##, ##\psi_y(x,0) = 0##, ##\psi_y(0,y) = 0##, ##\psi_y(H,y) = 0##
##\psi_x(x,L) = 0##, ##\psi_x(x,0) = 0##, ##\psi_x(0,y) = 0##, ##\psi_x(H,y) = 0##.

I don't know what the boundary conditions on ##\omega## would be. Just because the derivatives are zero at particular locations doesn't mean the second derivatives are, so I'm stumped. Any ideas?
I think you have L and H switched.
 
  • #24
Chestermiller said:
I think you have L and H switched.
Oh gosh, what a dumb mistake. Yes, of course, here are the actual boundary conditions:
##\psi_y(x,H) = U_0##, ##\psi_y(x,0) = 0##, ##\psi_y(0,y) = 0##, ##\psi_y(L,y) = 0##
##\psi_x(x,H) = 0##, ##\psi_x(x,0) = 0##, ##\psi_x(0,y) = 0##, ##\psi_x(L,y) = 0##.
 
  • #25
joshmccraney said:
Oh gosh, what a dumb mistake. Yes, of course, here are the actual boundary conditions:
##\psi_y(x,H) = U_0##, ##\psi_y(x,0) = 0##, ##\psi_y(0,y) = 0##, ##\psi_y(L,y) = 0##
##\psi_x(x,H) = 0##, ##\psi_x(x,0) = 0##, ##\psi_x(0,y) = 0##, ##\psi_x(L,y) = 0##.
You can replace the last 4 boundary conditions with an arbitrary constant value for psi, like ##\psi =0##, since the outer boundary is a streamline, and the stream function is constant on a streamline.

Doing this problem numerically, I know how I would proceed. I haven't tried figuring out how I would proceed analytically. But, certainly, since omega satisfies Laplace's equation, this is where I would start.
 
  • #26
Chestermiller said:
You can replace the last 4 boundary conditions with an arbitrary constant value for psi, like ##\psi =0##, since the outer boundary is a streamline, and the stream function is constant on a streamline.
So you're saying ##\psi = 0## along the outer boundary? How did you select 0? I know if I were doing this I wouldn't know what constant to select.

Chestermiller said:
Doing this problem numerically, I know how I would proceed. I haven't tried figuring out how I would proceed analytically. But, certainly, since omega satisfies Laplace's equation, this is where I would start.
So how would we solve ##\nabla^2 \omega =0## without boundary conditions on ##\omega##?
 
  • #27
joshmccraney said:
So you're saying ##\psi = 0## along the outer boundary? How did you select 0? I know if I were doing this I wouldn't know what constant to select.
It doesn't matter what value is used. I just chose 0 because it's easier to work with.

So how would we solve ##\nabla^2 \omega =0## without boundary conditions on ##\omega##?[/QUOTE]
I would start out by writing a general analytic solution down for omega, starting from X(x)Y(y), and getting it in terms of constants A, B, C, and D. Then I would substitute that into the Poisson equation for psi, ending up with additional constants.
 
  • #28
Chestermiller said:
It doesn't matter what value is used. I just chose 0 because it's easier to work with.
I'm with you here, but how would I know it doesn't matter?

Chestermiller said:
I would start out by writing a general analytic solution down for omega, starting from X(x)Y(y), and getting it in terms of constants A, B, C, and D. Then I would substitute that into the Poisson equation for psi, ending up with additional constants.
So I arrive at $$\omega(x,y) = Ae^{\sqrt{\lambda}y}+Be^{-\sqrt{\lambda}y}+Ce^{\sqrt{-\lambda}x}+De^{-\sqrt{-\lambda}x}:\lambda \in \mathbb{R}$$ You agree so far? (As an aside, I always assume the separation constant is real; is it ever not? This is definitely off task, but I'm curious if you've seen it?)
 
  • #29
joshmccraney said:
I'm with you here, but how would I know it doesn't matter?So I arrive at $$\omega(x,y) = Ae^{\sqrt{\lambda}y}+Be^{-\sqrt{\lambda}y}+Ce^{\sqrt{-\lambda}x}+De^{-\sqrt{-\lambda}x}:\lambda \in \mathbb{R}$$ You agree so far? (As an aside, I always assume the separation constant is real; is it ever not? This is definitely off task, but I'm curious if you've seen it?)
This looks OK so far. I don't even know what the term "separation constant" means.

I've never seen this full development, but I'm sure it's been published somewhere. My inclination would have been to solve the problem numerically.

Chet
 
  • #30
Chestermiller said:
This looks OK so far. I don't even know what the term "separation constant" means.
When separating a PDE in ##XY## as you suggested, you have ##Y''/Y=-X''/X = const## which is the separation constant. It seems like we always assume it to be a real number.

Chestermiller said:
I've never seen this full development, but I'm sure it's been published somewhere. My inclination would have been to solve the problem numerically.
Chet
You're probably right, and this is where the equation gets messy anyways, as substituting ##\omega## into ##\nabla^2 \psi = \omega## yields ##X''Y+Y''X = f_1(x) + f_2(y)## which doesn't look separable. Would we let ##\psi(x,y) = \phi(x,y)+g_1(x)+g_2(y) \implies \nabla^2\psi+g_1''(x)+g_2''(y)=f_1(x)+f_2(y)## and then let ##g_1''=f_1## and ##g_2''=f''_2## which yields ##\nabla^2\phi(x,y)=0##?
 
  • #31
I'm having second thoughts on your equation for ##\omega##. Shouldn't it be a function of x times a function of y, not the sum of such functions?

cosh cos, cosh sin, sinh cos, sinh sin
 
  • Like
Likes member 428835
  • #32
Chestermiller said:
I'm having second thoughts on your equation for ##\omega##. Shouldn't it be a function of x times a function of y, not the sum of such functions?

cosh cos, cosh sin, sinh cos, sinh sin

Shoot, you're totally right. Then ##\nabla \cdot \psi = \omega## is not separable. I can't think of a way to analytically solve. How would you do this numerically? Finite difference ##\nabla^4 \psi=0##?
 
  • #33
joshmccraney said:
Shoot, you're totally right. Then ##\nabla \cdot \psi = \omega## is not separable. I can't think of a way to analytically solve. How would you do this numerically? Finite difference ##\nabla^4 \psi=0##?
No. Solve the equations involving both omega and psi. The only tricky part is numerically specifying the boundary conditions on omega. But I know how to do that.
 
  • #34
Yea, how do you do that?
 

1. What is the Navier-Stokes problem?

The Navier-Stokes problem is a set of equations that describe the motion of fluids, such as liquids and gases. It is named after Claude-Louis Navier and George Gabriel Stokes, who developed the equations in the 19th century.

2. What is the significance of solving for pressure gradient in a 2D rectangular cavity?

The pressure gradient in a 2D rectangular cavity is an important parameter in understanding the flow of fluids. It can help predict the behavior of the fluid and is essential in many engineering applications, such as designing pipes and pumps.

3. How is the pressure gradient in a 2D rectangular cavity solved?

The pressure gradient in a 2D rectangular cavity can be solved using numerical methods, such as finite difference or finite element methods. These methods involve dividing the cavity into a grid and solving the Navier-Stokes equations at each point in the grid to calculate the pressure gradient.

4. What are the challenges in solving the Navier-Stokes problem?

The Navier-Stokes problem is a highly complex set of equations and solving them accurately can be computationally intensive. Additionally, the equations are nonlinear, which means that small changes in initial conditions can lead to significant changes in the solution.

5. What are the applications of solving the Navier-Stokes problem?

The Navier-Stokes problem has a wide range of applications in various fields, including engineering, meteorology, and oceanography. It is used to study fluid flow in pipes, pumps, and turbines, as well as weather patterns and ocean currents. The solutions to these equations also help in the design and optimization of various systems and processes.

Similar threads

  • Mechanical Engineering
Replies
4
Views
2K
Replies
1
Views
1K
Replies
6
Views
2K
  • Mechanical Engineering
Replies
1
Views
2K
  • Mechanical Engineering
Replies
3
Views
1K
  • Mechanical Engineering
Replies
18
Views
6K
  • Classical Physics
Replies
4
Views
1K
Replies
18
Views
1K
  • Mechanical Engineering
2
Replies
51
Views
6K
  • Calculus and Beyond Homework Help
Replies
3
Views
877
Back
Top