Skip to content

Commit

Permalink
Add new testcase
Browse files Browse the repository at this point in the history
  • Loading branch information
jibranhaider committed Aug 15, 2019
1 parent 360e871 commit c9a01ca
Show file tree
Hide file tree
Showing 14 changed files with 355,225 additions and 0 deletions.
45 changes: 45 additions & 0 deletions tutorials/solidFoam/stent/0/lmN
Original file line number Diff line number Diff line change
@@ -0,0 +1,45 @@
/*--------------------------------*- C++ -*----------------------------------*\
========= |
\\ / F ield | OpenFOAM: The Open Source CFD Toolbox
\\ / O peration | Website: https://openfoam.org
\\ / A nd | Version: 6
\\/ M anipulation |
\*---------------------------------------------------------------------------*/
FoamFile
{
version 2.0;
format ascii;
class pointVectorField;
location "0";
object lmN;
}
// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //

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

internalField uniform (0 0 0);

boundaryField
{
symmetricY
{
type zeroGradient;
}

free
{
type zeroGradient;
}

symmetricX
{
type zeroGradient;
}

symmetricZ
{
type zeroGradient;
}
}

// ************************************************************************* //
55 changes: 55 additions & 0 deletions tutorials/solidFoam/stent/0/lm_b.orig
Original file line number Diff line number Diff line change
@@ -0,0 +1,55 @@
/*--------------------------------*- C++ -*----------------------------------*\
========= |
\\ / F ield | OpenFOAM: The Open Source CFD Toolbox
\\ / O peration | Website: https://openfoam.org
\\ / A nd | Version: 6
\\/ M anipulation |
\*---------------------------------------------------------------------------*/
FoamFile
{
version 2.0;
format ascii;
class volVectorField;
location "0";
object lm_b;
}
// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //

#include "../constant/runParameters"

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

internalField uniform (0 0 0);

boundaryField
{
free
{
type tractionLinearMomentum;
tractionValue (0 0 0);
value uniform (0 0 0);
}

symmetricX
{
type symmetricLinearMomentum;
tractionValue (0 0 0);
value uniform (0 0 0);
}

symmetricY
{
type symmetricLinearMomentum;
traction (0 0 $traction);
value uniform (0 0 0);
}

symmetricZ
{
type symmetricLinearMomentum;
tractionValue (0 0 0);
value uniform (0 0 0);
}
}

// ************************************************************************* //
52 changes: 52 additions & 0 deletions tutorials/solidFoam/stent/0/t_b.orig
Original file line number Diff line number Diff line change
@@ -0,0 +1,52 @@
/*--------------------------------*- C++ -*----------------------------------*\
========= |
\\ / F ield | OpenFOAM: The Open Source CFD Toolbox
\\ / O peration | Website: https://openfoam.org
\\ / A nd | Version: 6
\\/ M anipulation |
\*---------------------------------------------------------------------------*/
FoamFile
{
version 2.0;
format ascii;
class volVectorField;
location "0";
object t_b;
}
// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //

#include "../constant/runParameters"

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

internalField uniform (0 0 0);

boundaryField
{
free
{
type fixedValue;
value uniform (0 0 0);
}

symmetricX
{
type symmetricTraction;
value uniform (0 0 0);
}

symmetricY
{
type symmetricTraction;
traction (0 0 $traction);
value uniform (0 0 0);
}

symmetricZ
{
type symmetricTraction;
value uniform (0 0 0);
}
}

// ************************************************************************* //
9 changes: 9 additions & 0 deletions tutorials/solidFoam/stent/clean
Original file line number Diff line number Diff line change
@@ -0,0 +1,9 @@
#!/bin/bash
cd ${0%/*} || exit 1 # Run from this directory

# Source tutorial clean functions
. $WM_PROJECT_DIR/bin/tools/CleanFunctions
cleanCase;
rm 0/p 0/uN;

echo Case Cleaned!
24 changes: 24 additions & 0 deletions tutorials/solidFoam/stent/constant/mechanicalProperties
Original file line number Diff line number Diff line change
@@ -0,0 +1,24 @@
/*--------------------------------*- C++ -*----------------------------------*\
========= |
\\ / F ield | OpenFOAM: The Open Source CFD Toolbox
\\ / O peration | Website: https://openfoam.org
\\ / A nd | Version: 6
\\/ M anipulation |
\*---------------------------------------------------------------------------*/
FoamFile
{
version 2.0;
format ascii;
class dictionary;
location "constant";
object mechanicalProperties;
}
// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //

solidModel neoHookean;

rho rho [1 -3 0 0 0 0 0] 1100;
E E [1 -1 -2 0 0 0 0] 17e6;
nu nu [0 0 0 0 0 0 0] 0.45;

// ************************************************************************* //
21 changes: 21 additions & 0 deletions tutorials/solidFoam/stent/constant/runParameters
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: 6
\\/ M anipulation |
\*---------------------------------------------------------------------------*/
FoamFile
{
version 2.0;
format ascii;
class dictionary;
location "constant";
object runParameters;
}
// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //

meshFile stent_6912.msh;
traction -100000;

// ************************************************************************* //
23 changes: 23 additions & 0 deletions tutorials/solidFoam/stent/run
Original file line number Diff line number Diff line change
@@ -0,0 +1,23 @@
#!/bin/bash
cd ${0%/*} || exit 1 # Run from this directory

# OpenFOAM functions
. $WM_PROJECT_DIR/bin/tools/RunFunctions
solver=`getApplication`

# Get number of processors
nProc=$(foamDictionary -entry numberOfSubdomains -value $nProc system/decomposeParDict)

# Generate mesh
meshFile=$(foamDictionary -entry meshFile -value $meshFile constant/runParameters)
fluentMeshToFoam $meshFile

# Run solver
if [ $nProc -eq 1 ]; then
$solver > log.$solver &
tail -f log.$solver

elif [ $nProc -gt 1 ]; then
runApplication decomposePar
runParallel $solver &
fi
Loading

0 comments on commit c9a01ca

Please sign in to comment.