Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

paddle #500

Merged
merged 1 commit into from
Aug 5, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
40 changes: 40 additions & 0 deletions examples/dfLowMachFoam/paddle/oneD_freelyPropagation/C2H4/0/U
Original file line number Diff line number Diff line change
@@ -0,0 +1,40 @@
/*--------------------------------*- C++ -*----------------------------------*\
========= |
\\ / F ield | OpenFOAM: The Open Source CFD Toolbox
\\ / O peration | Website: https://openfoam.org
\\ / A nd | Version: 7
\\/ M anipulation |
\*---------------------------------------------------------------------------*/
FoamFile
{
version 2.0;
format ascii;
class volVectorField;
location "0";
object U;
}
// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //

dimensions [0 1 -1 0 0 0 0];

internalField uniform (1.62 0 0);

boundaryField
{
boundary
{
type empty;
}
inlet
{
type fixedValue;
value uniform (1.62 0 0);
}
outlet
{
type zeroGradient;
}
}


// ************************************************************************* //
Original file line number Diff line number Diff line change
@@ -0,0 +1,40 @@
/*--------------------------------*- C++ -*----------------------------------*\
========= |
\\ / F ield | OpenFOAM: The Open Source CFD Toolbox
\\ / O peration | Website: https://openfoam.org
\\ / A nd | Version: 7
\\/ M anipulation |
\*---------------------------------------------------------------------------*/
FoamFile
{
version 2.0;
format ascii;
class volScalarField;
location "0";
object Ydefault;
}
// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //

dimensions [0 0 0 0 0 0 0];

internalField uniform 0;

boundaryField
{
boundary
{
type empty;
}
inlet
{
type fixedValue;
value uniform 0;
}
outlet
{
type zeroGradient;
}
}


// ************************************************************************* //
41 changes: 41 additions & 0 deletions examples/dfLowMachFoam/paddle/oneD_freelyPropagation/C2H4/0/p
Original file line number Diff line number Diff line change
@@ -0,0 +1,41 @@
/*--------------------------------*- C++ -*----------------------------------*\
========= |
\\ / F ield | OpenFOAM: The Open Source CFD Toolbox
\\ / O peration | Website: https://openfoam.org
\\ / A nd | Version: 7
\\/ M anipulation |
\*---------------------------------------------------------------------------*/
FoamFile
{
version 2.0;
format ascii;
class volScalarField;
location "0";
object p;
}
// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //

dimensions [1 -1 -2 0 0 0 0];

internalField uniform 101325;

boundaryField
{
boundary
{
type empty;
}
inlet
{
type zeroGradient;
}
outlet
{
type waveTransmissive;
gamma 1.4;
value uniform 101325;
}
}


// ************************************************************************* //
Original file line number Diff line number Diff line change
@@ -0,0 +1,9 @@
#!/bin/sh
cd ${0%/*} || exit 1 # Run from this directory

echo "Cleaning log.*"
rm log.*
echo "Cleaning processor*"
rm -r processor*
echo "Cleaning polyMesh/"
rm -r constant/polyMesh
22 changes: 22 additions & 0 deletions examples/dfLowMachFoam/paddle/oneD_freelyPropagation/C2H4/Allrun
Original file line number Diff line number Diff line change
@@ -0,0 +1,22 @@
#!/bin/sh
cd ${0%/*} || exit 1 # Run from this directory

if [ -e DNN_model.pt ]
then
echo "DNN_model.pt exists. Make sure correct DNN model has been used!"
else
echo "DNN_model.pt not exist. Downloading ..."
wget https://store.aissquare.com/models/5e1232cd-c23f-489f-9db4-ee09592beeb1/DNN_model.zip
unzip DNN_model.zip
cp ./DNN_model/C2H4/DNN_model.pt .
cp ./DNN_model/C2H4/Wu24sp.yaml .
fi

# Source tutorial run functions
. $WM_PROJECT_DIR/bin/tools/RunFunctions

application=dfLowMachFoam

runApplication blockMesh
runApplication decomposePar
runApplication mpirun -np 4 --allow-run-as-root $application -parallel
Original file line number Diff line number Diff line change
@@ -0,0 +1,53 @@
/*--------------------------------*- C++ -*----------------------------------*\
========= |
\\ / F ield | OpenFOAM: The Open Source CFD Toolbox
\\ / O peration | Website: https://openfoam.org
\\ / A nd | Version: 7
\\/ M anipulation |
\*---------------------------------------------------------------------------*/
FoamFile
{
version 2.0;
format ascii;
class dictionary;
location "constant";
object CanteraTorchProperties;
}
// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //

chemistry on;

CanteraMechanismFile "Wu24sp.yaml";

transportModel "Mix";

odeCoeffs
{
"relTol" 1e-6;
"absTol" 1e-10;
}

inertSpecie "N2";

splittingStrategy off;

TorchSettings
{
torch on;
GPU on;
log on;
torchModel "DNN_model.pt";
frozenTemperature 510;
inferenceDeltaTime 1e-7;
coresPerNode 4;
}

loadbalancing
{
active true;
log false;
algorithm allAverage;//headTail;
}


// ************************************************************************* //
Original file line number Diff line number Diff line change
@@ -0,0 +1,20 @@
/*--------------------------------*- C++ -*----------------------------------*\
========= |
\\ / F ield | OpenFOAM: The Open Source CFD Toolbox
\\ / O peration | Website: https://openfoam.org
\\ / A nd | Version: 7
\\/ M anipulation |
\*---------------------------------------------------------------------------*/
FoamFile
{
version 2.0;
format ascii;
class dictionary;
location "constant";
object combustionProperties;
}
// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //

combustionModel laminar;

// ************************************************************************* //
Original file line number Diff line number Diff line change
@@ -0,0 +1,18 @@
/*--------------------------------*- C++ -*----------------------------------*\
========= |
\\ / F ield | OpenFOAM: The Open Source CFD Toolbox
\\ / O peration | Website: https://openfoam.org
\\ / A nd | Version: 7
\\/ M anipulation |
\*---------------------------------------------------------------------------*/
FoamFile
{
version 2.0;
format ascii;
class dictionary;
location "constant";
object thermophysicalProperties;
}
// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //

// ************************************************************************* //
Original file line number Diff line number Diff line change
@@ -0,0 +1,21 @@
/*--------------------------------*- C++ -*----------------------------------*\
========= |
\\ / F ield | OpenFOAM: The Open Source CFD Toolbox
\\ / O peration | Website: https://openfoam.org
\\ / A nd | Version: 7
\\/ M anipulation |
\*---------------------------------------------------------------------------*/
FoamFile
{
version 2.0;
format ascii;
class dictionary;
location "constant";
object turbulenceProperties;
}
// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //

simulationType laminar;


// ************************************************************************* //
Loading
Loading