Completed porting, fixing bugs and testing
This commit is contained in:
@@ -41,7 +41,7 @@ tau 0.5 # safety factor for time stepsize control (<0 constant delt)
|
||||
|
||||
itermax 500 # maximal number of pressure iteration in one time step
|
||||
eps 0.00001 # stopping tolerance for pressure iteration
|
||||
rho 0.9999
|
||||
rho 0.52
|
||||
omg 1.8 # relaxation parameter for SOR iteration
|
||||
gamma 0.9 # upwind differencing factor gamma
|
||||
#===============================================================================
|
||||
|
@@ -1,5 +1,5 @@
|
||||
# Supported: GCC, CLANG, ICC
|
||||
TAG ?= CLANG
|
||||
TAG ?= ICC
|
||||
ENABLE_OPENMP ?= false
|
||||
|
||||
#Feature options
|
||||
|
@@ -41,7 +41,7 @@ tau 0.5 # safety factor for time stepsize control (<0 constant delt)
|
||||
|
||||
itermax 1000 # maximal number of pressure iteration in one time step
|
||||
eps 0.001 # stopping tolerance for pressure iteration
|
||||
rho 0.9999
|
||||
rho 0.5
|
||||
omg 1.7 # relaxation parameter for SOR iteration
|
||||
gamma 0.9 # upwind differencing factor gamma
|
||||
#===============================================================================
|
||||
|
File diff suppressed because it is too large
Load Diff
@@ -72,16 +72,10 @@ int main (int argc, char** argv)
|
||||
solve(&solver);
|
||||
adaptUV(&solver);
|
||||
t += solver.dt;
|
||||
|
||||
#ifdef VERBOSE
|
||||
if (rank == 0) {
|
||||
printf("TIME %f , TIMESTEP %f\n", t, solver.dt);
|
||||
}
|
||||
#else
|
||||
printProgress(t);
|
||||
#endif
|
||||
}
|
||||
|
||||
break;
|
||||
|
||||
case RB:
|
||||
printf("Red-black SOR\n");
|
||||
while (t <= te) {
|
||||
@@ -96,16 +90,10 @@ int main (int argc, char** argv)
|
||||
solveRB(&solver);
|
||||
adaptUV(&solver);
|
||||
t += solver.dt;
|
||||
|
||||
#ifdef VERBOSE
|
||||
if (rank == 0) {
|
||||
printf("TIME %f , TIMESTEP %f\n", t, solver.dt);
|
||||
}
|
||||
#else
|
||||
printProgress(t);
|
||||
#endif
|
||||
}
|
||||
|
||||
break;
|
||||
|
||||
case RBA:
|
||||
printf("Red-black SOR with acceleration\n");
|
||||
while (t <= te) {
|
||||
@@ -120,6 +108,10 @@ int main (int argc, char** argv)
|
||||
solveRBA(&solver);
|
||||
adaptUV(&solver);
|
||||
t += solver.dt;
|
||||
}
|
||||
|
||||
break;
|
||||
}
|
||||
|
||||
#ifdef VERBOSE
|
||||
if (rank == 0) {
|
||||
@@ -128,10 +120,6 @@ int main (int argc, char** argv)
|
||||
#else
|
||||
printProgress(t);
|
||||
#endif
|
||||
}
|
||||
break;
|
||||
}
|
||||
|
||||
|
||||
E = getTimeStamp();
|
||||
stopProgress();
|
||||
|
@@ -324,7 +324,7 @@ int solveRBA(Solver* s)
|
||||
double dy2 = s->dy * s->dy;
|
||||
double idx2 = 1.0 / dx2;
|
||||
double idy2 = 1.0 / dy2;
|
||||
double factor = s->omega * 0.5 * (dx2 * dy2) / (dx2 + dy2);
|
||||
double factor = 0.5 * (dx2 * dy2) / (dx2 + dy2);
|
||||
double* p = s->p;
|
||||
double* rhs = s->rhs;
|
||||
double epssq = eps * eps;
|
||||
|
File diff suppressed because it is too large
Load Diff
Binary file not shown.
Before Width: | Height: | Size: 11 KiB After Width: | Height: | Size: 11 KiB |
Reference in New Issue
Block a user