Please help with a fluid solver ^_^

  • Context: Graduate 
  • Thread starter Thread starter jojodi
  • Start date Start date
  • Tags Tags
    Fluid
Click For Summary

Discussion Overview

The discussion revolves around the development of a computational solver for fluid dynamics based on the Navier-Stokes Equations. Participants are addressing challenges related to calculating pressure at a given point in the next frame and the discretization of the equations involved.

Discussion Character

  • Technical explanation
  • Mathematical reasoning
  • Exploratory

Main Points Raised

  • Brandon expresses difficulty in calculating pressure at a given point for the next frame in his fluid dynamics solver.
  • Brandon has derived the finite difference form of the Navier-Stokes equations but acknowledges potential mistakes in his discretization.
  • Brandon provides a specific form of the Navier-Stokes equation and its discretized version, indicating uncertainty about the correctness of his approach.
  • Another participant suggests moving the discussion to a math-focused area and encourages sharing the discretized equations to foster conversation.

Areas of Agreement / Disagreement

Participants have not reached a consensus, and there are indications of uncertainty regarding the correctness of the equations and the discretization process.

Contextual Notes

Brandon's equations may contain mistakes, and there is a lack of clarity on the order of operations used in his derivations. The discussion does not resolve these issues.

jojodi
Messages
3
Reaction score
0
I've been working for the last month trying to figure this out.
I am trying to produce a computational solver for fluid dynamics based on the Navier-Stokes Equations. I have derived the finite difference form of all the terms and worked out the operators, but I have been unable in finding any way to claculate the pressure at a given point in the next frame. If someone could explain or possibly show me some pseudo-code to the procedure, I would be appreciative.

Thanks in Advance,
Brandon
 
Physics news on Phys.org
hmmm.. bump?
 
I'll move this over to math perhaps someone there can help out.

Meanwhile, if you posted what you have for the discretized equations it may spur some conversation.
 
The equations for Navier-Stokes that I have been working on also have some problems as well now that I look at them. I assume I am using an incorrect order of operatins.

[tex]\frac{\partial \bold{u}}{\partial t} + \bold{u} \cdot \nabla{\bold{u}} = -\frac{\nabla{P}}{\rho} + \nu\nabla^2\bold{u}[/tex]

Where [tex]\bold{u}[/tex] is the fluid parcel velocity, [tex]\rho[/tex] is the parcel density, and [tex]P[/tex] is the pressure at that point.

I have discretized this (I'm sure with some mistake(s) :smile: ) to...

[tex]\frac{\bold{u}_{t+\delta}-2 \bold{u}_{t}+\bold{u}_{t-\delta}}{\delta t^2} + \bold{u} \cdot<\frac{\partial \bold{u}}{\partial x},\frac{\partial \bold{u}}{\partial y}>= -\frac{<\frac{\partial P}{\partial x},\frac{\partial P}{\partial y}>}{\rho} + \nu({\frac{\partial^2 \bold{u}}{\partial x^2}+\frac{\partial^2 \bold{u}}{\partial y^2}}) \bold{u}[/tex]

then translates to (for the new frame) :

[tex]\bold{u}_{t+\delta}= \delta^2 ( -\frac{<\frac{\partial P}{\partial x},\frac{\partial P}{\partial y}>}{\rho} + \nu({\frac{\partial^2 \bold{u}}{\partial x^2}+\frac{\partial^2 \bold{u}}{\partial y^2}} - <\bold{u}\cdot\frac{\partial \bold{u}}{\partial x},\frac{\partial \bold{u}}{\partial y}>) \bold{u} ) + 2\bold{u}_{t}-\bold{u}_{t-\delta}[/tex]

For each dimension:
(under construction :-p)
[tex]\bold{u}_{x,t+\delta}= \delta^2 ( -\frac{\frac{\partial P}{\partial x}{\rho} + \nu(\frac{\partial^2 \bold{u}}{\partial x^2} + \frac{\partial^2 \bold{u}}{\partial y^2} - \bold{u}\cdot\frac{\partial \bold{u}}{\partial x}) \bold{u} ) + 2\bold{u}_{t}-\bold{u}_{t-\delta}[/tex]
 
Last edited:

Similar threads

  • · Replies 5 ·
Replies
5
Views
5K
  • · Replies 7 ·
Replies
7
Views
3K
Replies
9
Views
4K
  • · Replies 18 ·
Replies
18
Views
3K
  • · Replies 3 ·
Replies
3
Views
3K
Replies
5
Views
4K
  • · Replies 2 ·
Replies
2
Views
1K
Replies
4
Views
3K
  • · Replies 1 ·
Replies
1
Views
2K
  • · Replies 1 ·
Replies
1
Views
4K