Solving stokes flow use pde toolbox

35 ビュー (過去 30 日間)
Dominique Gorissen
Dominique Gorissen 2023 年 7 月 13 日
コメント済み: Precise Simulation 2024 年 2 月 22 日
I would like the solve a stokes flow equation using the matlab PDE-toolbox.
and
Using an inital guess for the pressure field, the first equation can be solved using the toolbox. This will then give a solution for u that in general does not fullfill the second equation.
I would like to implement a pressure correction to update the pressure field using the second equation and then solve again until the second equation is fullfilled as well. Can someone help me out on this?
Many thanks!!
  1 件のコメント
Precise Simulation
Precise Simulation 2024 年 2 月 22 日
You can possibly try to using a potential flow solution with correction for the Kutta condition as described here

サインインしてコメントする。

回答 (1 件)

Torsten
Torsten 2023 年 7 月 13 日
編集済み: Torsten 2023 年 7 月 13 日
The (simplified) Navier-Stokes equations need a special numerical treatment and cannot be solved by a general-purpose code like the PDE toolbox.
COMSOL with the fluid dynamics package and ANSYS are the commercial code options, OPENFOAM is a non-commercial alternative.
  2 件のコメント
Dominique Gorissen
Dominique Gorissen 2023 年 7 月 17 日
編集済み: Dominique Gorissen 2023 年 7 月 17 日
Hi Toristen,
I understand you answer, however I do think there is a way to implement it. I should have explained my question more clearly. My idea for implementing is as follows:
  1. make a Pressure array of size 1xNnodes. containing a guess for the pressure in each of the nodes. (this does not have to be the correct pressure just a first guess)
  2. make a function that as input takes: (Pressure array, location.x, location.y, Mesh.nodes) and returns. This function will become the "f" coefficient
  3. apply boundary conditions and parameters a=m=d=0 and c=viscosity
  4. Solve
  5. in each node compute using the "evaluateGradients" function. This should be zero, but since the first guess for the Pressure array is probably incorrect it will not be zero in all nodes. If <0 it means mass is flowing into the node and thus the pressure should be higher there compared to neigbouring nodes. If >0 it means mass is flowing out of the node and thus pressure is to high.
  6. based on results of 4 update the values of the Pressure array and repeat until convergence.
The part that I struggle with is how to implement step 5. I need an algorithm that updates the pressure based on the current values of Pressure and
Torsten
Torsten 2023 年 7 月 17 日
編集済み: Torsten 2023 年 7 月 17 日
Did you read about the many existing pressure-velocity coupling schemes in the literature?
E.g. Chapter 7 of
My advice: Use an existing CFD code for your problem.

サインインしてコメントする。

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!

Translated by