release on 2016-01-15_11-16-46
This commit is contained in:
119
tutorials/.gitignore
vendored
119
tutorials/.gitignore
vendored
@ -1,8 +1,121 @@
|
||||
*.vtk
|
||||
# C++.gitignore from github
|
||||
# Compiled Object files
|
||||
*.slo
|
||||
*.lo
|
||||
*.o
|
||||
*.d
|
||||
*.obj
|
||||
|
||||
# Precompiled Headers
|
||||
*.gch
|
||||
*.pch
|
||||
|
||||
# Compiled Dynamic libraries
|
||||
*.so
|
||||
*.dylib
|
||||
*.dll
|
||||
|
||||
# Fortran module files
|
||||
*.mod
|
||||
|
||||
# Compiled Static libraries
|
||||
*.lai
|
||||
*.la
|
||||
*.a
|
||||
*.lib
|
||||
|
||||
# Executables
|
||||
*.exe
|
||||
*.out
|
||||
*.app
|
||||
|
||||
# .gitignore from OpenFOAM-2.1.x
|
||||
# git-ls-files --others --exclude-from=.git/info/exclude
|
||||
# Lines that start with '#' are comments.
|
||||
|
||||
# editor and misc backup files - anywhere
|
||||
*~
|
||||
.*~
|
||||
*.bak
|
||||
*.bak[0-9][0-9]
|
||||
*.orig
|
||||
*.orig[0-9][0-9]
|
||||
\#*\#
|
||||
|
||||
# file-browser settings - anywhere
|
||||
.directory
|
||||
|
||||
# CVS recovered versions - anywhere
|
||||
.#*
|
||||
|
||||
# objects and archives - anywhere
|
||||
*.[oa]
|
||||
*.la
|
||||
*.so
|
||||
*.jar
|
||||
|
||||
# derived files
|
||||
lex.yy.c
|
||||
|
||||
# Corefiles
|
||||
core
|
||||
|
||||
# dependency files - anywhere
|
||||
*.dep
|
||||
|
||||
# lnInclude (symlink) folders - anywhere
|
||||
lnInclude
|
||||
|
||||
# build folders - anywhere
|
||||
linux*Clang*/
|
||||
linux*Gcc*/
|
||||
linux*Icc*/
|
||||
linuxming*/
|
||||
SiCortex*Gcc*/
|
||||
solaris*Gcc*/
|
||||
SunOS*Gcc*/
|
||||
platforms/
|
||||
|
||||
# reinstate wmake/rules that might look like build folders
|
||||
!wmake/rules/*/
|
||||
|
||||
# doxygen generated documentation
|
||||
doc/Doxygen/html
|
||||
doc/Doxygen/latex
|
||||
doc/Doxygen/man
|
||||
doc/Doxygen/DTAGS
|
||||
|
||||
# generated files in the main directory (e.g. ReleaseNotes-?.?.html)
|
||||
# and in the doc directory
|
||||
*.html
|
||||
|
||||
# untracked configuration files
|
||||
/etc/prefs.csh
|
||||
/etc/prefs.sh
|
||||
/etc/config/prefs.csh
|
||||
/etc/config/prefs.sh
|
||||
|
||||
# source packages - anywhere
|
||||
*.tar.bz2
|
||||
*.tar.gz
|
||||
*.tar
|
||||
*.tgz
|
||||
*.gtgz
|
||||
|
||||
# ignore the persistent .build tag in the main directory
|
||||
/.build
|
||||
|
||||
# ignore .timeStamp in the main directory
|
||||
/.timeStamp
|
||||
|
||||
# ignore .tags in the main directory
|
||||
/.tags
|
||||
|
||||
# ignore eclipse project files in the main directory
|
||||
/.cproject
|
||||
/.project
|
||||
|
||||
# ignore log files
|
||||
log_*
|
||||
log.*
|
||||
*~
|
||||
|
||||
# end-of-file
|
||||
|
||||
@ -77,7 +77,8 @@ if [ $postproc == "true" ]
|
||||
#- start paraview
|
||||
echo ""
|
||||
echo "trying to start paraview..."
|
||||
paraview
|
||||
#paraview4 # use your start command for paraview here
|
||||
$HOME/software/ParaView-4.3.1-Linux-64bit/bin/paraview
|
||||
read
|
||||
fi
|
||||
|
||||
|
||||
@ -65,6 +65,22 @@ turbulenceModelType RASProperties;
|
||||
//===========================================================================//
|
||||
// sub-model properties
|
||||
|
||||
typeConcentrationProps
|
||||
{
|
||||
verbose true;
|
||||
useDivided true;
|
||||
normConcentrationReference 0.07;
|
||||
typesA
|
||||
(
|
||||
1
|
||||
);
|
||||
|
||||
typesB
|
||||
(
|
||||
2
|
||||
);
|
||||
}
|
||||
|
||||
oneWayVTKProps
|
||||
{
|
||||
DEMts 0.0001;
|
||||
|
||||
@ -10,7 +10,7 @@ newton off
|
||||
units si
|
||||
|
||||
region reg block -0.015 0.015 -0.015 0.015 -0.001 0.0554 units box
|
||||
create_box 1 reg
|
||||
create_box 2 reg
|
||||
|
||||
neighbor 0.001 bin
|
||||
neigh_modify delay 0
|
||||
@ -18,10 +18,10 @@ neigh_modify delay 0
|
||||
|
||||
#Material properties required for new pair styles
|
||||
|
||||
fix m1 all property/global youngsModulus peratomtype 5.e6
|
||||
fix m2 all property/global poissonsRatio peratomtype 0.45
|
||||
fix m3 all property/global coefficientRestitution peratomtypepair 1 0.3
|
||||
fix m4 all property/global coefficientFriction peratomtypepair 1 0.5
|
||||
fix m1 all property/global youngsModulus peratomtype 5.e6 5.e6
|
||||
fix m2 all property/global poissonsRatio peratomtype 0.45 0.45
|
||||
fix m3 all property/global coefficientRestitution peratomtypepair 2 0.3 0.3 0.3 0.3
|
||||
fix m4 all property/global coefficientFriction peratomtypepair 2 0.5 0.5 0.5 0.5
|
||||
|
||||
#pair style
|
||||
pair_style gran model hertz tangential history
|
||||
@ -41,10 +41,14 @@ fix cylwalls all wall/gran model hertz tangential history primitive type 1 zcyli
|
||||
|
||||
#particle insertion
|
||||
region bc cylinder z 0.0 0.0 0.012 0.02 0.03 units box
|
||||
region bc2 cylinder z 0.0 0.0 0.012 0.01 0.02 units box
|
||||
fix pts1 all particletemplate/sphere 1 atom_type 1 density constant 200 radius constant 0.001
|
||||
fix pts2 all particletemplate/sphere 1 atom_type 2 density constant 200 radius constant 0.001
|
||||
fix pdd1 all particledistribution/discrete 1. 1 pts1 1.0
|
||||
fix pdd2 all particledistribution/discrete 1. 1 pts2 1.0
|
||||
|
||||
fix ins all insert/pack seed 100001 distributiontemplate pdd1 vel constant 0. 0. -1. insert_every once overlapcheck yes all_in yes particles_in_region 1000 region bc
|
||||
fix ins2 all insert/pack seed 100001 distributiontemplate pdd2 vel constant 0. 0. -1. insert_every once overlapcheck yes all_in yes particles_in_region 1000 region bc2
|
||||
|
||||
#apply nve integration to all particles that are inserted as single particles
|
||||
fix integr all nve/sphere
|
||||
|
||||
@ -23,7 +23,7 @@ startTime 0;
|
||||
|
||||
stopAt endTime;
|
||||
|
||||
endTime 0.05;
|
||||
endTime 0.1;
|
||||
|
||||
deltaT 0.0003;
|
||||
|
||||
@ -66,11 +66,14 @@ functions
|
||||
name drag;
|
||||
probeLocations
|
||||
(
|
||||
(0.0 0.0 0.0)
|
||||
(0.5001 0.5001 0.0001)
|
||||
(0.5001 0.5001 1.0001)
|
||||
(0.5001 0.5001 2.0001)
|
||||
(0.5001 0.5001 3.0001)
|
||||
);
|
||||
|
||||
// Fields to be probed
|
||||
fields ( particleForces );
|
||||
fields ( p );
|
||||
|
||||
// Write at same frequency as fields
|
||||
outputControl timeStep;//outputTime;
|
||||
|
||||
@ -1,6 +1,6 @@
|
||||
#echo both
|
||||
log ../DEM/log.liggghts
|
||||
thermo_log ../DEM/post/thermo.txt
|
||||
echo both
|
||||
log ../DEM/log.liggghts
|
||||
thermo_log ../DEM/post/thermo.txt
|
||||
|
||||
atom_style granular
|
||||
atom_modify map array
|
||||
|
||||
@ -16,7 +16,7 @@ source $CFDEM_SRC_DIR/lagrangian/cfdemParticle/etc/functions.sh
|
||||
#- define variables
|
||||
casePath="$(dirname "$(readlink -f ${BASH_SOURCE[0]})")"
|
||||
logpath=$casePath
|
||||
headerText="run_parallel_cfdemSolverPiso_ErgunTestMPI_CFDDEM"
|
||||
headerText="run_parallel_cfdemSolverIB_twoSpheresGlowinskiMPI_CFDDEM"
|
||||
logfileName="log_$headerText"
|
||||
solverName="cfdemSolverIB"
|
||||
nrProcs="4"
|
||||
|
||||
@ -2,7 +2,7 @@
|
||||
|
||||
#===================================================================#
|
||||
# allrun script for testcase as part of test routine
|
||||
# run settlingTest
|
||||
# run ErgunTestMPI
|
||||
# Christoph Goniva - Sept. 2010
|
||||
#===================================================================#
|
||||
|
||||
|
||||
@ -21,17 +21,7 @@ internalField uniform 0;
|
||||
|
||||
boundaryField
|
||||
{
|
||||
wall
|
||||
{
|
||||
type zeroGradient;
|
||||
//type fixedValue;
|
||||
//value uniform 0;
|
||||
}
|
||||
inlet
|
||||
{
|
||||
type zeroGradient;
|
||||
}
|
||||
outlet
|
||||
".*"
|
||||
{
|
||||
type zeroGradient;
|
||||
}
|
||||
|
||||
@ -44,13 +44,13 @@ boundaryField
|
||||
valueExpression "((time() < tEnd) ? Uend/tEnd*time():Uend)";
|
||||
value uniform (0 0 0);*/
|
||||
|
||||
/*// 2.0.x, 1.6,ext
|
||||
type timeVaryingUniformFixedValue;
|
||||
// 2.0.x, 1.6,ext
|
||||
/*type timeVaryingUniformFixedValue;
|
||||
fileName "steps_0p1s";
|
||||
outOfBounds clamp;
|
||||
value uniform (0 0 0);*/
|
||||
|
||||
// 2.1.x
|
||||
// 2.1.x or higher
|
||||
type uniformFixedValue;
|
||||
uniformValue table
|
||||
(
|
||||
|
||||
@ -21,23 +21,9 @@ internalField uniform (0 0 0);
|
||||
|
||||
boundaryField
|
||||
{
|
||||
wall
|
||||
".*"
|
||||
{
|
||||
type zeroGradient;
|
||||
//type fixedValue;
|
||||
//value uniform (1 0 0);
|
||||
}
|
||||
inlet
|
||||
{
|
||||
type zeroGradient;
|
||||
//type fixedValue;
|
||||
//value uniform (1 0 0);;
|
||||
}
|
||||
outlet
|
||||
{
|
||||
type zeroGradient;
|
||||
//type fixedValue;
|
||||
//value uniform (1 0 0);
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
@ -24,18 +24,16 @@ boundaryField
|
||||
wall
|
||||
{
|
||||
type zeroGradient;
|
||||
value $internalField;
|
||||
}
|
||||
|
||||
inlet
|
||||
{
|
||||
type zeroGradient;
|
||||
//type fixedValue;
|
||||
//value uniform 100000;
|
||||
value $internalField;
|
||||
}
|
||||
outlet
|
||||
{
|
||||
//type zeroGradient;
|
||||
|
||||
type fixedValue;
|
||||
value $internalField;
|
||||
}
|
||||
|
||||
@ -26,16 +26,13 @@ FoamFile
|
||||
//===========================================================================//
|
||||
// sub-models & settings
|
||||
|
||||
syncMode false;
|
||||
//verbose;
|
||||
|
||||
modelType "A"; // A or B
|
||||
|
||||
couplingInterval 100;
|
||||
|
||||
voidFractionModel divided;//centre;//
|
||||
|
||||
locateModel engine;//turboEngineM2M;//
|
||||
locateModel engine;
|
||||
|
||||
meshMotionModel noMeshMotion;
|
||||
|
||||
@ -45,7 +42,7 @@ IOModel basicIO;
|
||||
|
||||
probeModel off;
|
||||
|
||||
dataExchangeModel twoWayMPI;//twoWayM2M;//twoWayFiles;//oneWayVTK;//
|
||||
dataExchangeModel twoWayMPI;
|
||||
|
||||
averagingModel dense;//dilute;//
|
||||
|
||||
@ -144,6 +141,7 @@ GidaspowDragProps
|
||||
verbose true;
|
||||
velFieldName "U";
|
||||
voidfractionFieldName "voidfraction";
|
||||
granVelFieldName "Us";
|
||||
interpolation true;
|
||||
phi 1;
|
||||
}
|
||||
@ -267,7 +265,6 @@ twoWayMPIProps
|
||||
}
|
||||
twoWayM2MProps
|
||||
{
|
||||
maxNumberOfParticles 10100;
|
||||
liggghtsPath "../DEM/in.liggghts_run";
|
||||
}
|
||||
// ************************************************************************* //
|
||||
|
||||
@ -1,3 +1,4 @@
|
||||
%
|
||||
close all;
|
||||
clear;
|
||||
clc;
|
||||
@ -6,12 +7,16 @@ clc;
|
||||
% simulation data 1
|
||||
%====================================%
|
||||
rhoG = 10 % density in kg/m3
|
||||
%path = '../probes/0/p'; % 2.1.x
|
||||
path = '../postProcessing/probes/0/p'; % 2.2.x
|
||||
columns=22;
|
||||
headerlines=4;
|
||||
data = loaddata(path,columns,headerlines);
|
||||
data=transpose(data);
|
||||
%path = '../probes/0/p'; % ext32
|
||||
path = '../postProcessing/probes/0/p';
|
||||
|
||||
%- nomenclature before 2.4.x
|
||||
%columns=22;
|
||||
%headerlines=4;
|
||||
%data = loaddata(path,columns,headerlines);
|
||||
%data=transpose(data);
|
||||
|
||||
data = load(path);
|
||||
[x,y]=size(data)
|
||||
dp_sim = (data(:,2)-data(:,y))*rhoG; %conversion to Pa!
|
||||
t_sim = data(:,1);
|
||||
@ -27,7 +32,7 @@ t_sim = data(:,1);
|
||||
fprintf('\ncalc Ergun eqn:\n')
|
||||
dp = 0.001 % particle diameter
|
||||
phip = 1 % sphericity
|
||||
epsilon = 0.451335 % void fraction
|
||||
epsilon = 0.451335 % voidfraction
|
||||
Ustart = 0.002
|
||||
Uend = 0.02
|
||||
timeStepSize = 0.0005; % time interval of pressure data
|
||||
@ -72,6 +77,7 @@ dpUmf= L * (
|
||||
150*((1-epsilon)^2/epsilon^3)*((muG.*Umf)/(phip*dp)^2)
|
||||
+1.75*((1-epsilon)/epsilon^3)*((rhoG.*Umf.^2)/(phip*dp))
|
||||
);
|
||||
%pHydr=0;
|
||||
%dpUmf2=(L*(1-epsilon)*(rhoP-rhoG)*g+pHydr)
|
||||
%====================================%
|
||||
% plot data
|
||||
@ -95,5 +101,5 @@ ylabel("pressure drop [Pa]")
|
||||
axis([0,Uend,0,dpErgun(length(dpErgun))])
|
||||
|
||||
%print('cfdemSolverPiso_settlingTest.eps','-deps2')
|
||||
print -color "cfdemSolverPiso_ErgunTestMPI.eps"
|
||||
print -color "cfdemSolverPiso_ErgunTestMPI.png"
|
||||
|
||||
|
||||
@ -1,22 +1,4 @@
|
||||
(
|
||||
(0.000 (0 0 0.002))
|
||||
(0.010 (0 0 0.002))
|
||||
(0.011 (0 0 0.004))
|
||||
(0.020 (0 0 0.004))
|
||||
(0.021 (0 0 0.006))
|
||||
(0.030 (0 0 0.006))
|
||||
(0.031 (0 0 0.008))
|
||||
(0.040 (0 0 0.008))
|
||||
(0.041 (0 0 0.010))
|
||||
(0.050 (0 0 0.010))
|
||||
(0.051 (0 0 0.012))
|
||||
(0.060 (0 0 0.012))
|
||||
(0.061 (0 0 0.014))
|
||||
(0.070 (0 0 0.014))
|
||||
(0.071 (0 0 0.016))
|
||||
(0.080 (0 0 0.016))
|
||||
(0.081 (0 0 0.018))
|
||||
(0.090 (0 0 0.018))
|
||||
(0.091 (0 0 0.020))
|
||||
(0.100 (0 0 0.020))
|
||||
)
|
||||
|
||||
@ -15,7 +15,7 @@ FoamFile
|
||||
}
|
||||
// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
|
||||
|
||||
application pisoFoam;
|
||||
application cfdemSolverPiso;
|
||||
|
||||
startFrom startTime;
|
||||
|
||||
|
||||
@ -23,42 +23,22 @@ ddtSchemes
|
||||
gradSchemes
|
||||
{
|
||||
default Gauss linear;
|
||||
grad(p) Gauss linear;
|
||||
grad(U) Gauss linear;
|
||||
}
|
||||
|
||||
divSchemes
|
||||
{
|
||||
default Gauss linear;
|
||||
div(phi,U) Gauss limitedLinearV 1;
|
||||
div(phi,k) Gauss limitedLinear 1;
|
||||
div(phi,epsilon) Gauss limitedLinear 1;
|
||||
div(phi,R) Gauss limitedLinear 1;
|
||||
div(R) Gauss linear;
|
||||
div(phi,nuTilda) Gauss limitedLinear 1;
|
||||
div((viscousTerm*dev(grad(U).T()))) Gauss linear;
|
||||
div((nu*dev(grad(U).T()))) Gauss linear;
|
||||
div((nuEff*dev(grad(U).T()))) Gauss linear;
|
||||
}
|
||||
|
||||
laplacianSchemes
|
||||
{
|
||||
default Gauss linear corrected;
|
||||
laplacian(viscousTerm,U) Gauss linear corrected;
|
||||
laplacian(nu,U) Gauss linear corrected;
|
||||
laplacian(nuEff,U) Gauss linear corrected;
|
||||
laplacian((1|A(U)),p) Gauss linear corrected;
|
||||
laplacian((voidfraction2|A(U)),p) Gauss linear corrected;
|
||||
laplacian(DkEff,k) Gauss linear corrected;
|
||||
laplacian(DepsilonEff,epsilon) Gauss linear corrected;
|
||||
laplacian(DREff,R) Gauss linear corrected;
|
||||
laplacian(DnuTildaEff,nuTilda) Gauss linear corrected;
|
||||
}
|
||||
|
||||
interpolationSchemes
|
||||
{
|
||||
default linear;
|
||||
interpolate(U) linear;
|
||||
}
|
||||
|
||||
snGradSchemes
|
||||
|
||||
@ -17,7 +17,7 @@ FoamFile
|
||||
|
||||
solvers
|
||||
{
|
||||
"(p)"
|
||||
p
|
||||
{
|
||||
solver PCG;
|
||||
preconditioner DIC;
|
||||
@ -27,9 +27,7 @@ solvers
|
||||
|
||||
pFinal
|
||||
{
|
||||
solver PCG;
|
||||
preconditioner DIC;
|
||||
tolerance 1e-06;
|
||||
$p;
|
||||
relTol 0;
|
||||
}
|
||||
|
||||
@ -38,10 +36,16 @@ solvers
|
||||
solver PBiCG;
|
||||
preconditioner DILU;
|
||||
tolerance 1e-05;
|
||||
relTol 0.1;
|
||||
}
|
||||
|
||||
"(U|k|epsilon|R|nuTilda)Final"
|
||||
{
|
||||
$U;
|
||||
relTol 0;
|
||||
}
|
||||
|
||||
"(voidfraction|Us|Ksl|dSmoothing|UsNext|voidfractionNext)"
|
||||
"(voidfraction|Us|Ksl|dSmoothing|UsNext|voidfractionNext|sSmoothField|vSmoothField)"
|
||||
{
|
||||
solver PCG;
|
||||
preconditioner DIC;
|
||||
@ -57,6 +61,27 @@ PISO
|
||||
pRefCell 0;
|
||||
pRefValue 0;
|
||||
}
|
||||
PIMPLE
|
||||
{
|
||||
nOuterCorrectors 1;
|
||||
nCorrectors 4;
|
||||
nNonOrthogonalCorrectors 0;
|
||||
pRefCell 0;
|
||||
pRefValue 0;
|
||||
}
|
||||
relaxationFactors
|
||||
{
|
||||
fields
|
||||
{
|
||||
p 1.0;
|
||||
}
|
||||
equations
|
||||
{
|
||||
"U.*" 1.0;
|
||||
"k.*" 1.;
|
||||
"epsilon.*" 1.;
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
// ************************************************************************* //
|
||||
|
||||
@ -1,5 +1,7 @@
|
||||
# Pour granular particles into chute container, then induce flow
|
||||
echo both
|
||||
echo both
|
||||
log ../DEM/log.liggghts
|
||||
thermo_log ../DEM/post/thermo.txt
|
||||
|
||||
atom_style granular
|
||||
atom_modify map array
|
||||
communicate single vel yes
|
||||
@ -56,9 +58,6 @@ compute_modify thermo_temp dynamic yes
|
||||
# insert the first particles so that dump is not empty
|
||||
run 1
|
||||
dump dmp all custom 5000 post/dump.liggghts_init id type x y z ix iy iz vx vy vz fx fy fz omegax omegay omegaz radius
|
||||
#force : f_couple_cfd[0] f_couple_cfd[1] f_couple_cfd[2]
|
||||
#node : f_couple_cfd[6]
|
||||
#cell id : f_couple_cfd[7]
|
||||
|
||||
run 10000 upto
|
||||
write_restart post/restart/liggghts.restart
|
||||
|
||||
@ -1,4 +1,4 @@
|
||||
# Pour granular particles into chute container, then induce flow
|
||||
echo both
|
||||
log ../DEM/log.liggghts
|
||||
thermo_log ../DEM/post/thermo.txt
|
||||
|
||||
@ -64,5 +64,6 @@ thermo_modify lost ignore norm no
|
||||
compute_modify thermo_temp dynamic yes
|
||||
|
||||
dump dmp all custom 5000 ../DEM/post/dump*.liggghts_run id type x y z vx vy vz fx fy fz f_dragforce[1] f_dragforce[2] f_dragforce[3] radius
|
||||
#dump dmp all custom/vtk 5000 ../DEM/post/dump_liggghts_run.*.vtk id type x y z vx vy vz fx fy fz f_dragforce[1] f_dragforce[2] f_dragforce[3] radius
|
||||
|
||||
run 1
|
||||
|
||||
@ -21,7 +21,7 @@ logfileName="log_$headerText"
|
||||
solverName="cfdemSolverPiso"
|
||||
nrProcs="4"
|
||||
machineFileName="none" # yourMachinefileName | none
|
||||
debugMode="off" # on | off| strict
|
||||
debugMode="off" # on | off| strict | profile
|
||||
testHarnessPath="$CFDEM_TEST_HARNESS_PATH"
|
||||
runOctave="true"
|
||||
postproc="false"
|
||||
@ -40,24 +40,24 @@ if [ $runOctave == "true" ]
|
||||
cd octave
|
||||
|
||||
#- rmove old graph
|
||||
rm cfdemSolverPiso_ErgunTestMPI.eps
|
||||
rm cfdemSolverPiso_ErgunTestMPI.png
|
||||
|
||||
#- run octave
|
||||
octave totalPressureDrop.m
|
||||
|
||||
#- show plot
|
||||
evince cfdemSolverPiso_ErgunTestMPI.eps
|
||||
eog cfdemSolverPiso_ErgunTestMPI.png
|
||||
|
||||
#- copy log file to test harness
|
||||
cp ../../$logfileName $testHarnessPath
|
||||
cp cfdemSolverPiso_ErgunTestMPI.eps $testHarnessPath
|
||||
cp cfdemSolverPiso_ErgunTestMPI.png $testHarnessPath
|
||||
fi
|
||||
|
||||
if [ $postproc == "true" ]
|
||||
then
|
||||
|
||||
#- keep terminal open (if started in new terminal)
|
||||
echo "simulation finisehd? ...press enter to proceed"
|
||||
echo "simulation finished? ...press enter to proceed"
|
||||
read
|
||||
|
||||
#- get VTK data from liggghts dump file
|
||||
@ -86,6 +86,8 @@ source $WM_PROJECT_DIR/bin/tools/CleanFunctions
|
||||
cd $casePath/CFD
|
||||
cleanCase
|
||||
rm -r $casePath/CFD/clockData
|
||||
rm $casePath/CFD/octave/octave-workspace
|
||||
rm -r $casePath/CFD/hpctoolkit-*
|
||||
rm $casePath/DEM/post/*.*
|
||||
touch $casePath/DEM/post/.gitignore
|
||||
#rm $casePath/DEM/post/restart/*.*
|
||||
|
||||
@ -21,7 +21,7 @@ headerText="run_liggghts_init_DEM"
|
||||
logfileName="log_$headerText"
|
||||
solverName="in.liggghts_init"
|
||||
nrProcs=4
|
||||
machineFileName="none"
|
||||
machineFileName="none" # yourMachinefileName | none
|
||||
debugMode="off"
|
||||
#--------------------------------------------------------------------------------#
|
||||
|
||||
|
||||
@ -6,12 +6,16 @@ clc;
|
||||
% simulation data 1
|
||||
%====================================%
|
||||
rhoG = 0.01 % density in g/cm3
|
||||
%path = '../probes/0/p'; % 2.1.x
|
||||
path = '../postProcessing/probes/0/p'; % 2.2.x
|
||||
columns=22;
|
||||
headerlines=4;
|
||||
data = loaddata(path,columns,headerlines);
|
||||
data=transpose(data);
|
||||
%path = '../probes/0/p'; % ext32
|
||||
path = '../postProcessing/probes/0/p';
|
||||
|
||||
%- nomenclature before 2.4.x
|
||||
%columns=22;
|
||||
%headerlines=4;
|
||||
%data = loaddata(path,columns,headerlines);
|
||||
%data=transpose(data);
|
||||
|
||||
data = load(path);
|
||||
[x,y]=size(data)
|
||||
dp_sim = (data(:,2)-data(:,y))*rhoG*0.1; % *rhoG to get pressure, then *0.1 to get from Ba in Pa
|
||||
t_sim = data(:,1);
|
||||
|
||||
@ -1,5 +1,5 @@
|
||||
# Pour granular particles into chute container, then induce flow
|
||||
echo both
|
||||
echo both
|
||||
log ../DEM/log.liggghts
|
||||
atom_style granular
|
||||
atom_modify map array
|
||||
communicate single vel yes
|
||||
|
||||
@ -1,4 +1,4 @@
|
||||
# Pour granular particles into chute container, then induce flow
|
||||
echo both
|
||||
log ../DEM/log.liggghts
|
||||
thermo_log ../DEM/post/thermo.txt
|
||||
|
||||
|
||||
@ -109,6 +109,8 @@ echo "deleting data at: $casePath :\n"
|
||||
source $WM_PROJECT_DIR/bin/tools/CleanFunctions
|
||||
cd $casePath/CFD
|
||||
cleanCase
|
||||
rm -r $casePath/CFD/constant/liggghtsCommands
|
||||
rm -r $casePath/CFD/constant/couplingProperties
|
||||
rm -r $casePath/CFD/clockData
|
||||
rm -r $casePath/DEM/post/*.*
|
||||
#rm -r $casePath/DEM/post/restart/*.*
|
||||
|
||||
@ -44,35 +44,17 @@ boundaryField
|
||||
valueExpression "((time() < tEnd) ? Uend/tEnd*time():Uend)";
|
||||
value uniform (0 0 0);*/
|
||||
|
||||
/*// 2.0.x, 1.6,ext
|
||||
type timeVaryingUniformFixedValue;
|
||||
// 2.0.x, 1.6,ext
|
||||
/*type timeVaryingUniformFixedValue;
|
||||
fileName "steps_0p1s";
|
||||
outOfBounds clamp;
|
||||
value uniform (0 0 0);*/
|
||||
|
||||
// 2.1.x
|
||||
// 2.1.x or higher
|
||||
type uniformFixedValue;
|
||||
uniformValue table
|
||||
(
|
||||
(0.000 (0 0 0.002))
|
||||
/*(0.010 (0 0 0.002))
|
||||
(0.011 (0 0 0.004))
|
||||
(0.020 (0 0 0.004))
|
||||
(0.021 (0 0 0.006))
|
||||
(0.030 (0 0 0.006))
|
||||
(0.031 (0 0 0.008))
|
||||
(0.040 (0 0 0.008))
|
||||
(0.041 (0 0 0.010))
|
||||
(0.050 (0 0 0.010))
|
||||
(0.051 (0 0 0.012))
|
||||
(0.060 (0 0 0.012))
|
||||
(0.061 (0 0 0.014))
|
||||
(0.070 (0 0 0.014))
|
||||
(0.071 (0 0 0.016))
|
||||
(0.080 (0 0 0.016))
|
||||
(0.081 (0 0 0.018))
|
||||
(0.090 (0 0 0.018))
|
||||
(0.091 (0 0 0.020))*/
|
||||
(0.100 (0 0 0.020))
|
||||
);
|
||||
}
|
||||
|
||||
@ -25,7 +25,7 @@ FoamFile
|
||||
|
||||
//===========================================================================//
|
||||
// sub-models & settings
|
||||
|
||||
debug false;
|
||||
modelType "A"; // A or B
|
||||
|
||||
couplingInterval 100;
|
||||
@ -176,7 +176,7 @@ particleCellVolumeProps
|
||||
{
|
||||
upperThreshold 0.999;
|
||||
lowerThreshold 0.;
|
||||
verbose;
|
||||
verbose true;
|
||||
}
|
||||
|
||||
oneWayVTKProps
|
||||
|
||||
@ -25,7 +25,7 @@ FoamFile
|
||||
|
||||
//===========================================================================//
|
||||
// sub-models & settings
|
||||
|
||||
debug false;
|
||||
modelType "A"; // A or B
|
||||
|
||||
couplingInterval 100;
|
||||
@ -176,7 +176,7 @@ particleCellVolumeProps
|
||||
{
|
||||
upperThreshold 0.999;
|
||||
lowerThreshold 0.;
|
||||
verbose;
|
||||
verbose true;
|
||||
}
|
||||
|
||||
oneWayVTKProps
|
||||
|
||||
@ -6,12 +6,16 @@ clc;
|
||||
% simulation data 1
|
||||
%====================================%
|
||||
rhoG = 10 % density in kg/m3
|
||||
%path = '../probes/0/p'; % 2.1.x
|
||||
path = '../postProcessing/probes/0/p'; % 2.2.x
|
||||
columns=22;
|
||||
headerlines=4;
|
||||
data = loaddata(path,columns,headerlines);
|
||||
data=transpose(data);
|
||||
%path = '../probes/0/p'; % ext32
|
||||
path = '../postProcessing/probes/0/p';
|
||||
|
||||
%- nomenclature before 2.4.x
|
||||
%columns=22;
|
||||
%headerlines=4;
|
||||
%data = loaddata(path,columns,headerlines);
|
||||
%data=transpose(data);
|
||||
|
||||
data = load(path);
|
||||
[x,y]=size(data)
|
||||
dp_sim = (data(:,2)-data(:,y))*rhoG; % conversion to Pa
|
||||
t_sim = data(:,1);
|
||||
@ -20,12 +24,16 @@ t_sim = data(:,1);
|
||||
%====================================%
|
||||
% simulation data 2
|
||||
%====================================%
|
||||
%path = '../probes/0.05/p'; % 2.1.x
|
||||
path = '../postProcessing/probes/0.05/p'; % 2.2.x
|
||||
columns=22;
|
||||
headerlines=4;
|
||||
data = loaddata(path,columns,headerlines);
|
||||
data=transpose(data);
|
||||
%path = '../probes/0.05/p'; % ext32
|
||||
path = '../postProcessing/probes/0.05/p';
|
||||
|
||||
%- nomenclature before 2.4.x
|
||||
%columns=22;
|
||||
%headerlines=4;
|
||||
%data = loaddata(path,columns,headerlines);
|
||||
%data=transpose(data);
|
||||
|
||||
data = load(path);
|
||||
[x,y]=size(data)
|
||||
dp_sim_2 = (data(:,2)-data(:,y))*rhoG; % conversion to Pa
|
||||
t_sim_2 = data(:,1);
|
||||
|
||||
@ -0,0 +1,4 @@
|
||||
(
|
||||
(0.000 (0 0 0.002))
|
||||
(0.100 (0 0 0.020))
|
||||
)
|
||||
@ -31,7 +31,7 @@ couplingInterval 100;
|
||||
|
||||
voidFractionModel divided;//centre;//bigParticle;//
|
||||
|
||||
locateModel engine;//standard;
|
||||
locateModel engine;///ijk;//standard;
|
||||
|
||||
meshMotionModel noMeshMotion;
|
||||
|
||||
|
||||
@ -30,7 +30,7 @@ vertices
|
||||
|
||||
blocks
|
||||
(
|
||||
hex (0 1 2 3 4 5 6 7) (5 25 5) simpleGrading (1 1 1) // regular grid
|
||||
hex (0 1 2 3 4 5 6 7) (4 20 4) simpleGrading (1 1 1) // regular grid
|
||||
//hex (0 1 2 3 4 5 6 7) (25 125 25) simpleGrading (1 1 1) // irrregular fine grid
|
||||
//hex (0 1 2 3 4 5 6 7) (25 25 25) simpleGrading (1 1 1) // irrregular coarse grid
|
||||
//hex (0 1 2 3 4 5 6 7) (10 25 10) simpleGrading (1 1 1) // irrregular grid (ratio 2)
|
||||
|
||||
@ -21,7 +21,7 @@ method simple;
|
||||
|
||||
simpleCoeffs
|
||||
{
|
||||
n ( 1 1 2 );
|
||||
n ( 1 2 1 );
|
||||
delta 0.001;
|
||||
}
|
||||
|
||||
|
||||
@ -1,5 +1,4 @@
|
||||
# Pour granular particles into chute container, then induce flow
|
||||
echo both
|
||||
echo both
|
||||
log ../DEM/log.liggghts
|
||||
thermo_log ../DEM/post/thermo.txt
|
||||
|
||||
|
||||
23
tutorials/cfdemSolverPiso/voidfractionTest/Allrun.sh
Executable file
23
tutorials/cfdemSolverPiso/voidfractionTest/Allrun.sh
Executable file
@ -0,0 +1,23 @@
|
||||
#!/bin/bash
|
||||
|
||||
#===================================================================#
|
||||
# allrun script for testcase as part of test routine
|
||||
# run voidfractionTest
|
||||
# Christoph Goniva - Jan. 2016
|
||||
#===================================================================#
|
||||
|
||||
#- define variables
|
||||
casePath="$(dirname "$(readlink -f ${BASH_SOURCE[0]})")"
|
||||
|
||||
# check if mesh was built
|
||||
if [ -f "$casePath/CFD/constant/polyMesh/points" ]; then
|
||||
echo "mesh was built before - using old mesh"
|
||||
else
|
||||
echo "mesh needs to be built"
|
||||
cd $casePath/CFD
|
||||
blockMesh
|
||||
fi
|
||||
|
||||
#- run parallel CFD-DEM in new terminal
|
||||
#gnome-terminal --title='cfdemSolverPiso voidfractionTest CFD' -e "bash $casePath/parCFDDEMrun.sh"
|
||||
bash $casePath/parCFDDEMrun.sh
|
||||
32
tutorials/cfdemSolverPiso/voidfractionTest/CFD/0/Ksl
Normal file
32
tutorials/cfdemSolverPiso/voidfractionTest/CFD/0/Ksl
Normal file
@ -0,0 +1,32 @@
|
||||
/*--------------------------------*- C++ -*----------------------------------*\
|
||||
| ========= | |
|
||||
| \\ / F ield | OpenFOAM: The Open Source CFD Toolbox |
|
||||
| \\ / O peration | Version: 1.6 |
|
||||
| \\ / A nd | Web: www.OpenFOAM.org |
|
||||
| \\/ M anipulation | |
|
||||
\*---------------------------------------------------------------------------*/
|
||||
FoamFile
|
||||
{
|
||||
version 2.0;
|
||||
format ascii;
|
||||
class volScalarField;
|
||||
location "0";
|
||||
object Ksl;
|
||||
}
|
||||
// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
|
||||
|
||||
dimensions [1 -3 -1 0 0 0 0];
|
||||
|
||||
internalField uniform 0;
|
||||
|
||||
boundaryField
|
||||
{
|
||||
"(inlet|outlet|walls)"
|
||||
{
|
||||
type zeroGradient;
|
||||
value uniform 0;
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
// ************************************************************************* //
|
||||
42
tutorials/cfdemSolverPiso/voidfractionTest/CFD/0/U
Normal file
42
tutorials/cfdemSolverPiso/voidfractionTest/CFD/0/U
Normal file
@ -0,0 +1,42 @@
|
||||
/*--------------------------------*- C++ -*----------------------------------*\
|
||||
| ========= | |
|
||||
| \\ / F ield | OpenFOAM: The Open Source CFD Toolbox |
|
||||
| \\ / O peration | Version: 1.6 |
|
||||
| \\ / A nd | Web: www.OpenFOAM.org |
|
||||
| \\/ M anipulation | |
|
||||
\*---------------------------------------------------------------------------*/
|
||||
FoamFile
|
||||
{
|
||||
version 2.0;
|
||||
format ascii;
|
||||
class volVectorField;
|
||||
location "0";
|
||||
object U;
|
||||
}
|
||||
// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
|
||||
|
||||
dimensions [0 1 -1 0 0 0 0];
|
||||
|
||||
internalField uniform (0 0 0);
|
||||
|
||||
boundaryField
|
||||
{
|
||||
inlet
|
||||
{
|
||||
type fixedValue;
|
||||
value uniform (0 0 0);
|
||||
}
|
||||
outlet
|
||||
{
|
||||
type zeroGradient;
|
||||
value uniform (0 0 0);
|
||||
}
|
||||
walls
|
||||
{
|
||||
type fixedValue;
|
||||
value uniform (0 0 0);
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
// ************************************************************************* //
|
||||
32
tutorials/cfdemSolverPiso/voidfractionTest/CFD/0/Us
Normal file
32
tutorials/cfdemSolverPiso/voidfractionTest/CFD/0/Us
Normal file
@ -0,0 +1,32 @@
|
||||
/*--------------------------------*- C++ -*----------------------------------*\
|
||||
| ========= | |
|
||||
| \\ / F ield | OpenFOAM: The Open Source CFD Toolbox |
|
||||
| \\ / O peration | Version: 1.6 |
|
||||
| \\ / A nd | Web: www.OpenFOAM.org |
|
||||
| \\/ M anipulation | |
|
||||
\*---------------------------------------------------------------------------*/
|
||||
FoamFile
|
||||
{
|
||||
version 2.0;
|
||||
format ascii;
|
||||
class volVectorField;
|
||||
location "0";
|
||||
object Us;
|
||||
}
|
||||
// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
|
||||
|
||||
dimensions [0 1 -1 0 0 0 0];
|
||||
|
||||
internalField uniform (0 0 0);
|
||||
|
||||
boundaryField
|
||||
{
|
||||
"(inlet|outlet|walls)"
|
||||
{
|
||||
type zeroGradient;
|
||||
value uniform (0 0 0);
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
// ************************************************************************* //
|
||||
46
tutorials/cfdemSolverPiso/voidfractionTest/CFD/0/p
Normal file
46
tutorials/cfdemSolverPiso/voidfractionTest/CFD/0/p
Normal file
@ -0,0 +1,46 @@
|
||||
/*--------------------------------*- C++ -*----------------------------------*\
|
||||
| ========= | |
|
||||
| \\ / F ield | OpenFOAM: The Open Source CFD Toolbox |
|
||||
| \\ / O peration | Version: 1.6 |
|
||||
| \\ / A nd | Web: http://www.OpenFOAM.org |
|
||||
| \\/ M anipulation | |
|
||||
\*---------------------------------------------------------------------------*/
|
||||
FoamFile
|
||||
{
|
||||
version 2.0;
|
||||
format ascii;
|
||||
class volScalarField;
|
||||
object p;
|
||||
}
|
||||
// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
|
||||
|
||||
dimensions [0 2 -2 0 0 0 0];
|
||||
|
||||
internalField uniform 0;
|
||||
|
||||
boundaryField
|
||||
{
|
||||
walls
|
||||
{
|
||||
type zeroGradient;
|
||||
value uniform 0;
|
||||
}
|
||||
inlet
|
||||
{
|
||||
type zeroGradient;
|
||||
value uniform 0;
|
||||
}
|
||||
outlet
|
||||
{
|
||||
type totalPressure;
|
||||
p0 uniform 0;
|
||||
U U;
|
||||
phi phi;
|
||||
rho rho;
|
||||
psi none;
|
||||
gamma 1;
|
||||
value uniform 0;
|
||||
}
|
||||
}
|
||||
|
||||
// ************************************************************************* //
|
||||
30
tutorials/cfdemSolverPiso/voidfractionTest/CFD/0/rho
Normal file
30
tutorials/cfdemSolverPiso/voidfractionTest/CFD/0/rho
Normal file
@ -0,0 +1,30 @@
|
||||
/*--------------------------------*- C++ -*----------------------------------*\
|
||||
| ========= | |
|
||||
| \\ / F ield | OpenFOAM: The Open Source CFD Toolbox |
|
||||
| \\ / O peration | Version: 1.6 |
|
||||
| \\ / A nd | Web: http://www.OpenFOAM.org |
|
||||
| \\/ M anipulation | |
|
||||
\*---------------------------------------------------------------------------*/
|
||||
FoamFile
|
||||
{
|
||||
version 2.0;
|
||||
format ascii;
|
||||
class volScalarField;
|
||||
object p;
|
||||
}
|
||||
// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
|
||||
|
||||
dimensions [1 -3 0 0 0 0 0];
|
||||
|
||||
internalField uniform 10;
|
||||
|
||||
boundaryField
|
||||
{
|
||||
"(inlet|outlet|walls)"
|
||||
{
|
||||
type zeroGradient;
|
||||
value uniform 10;
|
||||
}
|
||||
}
|
||||
|
||||
// ************************************************************************* //
|
||||
@ -0,0 +1,30 @@
|
||||
/*--------------------------------*- C++ -*----------------------------------*\
|
||||
| ========= | |
|
||||
| \\ / F ield | OpenFOAM: The Open Source CFD Toolbox |
|
||||
| \\ / O peration | Version: 1.6 |
|
||||
| \\ / A nd | Web: http://www.OpenFOAM.org |
|
||||
| \\/ M anipulation | |
|
||||
\*---------------------------------------------------------------------------*/
|
||||
FoamFile
|
||||
{
|
||||
version 2.0;
|
||||
format ascii;
|
||||
class volScalarField;
|
||||
object voidfraction;
|
||||
}
|
||||
// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
|
||||
|
||||
dimensions [0 0 0 0 0 0 0];
|
||||
|
||||
internalField uniform 1;
|
||||
|
||||
boundaryField
|
||||
{
|
||||
"(inlet|outlet|walls)"
|
||||
{
|
||||
type zeroGradient;
|
||||
value uniform 1;
|
||||
}
|
||||
}
|
||||
|
||||
// ************************************************************************* //
|
||||
@ -0,0 +1,25 @@
|
||||
/*--------------------------------*- C++ -*----------------------------------*\
|
||||
| ========= | |
|
||||
| \\ / F ield | OpenFOAM: The Open Source CFD Toolbox |
|
||||
| \\ / O peration | Version: 1.6 |
|
||||
| \\ / A nd | Web: www.OpenFOAM.org |
|
||||
| \\/ M anipulation | |
|
||||
\*---------------------------------------------------------------------------*/
|
||||
FoamFile
|
||||
{
|
||||
version 2.0;
|
||||
format ascii;
|
||||
class dictionary;
|
||||
location "constant";
|
||||
object RASProperties;
|
||||
}
|
||||
// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
|
||||
|
||||
RASModel laminar;//kEpsilon;
|
||||
|
||||
turbulence on;
|
||||
|
||||
printCoeffs on;
|
||||
|
||||
|
||||
// ************************************************************************* //
|
||||
215
tutorials/cfdemSolverPiso/voidfractionTest/CFD/constant/couplingProperties
Executable file
215
tutorials/cfdemSolverPiso/voidfractionTest/CFD/constant/couplingProperties
Executable file
@ -0,0 +1,215 @@
|
||||
/*---------------------------------------------------------------------------*\
|
||||
| ========= | |
|
||||
| \\ / F ield | OpenFOAM: The Open Source CFD Toolbox |
|
||||
| \\ / O peration | Version: 1.4 |
|
||||
| \\ / A nd | Web: http://www.openfoam.org |
|
||||
| \\/ M anipulation | |
|
||||
\*---------------------------------------------------------------------------*/
|
||||
|
||||
|
||||
FoamFile
|
||||
{
|
||||
version 2.0;
|
||||
format ascii;
|
||||
|
||||
root "";
|
||||
case "";
|
||||
instance "";
|
||||
local "";
|
||||
|
||||
class dictionary;
|
||||
object couplingProperties;
|
||||
}
|
||||
|
||||
// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
|
||||
|
||||
//===========================================================================//
|
||||
// sub-models & settings
|
||||
|
||||
solveFlow off;
|
||||
|
||||
useDDTvoidfraction b;
|
||||
|
||||
modelType B; // A or B
|
||||
|
||||
couplingInterval 100;
|
||||
|
||||
voidFractionModel trilinear;//centre;//divided;//bigParticle;//
|
||||
|
||||
locateModel engine;//ijk;//standard;//
|
||||
|
||||
meshMotionModel noMeshMotion;
|
||||
|
||||
regionModel allRegion;
|
||||
|
||||
IOModel basicIO; //trackIO; //
|
||||
|
||||
probeModel off;
|
||||
|
||||
dataExchangeModel twoWayMPI;//twoWayFiles;//oneWayVTK;//
|
||||
|
||||
averagingModel dense;//dilute;//
|
||||
|
||||
clockModel off; //standardClock;//
|
||||
|
||||
smoothingModel off;//constDiffSmoothing; //
|
||||
|
||||
//useDDTvoidfraction;
|
||||
|
||||
forceModels
|
||||
(
|
||||
DiFeliceDrag
|
||||
Archimedes
|
||||
noDrag
|
||||
particleCellVolume
|
||||
volWeightedAverage
|
||||
);
|
||||
|
||||
momCoupleModels
|
||||
(
|
||||
implicitCouple
|
||||
);
|
||||
|
||||
turbulenceModelType RASProperties;//LESProperties;//
|
||||
|
||||
//===========================================================================//
|
||||
// sub-model properties
|
||||
|
||||
|
||||
particleCellVolumeProps
|
||||
{
|
||||
upperThreshold 1e20;
|
||||
lowerThreshold 0.;
|
||||
verbose true;
|
||||
writeToFile true;
|
||||
}
|
||||
|
||||
volWeightedAverageProps
|
||||
{
|
||||
scalarFieldNames
|
||||
(
|
||||
ddtVoidfraction
|
||||
);
|
||||
vectorFieldNames
|
||||
(
|
||||
);
|
||||
upperThreshold 1e20;
|
||||
lowerThreshold 0;
|
||||
writeToFile true;
|
||||
verbose;
|
||||
}
|
||||
|
||||
particleProbeProps
|
||||
{
|
||||
particleIDsToSample (0 0);
|
||||
verboseToFile; //main switch
|
||||
printEvery 1; //print every this many CFD time steps
|
||||
sampleAll; //Activate sampling for all particles
|
||||
probeDebug; //probes additional fields
|
||||
includePosition; //will include particle position in the output file
|
||||
writePrecision 4; //number of significant digits to print
|
||||
}
|
||||
|
||||
constDiffSmoothingProps
|
||||
{
|
||||
lowerLimit 0.0;
|
||||
upperLimit 1e99;
|
||||
smoothingLength 1e-3;
|
||||
}
|
||||
|
||||
implicitCoupleProps
|
||||
{
|
||||
velFieldName "U";
|
||||
granVelFieldName "Us";
|
||||
voidfractionFieldName "voidfraction";
|
||||
}
|
||||
|
||||
DiFeliceDragProps
|
||||
{
|
||||
velFieldName "U";
|
||||
voidfractionFieldName "voidfraction";
|
||||
granVelFieldName "Us";
|
||||
verbose false;
|
||||
|
||||
//- use of scalar viscosity for drag
|
||||
//scalarViscosity true;
|
||||
//nu nu [ 0 2 -1 0 0 0 0 ] 1e-04;
|
||||
}
|
||||
|
||||
SchillerNaumannDragProps
|
||||
{
|
||||
velFieldName "U";
|
||||
densityFieldName "rho";
|
||||
}
|
||||
|
||||
KochHillDragProps
|
||||
{
|
||||
velFieldName "U";
|
||||
densityFieldName "rho";
|
||||
voidfractionFieldName "voidfraction";
|
||||
}
|
||||
|
||||
MeiLiftProps
|
||||
{
|
||||
velFieldName "U";
|
||||
densityFieldName "rho";
|
||||
}
|
||||
|
||||
ArchimedesProps
|
||||
{
|
||||
densityFieldName "rho";
|
||||
gravityFieldName "g";
|
||||
}
|
||||
|
||||
virtualMassForceProps
|
||||
{
|
||||
velFieldName "U";
|
||||
densityFieldName "rho";
|
||||
}
|
||||
|
||||
oneWayVTKProps
|
||||
{
|
||||
couplingFilename "vtk_out%4.4d.vtk";
|
||||
maxNumberOfParticles 30000;
|
||||
}
|
||||
|
||||
twoWayMPIProps
|
||||
{
|
||||
liggghtsPath "../DEM/in.liggghts_run";
|
||||
}
|
||||
|
||||
twoWayFilesProps
|
||||
{
|
||||
maxNumberOfParticles 10000;
|
||||
DEMts 0.00001;
|
||||
}
|
||||
|
||||
centreProps
|
||||
{
|
||||
alphaMin 0.30;
|
||||
}
|
||||
|
||||
dividedProps
|
||||
{
|
||||
alphaMin 0.3;
|
||||
scaleUpVol 1.0;
|
||||
}
|
||||
|
||||
trilinearProps
|
||||
{
|
||||
alphaMin 0.3; // not yet used in code!
|
||||
}
|
||||
|
||||
bigParticleProps
|
||||
{
|
||||
maxCellsPerParticle 1000;
|
||||
alphaMin 0.30;
|
||||
scaleUpVol 1.0;
|
||||
}
|
||||
|
||||
engineProps
|
||||
{
|
||||
treeSearch true;
|
||||
}
|
||||
|
||||
// ************************************************************************* //
|
||||
22
tutorials/cfdemSolverPiso/voidfractionTest/CFD/constant/g
Normal file
22
tutorials/cfdemSolverPiso/voidfractionTest/CFD/constant/g
Normal file
@ -0,0 +1,22 @@
|
||||
/*--------------------------------*- C++ -*----------------------------------*\
|
||||
| ========= | |
|
||||
| \\ / F ield | OpenFOAM: The Open Source CFD Toolbox |
|
||||
| \\ / O peration | Version: 1.6 |
|
||||
| \\ / A nd | Web: www.OpenFOAM.org |
|
||||
| \\/ M anipulation | |
|
||||
\*---------------------------------------------------------------------------*/
|
||||
FoamFile
|
||||
{
|
||||
version 2.0;
|
||||
format ascii;
|
||||
class uniformDimensionedVectorField;
|
||||
location "constant";
|
||||
object g;
|
||||
}
|
||||
// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
|
||||
|
||||
dimensions [0 1 -2 0 0 0 0];
|
||||
value ( 0 -9.81 0);
|
||||
|
||||
|
||||
// ************************************************************************* //
|
||||
@ -0,0 +1,40 @@
|
||||
/*---------------------------------------------------------------------------*\
|
||||
| ========= | |
|
||||
| \\ / F ield | OpenFOAM: The Open Source CFD Toolbox |
|
||||
| \\ / O peration | Version: 1.4 |
|
||||
| \\ / A nd | Web: http://www.openfoam.org |
|
||||
| \\/ M anipulation | |
|
||||
\*---------------------------------------------------------------------------*/
|
||||
|
||||
|
||||
FoamFile
|
||||
{
|
||||
version 2.0;
|
||||
format ascii;
|
||||
|
||||
root "";
|
||||
case "";
|
||||
instance "";
|
||||
local "";
|
||||
|
||||
class dictionary;
|
||||
object liggghtsCommands;
|
||||
}
|
||||
|
||||
// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
|
||||
|
||||
liggghtsCommandModels
|
||||
(
|
||||
runLiggghts
|
||||
//writeLiggghts
|
||||
);
|
||||
|
||||
// ************************************************************************* //
|
||||
|
||||
writeLiggghtsProps
|
||||
{
|
||||
writeLast off;
|
||||
//writeName "name";
|
||||
overwrite on;
|
||||
verbose;
|
||||
}
|
||||
@ -0,0 +1,66 @@
|
||||
/*--------------------------------*- C++ -*----------------------------------*\
|
||||
| ========= | |
|
||||
| \\ / F ield | OpenFOAM: The Open Source CFD Toolbox |
|
||||
| \\ / O peration | Version: 1.6 |
|
||||
| \\ / A nd | Web: http://www.OpenFOAM.org |
|
||||
| \\/ M anipulation | |
|
||||
\*---------------------------------------------------------------------------*/
|
||||
FoamFile
|
||||
{
|
||||
version 2.0;
|
||||
format ascii;
|
||||
class dictionary;
|
||||
object blockMeshDict;
|
||||
}
|
||||
// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
|
||||
|
||||
convertToMeters 1;
|
||||
|
||||
vertices
|
||||
(
|
||||
(0.0 0 0.0)
|
||||
(0.1 0 0.0)
|
||||
(0.1 0.1 0.0)
|
||||
(0.0 0.1 0.0)
|
||||
(0.0 0 1.0)
|
||||
(0.1 0 1.0)
|
||||
(0.1 0.1 1.0)
|
||||
(0.0 0.1 1.0)
|
||||
);
|
||||
|
||||
blocks
|
||||
(
|
||||
hex (0 1 2 3 4 5 6 7) (10 10 100) simpleGrading (1 1 1) // regular grid
|
||||
//hex (0 1 2 3 4 5 6 7) (25 125 25) simpleGrading (1 1 1) // irrregular fine grid
|
||||
//hex (0 1 2 3 4 5 6 7) (25 25 25) simpleGrading (1 1 1) // irrregular coarse grid
|
||||
//hex (0 1 2 3 4 5 6 7) (10 25 10) simpleGrading (1 1 1) // irrregular grid (ratio 2)
|
||||
);
|
||||
|
||||
edges
|
||||
(
|
||||
);
|
||||
|
||||
patches
|
||||
(
|
||||
patch inlet
|
||||
(
|
||||
(3 7 6 2)
|
||||
)
|
||||
patch outlet
|
||||
(
|
||||
(1 5 4 0)
|
||||
)
|
||||
wall walls
|
||||
(
|
||||
(0 4 7 3)
|
||||
(2 6 5 1)
|
||||
(0 3 2 1)
|
||||
(4 5 6 7)
|
||||
)
|
||||
);
|
||||
|
||||
mergePatchPairs
|
||||
(
|
||||
);
|
||||
|
||||
// ************************************************************************* //
|
||||
@ -0,0 +1,39 @@
|
||||
/*--------------------------------*- C++ -*----------------------------------*\
|
||||
| ========= | |
|
||||
| \\ / F ield | OpenFOAM: The Open Source CFD Toolbox |
|
||||
| \\ / O peration | Version: 1.6 |
|
||||
| \\ / A nd | Web: www.OpenFOAM.org |
|
||||
| \\/ M anipulation | |
|
||||
\*---------------------------------------------------------------------------*/
|
||||
FoamFile
|
||||
{
|
||||
version 2.0;
|
||||
format ascii;
|
||||
class dictionary;
|
||||
location "constant";
|
||||
object transportProperties;
|
||||
}
|
||||
// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
|
||||
|
||||
|
||||
transportModel Newtonian;
|
||||
|
||||
nu nu [ 0 2 -1 0 0 0 0 ] 1e-05;
|
||||
|
||||
CrossPowerLawCoeffs
|
||||
{
|
||||
nu0 nu0 [ 0 2 -1 0 0 0 0 ] 1e-06;
|
||||
nuInf nuInf [ 0 2 -1 0 0 0 0 ] 1e-06;
|
||||
m m [ 0 0 1 0 0 0 0 ] 1;
|
||||
n n [ 0 0 0 0 0 0 0 ] 1;
|
||||
}
|
||||
|
||||
BirdCarreauCoeffs
|
||||
{
|
||||
nu0 nu0 [ 0 2 -1 0 0 0 0 ] 1e-06;
|
||||
nuInf nuInf [ 0 2 -1 0 0 0 0 ] 1e-06;
|
||||
k k [ 0 0 1 0 0 0 0 ] 0;
|
||||
n n [ 0 0 0 0 0 0 0 ] 1;
|
||||
}
|
||||
|
||||
// ************************************************************************* //
|
||||
@ -0,0 +1,21 @@
|
||||
/*--------------------------------*- C++ -*----------------------------------*\
|
||||
| ========= | |
|
||||
| \\ / F ield | OpenFOAM: The Open Source CFD Toolbox |
|
||||
| \\ / O peration | Version: 1.6 |
|
||||
| \\ / A nd | Web: www.OpenFOAM.org |
|
||||
| \\/ M anipulation | |
|
||||
\*---------------------------------------------------------------------------*/
|
||||
FoamFile
|
||||
{
|
||||
version 2.0;
|
||||
format ascii;
|
||||
class dictionary;
|
||||
location "constant";
|
||||
object turbulenceProperties;
|
||||
}
|
||||
// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
|
||||
|
||||
simulationType RASModel;//LESModel; //
|
||||
|
||||
|
||||
// ************************************************************************* //
|
||||
@ -0,0 +1,59 @@
|
||||
%test
|
||||
close all;
|
||||
clear;
|
||||
clc;
|
||||
|
||||
%====================================%
|
||||
% simulation data
|
||||
%====================================%
|
||||
path = '../postProcessing/particleCellVolume/0/particleCellVolume.txt';
|
||||
data = load(path);
|
||||
Vp_sim = data(:,2);
|
||||
t_sim = data(:,1);
|
||||
|
||||
path = '../postProcessing/volWeightedAverage/0/volWeightedAverage.txt';
|
||||
data = load(path);
|
||||
volAvDdtVoidFraction_sim = data(:,2);
|
||||
t_sim = data(:,1);
|
||||
|
||||
%====================================%
|
||||
dp=2*0.0015;
|
||||
vp=0.3
|
||||
deltaT=0.001 % coupling time
|
||||
%====================================%
|
||||
% analytical calculation
|
||||
%====================================%
|
||||
Vp=dp*dp*dp*pi/6;
|
||||
np=1000;
|
||||
Vptot=np*Vp
|
||||
|
||||
kernelSize=8
|
||||
Vc=(0.1/10)^3*kernelSize
|
||||
Vp=dp^3*pi/6
|
||||
deltaVpdt=Vp*(deltaT*vp)/dp
|
||||
avg_ddt_voidfraction=deltaVpdt/(Vc*deltaT)
|
||||
|
||||
%====================================%
|
||||
% plot data
|
||||
%====================================%
|
||||
figure(1)
|
||||
plot(t_sim,(Vp_sim./Vptot)*100,'r-')
|
||||
hold on;
|
||||
%legend("error")
|
||||
title("particle volume represented in cells");
|
||||
grid on;
|
||||
xlabel("time in s");
|
||||
ylabel("particle cell volume / particle volume in %");
|
||||
print('-dpng','-r450', 'particleCellVolume')
|
||||
|
||||
figure(2)
|
||||
plot(t_sim,volAvDdtVoidFraction_sim,'r-',[min(t_sim),max(t_sim)],[avg_ddt_voidfraction,avg_ddt_voidfraction],'b-')
|
||||
grid on;
|
||||
%axis([0,max(t_sim),0,100])
|
||||
hold on;
|
||||
legend("simulation",'analytic')
|
||||
title("average ddt(voidfraction)");
|
||||
grid on;
|
||||
xlabel("time in s");
|
||||
ylabel("average ddt(voidfraction)");
|
||||
print('-dpng','-r450', 'averageDDTvoidfraction')
|
||||
@ -0,0 +1,55 @@
|
||||
/*--------------------------------*- C++ -*----------------------------------*\
|
||||
| ========= | |
|
||||
| \\ / F ield | OpenFOAM: The Open Source CFD Toolbox |
|
||||
| \\ / O peration | Version: 1.6 |
|
||||
| \\ / A nd | Web: www.OpenFOAM.org |
|
||||
| \\/ M anipulation | |
|
||||
\*---------------------------------------------------------------------------*/
|
||||
FoamFile
|
||||
{
|
||||
version 2.0;
|
||||
format ascii;
|
||||
class dictionary;
|
||||
location "system";
|
||||
object controlDict;
|
||||
}
|
||||
// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
|
||||
|
||||
application cfdemSolverPiso;
|
||||
|
||||
startFrom startTime;
|
||||
|
||||
startTime 0;
|
||||
|
||||
stopAt endTime;
|
||||
|
||||
endTime 0.2;
|
||||
|
||||
deltaT 0.001;
|
||||
|
||||
writeControl adjustableRunTime;
|
||||
|
||||
writeInterval 0.001;
|
||||
|
||||
purgeWrite 0;
|
||||
|
||||
writeFormat ascii;
|
||||
|
||||
writePrecision 6;
|
||||
|
||||
writeCompression uncompressed;
|
||||
|
||||
timeFormat general;
|
||||
|
||||
timePrecision 6;
|
||||
|
||||
runTimeModifiable yes;
|
||||
|
||||
adjustTimeStep no;
|
||||
|
||||
maxCo 1;
|
||||
|
||||
maxDeltaT 1;
|
||||
|
||||
|
||||
// ************************************************************************* //
|
||||
@ -0,0 +1,55 @@
|
||||
/*--------------------------------*- C++ -*----------------------------------*\
|
||||
| ========= | |
|
||||
| \\ / F ield | OpenFOAM: The Open Source CFD Toolbox |
|
||||
| \\ / O peration | Version: 1.6 |
|
||||
| \\ / A nd | Web: www.OpenFOAM.org |
|
||||
| \\/ M anipulation | |
|
||||
\*---------------------------------------------------------------------------*/
|
||||
FoamFile
|
||||
{
|
||||
version 2.0;
|
||||
format ascii;
|
||||
class dictionary;
|
||||
location "system";
|
||||
object controlDict;
|
||||
}
|
||||
// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
|
||||
|
||||
application interDyMFoam;
|
||||
|
||||
startFrom startTime;
|
||||
|
||||
startTime 0;
|
||||
|
||||
stopAt endTime;
|
||||
|
||||
endTime 0.15;
|
||||
|
||||
deltaT 0.001; //0.0005;
|
||||
|
||||
writeControl adjustableRunTime;
|
||||
|
||||
writeInterval 0.01;//0.05;
|
||||
|
||||
purgeWrite 0;
|
||||
|
||||
writeFormat ascii;
|
||||
|
||||
writePrecision 6;
|
||||
|
||||
writeCompression uncompressed;
|
||||
|
||||
timeFormat general;
|
||||
|
||||
timePrecision 6;
|
||||
|
||||
runTimeModifiable yes;
|
||||
|
||||
adjustTimeStep no;
|
||||
|
||||
maxCo 1;
|
||||
|
||||
maxDeltaT 1;
|
||||
|
||||
|
||||
// ************************************************************************* //
|
||||
@ -0,0 +1,49 @@
|
||||
/*--------------------------------*- C++ -*----------------------------------*\
|
||||
| ========= | |
|
||||
| \\ / F ield | OpenFOAM: The Open Source CFD Toolbox |
|
||||
| \\ / O peration | Version: 1.6 |
|
||||
| \\ / A nd | Web: www.OpenFOAM.org |
|
||||
| \\/ M anipulation | |
|
||||
\*---------------------------------------------------------------------------*/
|
||||
FoamFile
|
||||
{
|
||||
version 2.0;
|
||||
format ascii;
|
||||
class dictionary;
|
||||
location "system";
|
||||
object decomposeParDict;
|
||||
}
|
||||
// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
|
||||
|
||||
numberOfSubdomains 2;
|
||||
|
||||
method simple;
|
||||
|
||||
simpleCoeffs
|
||||
{
|
||||
n ( 1 1 2 );
|
||||
delta 0.001;
|
||||
}
|
||||
|
||||
hierarchicalCoeffs
|
||||
{
|
||||
n ( 2 2 1 );
|
||||
delta 0.001;
|
||||
order xyz;
|
||||
}
|
||||
|
||||
metisCoeffs
|
||||
{
|
||||
}
|
||||
|
||||
manualCoeffs
|
||||
{
|
||||
dataFile "";
|
||||
}
|
||||
|
||||
distributed no;
|
||||
|
||||
roots ( );
|
||||
|
||||
|
||||
// ************************************************************************* //
|
||||
@ -0,0 +1,82 @@
|
||||
/*--------------------------------*- C++ -*----------------------------------*\
|
||||
| ========= | |
|
||||
| \\ / F ield | OpenFOAM: The Open Source CFD Toolbox |
|
||||
| \\ / O peration | Version: 1.6 |
|
||||
| \\ / A nd | Web: www.OpenFOAM.org |
|
||||
| \\/ M anipulation | |
|
||||
\*---------------------------------------------------------------------------*/
|
||||
FoamFile
|
||||
{
|
||||
version 2.0;
|
||||
format ascii;
|
||||
class dictionary;
|
||||
location "system";
|
||||
object fvSchemes;
|
||||
}
|
||||
// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
|
||||
|
||||
ddtSchemes
|
||||
{
|
||||
default Euler;
|
||||
}
|
||||
|
||||
gradSchemes
|
||||
{
|
||||
default Gauss linear;
|
||||
grad(p) Gauss linear;
|
||||
grad(U) Gauss linear;
|
||||
}
|
||||
|
||||
divSchemes
|
||||
{
|
||||
default Gauss linear;
|
||||
div(phi,U) Gauss limitedLinearV 1;
|
||||
div(phi,k) Gauss limitedLinear 1;
|
||||
div(phi,epsilon) Gauss limitedLinear 1;
|
||||
div(phi,R) Gauss limitedLinear 1;
|
||||
div(R) Gauss linear;
|
||||
div(phi,nuTilda) Gauss limitedLinear 1;
|
||||
div((nuEff*dev(grad(U).T()))) Gauss linear;
|
||||
div((nuEff*dev(T(grad(U))))) Gauss linear;
|
||||
div((viscousTerm*dev(grad(U).T()))) Gauss linear;
|
||||
div((nu*dev(grad(U).T()))) Gauss linear;
|
||||
}
|
||||
|
||||
laplacianSchemes
|
||||
{
|
||||
default Gauss linear corrected;
|
||||
laplacian(viscousTerm,U) Gauss linear corrected;
|
||||
laplacian(nu,U) Gauss linear corrected;
|
||||
laplacian(nuEff,U) Gauss linear corrected;
|
||||
laplacian((1|A(U)),p) Gauss linear corrected;
|
||||
laplacian((voidfraction2|A(U)),p) Gauss linear corrected;
|
||||
laplacian(DkEff,k) Gauss linear corrected;
|
||||
laplacian(DepsilonEff,epsilon) Gauss linear corrected;
|
||||
laplacian(DREff,R) Gauss linear corrected;
|
||||
laplacian(DnuTildaEff,nuTilda) Gauss linear corrected;
|
||||
}
|
||||
|
||||
interpolationSchemes
|
||||
{
|
||||
default linear;
|
||||
//interpolate(U) linear;
|
||||
//interpolate((1|A(U))) linear;
|
||||
//interpolate((U*voidfraction)) linear;
|
||||
//interpolate((Us*voidfraction)) linear;
|
||||
//interpolate((Ksl|rho)) linear;
|
||||
|
||||
}
|
||||
|
||||
snGradSchemes
|
||||
{
|
||||
default corrected;
|
||||
}
|
||||
|
||||
fluxRequired
|
||||
{
|
||||
default no;
|
||||
p ;
|
||||
}
|
||||
|
||||
|
||||
// ************************************************************************* //
|
||||
@ -0,0 +1,62 @@
|
||||
/*--------------------------------*- C++ -*----------------------------------*\
|
||||
| ========= | |
|
||||
| \\ / F ield | OpenFOAM: The Open Source CFD Toolbox |
|
||||
| \\ / O peration | Version: 1.6 |
|
||||
| \\ / A nd | Web: www.OpenFOAM.org |
|
||||
| \\/ M anipulation | |
|
||||
\*---------------------------------------------------------------------------*/
|
||||
FoamFile
|
||||
{
|
||||
version 2.0;
|
||||
format ascii;
|
||||
class dictionary;
|
||||
location "system";
|
||||
object fvSolution;
|
||||
}
|
||||
// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
|
||||
|
||||
solvers
|
||||
{
|
||||
p
|
||||
{
|
||||
solver PCG;
|
||||
preconditioner DIC;
|
||||
tolerance 1e-06;
|
||||
relTol 0.1;
|
||||
}
|
||||
|
||||
pFinal
|
||||
{
|
||||
solver PCG;
|
||||
preconditioner DIC;
|
||||
tolerance 1e-06;
|
||||
relTol 0;
|
||||
}
|
||||
|
||||
"(U|k|epsilon|R|nuTilda)"
|
||||
{
|
||||
solver PBiCG;
|
||||
preconditioner DILU;
|
||||
tolerance 1e-05;
|
||||
relTol 0;
|
||||
}
|
||||
|
||||
"(voidfraction|Ksl|UsNext|voidfractionNext|sSmoothField|vSmoothField|fSmooth)"
|
||||
{
|
||||
solver PCG;
|
||||
preconditioner DIC;
|
||||
tolerance 1e-09;
|
||||
relTol 1e-06;
|
||||
}
|
||||
}
|
||||
|
||||
PISO
|
||||
{
|
||||
nCorrectors 4;
|
||||
nNonOrthogonalCorrectors 0;
|
||||
pRefCell 0;
|
||||
pRefValue 0;
|
||||
}
|
||||
|
||||
|
||||
// ************************************************************************* //
|
||||
@ -0,0 +1,78 @@
|
||||
echo both
|
||||
log ../DEM/log.liggghts
|
||||
thermo_log ../DEM/post/thermo.txt
|
||||
|
||||
atom_style granular
|
||||
atom_modify map array sort 0 0
|
||||
communicate single vel yes
|
||||
|
||||
boundary f f f
|
||||
newton off
|
||||
|
||||
units si
|
||||
|
||||
region reg block 0 0.1 0 0.1 0. 1.0 units box
|
||||
create_box 1 reg
|
||||
|
||||
neighbor 0.003 bin
|
||||
neigh_modify delay 0 binsize 0.01
|
||||
|
||||
|
||||
# Material properties required for granular pair styles
|
||||
fix m1 all property/global youngsModulus peratomtype 5.e6
|
||||
fix m2 all property/global poissonsRatio peratomtype 0.45
|
||||
fix m3 all property/global coefficientRestitution peratomtypepair 1 0.3
|
||||
fix m4 all property/global coefficientFriction peratomtypepair 1 0.5
|
||||
#fix m5 all property/global characteristicVelocity scalar 2.0
|
||||
|
||||
# pair style
|
||||
pair_style gran model hertz tangential history # hertz without cohesion
|
||||
pair_coeff * *
|
||||
|
||||
# timestep, gravity
|
||||
timestep 0.00001
|
||||
fix gravi all gravity 0.0 vector 0.0 0.0 -1.0
|
||||
|
||||
# walls
|
||||
fix xwalls1 all wall/gran model hertz tangential history primitive type 1 xplane 0.0
|
||||
fix xwalls2 all wall/gran model hertz tangential history primitive type 1 xplane 0.1
|
||||
fix ywalls1 all wall/gran model hertz tangential history primitive type 1 yplane 0.0
|
||||
fix ywalls2 all wall/gran model hertz tangential history primitive type 1 yplane 0.1
|
||||
fix zwalls1 all wall/gran model hertz tangential history primitive type 1 zplane 0.0
|
||||
fix zwalls2 all wall/gran model hertz tangential history primitive type 1 zplane 0.01
|
||||
|
||||
# create single partciles
|
||||
region bc block 0 0.1 0 0.1 0.53 1.0 units box
|
||||
fix pts1 all particletemplate/sphere 1 atom_type 1 density constant 3000 radius constant 0.0015
|
||||
fix pdd1 all particledistribution/discrete 1. 1 pts1 1.0
|
||||
|
||||
fix ins all insert/pack seed 100001 distributiontemplate pdd1 vel constant 0. 0. -0.3 insert_every once overlapcheck yes all_in yes particles_in_region 1000 region bc
|
||||
|
||||
#create_atoms 1 single 0.00733 0.0517 0.6 units box
|
||||
#set group all diameter 0.003 density 3000
|
||||
|
||||
# cfd coupling
|
||||
fix cfd all couple/cfd couple_every 100 mpi
|
||||
fix cfd2 all couple/cfd/force
|
||||
|
||||
variable vx equal vx[1]
|
||||
variable vy equal vy[1]
|
||||
variable vz equal vz[1]
|
||||
variable time equal step*dt
|
||||
fix extra all print 100 "${time} ${vx} ${vy} ${vz}" file ../DEM/post/velocity.txt title "#" screen no
|
||||
|
||||
# apply nve integration to all particles that are inserted as single particles
|
||||
fix integr all nve/sphere
|
||||
|
||||
# screen output
|
||||
compute rke all erotate/sphere
|
||||
thermo_style custom step atoms ke c_rke vol
|
||||
thermo 1000
|
||||
thermo_modify lost ignore norm no
|
||||
compute_modify thermo_temp dynamic yes
|
||||
|
||||
# insert the first particles so that dump is not empty
|
||||
run 0
|
||||
dump dmp all custom 1000 ../DEM/post/dump.liggghts_run id type x y z ix iy iz vx vy vz fx fy fz omegax omegay omegaz radius
|
||||
|
||||
run 0 upto
|
||||
0
tutorials/cfdemSolverPiso/voidfractionTest/DEM/post/.gitignore
vendored
Normal file
0
tutorials/cfdemSolverPiso/voidfractionTest/DEM/post/.gitignore
vendored
Normal file
99
tutorials/cfdemSolverPiso/voidfractionTest/parCFDDEMrun.sh
Normal file
99
tutorials/cfdemSolverPiso/voidfractionTest/parCFDDEMrun.sh
Normal file
@ -0,0 +1,99 @@
|
||||
#!/bin/bash
|
||||
|
||||
#===================================================================#
|
||||
# allrun script for testcase as part of test routine
|
||||
# run settlingTest CFD part
|
||||
# Christoph Goniva - Feb. 2011
|
||||
#===================================================================#
|
||||
|
||||
#- source CFDEM env vars
|
||||
. ~/.bashrc
|
||||
|
||||
#- include functions
|
||||
source $CFDEM_SRC_DIR/lagrangian/cfdemParticle/etc/functions.sh
|
||||
|
||||
#--------------------------------------------------------------------------------#
|
||||
#- define variables
|
||||
casePath="$(dirname "$(readlink -f ${BASH_SOURCE[0]})")"
|
||||
logpath=$casePath
|
||||
headerText="run_parallel_cfdemSolverPiso_voidfractionTest_CFDDEM"
|
||||
logfileName="log_$headerText"
|
||||
solverName="cfdemSolverPiso"
|
||||
nrProcs="2"
|
||||
machineFileName="none" # yourMachinefileName | none
|
||||
debugMode="off" # on | off| strict
|
||||
reconstuctCase="false"
|
||||
testHarnessPath="$CFDEM_TEST_HARNESS_PATH"
|
||||
runOctave="true"
|
||||
cleanUp="true"
|
||||
postproc="false"
|
||||
#--------------------------------------------------------------------------------#
|
||||
|
||||
#- call function to run a parallel CFD-DEM case
|
||||
parCFDDEMrun $logpath $logfileName $casePath $headerText $solverName $nrProcs $machineFileName $debugMode $reconstuctCase
|
||||
|
||||
if [ $runOctave == "true" ]
|
||||
then
|
||||
#- change path
|
||||
cd octave
|
||||
|
||||
#- rmove old graph
|
||||
rm averageDDTvoidfraction.png
|
||||
|
||||
#- run octave
|
||||
octave particleCellVolume.m
|
||||
|
||||
#- show plot
|
||||
eog averageDDTvoidfraction.png
|
||||
|
||||
#- copy log file to test harness
|
||||
cp ../../$logfileName $testHarnessPath
|
||||
cp averageDDTvoidfraction.png $testHarnessPath
|
||||
fi
|
||||
|
||||
if [ $postproc == "true" ]
|
||||
then
|
||||
|
||||
#- keep terminal open (if started in new terminal)
|
||||
echo "simulation finished? ...press enter to proceed"
|
||||
read
|
||||
|
||||
#- get VTK data from liggghts dump file
|
||||
cd $casePath/DEM/post
|
||||
python -i $CFDEM_LPP_DIR/lpp.py dump.liggghts_run
|
||||
|
||||
#- get VTK data from CFD sim
|
||||
cd $casePath/CFD
|
||||
foamToVTK #- serial run of foamToVTK
|
||||
#source $CFDEM_SRC_DIR/lagrangian/cfdemParticle/etc/functions.sh #- include functions
|
||||
#pseudoParallelRun "foamToVTK" $nrPostProcProcessors #- pseudo parallel run of foamToVTK
|
||||
|
||||
#- start paraview
|
||||
paraview
|
||||
|
||||
#- keep terminal open (if started in new terminal)
|
||||
echo "...press enter to clean up case"
|
||||
echo "press Ctr+C to keep data"
|
||||
read
|
||||
fi
|
||||
|
||||
#- clean up case
|
||||
if [ $cleanUp == "true" ]
|
||||
then
|
||||
echo "deleting data at: $casePath ?:\n"
|
||||
read
|
||||
source $WM_PROJECT_DIR/bin/tools/CleanFunctions
|
||||
cd $casePath/CFD
|
||||
cleanCase
|
||||
cd $casePath
|
||||
rm -r $casePath/CFD/particleProbes
|
||||
rm -r $casePath/CFD/postProcessing
|
||||
rm -r $casePath/CFD/clockData
|
||||
rm -r $casePath/DEM/post/*
|
||||
rm -r $casePath/DEM/liggghts.restartCFDEM*
|
||||
echo "done"
|
||||
fi
|
||||
|
||||
#- preserve post directory
|
||||
touch $casePath/DEM/post/.gitignore
|
||||
|
||||
30
tutorials/cfdemSolverPisoSTM/packedBedTemp/Allrun.sh
Executable file
30
tutorials/cfdemSolverPisoSTM/packedBedTemp/Allrun.sh
Executable file
@ -0,0 +1,30 @@
|
||||
#!/bin/bash
|
||||
|
||||
#===================================================================#
|
||||
# allrun script for testcase as part of test routine
|
||||
# run settlingTest
|
||||
# Christoph Goniva - August 2011
|
||||
#===================================================================#
|
||||
|
||||
#- define variables
|
||||
casePath="$(dirname "$(readlink -f ${BASH_SOURCE[0]})")"
|
||||
|
||||
# check if mesh was built
|
||||
if [ -f "$casePath/CFD/constant/polyMesh/points" ]; then
|
||||
echo "mesh was built before - using old mesh"
|
||||
else
|
||||
echo "mesh needs to be built"
|
||||
cd $casePath/CFD
|
||||
blockMesh
|
||||
fi
|
||||
|
||||
if [ -f "$casePath/DEM/post/restart/liggghts.restart" ]; then
|
||||
echo "LIGGGHTS init was run before - using existing restart file"
|
||||
else
|
||||
#- run DEM init
|
||||
$casePath/parDEMrun.sh
|
||||
fi
|
||||
|
||||
#- run parallel CFD-DEM in new terminal
|
||||
#gnome-terminal --title='cfdemSolverPisoScalar packedBedTemp CFD' -e "bash $casePath/parCFDDEMrun.sh"
|
||||
bash $casePath/parCFDDEMrun.sh
|
||||
40
tutorials/cfdemSolverPisoSTM/packedBedTemp/CFD/0/C
Normal file
40
tutorials/cfdemSolverPisoSTM/packedBedTemp/CFD/0/C
Normal file
@ -0,0 +1,40 @@
|
||||
/*--------------------------------*- C++ -*----------------------------------*\
|
||||
| ========= | |
|
||||
| \\ / F ield | OpenFOAM: The Open Source CFD Toolbox |
|
||||
| \\ / O peration | Version: 1.6 |
|
||||
| \\ / A nd | Web: http://www.OpenFOAM.org |
|
||||
| \\/ M anipulation | |
|
||||
\*---------------------------------------------------------------------------*/
|
||||
FoamFile
|
||||
{
|
||||
version 2.0;
|
||||
format ascii;
|
||||
class volScalarField;
|
||||
object C;
|
||||
}
|
||||
// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
|
||||
|
||||
dimensions [0 0 0 0 0 0 0];
|
||||
|
||||
internalField uniform 0;
|
||||
|
||||
boundaryField
|
||||
{
|
||||
inlet
|
||||
{
|
||||
type fixedValue;
|
||||
value $internalField;
|
||||
}
|
||||
|
||||
outlet
|
||||
{
|
||||
type zeroGradient;
|
||||
}
|
||||
|
||||
wall
|
||||
{
|
||||
type zeroGradient;
|
||||
}
|
||||
}
|
||||
|
||||
// ************************************************************************* //
|
||||
42
tutorials/cfdemSolverPisoSTM/packedBedTemp/CFD/0/CSource
Normal file
42
tutorials/cfdemSolverPisoSTM/packedBedTemp/CFD/0/CSource
Normal file
@ -0,0 +1,42 @@
|
||||
/*--------------------------------*- C++ -*----------------------------------*\
|
||||
| ========= | |
|
||||
| \\ / F ield | OpenFOAM: The Open Source CFD Toolbox |
|
||||
| \\ / O peration | Version: 1.6 |
|
||||
| \\ / A nd | Web: www.OpenFOAM.org |
|
||||
| \\/ M anipulation | |
|
||||
\*---------------------------------------------------------------------------*/
|
||||
FoamFile
|
||||
{
|
||||
version 2.0;
|
||||
format ascii;
|
||||
class volScalarField;
|
||||
location "0.05";
|
||||
object CSource;
|
||||
}
|
||||
// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
|
||||
|
||||
dimensions [0 0 -1 0 0 0 0];
|
||||
|
||||
internalField uniform 0;
|
||||
|
||||
boundaryField
|
||||
{
|
||||
inlet
|
||||
{
|
||||
type zeroGradient;
|
||||
value uniform 0;
|
||||
}
|
||||
outlet
|
||||
{
|
||||
type zeroGradient;
|
||||
value uniform 0;
|
||||
}
|
||||
wall
|
||||
{
|
||||
type zeroGradient;
|
||||
value uniform 0;
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
// ************************************************************************* //
|
||||
41
tutorials/cfdemSolverPisoSTM/packedBedTemp/CFD/0/Ksl
Normal file
41
tutorials/cfdemSolverPisoSTM/packedBedTemp/CFD/0/Ksl
Normal file
@ -0,0 +1,41 @@
|
||||
/*--------------------------------*- C++ -*----------------------------------*\
|
||||
| ========= | |
|
||||
| \\ / F ield | OpenFOAM: The Open Source CFD Toolbox |
|
||||
| \\ / O peration | Version: 1.6 |
|
||||
| \\ / A nd | Web: www.OpenFOAM.org |
|
||||
| \\/ M anipulation | |
|
||||
\*---------------------------------------------------------------------------*/
|
||||
FoamFile
|
||||
{
|
||||
version 2.0;
|
||||
format ascii;
|
||||
class volScalarField;
|
||||
location "0";
|
||||
object Ksl;
|
||||
}
|
||||
// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
|
||||
|
||||
dimensions [1 -3 -1 0 0 0 0];
|
||||
|
||||
internalField uniform 0;
|
||||
|
||||
boundaryField
|
||||
{
|
||||
wall
|
||||
{
|
||||
type zeroGradient;
|
||||
//type fixedValue;
|
||||
//value uniform 0;
|
||||
}
|
||||
inlet
|
||||
{
|
||||
type zeroGradient;
|
||||
}
|
||||
outlet
|
||||
{
|
||||
type zeroGradient;
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
// ************************************************************************* //
|
||||
40
tutorials/cfdemSolverPisoSTM/packedBedTemp/CFD/0/T
Normal file
40
tutorials/cfdemSolverPisoSTM/packedBedTemp/CFD/0/T
Normal file
@ -0,0 +1,40 @@
|
||||
/*--------------------------------*- C++ -*----------------------------------*\
|
||||
| ========= | |
|
||||
| \\ / F ield | OpenFOAM: The Open Source CFD Toolbox |
|
||||
| \\ / O peration | Version: 1.6 |
|
||||
| \\ / A nd | Web: http://www.OpenFOAM.org |
|
||||
| \\/ M anipulation | |
|
||||
\*---------------------------------------------------------------------------*/
|
||||
FoamFile
|
||||
{
|
||||
version 2.0;
|
||||
format ascii;
|
||||
class volScalarField;
|
||||
object T;
|
||||
}
|
||||
// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
|
||||
|
||||
dimensions [0 0 0 1 0 0 0];
|
||||
|
||||
internalField uniform 263;
|
||||
|
||||
boundaryField
|
||||
{
|
||||
inlet
|
||||
{
|
||||
type fixedValue;
|
||||
value uniform 263;
|
||||
}
|
||||
|
||||
outlet
|
||||
{
|
||||
type zeroGradient;
|
||||
}
|
||||
|
||||
wall
|
||||
{
|
||||
type zeroGradient;
|
||||
}
|
||||
}
|
||||
|
||||
// ************************************************************************* //
|
||||
50
tutorials/cfdemSolverPisoSTM/packedBedTemp/CFD/0/TSource
Normal file
50
tutorials/cfdemSolverPisoSTM/packedBedTemp/CFD/0/TSource
Normal file
@ -0,0 +1,50 @@
|
||||
/*--------------------------------*- C++ -*----------------------------------*\
|
||||
| ========= | |
|
||||
| \\ / F ield | OpenFOAM: The Open Source CFD Toolbox |
|
||||
| \\ / O peration | Version: 1.6 |
|
||||
| \\ / A nd | Web: www.OpenFOAM.org |
|
||||
| \\/ M anipulation | |
|
||||
\*---------------------------------------------------------------------------*/
|
||||
FoamFile
|
||||
{
|
||||
version 2.0;
|
||||
format ascii;
|
||||
class volScalarField;
|
||||
location "0.05";
|
||||
object TSource;
|
||||
}
|
||||
// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
|
||||
|
||||
dimensions [0 0 -1 1 0 0 0];
|
||||
|
||||
// Tsource[K/s] = q[W/m3]/(rho[kg/m3]*cp[W*s/(kg*K)])
|
||||
// Q=10 W
|
||||
// V=0.01 m3
|
||||
// q=1000 W/m3
|
||||
// cp=1000
|
||||
// rho=1
|
||||
// --> Tsource = 1
|
||||
|
||||
internalField uniform 0;
|
||||
|
||||
boundaryField
|
||||
{
|
||||
inlet
|
||||
{
|
||||
type zeroGradient;
|
||||
value uniform 0;
|
||||
}
|
||||
outlet
|
||||
{
|
||||
type zeroGradient;
|
||||
value uniform 0;
|
||||
}
|
||||
wall
|
||||
{
|
||||
type zeroGradient;
|
||||
value uniform 0;
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
// ************************************************************************* //
|
||||
43
tutorials/cfdemSolverPisoSTM/packedBedTemp/CFD/0/U
Normal file
43
tutorials/cfdemSolverPisoSTM/packedBedTemp/CFD/0/U
Normal file
@ -0,0 +1,43 @@
|
||||
/*--------------------------------*- C++ -*----------------------------------*\
|
||||
| ========= | |
|
||||
| \\ / F ield | OpenFOAM: The Open Source CFD Toolbox |
|
||||
| \\ / O peration | Version: 1.6 |
|
||||
| \\ / A nd | Web: http://www.OpenFOAM.org |
|
||||
| \\/ M anipulation | |
|
||||
\*---------------------------------------------------------------------------*/
|
||||
FoamFile
|
||||
{
|
||||
version 2.0;
|
||||
format ascii;
|
||||
class volVectorField;
|
||||
object U;
|
||||
}
|
||||
// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
|
||||
|
||||
dimensions [0 1 -1 0 0 0 0];
|
||||
|
||||
internalField uniform (0 0 0.001);
|
||||
|
||||
boundaryField
|
||||
{
|
||||
|
||||
wall
|
||||
{
|
||||
//type fixedValue;
|
||||
//value uniform (0 0 0);
|
||||
type slip;
|
||||
}
|
||||
|
||||
inlet
|
||||
{
|
||||
type fixedValue;
|
||||
value uniform (0 0 1);
|
||||
}
|
||||
|
||||
outlet
|
||||
{
|
||||
type zeroGradient;
|
||||
}
|
||||
}
|
||||
|
||||
// ************************************************************************* //
|
||||
45
tutorials/cfdemSolverPisoSTM/packedBedTemp/CFD/0/Us
Normal file
45
tutorials/cfdemSolverPisoSTM/packedBedTemp/CFD/0/Us
Normal file
@ -0,0 +1,45 @@
|
||||
/*--------------------------------*- C++ -*----------------------------------*\
|
||||
| ========= | |
|
||||
| \\ / F ield | OpenFOAM: The Open Source CFD Toolbox |
|
||||
| \\ / O peration | Version: 1.6 |
|
||||
| \\ / A nd | Web: www.OpenFOAM.org |
|
||||
| \\/ M anipulation | |
|
||||
\*---------------------------------------------------------------------------*/
|
||||
FoamFile
|
||||
{
|
||||
version 2.0;
|
||||
format ascii;
|
||||
class volVectorField;
|
||||
location "0";
|
||||
object Us;
|
||||
}
|
||||
// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
|
||||
|
||||
dimensions [0 1 -1 0 0 0 0];
|
||||
|
||||
internalField uniform (0 0 0);
|
||||
|
||||
boundaryField
|
||||
{
|
||||
wall
|
||||
{
|
||||
type zeroGradient;
|
||||
//type fixedValue;
|
||||
//value uniform (1 0 0);
|
||||
}
|
||||
inlet
|
||||
{
|
||||
type zeroGradient;
|
||||
//type fixedValue;
|
||||
//value uniform (1 0 0);;
|
||||
}
|
||||
outlet
|
||||
{
|
||||
type zeroGradient;
|
||||
//type fixedValue;
|
||||
//value uniform (1 0 0);
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
// ************************************************************************* //
|
||||
48
tutorials/cfdemSolverPisoSTM/packedBedTemp/CFD/0/epsilon
Normal file
48
tutorials/cfdemSolverPisoSTM/packedBedTemp/CFD/0/epsilon
Normal file
@ -0,0 +1,48 @@
|
||||
/*--------------------------------*- C++ -*----------------------------------*\
|
||||
| ========= | |
|
||||
| \\ / F ield | OpenFOAM: The Open Source CFD Toolbox |
|
||||
| \\ / O peration | Version: 1.6 |
|
||||
| \\ / A nd | Web: www.OpenFOAM.org |
|
||||
| \\/ M anipulation | |
|
||||
\*---------------------------------------------------------------------------*/
|
||||
FoamFile
|
||||
{
|
||||
version 2.0;
|
||||
format ascii;
|
||||
class volScalarField;
|
||||
location "0";
|
||||
object epsilon;
|
||||
}
|
||||
// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
|
||||
|
||||
dimensions [0 2 -3 0 0 0 0];
|
||||
|
||||
internalField uniform 0.003;
|
||||
|
||||
boundaryField
|
||||
{
|
||||
wall
|
||||
{
|
||||
type epsilonWallFunction;
|
||||
Cmu 0.09;
|
||||
kappa 0.41;
|
||||
E 9.8;
|
||||
value uniform 0.003;
|
||||
}
|
||||
outlet
|
||||
{
|
||||
type inletOutlet;
|
||||
inletValue uniform 0.003;
|
||||
value uniform 0.003;
|
||||
}
|
||||
inlet
|
||||
{
|
||||
/*type turbulentMixingLengthDissipationRateInlet;
|
||||
mixingLength 0.005;
|
||||
value uniform 0.003;*/
|
||||
type zeroGradient;
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
// ************************************************************************* //
|
||||
45
tutorials/cfdemSolverPisoSTM/packedBedTemp/CFD/0/k
Normal file
45
tutorials/cfdemSolverPisoSTM/packedBedTemp/CFD/0/k
Normal file
@ -0,0 +1,45 @@
|
||||
/*--------------------------------*- C++ -*----------------------------------*\
|
||||
| ========= | |
|
||||
| \\ / F ield | OpenFOAM: The Open Source CFD Toolbox |
|
||||
| \\ / O peration | Version: 1.6 |
|
||||
| \\ / A nd | Web: www.OpenFOAM.org |
|
||||
| \\/ M anipulation | |
|
||||
\*---------------------------------------------------------------------------*/
|
||||
FoamFile
|
||||
{
|
||||
version 2.0;
|
||||
format ascii;
|
||||
class volScalarField;
|
||||
location "0";
|
||||
object k;
|
||||
}
|
||||
// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
|
||||
|
||||
dimensions [0 2 -2 0 0 0 0];
|
||||
|
||||
internalField uniform 0.001;
|
||||
|
||||
boundaryField
|
||||
{
|
||||
wall
|
||||
{
|
||||
type kqRWallFunction;
|
||||
value uniform 0.001;
|
||||
}
|
||||
outlet
|
||||
{
|
||||
type inletOutlet;
|
||||
inletValue uniform 0.001;
|
||||
value uniform 0.001;
|
||||
}
|
||||
inlet
|
||||
{
|
||||
/*type turbulentIntensityKineticEnergyInlet;
|
||||
intensity 0.05;
|
||||
value uniform 0.001;*/
|
||||
type zeroGradient;
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
// ************************************************************************* //
|
||||
45
tutorials/cfdemSolverPisoSTM/packedBedTemp/CFD/0/nut
Normal file
45
tutorials/cfdemSolverPisoSTM/packedBedTemp/CFD/0/nut
Normal file
@ -0,0 +1,45 @@
|
||||
/*--------------------------------*- C++ -*----------------------------------*\
|
||||
| ========= | |
|
||||
| \\ / F ield | OpenFOAM: The Open Source CFD Toolbox |
|
||||
| \\ / O peration | Version: 1.6 |
|
||||
| \\ / A nd | Web: www.OpenFOAM.org |
|
||||
| \\/ M anipulation | |
|
||||
\*---------------------------------------------------------------------------*/
|
||||
FoamFile
|
||||
{
|
||||
version 2.0;
|
||||
format ascii;
|
||||
class volScalarField;
|
||||
location "0";
|
||||
object nut;
|
||||
}
|
||||
// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
|
||||
|
||||
dimensions [0 2 -1 0 0 0 0];
|
||||
|
||||
internalField uniform 0;
|
||||
|
||||
boundaryField
|
||||
{
|
||||
wall
|
||||
{
|
||||
type nutkWallFunction;
|
||||
Cmu 0.09;
|
||||
kappa 0.41;
|
||||
E 9.8;
|
||||
value uniform 0;
|
||||
}
|
||||
outlet
|
||||
{
|
||||
type calculated;
|
||||
value uniform 0;
|
||||
}
|
||||
inlet
|
||||
{
|
||||
type calculated;
|
||||
value uniform 0;
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
// ************************************************************************* //
|
||||
43
tutorials/cfdemSolverPisoSTM/packedBedTemp/CFD/0/p
Normal file
43
tutorials/cfdemSolverPisoSTM/packedBedTemp/CFD/0/p
Normal file
@ -0,0 +1,43 @@
|
||||
/*--------------------------------*- C++ -*----------------------------------*\
|
||||
| ========= | |
|
||||
| \\ / F ield | OpenFOAM: The Open Source CFD Toolbox |
|
||||
| \\ / O peration | Version: 1.6 |
|
||||
| \\ / A nd | Web: http://www.OpenFOAM.org |
|
||||
| \\/ M anipulation | |
|
||||
\*---------------------------------------------------------------------------*/
|
||||
FoamFile
|
||||
{
|
||||
version 2.0;
|
||||
format ascii;
|
||||
class volScalarField;
|
||||
object p;
|
||||
}
|
||||
// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
|
||||
|
||||
dimensions [0 2 -2 0 0 0 0];
|
||||
|
||||
internalField uniform 0;
|
||||
|
||||
boundaryField
|
||||
{
|
||||
|
||||
wall
|
||||
{
|
||||
type zeroGradient;
|
||||
}
|
||||
|
||||
inlet
|
||||
{
|
||||
type zeroGradient;
|
||||
//type fixedValue;
|
||||
//value uniform 100000;
|
||||
}
|
||||
outlet
|
||||
{
|
||||
//type zeroGradient;
|
||||
type fixedValue;
|
||||
value uniform 0;
|
||||
}
|
||||
}
|
||||
|
||||
// ************************************************************************* //
|
||||
39
tutorials/cfdemSolverPisoSTM/packedBedTemp/CFD/0/rho
Normal file
39
tutorials/cfdemSolverPisoSTM/packedBedTemp/CFD/0/rho
Normal file
@ -0,0 +1,39 @@
|
||||
/*--------------------------------*- C++ -*----------------------------------*\
|
||||
| ========= | |
|
||||
| \\ / F ield | OpenFOAM: The Open Source CFD Toolbox |
|
||||
| \\ / O peration | Version: 1.6 |
|
||||
| \\ / A nd | Web: http://www.OpenFOAM.org |
|
||||
| \\/ M anipulation | |
|
||||
\*---------------------------------------------------------------------------*/
|
||||
FoamFile
|
||||
{
|
||||
version 2.0;
|
||||
format ascii;
|
||||
class volScalarField;
|
||||
object rho;
|
||||
}
|
||||
// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
|
||||
|
||||
dimensions [1 -3 0 0 0 0 0];
|
||||
|
||||
internalField uniform 1.188;
|
||||
|
||||
boundaryField
|
||||
{
|
||||
|
||||
wall
|
||||
{
|
||||
type zeroGradient;
|
||||
}
|
||||
|
||||
inlet
|
||||
{
|
||||
type zeroGradient;
|
||||
}
|
||||
outlet
|
||||
{
|
||||
type zeroGradient;
|
||||
}
|
||||
}
|
||||
|
||||
// ************************************************************************* //
|
||||
@ -0,0 +1,41 @@
|
||||
/*--------------------------------*- C++ -*----------------------------------*\
|
||||
| ========= | |
|
||||
| \\ / F ield | OpenFOAM: The Open Source CFD Toolbox |
|
||||
| \\ / O peration | Version: 1.6 |
|
||||
| \\ / A nd | Web: www.OpenFOAM.org |
|
||||
| \\/ M anipulation | |
|
||||
\*---------------------------------------------------------------------------*/
|
||||
FoamFile
|
||||
{
|
||||
version 2.0;
|
||||
format ascii;
|
||||
class volScalarField;
|
||||
location "0";
|
||||
object voidfraction;
|
||||
}
|
||||
// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
|
||||
|
||||
dimensions [0 0 0 0 0 0 0];
|
||||
|
||||
internalField uniform 1;
|
||||
|
||||
boundaryField
|
||||
{
|
||||
wall
|
||||
{
|
||||
type zeroGradient;
|
||||
}
|
||||
outlet
|
||||
{
|
||||
type fixedValue;
|
||||
value uniform 1;
|
||||
}
|
||||
inlet
|
||||
{
|
||||
type fixedValue;
|
||||
value uniform 1;
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
// ************************************************************************* //
|
||||
@ -0,0 +1,86 @@
|
||||
/*--------------------------------*- C++ -*----------------------------------*\
|
||||
| ========= | |
|
||||
| \\ / F ield | OpenFOAM: The Open Source CFD Toolbox |
|
||||
| \\ / O peration | Version: 1.6 |
|
||||
| \\ / A nd | Web: www.OpenFOAM.org |
|
||||
| \\/ M anipulation | |
|
||||
\*---------------------------------------------------------------------------*/
|
||||
FoamFile
|
||||
{
|
||||
version 2.0;
|
||||
format ascii;
|
||||
class dictionary;
|
||||
location "constant";
|
||||
object LESProperties;
|
||||
}
|
||||
// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
|
||||
|
||||
LESModel oneEqEddy;
|
||||
|
||||
delta cubeRootVol;
|
||||
|
||||
printCoeffs on;
|
||||
|
||||
cubeRootVolCoeffs
|
||||
{
|
||||
deltaCoeff 1;
|
||||
}
|
||||
|
||||
PrandtlCoeffs
|
||||
{
|
||||
delta cubeRootVol;
|
||||
cubeRootVolCoeffs
|
||||
{
|
||||
deltaCoeff 1;
|
||||
}
|
||||
|
||||
smoothCoeffs
|
||||
{
|
||||
delta cubeRootVol;
|
||||
cubeRootVolCoeffs
|
||||
{
|
||||
deltaCoeff 1;
|
||||
}
|
||||
|
||||
maxDeltaRatio 1.1;
|
||||
}
|
||||
|
||||
Cdelta 0.158;
|
||||
}
|
||||
|
||||
vanDriestCoeffs
|
||||
{
|
||||
delta cubeRootVol;
|
||||
cubeRootVolCoeffs
|
||||
{
|
||||
deltaCoeff 1;
|
||||
}
|
||||
|
||||
smoothCoeffs
|
||||
{
|
||||
delta cubeRootVol;
|
||||
cubeRootVolCoeffs
|
||||
{
|
||||
deltaCoeff 1;
|
||||
}
|
||||
|
||||
maxDeltaRatio 1.1;
|
||||
}
|
||||
|
||||
Aplus 26;
|
||||
Cdelta 0.158;
|
||||
}
|
||||
|
||||
smoothCoeffs
|
||||
{
|
||||
delta cubeRootVol;
|
||||
cubeRootVolCoeffs
|
||||
{
|
||||
deltaCoeff 1;
|
||||
}
|
||||
|
||||
maxDeltaRatio 1.1;
|
||||
}
|
||||
|
||||
|
||||
// ************************************************************************* //
|
||||
@ -0,0 +1,25 @@
|
||||
/*--------------------------------*- C++ -*----------------------------------*\
|
||||
| ========= | |
|
||||
| \\ / F ield | OpenFOAM: The Open Source CFD Toolbox |
|
||||
| \\ / O peration | Version: 1.6 |
|
||||
| \\ / A nd | Web: www.OpenFOAM.org |
|
||||
| \\/ M anipulation | |
|
||||
\*---------------------------------------------------------------------------*/
|
||||
FoamFile
|
||||
{
|
||||
version 2.0;
|
||||
format ascii;
|
||||
class dictionary;
|
||||
location "constant";
|
||||
object RASProperties;
|
||||
}
|
||||
// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
|
||||
|
||||
RASModel kEpsilon;
|
||||
|
||||
turbulence on;
|
||||
|
||||
printCoeffs on;
|
||||
|
||||
|
||||
// ************************************************************************* //
|
||||
@ -0,0 +1,185 @@
|
||||
/*---------------------------------------------------------------------------*\
|
||||
| ========= | |
|
||||
| \\ / F ield | OpenFOAM: The Open Source CFD Toolbox |
|
||||
| \\ / O peration | Version: 1.4 |
|
||||
| \\ / A nd | Web: http://www.openfoam.org |
|
||||
| \\/ M anipulation | |
|
||||
\*---------------------------------------------------------------------------*/
|
||||
|
||||
|
||||
FoamFile
|
||||
{
|
||||
version 2.0;
|
||||
format ascii;
|
||||
|
||||
root "";
|
||||
case "";
|
||||
instance "";
|
||||
local "";
|
||||
|
||||
class dictionary;
|
||||
object couplingProperties;
|
||||
}
|
||||
|
||||
// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
|
||||
|
||||
//===========================================================================//
|
||||
// sub-models & settings
|
||||
solveFlow true;
|
||||
|
||||
modelType B; // A or B
|
||||
|
||||
couplingInterval 500;
|
||||
|
||||
voidFractionModel divided;
|
||||
|
||||
locateModel engine;
|
||||
|
||||
meshMotionModel noMeshMotion;
|
||||
|
||||
regionModel allRegion;
|
||||
|
||||
IOModel basicIO;
|
||||
|
||||
probeModel off;
|
||||
|
||||
dataExchangeModel twoWayMPI;
|
||||
|
||||
averagingModel dense;//dilute;//
|
||||
|
||||
clockModel off;//standardClock;//
|
||||
|
||||
smoothingModel off;
|
||||
|
||||
forceModels
|
||||
(
|
||||
KochHillDrag
|
||||
scalarGeneralExchange // must be 2nd pos!
|
||||
Archimedes
|
||||
);
|
||||
|
||||
momCoupleModels
|
||||
(
|
||||
implicitCouple
|
||||
);
|
||||
|
||||
turbulenceModelType RASProperties;//LESProperties;//
|
||||
|
||||
//===========================================================================//
|
||||
// sub-model properties
|
||||
|
||||
scalarGeneralExchangeProps
|
||||
{
|
||||
/* verbose true;*/
|
||||
velFieldName "U";
|
||||
voidfractionFieldName "voidfraction";
|
||||
tempFieldName "T";
|
||||
partTempName "Temp";
|
||||
partHeatFluxName "convectiveHeatFlux";
|
||||
lambda 0.0256;
|
||||
Prandtl 70.097; //WARNING: this is not a typical gas - just for testing purposes!
|
||||
useLiMason true;
|
||||
|
||||
//Lists with information for each species FOR THE PARTICLES
|
||||
//MUST be in the same order as eulerian species in 'scalarTransportProperties'
|
||||
//MUST correspond to property/atom in ligghts (use 'couple/cfd/speciesConvection' to auto-generate individual fields)
|
||||
partSpeciesNames
|
||||
(
|
||||
speciesC
|
||||
);
|
||||
partSpeciesFluxNames
|
||||
(
|
||||
speciesCFlux
|
||||
);
|
||||
partSpeciesTransCoeffNames
|
||||
(
|
||||
speciesCTransCoeff
|
||||
);
|
||||
partSpeciesFluidNames
|
||||
(
|
||||
speciesCFluid
|
||||
);
|
||||
DMolecular
|
||||
(
|
||||
1e-5
|
||||
);
|
||||
//parameters for the vapor pressure model
|
||||
parameterVap
|
||||
(
|
||||
0
|
||||
);
|
||||
|
||||
}
|
||||
|
||||
implicitCoupleProps
|
||||
{
|
||||
velFieldName "U";
|
||||
granVelFieldName "Us";
|
||||
voidfractionFieldName "voidfraction";
|
||||
//KslLimit 0; // source switched off!!!
|
||||
}
|
||||
|
||||
explicitCoupleProps
|
||||
{
|
||||
//fLimit (0 0 0);
|
||||
}
|
||||
|
||||
KochHillDragProps
|
||||
{
|
||||
velFieldName "U";
|
||||
voidfractionFieldName "voidfraction";
|
||||
}
|
||||
|
||||
DiFeliceDragProps
|
||||
{
|
||||
velFieldName "U";
|
||||
//verbose true;
|
||||
}
|
||||
|
||||
ArchimedesProps
|
||||
{
|
||||
gravityFieldName "g";
|
||||
}
|
||||
gradPForceProps
|
||||
{
|
||||
pFieldName "p";
|
||||
voidfractionFieldName "voidfraction";
|
||||
velocityFieldName "U";
|
||||
//interpolation true;
|
||||
}
|
||||
|
||||
viscForceProps
|
||||
{
|
||||
velocityFieldName "U";
|
||||
interpolation true;
|
||||
}
|
||||
|
||||
oneWayVTKProps
|
||||
{
|
||||
couplingFilename "vtk_out%4.4d.vtk";
|
||||
maxNumberOfParticles 30000;
|
||||
}
|
||||
|
||||
twoWayMPIProps
|
||||
{
|
||||
maxNumberOfParticles 10000;
|
||||
liggghtsPath "../DEM/in.liggghts_run";
|
||||
}
|
||||
|
||||
centreProps
|
||||
{
|
||||
alphaMin 0.1;
|
||||
}
|
||||
|
||||
dividedProps
|
||||
{
|
||||
alphaMin 0.4;
|
||||
scaleUpVol 1.0;
|
||||
}
|
||||
|
||||
engineProps
|
||||
{
|
||||
treeSearch true;
|
||||
}
|
||||
|
||||
// ************************************************************************* //
|
||||
22
tutorials/cfdemSolverPisoSTM/packedBedTemp/CFD/constant/g
Normal file
22
tutorials/cfdemSolverPisoSTM/packedBedTemp/CFD/constant/g
Normal file
@ -0,0 +1,22 @@
|
||||
/*--------------------------------*- C++ -*----------------------------------*\
|
||||
| ========= | |
|
||||
| \\ / F ield | OpenFOAM: The Open Source CFD Toolbox |
|
||||
| \\ / O peration | Version: 1.6 |
|
||||
| \\ / A nd | Web: www.OpenFOAM.org |
|
||||
| \\/ M anipulation | |
|
||||
\*---------------------------------------------------------------------------*/
|
||||
FoamFile
|
||||
{
|
||||
version 2.0;
|
||||
format ascii;
|
||||
class uniformDimensionedVectorField;
|
||||
location "constant";
|
||||
object g;
|
||||
}
|
||||
// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
|
||||
|
||||
dimensions [0 1 -2 0 0 0 0];
|
||||
value ( 0 -9.81 0);
|
||||
|
||||
|
||||
// ************************************************************************* //
|
||||
@ -0,0 +1,57 @@
|
||||
/*---------------------------------------------------------------------------*\
|
||||
| ========= | |
|
||||
| \\ / F ield | OpenFOAM: The Open Source CFD Toolbox |
|
||||
| \\ / O peration | Version: 1.4 |
|
||||
| \\ / A nd | Web: http://www.openfoam.org |
|
||||
| \\/ M anipulation | |
|
||||
\*---------------------------------------------------------------------------*/
|
||||
|
||||
|
||||
FoamFile
|
||||
{
|
||||
version 2.0;
|
||||
format ascii;
|
||||
|
||||
root "";
|
||||
case "";
|
||||
instance "";
|
||||
local "";
|
||||
|
||||
class dictionary;
|
||||
object liggghtsCommands;
|
||||
}
|
||||
|
||||
// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
|
||||
|
||||
liggghtsCommandModels
|
||||
(
|
||||
runLiggghts
|
||||
execute
|
||||
);
|
||||
|
||||
// reset particle temperature every coupling step
|
||||
executeProps1
|
||||
{
|
||||
command
|
||||
(
|
||||
set
|
||||
region
|
||||
total
|
||||
noBlanks
|
||||
property
|
||||
slash
|
||||
atom // former peratom
|
||||
blanks
|
||||
Temp
|
||||
number
|
||||
);
|
||||
scalars
|
||||
(
|
||||
600
|
||||
);
|
||||
runFirst off;
|
||||
runLast off;
|
||||
runEveryCouplingStep on;
|
||||
}
|
||||
|
||||
// ************************************************************************* //
|
||||
@ -0,0 +1,63 @@
|
||||
/*--------------------------------*- C++ -*----------------------------------*\
|
||||
| ========= | |
|
||||
| \\ / F ield | OpenFOAM: The Open Source CFD Toolbox |
|
||||
| \\ / O peration | Version: 1.6 |
|
||||
| \\ / A nd | Web: http://www.OpenFOAM.org |
|
||||
| \\/ M anipulation | |
|
||||
\*---------------------------------------------------------------------------*/
|
||||
FoamFile
|
||||
{
|
||||
version 2.0;
|
||||
format ascii;
|
||||
class dictionary;
|
||||
object blockMeshDict;
|
||||
}
|
||||
// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
|
||||
|
||||
convertToMeters 1.;
|
||||
|
||||
vertices
|
||||
(
|
||||
(0. 0 -0.5)
|
||||
(0.1 0 -0.5)
|
||||
(0.1 0.1 -0.5)
|
||||
(0. 0.1 -0.5)
|
||||
(0. 0 1.5)
|
||||
(0.1 0 1.5)
|
||||
(0.1 0.1 1.5)
|
||||
(0. 0.1 1.5)
|
||||
);
|
||||
|
||||
blocks
|
||||
(
|
||||
hex (0 1 2 3 4 5 6 7) (2 2 33) simpleGrading (1 1 1)
|
||||
);
|
||||
|
||||
edges
|
||||
(
|
||||
);
|
||||
|
||||
patches
|
||||
(
|
||||
wall inlet
|
||||
(
|
||||
(0 3 2 1)
|
||||
)
|
||||
wall outlet
|
||||
(
|
||||
(4 5 6 7)
|
||||
)
|
||||
wall wall
|
||||
(
|
||||
(3 7 6 2)
|
||||
(1 5 4 0)
|
||||
(0 4 7 3)
|
||||
(2 6 5 1)
|
||||
)
|
||||
);
|
||||
|
||||
mergePatchPairs
|
||||
(
|
||||
);
|
||||
|
||||
// ************************************************************************* //
|
||||
@ -0,0 +1,54 @@
|
||||
/*---------------------------------------------------------------------------*\
|
||||
| ========= | |
|
||||
| \\ / F ield | OpenFOAM: The Open Source CFD Toolbox |
|
||||
| \\ / O peration | Version: 1.4 |
|
||||
| \\ / A nd | Web: http://www.openfoam.org |
|
||||
| \\/ M anipulation | |
|
||||
\*---------------------------------------------------------------------------*/
|
||||
|
||||
|
||||
FoamFile
|
||||
{
|
||||
version 2.0;
|
||||
format ascii;
|
||||
|
||||
root "";
|
||||
case "";
|
||||
instance "";
|
||||
local "";
|
||||
|
||||
class dictionary;
|
||||
object scalarTransportProperties;
|
||||
}
|
||||
|
||||
// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
|
||||
|
||||
//===========================================================================//
|
||||
// sub-models & settings
|
||||
|
||||
scalarTransportModel generalManual;
|
||||
|
||||
generalManualProps
|
||||
{
|
||||
ScT 0.7; //optional
|
||||
PrT 0.7; //optional
|
||||
|
||||
//in case the user does not want to generate a separate field,
|
||||
//the volumetric heat capacity can be set here (as a global constant)
|
||||
cpVolumetric 1196; //this is the mixture density times the heat capacity
|
||||
//must have dimensions [J/K/(m_voidspace)³]
|
||||
//will only be used if cpVolumetricFieldName, or updateMixtureProperties = false
|
||||
|
||||
cpVolumetricFieldName "cpRho";
|
||||
rhoMixFieldName "rhoMix";
|
||||
|
||||
eulerianFields
|
||||
(
|
||||
C //any concentration fields MUST be first to have correct numbering
|
||||
T
|
||||
);
|
||||
|
||||
fvOptionsC {};
|
||||
fvOptionsT {};
|
||||
};
|
||||
// ************************************************************************* //
|
||||
@ -0,0 +1,24 @@
|
||||
/*--------------------------------*- C++ -*----------------------------------*\
|
||||
| ========= | |
|
||||
| \\ / F ield | OpenFOAM: The Open Source CFD Toolbox |
|
||||
| \\ / O peration | Version: 1.6 |
|
||||
| \\ / A nd | Web: www.OpenFOAM.org |
|
||||
| \\/ M anipulation | |
|
||||
\*---------------------------------------------------------------------------*/
|
||||
FoamFile
|
||||
{
|
||||
version 2.0;
|
||||
format ascii;
|
||||
class dictionary;
|
||||
location "constant";
|
||||
object transportProperties;
|
||||
}
|
||||
// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
|
||||
|
||||
transportModel Newtonian;
|
||||
|
||||
nu nu [ 0 2 -1 0 0 0 0 ] 1.5e-03;
|
||||
|
||||
DT DT [ 0 2 -1 0 0 0 0 ] 2.1399e-5;//2.1399e-5; // lambda/(rho*Cp) = 0.0256/(1.188*1007)
|
||||
|
||||
// ************************************************************************* //
|
||||
@ -0,0 +1,21 @@
|
||||
/*--------------------------------*- C++ -*----------------------------------*\
|
||||
| ========= | |
|
||||
| \\ / F ield | OpenFOAM: The Open Source CFD Toolbox |
|
||||
| \\ / O peration | Version: 1.6 |
|
||||
| \\ / A nd | Web: www.OpenFOAM.org |
|
||||
| \\/ M anipulation | |
|
||||
\*---------------------------------------------------------------------------*/
|
||||
FoamFile
|
||||
{
|
||||
version 2.0;
|
||||
format ascii;
|
||||
class dictionary;
|
||||
location "constant";
|
||||
object turbulenceProperties;
|
||||
}
|
||||
// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
|
||||
|
||||
simulationType RASModel;//LESModel; //
|
||||
|
||||
|
||||
// ************************************************************************* //
|
||||
@ -0,0 +1,143 @@
|
||||
close all;
|
||||
clear;
|
||||
clc;
|
||||
|
||||
|
||||
%*********************************************************************%
|
||||
% pressure drop
|
||||
%*********************************************************************%
|
||||
|
||||
%===================
|
||||
% Ergun Equation
|
||||
%===================
|
||||
fprintf('\ncalc Ergun eqn:\n')
|
||||
dp = 0.022; % particle diameter
|
||||
phip = 1; % sphericity
|
||||
epsilon = 0.4436; % voidfraction
|
||||
U = 1; % superficial velocity
|
||||
L = 1; % length of bed
|
||||
rhoG = 1.188; % density in kg/m
|
||||
nuG = 1.5e-3; % kinemat Visk in m2/s
|
||||
muG = nuG*rhoG % dynam visc in Pa s
|
||||
|
||||
dpErgun= L * (
|
||||
150*((1-epsilon)^2/epsilon^3)*((muG*U)/(phip*dp)^2)
|
||||
+1.75*((1-epsilon)/epsilon^3)*((rhoG*U^2)/(phip*dp))
|
||||
)
|
||||
|
||||
fprintf('final pressure drop = %f Pa\n',dpErgun)
|
||||
%====================================%
|
||||
% simulation data
|
||||
%====================================%
|
||||
%path = '../probes/0/p'; % 2.1.x
|
||||
path = '../postProcessing/probes/0/p'; % 2.2.x
|
||||
|
||||
%- nomenclature before 2.4.x
|
||||
%columns=3;
|
||||
%headerlines=5;
|
||||
%data = loaddata(path,columns,headerlines);
|
||||
%data=transpose(data);
|
||||
|
||||
data = load(path);
|
||||
[x,y]=size(data);
|
||||
dp_sim = data(:,2)-data(:,y);
|
||||
t_sim = data(:,1);
|
||||
fprintf('final pressureDrop of sim = %f Pa\n',dp_sim(length(dp_sim)) )
|
||||
|
||||
%====================================%
|
||||
% plot data
|
||||
%====================================%
|
||||
figure(1)
|
||||
plot(t_sim,dpErgun*ones(1,length(t_sim)),t_sim,dp_sim)
|
||||
axis([0,0.7,0,dpErgun(length(dpErgun))])
|
||||
title("Ergun pressure drop")
|
||||
legend("analytical - Ergun","simulation")
|
||||
|
||||
%print('cfdemSolverPiso_settlingTest.eps','-deps2')
|
||||
print -color "cfdemSolverPisoScalar_pressureDrop.eps"
|
||||
|
||||
%*********************************************************************%
|
||||
% heat transfer
|
||||
%*********************************************************************%
|
||||
|
||||
%====================================%
|
||||
% simulation data
|
||||
%====================================%
|
||||
|
||||
cp = 1007;
|
||||
A = 0.01;
|
||||
U = U;
|
||||
alpha = epsilon;
|
||||
nuF = nuG;
|
||||
rhoF = rhoG;
|
||||
Tp = 600;
|
||||
Np = 1005;
|
||||
lambda = 0.0256;
|
||||
|
||||
%path = '../probes/0/T'; % 2.1.x
|
||||
path = '../postProcessing/probes/0/T'; % 2.2.x
|
||||
%- nomenclature before 2.4.x
|
||||
%columns=5;
|
||||
%headerlines=5;
|
||||
%data = loaddata(path,columns,headerlines);
|
||||
%data=transpose(data);
|
||||
|
||||
data = load(path);
|
||||
[x,y]=size(data);
|
||||
Tin_sim = data(:,2); % mean temp inlet temp [K]
|
||||
Tout_sim = data(:,3); % mean temp outlet temp [K]
|
||||
t_sim = data(:,1);
|
||||
fprintf('final inlet temperature of sim = %f K\n',Tin_sim(length(Tin_sim)) )
|
||||
fprintf('final outlet temperature of sim = %f K\n',Tout_sim(length(Tout_sim)) )
|
||||
|
||||
|
||||
uF = U/alpha; % interstitial velocity [m/s]
|
||||
ReP_sim = uF.*ones(length(t_sim),1)*dp/nuF; % ReynoldsNr based in dp
|
||||
Pr = nuF*rhoF*cp/lambda;
|
||||
qin_sim = U * A * rhoF * cp .* Tin_sim;
|
||||
qout_sim = U * A * rhoF * cp .* Tout_sim;
|
||||
q_sim = (qout_sim-qin_sim); % particle fluid heat flux [W] (out-in)
|
||||
Tmean_sim = 0.5*(Tin_sim+Tout_sim); % mean temp of fluid
|
||||
deltaT = Tp - Tmean_sim; % mean temp diff between partcles and fluid
|
||||
h=q_sim./(Np*dp^2*pi*deltaT); % average particle-fluid heat transfer coeff [W/(m2*K)]
|
||||
Nu_sim = h.*dp/lambda; % mean particle Nusselt nr
|
||||
t_sim = data(:,1);
|
||||
fprintf('q_sim = %f \n',q_sim(length(Nu_sim)))
|
||||
fprintf('Nu_sim = %f \n',Nu_sim(length(Nu_sim)))
|
||||
|
||||
%===================
|
||||
% Nusselt Equation
|
||||
%===================
|
||||
fprintf('\ncalc Nusselt eqn:\n')
|
||||
|
||||
%% following Li and Mason
|
||||
n=3.5
|
||||
if (ReP_sim(length(uF)) <200)
|
||||
Nu_LiMason=2.*ones(length(uF),1)+0.6*alpha^n.*ReP_sim.^0.5.*Pr^0.33;
|
||||
elseif (ReP_sim(length(uF)) <1500)
|
||||
Nu_LiMason=2.*ones(length(uF),1)+0.5*alpha^n.*ReP_sim.^0.5*Pr^0.33 + 0.02*alpha^n.*ReP_sim.^0.8.*Pr^0.33;
|
||||
else
|
||||
Nu_LiMason=2.*ones(length(uF),1) +0.000045*alpha^n.*ReP_sim.^1.8;
|
||||
end
|
||||
|
||||
fprintf('Nu_LiMason = %f \n',Nu_LiMason(length(Nu_LiMason)))
|
||||
|
||||
%====================================%
|
||||
% plot data
|
||||
%====================================%
|
||||
figure(2)
|
||||
plot(t_sim,Nu_LiMason,t_sim,Nu_sim)
|
||||
title("Nusselt nr")
|
||||
legend("analytical - ","simulation")
|
||||
|
||||
%print('cfdemSolverPisoScalar_NusseltNr.eps','-deps2')
|
||||
print -color "cfdemSolverPisoScalar_Nusselt.eps"
|
||||
|
||||
figure(3)
|
||||
plot(t_sim,Tin_sim,t_sim,Tout_sim)
|
||||
title("inlet/outlet temperature")
|
||||
legend("inlet","outlet")
|
||||
|
||||
%print('cfdemSolverPisoScalar_NusseltNr.eps','-deps2')
|
||||
print -color "cfdemSolverPisoScalar_temperatures.eps"
|
||||
|
||||
@ -0,0 +1,159 @@
|
||||
/*--------------------------------*- C++ -*----------------------------------*\
|
||||
| ========= | |
|
||||
| \\ / F ield | OpenFOAM: The Open Source CFD Toolbox |
|
||||
| \\ / O peration | Version: 1.6 |
|
||||
| \\ / A nd | Web: www.OpenFOAM.org |
|
||||
| \\/ M anipulation | |
|
||||
\*---------------------------------------------------------------------------*/
|
||||
FoamFile
|
||||
{
|
||||
version 2.0;
|
||||
format ascii;
|
||||
class dictionary;
|
||||
location "system";
|
||||
object controlDict;
|
||||
}
|
||||
// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
|
||||
|
||||
application cfdemSolverPisoScalar;
|
||||
|
||||
startFrom startTime;
|
||||
|
||||
startTime 0;
|
||||
|
||||
stopAt endTime;
|
||||
|
||||
endTime 1.5;
|
||||
|
||||
deltaT 0.005;
|
||||
|
||||
writeControl adjustableRunTime;
|
||||
|
||||
writeInterval 0.1;
|
||||
|
||||
purgeWrite 0;
|
||||
|
||||
writeFormat ascii;
|
||||
|
||||
writePrecision 6;
|
||||
|
||||
writeCompression uncompressed;
|
||||
|
||||
timeFormat general;
|
||||
|
||||
timePrecision 6;
|
||||
|
||||
runTimeModifiable yes;
|
||||
|
||||
adjustTimeStep no;
|
||||
|
||||
maxCo 0.1;
|
||||
|
||||
maxDeltaT 1;
|
||||
|
||||
//libs ( "libgroovyBC.so" );
|
||||
|
||||
functions
|
||||
(
|
||||
|
||||
probes
|
||||
{
|
||||
type probes;
|
||||
// Where to load it from
|
||||
functionObjectLibs ( "libsampling.so" );
|
||||
// Name of the directory for probe data
|
||||
name probes;
|
||||
probeLocations
|
||||
(
|
||||
(0.05 0.05 -0.499)
|
||||
(0.05 0.05 1.499)
|
||||
);
|
||||
|
||||
// Fields to be probed
|
||||
fields ( p T );
|
||||
|
||||
// Write at same frequency as fields
|
||||
outputControl timeStep;//outputTime;
|
||||
outputInterval 1;
|
||||
}
|
||||
|
||||
/*
|
||||
// simpleFunctionObjects
|
||||
heatFlux
|
||||
{
|
||||
type patchHeatFlux;
|
||||
functionObjectLibs
|
||||
(
|
||||
"libsimpleFunctionObjects.so"
|
||||
);
|
||||
verbose true;
|
||||
patches
|
||||
(
|
||||
inlet
|
||||
outlet
|
||||
);
|
||||
fields // name of temp field
|
||||
(
|
||||
T
|
||||
);
|
||||
cp 1007; // cp in [J/(kg*K)]
|
||||
factor 1.188; // density for incomp solvers!
|
||||
}
|
||||
|
||||
massFlux
|
||||
{
|
||||
type patchMassFlow;
|
||||
functionObjectLibs
|
||||
(
|
||||
"libsimpleFunctionObjects.so"
|
||||
);
|
||||
verbose true;
|
||||
patches
|
||||
(
|
||||
inlet
|
||||
outlet
|
||||
);
|
||||
factor 1.188; // density for incomp solvers!
|
||||
}
|
||||
|
||||
pressureDrop
|
||||
{
|
||||
type patchAverage;
|
||||
functionObjectLibs
|
||||
(
|
||||
"libsimpleFunctionObjects.so"
|
||||
);
|
||||
verbose true;
|
||||
patches
|
||||
(
|
||||
inlet
|
||||
outlet
|
||||
);
|
||||
fields
|
||||
(
|
||||
p
|
||||
);
|
||||
factor 1;
|
||||
}
|
||||
|
||||
T
|
||||
{
|
||||
type patchAverage;
|
||||
functionObjectLibs
|
||||
(
|
||||
"libsimpleFunctionObjects.so"
|
||||
);
|
||||
verbose true;
|
||||
patches
|
||||
(
|
||||
inlet
|
||||
outlet
|
||||
);
|
||||
fields // name of temp field
|
||||
(
|
||||
T
|
||||
);
|
||||
factor 1;
|
||||
}*/
|
||||
);
|
||||
// ************************************************************************* //
|
||||
@ -0,0 +1,56 @@
|
||||
/*--------------------------------*- C++ -*----------------------------------*\
|
||||
| ========= | |
|
||||
| \\ / F ield | OpenFOAM: The Open Source CFD Toolbox |
|
||||
| \\ / O peration | Version: 1.6 |
|
||||
| \\ / A nd | Web: www.OpenFOAM.org |
|
||||
| \\/ M anipulation | |
|
||||
\*---------------------------------------------------------------------------*/
|
||||
FoamFile
|
||||
{
|
||||
version 2.0;
|
||||
format ascii;
|
||||
class dictionary;
|
||||
location "system";
|
||||
object decomposeParDict;
|
||||
}
|
||||
// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
|
||||
|
||||
numberOfSubdomains 2;
|
||||
|
||||
method simple;
|
||||
|
||||
simpleCoeffs
|
||||
{
|
||||
n ( 1 1 2 );
|
||||
delta 0.001;
|
||||
}
|
||||
|
||||
hierarchicalCoeffs
|
||||
{
|
||||
n ( 2 2 1 );
|
||||
delta 0.001;
|
||||
order xyz;
|
||||
}
|
||||
|
||||
metisCoeffs
|
||||
{
|
||||
}
|
||||
|
||||
manualCoeffs
|
||||
{
|
||||
dataFile "";
|
||||
}
|
||||
|
||||
distributed no;
|
||||
|
||||
//// Is the case distributed
|
||||
//distributed yes;
|
||||
//// Per slave (so nProcs-1 entries) the directory above the case.
|
||||
//roots
|
||||
//(
|
||||
// "/tmp"
|
||||
// "/tmp"
|
||||
//);
|
||||
|
||||
|
||||
// ************************************************************************* //
|
||||
@ -0,0 +1,78 @@
|
||||
/*--------------------------------*- C++ -*----------------------------------*\
|
||||
| ========= | |
|
||||
| \\ / F ield | OpenFOAM: The Open Source CFD Toolbox |
|
||||
| \\ / O peration | Version: 1.6 |
|
||||
| \\ / A nd | Web: www.OpenFOAM.org |
|
||||
| \\/ M anipulation | |
|
||||
\*---------------------------------------------------------------------------*/
|
||||
FoamFile
|
||||
{
|
||||
version 2.0;
|
||||
format ascii;
|
||||
class dictionary;
|
||||
location "system";
|
||||
object fvSchemes;
|
||||
}
|
||||
// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
|
||||
|
||||
ddtSchemes
|
||||
{
|
||||
default Euler;
|
||||
}
|
||||
|
||||
gradSchemes
|
||||
{
|
||||
default Gauss linear;
|
||||
grad(p) Gauss linear;
|
||||
grad(U) Gauss linear;
|
||||
}
|
||||
|
||||
divSchemes
|
||||
{
|
||||
default Gauss linear;
|
||||
div(phi,U) Gauss limitedLinearV 1;
|
||||
div(phi,k) Gauss limitedLinear 1;
|
||||
div(phi,epsilon) Gauss limitedLinear 1;
|
||||
div(phi,R) Gauss limitedLinear 1;
|
||||
div(R) Gauss linear;
|
||||
div(phi,nuTilda) Gauss limitedLinear 1;
|
||||
div((nuEff*dev(grad(U).T()))) Gauss linear;
|
||||
div((viscousTerm*dev(grad(U).T()))) Gauss linear;
|
||||
div((nu*dev(grad(U).T()))) Gauss linear;
|
||||
div(phi,T) Gauss limitedLinear 1; //Gauss upwind; //
|
||||
}
|
||||
|
||||
laplacianSchemes
|
||||
{
|
||||
default Gauss linear corrected;
|
||||
laplacian(nuEff,U) Gauss linear corrected;
|
||||
laplacian(viscousTerm,U) Gauss linear corrected;
|
||||
laplacian(nu,U) Gauss linear corrected;
|
||||
laplacian((1|A(U)),p) Gauss linear corrected;
|
||||
laplacian((voidfraction2|A(U)),p) Gauss linear corrected;
|
||||
laplacian(DkEff,k) Gauss linear corrected;
|
||||
laplacian(DepsilonEff,epsilon) Gauss linear corrected;
|
||||
laplacian(DREff,R) Gauss linear corrected;
|
||||
laplacian(DnuTildaEff,nuTilda) Gauss linear corrected;
|
||||
laplacian((DT*voidfraction),T) Gauss linear corrected;
|
||||
}
|
||||
|
||||
interpolationSchemes
|
||||
{
|
||||
default linear;
|
||||
interpolate(U) linear;
|
||||
}
|
||||
|
||||
snGradSchemes
|
||||
{
|
||||
default corrected;
|
||||
}
|
||||
|
||||
fluxRequired
|
||||
{
|
||||
default no;
|
||||
p ;
|
||||
}
|
||||
|
||||
|
||||
// ************************************************************************* //
|
||||
117
tutorials/cfdemSolverPisoSTM/packedBedTemp/CFD/system/fvSolution
Normal file
117
tutorials/cfdemSolverPisoSTM/packedBedTemp/CFD/system/fvSolution
Normal file
@ -0,0 +1,117 @@
|
||||
/*--------------------------------*- C++ -*----------------------------------*\
|
||||
| ========= | |
|
||||
| \\ / F ield | OpenFOAM: The Open Source CFD Toolbox |
|
||||
| \\ / O peration | Version: 1.6 |
|
||||
| \\ / A nd | Web: www.OpenFOAM.org |
|
||||
| \\/ M anipulation | |
|
||||
\*---------------------------------------------------------------------------*/
|
||||
FoamFile
|
||||
{
|
||||
version 2.0;
|
||||
format ascii;
|
||||
class dictionary;
|
||||
location "system";
|
||||
object fvSolution;
|
||||
}
|
||||
// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
|
||||
|
||||
solvers
|
||||
{
|
||||
p
|
||||
{
|
||||
solver PCG;
|
||||
preconditioner DIC;
|
||||
tolerance 1e-06;
|
||||
relTol 0.1;
|
||||
}
|
||||
|
||||
pFinal
|
||||
{
|
||||
solver PCG;
|
||||
preconditioner DIC;
|
||||
tolerance 1e-06;
|
||||
relTol 0;
|
||||
}
|
||||
|
||||
U
|
||||
{
|
||||
solver PBiCG;
|
||||
preconditioner DILU;
|
||||
tolerance 1e-05;
|
||||
relTol 0;
|
||||
}
|
||||
|
||||
UFinal
|
||||
{
|
||||
$U
|
||||
}
|
||||
|
||||
k
|
||||
{
|
||||
solver PBiCG;
|
||||
preconditioner DILU;
|
||||
tolerance 1e-05;
|
||||
relTol 0;
|
||||
}
|
||||
|
||||
epsilon
|
||||
{
|
||||
solver PBiCG;
|
||||
preconditioner DILU;
|
||||
tolerance 1e-05;
|
||||
relTol 0;
|
||||
}
|
||||
|
||||
R
|
||||
{
|
||||
solver PBiCG;
|
||||
preconditioner DILU;
|
||||
tolerance 1e-05;
|
||||
relTol 0;
|
||||
}
|
||||
|
||||
nuTilda
|
||||
{
|
||||
solver PBiCG;
|
||||
preconditioner DILU;
|
||||
tolerance 1e-05;
|
||||
relTol 0;
|
||||
}
|
||||
|
||||
"(T|C)"
|
||||
{
|
||||
solver PBiCG;
|
||||
preconditioner DILU;
|
||||
tolerance 1e-06;
|
||||
relTol 0;
|
||||
}
|
||||
}
|
||||
|
||||
PIMPLE
|
||||
{
|
||||
nOuterCorrectors 1;
|
||||
}
|
||||
relaxationFactors
|
||||
{
|
||||
fields
|
||||
{
|
||||
p 1.0;
|
||||
}
|
||||
equations
|
||||
{
|
||||
"U.*" 1.0;
|
||||
"k.*" 1.;
|
||||
"epsilon.*" 1.;
|
||||
}
|
||||
}
|
||||
|
||||
PISO
|
||||
{
|
||||
nCorrectors 4;
|
||||
nNonOrthogonalCorrectors 0;
|
||||
pRefCell 0;
|
||||
pRefValue 0;
|
||||
}
|
||||
|
||||
|
||||
// ************************************************************************* //
|
||||
@ -0,0 +1,73 @@
|
||||
echo both
|
||||
log ../DEM/log.liggghts
|
||||
|
||||
atom_style granular
|
||||
atom_modify map array
|
||||
boundary m m m
|
||||
newton off
|
||||
|
||||
communicate single vel yes
|
||||
|
||||
units si
|
||||
processors 1 1 2
|
||||
|
||||
region reg block 0. 0.1 0. 0.1 0. 1.1 units box
|
||||
create_box 1 reg
|
||||
|
||||
neighbor 0.002 bin
|
||||
neigh_modify delay 0
|
||||
|
||||
|
||||
# Material properties required for granular pair styles
|
||||
|
||||
fix m1 all property/global youngsModulus peratomtype 5.e6
|
||||
fix m2 all property/global poissonsRatio peratomtype 0.45
|
||||
fix m3 all property/global coefficientRestitution peratomtypepair 1 0.3
|
||||
fix m4 all property/global coefficientFriction peratomtypepair 1 0.5
|
||||
|
||||
# pair style
|
||||
pair_style gran model hertz tangential history #Hertzian without cohesion
|
||||
pair_coeff * *
|
||||
|
||||
timestep 0.00001
|
||||
|
||||
# walls
|
||||
fix xwalls1 all wall/gran model hertz tangential history primitive type 1 xplane 0.0
|
||||
fix xwalls2 all wall/gran model hertz tangential history primitive type 1 xplane 0.1
|
||||
fix ywalls1 all wall/gran model hertz tangential history primitive type 1 yplane 0.0
|
||||
fix ywalls2 all wall/gran model hertz tangential history primitive type 1 yplane 0.1
|
||||
fix zwalls1 all wall/gran model hertz tangential history primitive type 1 zplane 0.0
|
||||
fix zwalls2 all wall/gran model hertz tangential history primitive type 1 zplane 1.1
|
||||
|
||||
fix gravi all gravity 9.81 vector 0.0 0.0 -1.0
|
||||
|
||||
# heat transfer
|
||||
fix ftco all property/global thermalConductivity peratomtype 5.
|
||||
fix ftca all property/global thermalCapacity peratomtype 10.
|
||||
fix heattransfer all heat/gran initial_temperature 263.
|
||||
|
||||
# particle distributions and insertion
|
||||
region bc block 0. 0.1 0. 0.1 0. 1.1 units box
|
||||
fix pts1 all particletemplate/sphere 1 atom_type 1 density constant 2500 radius constant 0.011
|
||||
fix pdd1 all particledistribution/discrete 1 1 pts1 1.0
|
||||
|
||||
fix ins all insert/pack seed 100001 distributiontemplate pdd1 vel constant 0. 0. -3. insert_every 10000 overlapcheck yes all_in yes particles_in_region 1005 region bc
|
||||
|
||||
# apply nve integration to all particles that are inserted as single particles
|
||||
fix integr all nve/sphere
|
||||
|
||||
# output settings, include total thermal energy
|
||||
compute rke all erotate/sphere
|
||||
thermo_style custom step atoms ke c_rke f_heattransfer vol
|
||||
thermo 1000
|
||||
thermo_modify lost ignore norm no
|
||||
compute_modify thermo_temp dynamic yes
|
||||
|
||||
#insert the first particles
|
||||
run 1
|
||||
dump dmp all custom 1000 post/dump.liggghts_init id type x y z ix iy iz vx vy vz fx fy fz omegax omegay omegaz radius f_heattransfer[0] f_heatFlux[0]
|
||||
|
||||
run 150000
|
||||
|
||||
write_restart post/restart/liggghts.restart
|
||||
|
||||
@ -0,0 +1,88 @@
|
||||
echo both
|
||||
log ../DEM/log.liggghts
|
||||
thermo_log ../DEM/post/thermo.txt
|
||||
|
||||
#######################################################
|
||||
# variables #
|
||||
#######################################################
|
||||
variable r0 equal 0.011
|
||||
#######################################################
|
||||
|
||||
# read packed bed and calc convective heat transfer
|
||||
atom_style granular
|
||||
atom_modify map array
|
||||
boundary m m m
|
||||
newton off
|
||||
|
||||
communicate single vel yes
|
||||
|
||||
units si
|
||||
processors 1 1 2
|
||||
|
||||
# read the restart file
|
||||
read_restart ../DEM/post/restart/liggghts.restart
|
||||
|
||||
neighbor ${r0} bin
|
||||
neigh_modify delay 0 binsize 0.01
|
||||
|
||||
|
||||
# Material properties required for granular pair styles
|
||||
|
||||
fix m1 all property/global youngsModulus peratomtype 5.e6
|
||||
fix m2 all property/global poissonsRatio peratomtype 0.45
|
||||
fix m3 all property/global coefficientRestitution peratomtypepair 1 0.3
|
||||
fix m4 all property/global coefficientFriction peratomtypepair 1 0.5
|
||||
|
||||
# pair style
|
||||
pair_style gran model hertz tangential history
|
||||
pair_coeff * *
|
||||
|
||||
# timestep, gravity
|
||||
timestep 0.00001
|
||||
fix gravi all gravity 9.81 vector 0. 0. -1.
|
||||
|
||||
# walls
|
||||
fix xwalls1 all wall/gran model hertz tangential history primitive type 1 xplane 0.0
|
||||
fix xwalls2 all wall/gran model hertz tangential history primitive type 1 xplane 0.1
|
||||
fix ywalls1 all wall/gran model hertz tangential history primitive type 1 yplane 0.0
|
||||
fix ywalls2 all wall/gran model hertz tangential history primitive type 1 yplane 0.1
|
||||
fix zwalls1 all wall/gran model hertz tangential history primitive type 1 zplane 0.0
|
||||
fix zwalls2 all wall/gran model hertz tangential history primitive type 1 zplane 1.1
|
||||
|
||||
# cfd coupling
|
||||
fix cfd all couple/cfd couple_every 100 mpi
|
||||
fix cfd2 all couple/cfd/force
|
||||
|
||||
|
||||
# heat transfer
|
||||
fix ftco all property/global thermalConductivity peratomtype 5. # lambda in [W/(K*m)]
|
||||
fix ftca all property/global thermalCapacity peratomtype 0.1 # cp in [J/(kg*K)]
|
||||
fix cfd3 all couple/cfd/convection T0 600
|
||||
|
||||
# species transfer
|
||||
fix specCap all property/global speciesCCapacity peratomtype 1.0
|
||||
fix cfd4 all couple/cfd/speciesConvection speciesName speciesC species0 1.0 #this fix will add all relevant exchange fields for the species
|
||||
|
||||
# set particle temperature for the bed
|
||||
run 0
|
||||
region total block INF INF INF INF INF INF units box
|
||||
set region total property/atom Temp 600.
|
||||
|
||||
|
||||
# this one invokes heat transfer calculation, transfers per-particle temperature and adds convective heat flux to particles
|
||||
|
||||
|
||||
|
||||
# apply nve integration to all particles that are inserted as single particles
|
||||
fix integr all nve/sphere
|
||||
|
||||
# output settings, include total thermal energy
|
||||
compute rke all erotate/sphere
|
||||
thermo_style custom step atoms ke c_rke
|
||||
thermo 1000
|
||||
thermo_modify lost ignore norm no
|
||||
compute_modify thermo_temp dynamic yes
|
||||
|
||||
dump dmp all custom 20000 ../DEM/post/dump*.liggghts_run id type x y z ix iy iz vx vy vz fx fy fz omegax omegay omegaz radius f_Temp[0] f_heatFlux[0] f_speciesC[0] f_speciesCFlux[0]
|
||||
|
||||
run 0
|
||||
0
tutorials/cfdemSolverPisoSTM/packedBedTemp/DEM/post/restart/.gitignore
vendored
Normal file
0
tutorials/cfdemSolverPisoSTM/packedBedTemp/DEM/post/restart/.gitignore
vendored
Normal file
68
tutorials/cfdemSolverPisoSTM/packedBedTemp/cleanCase.sh
Executable file
68
tutorials/cfdemSolverPisoSTM/packedBedTemp/cleanCase.sh
Executable file
@ -0,0 +1,68 @@
|
||||
#!/bin/bash
|
||||
|
||||
#===================================================================#
|
||||
# allrun script for testcase as part of test routine
|
||||
# run settlingTest CFD part
|
||||
# Christoph Goniva - Feb. 2011
|
||||
#===================================================================#
|
||||
|
||||
#- source CFDEM env vars
|
||||
. ~/.bashrc
|
||||
|
||||
#--------------------------------------------------------------------------------#
|
||||
#- define variables
|
||||
casePath="$(dirname "$(readlink -f ${BASH_SOURCE[0]})")"
|
||||
#--------------------------------------------------------------------------------#
|
||||
|
||||
|
||||
|
||||
#- clean up case
|
||||
echo "deleting data at: $casePath ?"
|
||||
#read
|
||||
rm -r $casePath/*.e*
|
||||
rm -r $casePath/*.o*
|
||||
rm -r $casePath/log*
|
||||
rm -r $casePath/CFD/0.0*
|
||||
rm -r $casePath/CFD/log.*
|
||||
rm -r $casePath/CFD/averageProps
|
||||
rm -r $casePath/CFD/*.OpenFOAM
|
||||
rm -r $casePath/CFD/*.restart*
|
||||
rm -r $casePath/CFD/clockData
|
||||
rm -r $casePath/CFD/*.dat
|
||||
rm -r $casePath/CFD/octave/*.dat
|
||||
rm -r $casePath/CFD/octave/*.eps
|
||||
rm -r $casePath/CFD/processor*
|
||||
rm -r $casePath/CFD/VTK
|
||||
rm -r $casePath/CFD/volAvU
|
||||
rm -r $casePath/CFD/couplingFiles
|
||||
rm -r $casePath/CFD/particles
|
||||
rm -r $casePath/CFD/probe*
|
||||
rm -r $casePath/CFD/postProcess*
|
||||
rm -r $casePath/CFD/particleProbes
|
||||
rm -r $casePath/CFD/*Restart*
|
||||
rm -r $casePath/CFD/*restart*
|
||||
rm -r $casePath/CFD/fluidFlowStats.res
|
||||
rm -r $casePath/CFD/constant/polyMesh/*.gz
|
||||
rm -r $casePath/CFD/constant/polyMesh/faces
|
||||
rm -r $casePath/CFD/constant/polyMesh/neighbour
|
||||
rm -r $casePath/CFD/constant/polyMesh/owner
|
||||
rm -r $casePath/CFD/constant/polyMesh/points
|
||||
rm -r $casePath/CFD/constant/polyMesh/boundary
|
||||
rm -r $casePath/CFD/processor*
|
||||
rm -r $casePath/DEM/postParticles/*
|
||||
rm -r $casePath/DEM/postGlobal/*
|
||||
rm -r $casePath/DEM/post/*.*
|
||||
rm -r $casePath/DEM/post/restart/*.*
|
||||
rm -r $casePath/DEM/log.*
|
||||
rm -r $casePath/DEM/*Restart*
|
||||
rm -r $casePath/DEM/*restart*
|
||||
|
||||
rm -r $casePath/CFD/pascal/0.*
|
||||
rm -r $casePath/CFD/pascal/1.*
|
||||
rm -r $casePath/CFD/pascal/2.*
|
||||
rm -r $casePath/CFD/codeInfo.*
|
||||
rm -r $casePath/CFD/*.dat
|
||||
|
||||
echo "done"
|
||||
|
||||
|
||||
103
tutorials/cfdemSolverPisoSTM/packedBedTemp/parCFDDEMrun.sh
Normal file
103
tutorials/cfdemSolverPisoSTM/packedBedTemp/parCFDDEMrun.sh
Normal file
@ -0,0 +1,103 @@
|
||||
#!/bin/bash
|
||||
|
||||
#===================================================================#
|
||||
# allrun script for testcase as part of test routine
|
||||
# run settlingTest CFD part
|
||||
# Christoph Goniva - May. 2011
|
||||
#===================================================================#
|
||||
|
||||
#- source CFDEM env vars
|
||||
. ~/.bashrc
|
||||
|
||||
#- include functions
|
||||
source $CFDEM_SRC_DIR/lagrangian/cfdemParticle/etc/functions.sh
|
||||
|
||||
#--------------------------------------------------------------------------------#
|
||||
#- define variables
|
||||
casePath="$(dirname "$(readlink -f ${BASH_SOURCE[0]})")"
|
||||
logpath=$casePath
|
||||
headerText="run_parallel_cfdemSolverPisoSTM_packedBedTemp_CFDDEM"
|
||||
logfileName="log_$headerText"
|
||||
solverName="cfdemSolverPisoSTM"
|
||||
nrProcs="2"
|
||||
machineFileName="none" # yourMachinefileName | none
|
||||
debugMode="off" # on | off| strict
|
||||
testHarnessPath="$CFDEM_TEST_HARNESS_PATH"
|
||||
runOctave="true"
|
||||
postproc="false"
|
||||
cleanup="true"
|
||||
#--------------------------------------------------------------------------------#
|
||||
|
||||
#- call function to run a parallel CFD-DEM case
|
||||
parCFDDEMrun $logpath $logfileName $casePath $headerText $solverName $nrProcs $machineFileName $debugMode
|
||||
|
||||
#------------------------------#
|
||||
if [ $runOctave == "true" ]
|
||||
then
|
||||
|
||||
#- change path
|
||||
cd octave
|
||||
|
||||
#- rmove old graph
|
||||
rm *.eps
|
||||
|
||||
#- run octave
|
||||
octave totalPressureDropAndNusselt.m
|
||||
|
||||
#- show plots
|
||||
evince cfdemSolverPisoScalar_Nusselt.eps &
|
||||
evince cfdemSolverPisoScalar_pressureDrop.eps
|
||||
#------------------------------#
|
||||
|
||||
#- copy log file to test harness
|
||||
cp ../../$logfileName $testHarnessPath
|
||||
cp cfdemSolverPisoScalar_Nusselt.eps $testHarnessPath
|
||||
cp cfdemSolverPisoScalar_pressureDrop.eps $testHarnessPath
|
||||
|
||||
fi
|
||||
|
||||
#-------------------------------------------------------#
|
||||
if [ $postproc == "true" ]
|
||||
then
|
||||
|
||||
#- keep terminal open (if started in new terminal)
|
||||
echo "simulation finished? ...press enter to proceed"
|
||||
read
|
||||
|
||||
#- get VTK data from liggghts dump file
|
||||
cd $casePath/DEM/post
|
||||
python -i $CFDEM_LPP_DIR/lpp.py dump.liggghts_run
|
||||
|
||||
#- get VTK data from CFD sim
|
||||
cd $casePath/CFD
|
||||
foamToVTK #- serial run of foamToVTK
|
||||
#source $CFDEM_SRC_DIR/lagrangian/cfdemParticle/etc/functions.sh #- include functions
|
||||
#pseudoParallelRun "foamToVTK" $nrPostProcProcessors #- pseudo parallel run of foamToVTK
|
||||
|
||||
#- start paraview
|
||||
paraview
|
||||
|
||||
#- keep terminal open (if started in new terminal)
|
||||
echo "...press enter to clean up case"
|
||||
echo "press Ctr+C to keep data"
|
||||
read
|
||||
fi
|
||||
|
||||
#- clean up case
|
||||
if [ $cleanup == "true" ]
|
||||
then
|
||||
echo "deleting data at: $casePath : \n"
|
||||
source $WM_PROJECT_DIR/bin/tools/CleanFunctions
|
||||
cd $casePath/CFD
|
||||
cleanCase
|
||||
rm -r $casePath/CFD/clockData
|
||||
rm $casePath/DEM/post/*.*
|
||||
#rm -r $casePath/DEM/post/restart/*.*
|
||||
echo "done"
|
||||
|
||||
#- preserve post directory
|
||||
touch $casePath/DEM/post/.gitignore
|
||||
touch $casePath/DEM/post/restart/.gitignore
|
||||
fi
|
||||
|
||||
|
||||
28
tutorials/cfdemSolverPisoSTM/packedBedTemp/parDEMrun.sh
Executable file
28
tutorials/cfdemSolverPisoSTM/packedBedTemp/parDEMrun.sh
Executable file
@ -0,0 +1,28 @@
|
||||
#!/bin/bash
|
||||
|
||||
#===================================================================#
|
||||
# DEMrun script for ErgunTestMPI testcase
|
||||
# init ErgunTestMPI
|
||||
# Daniel Queteschiner - June 2014
|
||||
#===================================================================#
|
||||
|
||||
#- source CFDEM env vars
|
||||
. ~/.bashrc
|
||||
|
||||
#- include functions
|
||||
source $CFDEM_SRC_DIR/lagrangian/cfdemParticle/etc/functions.sh
|
||||
|
||||
#--------------------------------------------------------------------------------#
|
||||
#- define variables
|
||||
casePath="$(dirname "$(readlink -f ${BASH_SOURCE[0]})")"
|
||||
logpath="$casePath"
|
||||
headerText="run_liggghts_init_DEM"
|
||||
logfileName="log_$headerText"
|
||||
solverName="in.liggghts_init"
|
||||
nrProcs="2"
|
||||
machineFileName="none" # yourMachinefileName | none
|
||||
#--------------------------------------------------------------------------------#
|
||||
|
||||
#- call function to run DEM case
|
||||
parDEMrun $logpath $logfileName $casePath $headerText $solverName $nrProcs $machineFileName
|
||||
|
||||
@ -135,7 +135,7 @@ centreProps
|
||||
|
||||
dividedProps
|
||||
{
|
||||
alphaMin 0.1;
|
||||
alphaMin 0.4;
|
||||
scaleUpVol 1.0;
|
||||
}
|
||||
|
||||
|
||||
@ -1,69 +0,0 @@
|
||||
function [data,colname]=loaddata(filename,columns,headerlines)
|
||||
|
||||
% data = loaddata(filename,columns,headerlines)
|
||||
% data = loaddata(filename,0,headerlines): automatc detection of
|
||||
% columns by word count in first headerline or first data line
|
||||
% (if headerline==0), separated by blanks or tabs
|
||||
% columns=-1: write colum assignment code lines
|
||||
% works only if headerline>0 and colnames separated by
|
||||
% not more than 1 blank!
|
||||
% columns=-2: columns separated by 2 blanks (fluent/scheme auswertung-instat.scm)
|
||||
% [data, colname] = loaddata(filename,0,headerlines)
|
||||
% colname = cell string array of column names from headerline
|
||||
|
||||
fprintf(1,'loading %s ... ', filename);
|
||||
f=fopen(filename,'r');
|
||||
if f==-1
|
||||
fprintf(1,'\n*** error: could not open "%s" ...\n', filename);
|
||||
data=[];
|
||||
else
|
||||
for i=1:headerlines
|
||||
if i==1 s=fgets(f); else fgets(f); end
|
||||
end
|
||||
if headerlines==0
|
||||
s=fgets(f); frewind(f);
|
||||
end
|
||||
if columns<=0 % & headerlines>=1
|
||||
fprintf(1,'\n');
|
||||
fprintf(1,' %s',s);
|
||||
pos = findstr(sprintf('\t'),s); % trennzeichenpositionen in zeile suchen
|
||||
if length(pos)>0
|
||||
endpos=length(s);
|
||||
%if isspace(s(endpos-1)) endpos=endpos-1; end
|
||||
pos = [0 pos(1,:) endpos]; % anfangs- und endposition hinzuf<EFBFBD>gen
|
||||
elseif columns==-2 % spalteneintr<EFBFBD>ge durch 2 blanks getrennt (fluent/scheme)
|
||||
pos=[0];
|
||||
for i=1:length(s)-1
|
||||
if isspace(s(i)) & isspace(s(i+1))
|
||||
pos(end+1)=i+1;
|
||||
end
|
||||
end
|
||||
pos(end+1)=length(s);
|
||||
else % spalteneintr<EFBFBD>ge durch blanks getrennt
|
||||
%pos = findstr(' ',s); % trennzeichenpositionen in zeile suchen
|
||||
pos=[];
|
||||
word=0;
|
||||
for i=1:length(s)
|
||||
if isspace(s(i))
|
||||
word=0;
|
||||
elseif ~word
|
||||
word=1;
|
||||
pos(end+1)=i-1;
|
||||
end
|
||||
end
|
||||
pos(end+1)=length(s);
|
||||
end
|
||||
if headerlines>=1
|
||||
for i=1:length(pos)-1 % alle spalten
|
||||
colname{i}=s(pos(i)+1:pos(i+1)-1);
|
||||
if columns==-1 fprintf(' = data(strmatch(''%s'',colname),:); %% column %d\n', colname{i},i); end
|
||||
if columns==-2 fprintf('%% column %d: %s\n', i, colname{i}); end
|
||||
end
|
||||
end
|
||||
columns = length(pos)-1;
|
||||
fprintf(1,' total: %d columns ',columns);
|
||||
end
|
||||
data=fscanf(f,'%f',[columns,inf]);
|
||||
fclose(f);
|
||||
fprintf(1,'done.\n');
|
||||
end
|
||||
@ -29,12 +29,10 @@ fprintf('final pressure drop = %f Pa\n',dpErgun)
|
||||
%====================================%
|
||||
% simulation data
|
||||
%====================================%
|
||||
%path = '../probes/0/p'; % 2.1.x
|
||||
path = '../postProcessing/probes/0/p'; % 2.2.x
|
||||
columns=3;
|
||||
headerlines=5;
|
||||
data = loaddata(path,columns,headerlines);
|
||||
data=transpose(data);
|
||||
%path = '../probes/0/p'; % ext32
|
||||
path = '../postProcessing/probes/0/p';
|
||||
|
||||
data = load(path);
|
||||
[x,y]=size(data);
|
||||
dp_sim = data(:,2)-data(:,y);
|
||||
t_sim = data(:,1);
|
||||
@ -70,12 +68,10 @@ Tp = 600;
|
||||
Np = 1005;
|
||||
lambda = 0.0256;
|
||||
|
||||
%path = '../probes/0/T'; % 2.1.x
|
||||
path = '../postProcessing/probes/0/T'; % 2.2.x
|
||||
columns=3;
|
||||
headerlines=5;
|
||||
data = loaddata(path,columns,headerlines);
|
||||
data=transpose(data);
|
||||
%path = '../probes/0/T'; % ext32
|
||||
path = '../postProcessing/probes/0/T';
|
||||
|
||||
data = load(path);
|
||||
[x,y]=size(data);
|
||||
Tin_sim = data(:,2); % mean temp inlet temp [K]
|
||||
Tout_sim = data(:,3); % mean temp outlet temp [K]
|
||||
|
||||
@ -23,7 +23,7 @@ startTime 0;
|
||||
|
||||
stopAt endTime;
|
||||
|
||||
endTime 1.0;
|
||||
endTime 1.5;
|
||||
|
||||
deltaT 0.005;
|
||||
|
||||
|
||||
@ -1,10 +1,12 @@
|
||||
echo both
|
||||
log ../DEM/log.liggghts
|
||||
|
||||
# Particle packing by insertion and successive growing of particles
|
||||
|
||||
atom_style granular
|
||||
atom_modify map array
|
||||
boundary m m m
|
||||
newton off
|
||||
echo both
|
||||
|
||||
communicate single vel yes
|
||||
|
||||
|
||||
@ -1,20 +1,28 @@
|
||||
# read packed bed and calc convective heat transfer
|
||||
echo both
|
||||
log ../DEM/log.liggghts
|
||||
thermo_log ../DEM/post/thermo.txt
|
||||
|
||||
#######################################################
|
||||
# variables #
|
||||
#######################################################
|
||||
variable r0 equal 0.011
|
||||
#######################################################
|
||||
|
||||
# read packed bed and calc convective heat transfer
|
||||
atom_style granular
|
||||
atom_modify map array
|
||||
communicate single vel yes
|
||||
boundary m m m
|
||||
newton off
|
||||
echo both
|
||||
|
||||
communicate single vel yes
|
||||
|
||||
units si
|
||||
processors 1 1 2
|
||||
|
||||
# read the restart file
|
||||
read_restart ../DEM/post/restart/liggghts.restart
|
||||
|
||||
neighbor 0.003 bin
|
||||
neighbor ${r0} bin
|
||||
neigh_modify delay 0 binsize 0.01
|
||||
|
||||
|
||||
@ -26,7 +34,7 @@ fix m3 all property/global coefficientRestitution peratomtypepair 1 0.3
|
||||
fix m4 all property/global coefficientFriction peratomtypepair 1 0.5
|
||||
|
||||
# pair style
|
||||
pair_style gran model hertz tangential history # Hertzian without cohesion
|
||||
pair_style gran model hertz tangential history
|
||||
pair_coeff * *
|
||||
|
||||
# timestep, gravity
|
||||
@ -53,23 +61,22 @@ region total block INF INF INF INF INF INF units box
|
||||
set region total property/atom Temp 600.
|
||||
|
||||
# cfd coupling
|
||||
fix cfd all couple/cfd couple_every 100 mpi
|
||||
fix cfd2 all couple/cfd/force
|
||||
fix cfd all couple/cfd couple_every 100 mpi
|
||||
fix cfd2 all couple/cfd/force
|
||||
|
||||
# this one invokes heat transfer calculation, transfers per-particle temperature and adds convective heat flux to particles
|
||||
fix cfd3 all couple/cfd/convection T0 600
|
||||
fix cfd3 all couple/cfd/convection T0 600
|
||||
|
||||
# apply nve integration to all particles that are inserted as single particles
|
||||
fix integr all nve/sphere
|
||||
fix integr all nve/sphere
|
||||
|
||||
|
||||
# screen output
|
||||
# output settings, include total thermal energy
|
||||
compute rke all erotate/sphere
|
||||
thermo_style custom step atoms ke c_rke vol
|
||||
thermo_style custom step atoms ke c_rke f_heattransfer vol
|
||||
thermo 1000
|
||||
thermo_modify lost ignore norm no
|
||||
compute_modify thermo_temp dynamic yes
|
||||
|
||||
dump dmp all custom 100 ../DEM/post/dump.liggghts_run id type x y z ix iy iz vx vy vz fx fy fz omegax omegay omegaz radius f_Temp[0] f_heatFlux[0]
|
||||
|
||||
run 1
|
||||
run 0
|
||||
|
||||
@ -25,6 +25,7 @@ debugMode="off" # on | off| strict
|
||||
testHarnessPath="$CFDEM_TEST_HARNESS_PATH"
|
||||
runOctave="true"
|
||||
postproc="false"
|
||||
cleanup="true"
|
||||
#--------------------------------------------------------------------------------#
|
||||
|
||||
#- call function to run a parallel CFD-DEM case
|
||||
@ -83,17 +84,20 @@ if [ $postproc == "true" ]
|
||||
fi
|
||||
|
||||
#- clean up case
|
||||
echo "deleting data at: $casePath : ???\n"
|
||||
source $WM_PROJECT_DIR/bin/tools/CleanFunctions
|
||||
cd $casePath/CFD
|
||||
cleanCase
|
||||
rm -r $casePath/CFD/clockData
|
||||
rm $casePath/DEM/post/*.*
|
||||
#rm -r $casePath/DEM/post/restart/*.*
|
||||
echo "done"
|
||||
if [ $cleanup == "true" ]
|
||||
then
|
||||
echo "deleting data at: $casePath : \n"
|
||||
source $WM_PROJECT_DIR/bin/tools/CleanFunctions
|
||||
cd $casePath/CFD
|
||||
cleanCase
|
||||
rm -r $casePath/CFD/clockData
|
||||
rm $casePath/DEM/post/*.*
|
||||
#rm -r $casePath/DEM/post/restart/*.*
|
||||
echo "done"
|
||||
|
||||
#- preserve post directory
|
||||
touch $casePath/DEM/post/.gitignore
|
||||
touch $casePath/DEM/post/restart/.gitignore
|
||||
#- preserve post directory
|
||||
touch $casePath/DEM/post/.gitignore
|
||||
touch $casePath/DEM/post/restart/.gitignore
|
||||
fi
|
||||
|
||||
|
||||
|
||||
Reference in New Issue
Block a user