diff --git a/Allwclean b/Allwclean new file mode 100644 index 0000000..662593b --- /dev/null +++ b/Allwclean @@ -0,0 +1,20 @@ +#!/bin/bash +cd "${0%/*}" || exit # Run from this directory + +#------------------------------------------------------------------------------ +echo WARNING: This will clean all the libraries and solvers! +echo Press y to proceed or anything else to abort. + +read varname; + +if [[ "$varname" == "y" ]]; +then + input="etc/buildList" + + while IFS= read -r target + do + wclean $targetType $target + done < "$input" + +fi +#------------------------------------------------------------------------------ diff --git a/Allwmake b/Allwmake new file mode 100644 index 0000000..194e1d1 --- /dev/null +++ b/Allwmake @@ -0,0 +1,13 @@ +#!/bin/sh +cd "${0%/*}" || exit # Run from this directory +. ${WM_PROJECT_DIR:?}/wmake/scripts/AllwmakeParseArguments + +#------------------------------------------------------------------------------ +input="etc/buildList" + +while IFS= read -r target +do + wmake $targetType $target +done < "$input" + +#------------------------------------------------------------------------------ diff --git a/applications/solvers/icoBoilingFoam/Make/files b/applications/solvers/icoBoilingFoam/Make/files new file mode 100644 index 0000000..82d18a8 --- /dev/null +++ b/applications/solvers/icoBoilingFoam/Make/files @@ -0,0 +1,5 @@ +fluid/compressibleCourantNo.C +solid/solidRegionDiffNo.C +icoBoilingFoam.C + +EXE = $(FOAM_USER_APPBIN)/icoBoilingFoam diff --git a/applications/solvers/icoBoilingFoam/Make/options b/applications/solvers/icoBoilingFoam/Make/options new file mode 100644 index 0000000..8cdde07 --- /dev/null +++ b/applications/solvers/icoBoilingFoam/Make/options @@ -0,0 +1,52 @@ +EXE_INC = \ + -I./fluid \ + -I./fluid/VoF \ + -I./solid \ + -I./include \ + -I../../../src/interfaceProperties/lnInclude \ + -I../../../src/geometricVoF/lnInclude \ + -I$(LIB_SRC)/transportModels/twoPhaseMixture/lnInclude \ + -I$(LIB_SRC)/transportModels \ + -I$(LIB_SRC)/transportModels/incompressible/lnInclude \ + -I$(LIB_SRC)/transportModels/interfaceProperties/lnInclude \ + -I$(LIB_SRC)/TurbulenceModels/turbulenceModels/lnInclude \ + -I$(LIB_SRC)/TurbulenceModels/incompressible/lnInclude \ + -I$(LIB_SRC)/finiteVolume/lnInclude \ + -I$(LIB_SRC)/dynamicFvMesh/lnInclude \ + -I$(LIB_SRC)/surfMesh/lnInclude \ + -I$(LIB_SRC)/meshTools/lnInclude \ + -I$(LIB_SRC)/sampling/lnInclude \ + -I$(LIB_SRC)/transportModels/compressible/lnInclude \ + -I$(LIB_SRC)/thermophysicalModels/basic/lnInclude \ + -I$(LIB_SRC)/thermophysicalModels/specie/lnInclude \ + -I$(LIB_SRC)/thermophysicalModels/reactionThermo/lnInclude \ + -I$(LIB_SRC)/thermophysicalModels/solidThermo/lnInclude \ + -I$(LIB_SRC)/thermophysicalModels/chemistryModel/lnInclude \ + -I$(LIB_SRC)/ODE/lnInclude \ + -I$(LIB_SRC)/combustionModels/lnInclude \ + -I$(LIB_SRC)/thermophysicalModels/radiation/lnInclude \ + -I$(LIB_SRC)/regionModels/regionModel/lnInclude \ + -Wfatal-errors + +EXE_LIBS = \ + -lincompressibleTransportModels \ + -lturbulenceModels \ + -lincompressibleTurbulenceModels \ + -lfiniteVolume \ + -ldynamicFvMesh \ + -lsurfMesh \ + -lfvOptions \ + -lmeshTools \ + -lsampling \ + -lwaveModels \ + -lspecie \ + -lreactionThermophysicalModels \ + -lsolidThermo \ + -lchemistryModel \ + -lODE \ + -lcombustionModels \ + -lturbulenceModels \ + -lcompressibleTurbulenceModels \ + -lradiationModels \ + -lregionModels \ + -L$(FOAM_USER_LIBBIN) -linterfacePropertiesBoiling -lgeometricVoFBoiling diff --git a/applications/solvers/icoBoilingFoam/createFields.H b/applications/solvers/icoBoilingFoam/createFields.H new file mode 100644 index 0000000..30f4452 --- /dev/null +++ b/applications/solvers/icoBoilingFoam/createFields.H @@ -0,0 +1,2 @@ +#include "createFluidFields.H" +#include "createSolidFields.H" diff --git a/applications/solvers/icoBoilingFoam/createMeshes.H b/applications/solvers/icoBoilingFoam/createMeshes.H new file mode 100644 index 0000000..97aed21 --- /dev/null +++ b/applications/solvers/icoBoilingFoam/createMeshes.H @@ -0,0 +1,4 @@ +regionProperties rp(runTime); + +#include "createFluidMeshes.H" +#include "createSolidMeshes.H" diff --git a/applications/solvers/icoBoilingFoam/createMeshesPostProcess.H b/applications/solvers/icoBoilingFoam/createMeshesPostProcess.H new file mode 100644 index 0000000..d6d60a1 --- /dev/null +++ b/applications/solvers/icoBoilingFoam/createMeshesPostProcess.H @@ -0,0 +1,9 @@ +#include "createMeshes.H" + +if (!fluidRegions.size() && !solidRegions.size()) +{ + FatalErrorIn(args.executable()) + << "No region meshes present" << exit(FatalError); +} + +fvMesh& mesh = fluidRegions.size() ? fluidRegions[0] : solidRegions[0]; diff --git a/applications/solvers/icoBoilingFoam/fluid/TEqn.H b/applications/solvers/icoBoilingFoam/fluid/TEqn.H new file mode 100644 index 0000000..aca4e93 --- /dev/null +++ b/applications/solvers/icoBoilingFoam/fluid/TEqn.H @@ -0,0 +1,33 @@ +{ + + kappa = alpha1*k1 + alpha2*k2; + surfaceScalarField kappaf(fvc::interpolate(kappa)); + volScalarField energyExp(energySource*Tsat); + + #include "computeMassSource.H" + + + + fvScalarMatrix TEqn + ( + fvm::ddt(rhoCp,T) + + fvm::div(rhoCpPhi,T) + - fvm::Sp(fvc::ddt(rhoCp) + fvc::div(rhoCpPhi), T) + - fvm::laplacian(kappaf,T) + - fvm::Sp(energySource,T) + // - fvc::DDt(phi,p_rgh) + == + - energyExp + ); + + + TEqn.relax(); + TEqn.solve(); + + Info<< "min/max(T) = " << min(T).value() << ", " << max(T).value() < tUEqn + ( + fvm::ddt(rho, U) + fvm::div(rhoPhi, U) + - fvm::Sp(fvc::ddt(rho) + fvc::div(rhoPhi), U) + + MRF.DDt(rho, U) + + turbulence.divDevRhoReff(rho,U) + == + fvOptions(rho, U) + ); + fvVectorMatrix& UEqn = tUEqn.ref(); + + UEqn.relax(); + + fvOptions.constrain(UEqn); + + if (momentumPredictor) + { + + #include "pEqnCorr.H" + + solve + ( + UEqn + == + fvc::reconstruct + ( + ( + interface.surfaceTensionForce() + - ghf*fvc::snGrad(rho) + - fvc::snGrad(p_rgh) + )*mesh.magSf() + ), + mesh.solver(U.select(finalIter)) + ); + + fvOptions.correct(U); + } diff --git a/applications/solvers/icoBoilingFoam/fluid/VoF/alphaControls_advector.H b/applications/solvers/icoBoilingFoam/fluid/VoF/alphaControls_advector.H new file mode 100644 index 0000000..2e94f34 --- /dev/null +++ b/applications/solvers/icoBoilingFoam/fluid/VoF/alphaControls_advector.H @@ -0,0 +1,3 @@ +const dictionary& alphaControls = mesh.solverDict(alpha1.name()); + +label nAlphaSubCycles(alphaControls.get