3D Seq MultiGrid complete
This commit is contained in:
@@ -15,7 +15,7 @@ bcRight 3 #
|
||||
gx 0.0 # Body forces (e.g. gravity)
|
||||
gy 0.0 #
|
||||
|
||||
re 7500.0 # Reynolds number
|
||||
re 36500.0 # Reynolds number
|
||||
|
||||
u_init 1.0 # initial value for velocity in x-direction
|
||||
v_init 0.0 # initial value for velocity in y-direction
|
||||
@@ -32,7 +32,7 @@ jmax 45 # number of interior cells in y-direction
|
||||
# Time Data:
|
||||
# ---------
|
||||
|
||||
te 100.0 # final time
|
||||
te 60.0 # final time
|
||||
dt 0.02 # time stepsize
|
||||
tau 0.5 # safety factor for time stepsize control (<0 constant delt)
|
||||
|
||||
@@ -44,7 +44,6 @@ eps 0.0001 # stopping tolerance for pressure iteration
|
||||
rho 0.52
|
||||
omg 1.8 # relaxation parameter for SOR iteration
|
||||
gamma 0.9 # upwind differencing factor gamma
|
||||
levels 5 # Multigrid levels
|
||||
|
||||
# Particle Tracing Data:
|
||||
# -----------------------
|
||||
@@ -66,8 +65,8 @@ y2 1.5
|
||||
shape 1
|
||||
xCenter 0.0
|
||||
yCenter 0.0
|
||||
xRectLength 1.0
|
||||
yRectLength 2.0
|
||||
xRectLength 2.0
|
||||
yRectLength 1.0
|
||||
circleRadius 1.0
|
||||
|
||||
#===============================================================================
|
||||
|
@@ -50,7 +50,7 @@ levels 5 # Multigrid levels
|
||||
# -----------------------
|
||||
|
||||
numberOfParticles 200
|
||||
startTime 0
|
||||
startTime 100
|
||||
injectTimePeriod 0.5
|
||||
writeTimePeriod 0.2
|
||||
|
||||
|
Binary file not shown.
Before Width: | Height: | Size: 30 KiB After Width: | Height: | Size: 25 KiB |
File diff suppressed because it is too large
Load Diff
@@ -201,23 +201,6 @@ void initSolver(Solver* solver, Parameter* params)
|
||||
if (params->shape != NOSHAPE) {
|
||||
for (int j = 1; j < jmax + 1; j++) {
|
||||
for (int i = 1; i < imax + 1; i++) {
|
||||
// if( S(i+1,j+1) == NONE && S(i+1,j) == NONE && S(i,j+1) == NONE &&
|
||||
// S(i-1,j-1) == LOCAL && S(i,j) == LOCAL ) S(i,j) = BOTTOMRIGHT; else if(
|
||||
// S(i-1,j+1) == NONE && S(i-1,j) == NONE && S(i,j+1) == NONE &&
|
||||
// S(i+1,j-1) == LOCAL && S(i,j) == LOCAL ) S(i,j) = BOTTOMLEFT; else if(
|
||||
// S(i+1,j-1) == NONE
|
||||
// && S(i,j-1) == NONE && S(i+1,j) == NONE && S(i-1,j+1) == LOCAL &&
|
||||
// S(i,j) == LOCAL ) S(i,j) = TOPRIGHT; else if( S(i-1,j-1) == NONE &&
|
||||
// S(i,j-1) == NONE
|
||||
// && S(i-1,j) == NONE && S(i+1,j+1) == LOCAL && S(i,j) == LOCAL ) S(i,j)
|
||||
// = TOPLEFT; else if( S(i+1,j) == NONE && S(i-1,j) == LOCAL && S(i,j) ==
|
||||
// LOCAL ) S(i,j) = RIGHT; else if( S(i,j+1) == NONE && S(i,j-1) == LOCAL
|
||||
// && S(i,j)
|
||||
// == LOCAL ) S(i,j) = BOTTOM; else if( S(i-1,j) == NONE && S(i+1,j) ==
|
||||
// LOCAL
|
||||
// && S(i,j) == LOCAL ) S(i,j) = LEFT; else if( S(i,j-1) == NONE &&
|
||||
// S(i,j+1)
|
||||
// == LOCAL && S(i,j) == LOCAL ) S(i,j) = TOP;
|
||||
|
||||
if (S(i, j - 1) == NONE && S(i, j + 1) == LOCAL && S(i, j) == LOCAL)
|
||||
S(i, j) = BOTTOM; // TOP
|
||||
|
@@ -49,7 +49,6 @@ typedef struct {
|
||||
extern void initSolver(Solver*, Parameter*);
|
||||
extern void computeRHS(Solver*);
|
||||
extern double smoothRB(Solver*);
|
||||
extern void residualRB(Solver*);
|
||||
extern void restrictMG(Solver*);
|
||||
extern void prolongate(Solver*);
|
||||
extern void correct(Solver*);
|
||||
|
File diff suppressed because it is too large
Load Diff
Binary file not shown.
Before Width: | Height: | Size: 364 KiB After Width: | Height: | Size: 117 KiB |
Reference in New Issue
Block a user