From 94a6f182b6ef423666779b237789c8a8e5e672a3 Mon Sep 17 00:00:00 2001 From: ignis Date: Sun, 11 Nov 2018 05:32:07 +0900 Subject: [PATCH] added job.mpi sbatch script and system/ and constant/ update --- constant/thermophysicalProperties | 4 ++-- job.mpi | 12 ++++++++++++ system/controlDict | 6 ++++-- system/fvOptions | 11 ++++++----- system/fvSchemes | 21 +-------------------- system/fvSolution | 28 +--------------------------- 6 files changed, 26 insertions(+), 56 deletions(-) create mode 100644 job.mpi diff --git a/constant/thermophysicalProperties b/constant/thermophysicalProperties index 63c5209..feaff96 100644 --- a/constant/thermophysicalProperties +++ b/constant/thermophysicalProperties @@ -30,8 +30,8 @@ inertSpecie N2; chemistryReader foamChemistryReader; -foamChemistryFile "$FOAM_CASE/constant/prager/grimech30.foam"; +foamChemistryFile "$FOAM_CASE/constant/mech/methane-air-2step-BFER/reactions"; -foamChemistryThermoFile "$FOAM_CASE/constant/prager/thermo30.foam"; +foamChemistryThermoFile "$FOAM_CASE/constant/mech/methane-air-2step-BFER/thermos"; // ************************************************************************* // diff --git a/job.mpi b/job.mpi new file mode 100644 index 0000000..26688ca --- /dev/null +++ b/job.mpi @@ -0,0 +1,12 @@ +#!/bin/bash + +#SBATCH -J testLaminar # Job name +#SBATCH -o job.%j.out # Name of stdout output file (%j expands to jobId) +#SBATCH -n 100 # Total number of mpi tasks requested +#SBATCH --ntasks-per-node=20 +#SBATCH --mail-user=ignis@postech.ac.kr +#SBATCH --mail-type=ALL + +# Launch MPI-based executable + +prun reactingFoam -parallel diff --git a/system/controlDict b/system/controlDict index 1427149..084defd 100644 --- a/system/controlDict +++ b/system/controlDict @@ -29,7 +29,7 @@ deltaT 1.0e-6; writeControl adjustableRunTime; // clockTime; // timeStep; // -writeInterval 1000; // 10000; // 0.05; // 0.000078; //3600; // +writeInterval 0.05; // 0.000078; //3600; // 1000; // 10000; // purgeWrite 0; @@ -41,11 +41,13 @@ secondaryWriteInterval 501; // 3600; // secondaryPurgeWrite 1; */ +/* secondaryWriteControl clockTime; // timeStep; // secondaryWriteInterval 3000; // 1; secondaryPurgeWrite 2; +*/ writeFormat ascii; @@ -59,7 +61,7 @@ timePrecision 8; runTimeModifiable true; -adjustTimeStep no; +adjustTimeStep yes; maxCo 0.4; diff --git a/system/fvOptions b/system/fvOptions index 7122a9f..8c1505e 100644 --- a/system/fvOptions +++ b/system/fvOptions @@ -18,20 +18,21 @@ FoamFile source1 { type fixedTemperatureConstraint; - active false; + active true; timeStart 0.0; duration 0.1; - selectionMode cellSet; - cellSet ignitionCells; fixedTemperatureConstraintCoeffs { + selectionMode cellSet; + cellSet ignitionCells; + mode uniform; - temperature table + temperature table 2 ( (0 300) - (0.01 2000) + (0.01 2250) ) ; } diff --git a/system/fvSchemes b/system/fvSchemes index c207593..5370070 100644 --- a/system/fvSchemes +++ b/system/fvSchemes @@ -29,26 +29,13 @@ divSchemes { default none; -/* - div(phi,U) Gauss linearUpwindV cellLimited 1; - div(phi,Yi_h) Gauss linearUpwind cellLimited 1; - div(phi,K) Gauss linearUpwind cellLimited 1; - div(phid,p) Gauss linearUpwind cellLimited 1; - div(phi,epsilon) Gauss linearUpwind cellLimited 1; - div(phi,k) Gauss linearUpwind cellLimited 1; - div((muEff*dev2(T(grad(U))))) Gauss linear; - div((interpolate((((De|ng)|Te)*grad(Te)))&S),ne) Gauss linearUpwind cellLimited 1; - div(ve,ne) Gauss linearUpwind cellLimited 1; -*/ div(phi,U) Gauss limitedLinearV 1; div(phi,Yi_h) Gauss limitedLinear 1; div(phi,K) Gauss limitedLinear 1; div(phid,p) Gauss limitedLinear 1; div(phi,epsilon) Gauss limitedLinear 1; div(phi,k) Gauss limitedLinear 1; - div((muEff*dev2(T(grad(U))))) Gauss linear; - div((interpolate((((De|ng)|Te)*grad(Te)))&S),ne) Gauss limitedLinear 1; - div(ve,ne) Gauss limitedLinear 1; + div(((rho*nuEff)*dev2(T(grad(U))))) Gauss linear; } laplacianSchemes @@ -66,11 +53,5 @@ snGradSchemes default orthogonal; } -fluxRequired -{ - default no; - p; -} - // ************************************************************************* // diff --git a/system/fvSolution b/system/fvSolution index df6ab76..41233f4 100644 --- a/system/fvSolution +++ b/system/fvSolution @@ -53,33 +53,7 @@ solvers Yi { - solver smoothSolver; - smoother DILU; - tolerance 1e-6; - relTol 0; - // $hFinal; - } - - ne - { - $Yi; - tolerance 1e-9; - nNeSubCycles 1000; - } - - Phi - { - solver PCG; - preconditioner DIC; - tolerance 1e-08; - relTol 0.2; - } - - PhiFinal - { - $Phi; - tolerance 1e-08; - relTol 0.0; + $hFinal; } }