You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: readme.md
+27Lines changed: 27 additions & 0 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -4,6 +4,33 @@
4
4
5
5
This MATLAB code implements a mesh-free method to solve the incompressible Navier-Stokes equations for flow around a cylinder using Polyharmonic Spline Radial Basis Functions (PHS-RBF). The approach uses a staggered grid formulation and a fractional step method for time integration.
6
6
7
+
### How to Run the Code
8
+
9
+
1.**Requirements**:
10
+
- MATLAB (the code has been tested on MATLAB R2019b and newer versions)
11
+
- No additional toolboxes are required
12
+
13
+
2.**Running the Simulation**:
14
+
- Open MATLAB and navigate to the repository directory
15
+
- Run the main script by typing `cylinder` in the MATLAB command window
16
+
- Alternatively, open `cylinder.m` in the MATLAB editor and click the "Run" button
17
+
18
+
3.**What to Expect**:
19
+
- The script will generate a mesh for the flow domain
20
+
- Set up the differentiation matrices using RBF-FD
21
+
- Run the time-stepping loop for 5000 iterations (by default)
22
+
- Display the final velocity field as scatter plots showing the u and v components
23
+
24
+
4.**Modifying Simulation Parameters**:
25
+
- Reynolds number: Look for the variable `nu` in `cylinder.m` (currently set to 1/100)
26
+
- Time step: Look for the variable `dt` in `cylinder.m` (currently set to 1e-2)
27
+
- Number of time steps: Look for the variable `Nt` in `cylinder.m` (currently set to 5000)
28
+
- These parameters are defined in the simulation setup section of the code
29
+
30
+
5.**Computational Requirements**:
31
+
- The simulation is computationally intensive and may take time to complete
32
+
- For a full simulation with 5000 time steps, expect several minutes of computation time depending on your hardware
0 commit comments