mirror of
https://github.com/OpenFOAM/OpenFOAM-6.git
synced 2025-12-08 06:57:46 +00:00
This addition allows for theoretical wave models to be utilised for
initialisation and as boundary conditions. Multiple models can be used
simultaneously, each with differing phases and orientations. If multiple
models are used the shapes and velocities are superimposed.
The wave models are specified in the velocity boundary condition. The
phase fraction boundary condition and the set utility both look up the
velocity condition in order to access the wave model. A velocity
boundary may be specified as follows:
inlet
{
type waveVelocity;
origin (0 0 0);
direction (1 0 0);
speed 2;
waves
(
Airy
{
length 300;
amplitude 2.5;
depth 150;
phase 0;
angle 0;
}
);
scale table ((1200 1) (1800 0));
crossScale constant 1;
}
The alpha boundary only requires the type, unless the name of the
velocity field is non-standard, in which case a "U" entry will also be
needed. The setWaves utility does not require a dictionary file; non-
standard field names can be specified as command-line arguments.
Wave models currently available are Airy (1st order) and Stokes2 (second
order). If a depth is specified, and it is not too large, then shallow
terms will be included, otherwise the models assume that the liquid is
deep.
This work was supported by Jan Kaufmann and Jan Oberhagemann at DNV GL.
85 lines
2.4 KiB
Bash
Executable File
85 lines
2.4 KiB
Bash
Executable File
#!/bin/sh
|
|
cd ${0%/*} || exit 1 # Run from this directory
|
|
|
|
# Parse arguments for library compilation
|
|
. ../wmake/scripts/AllwmakeParseArguments
|
|
|
|
# Perform various checks
|
|
wmakeCheckPwd "$WM_PROJECT_DIR/src" || {
|
|
echo "Allwmake error: Current directory is not \$WM_PROJECT_DIR/src"
|
|
echo " The environment variables are inconsistent with the installation."
|
|
echo " Check the OpenFOAM entries in your dot-files and source them."
|
|
exit 1
|
|
}
|
|
|
|
[ -n "$FOAM_EXT_LIBBIN" ] || {
|
|
echo "Allwmake error: FOAM_EXT_LIBBIN not set"
|
|
echo " Check the OpenFOAM entries in your dot-files and source them."
|
|
exit 1
|
|
}
|
|
|
|
# Update OpenFOAM version strings if required
|
|
wmakePrintBuild -check || wrmo OpenFOAM/global/global.o 2>/dev/null
|
|
|
|
wmakeLnInclude OpenFOAM
|
|
wmakeLnInclude OSspecific/${WM_OSTYPE:-POSIX}
|
|
Pstream/Allwmake $targetType $*
|
|
|
|
OSspecific/${WM_OSTYPE:-POSIX}/Allwmake $targetType $*
|
|
wmake $targetType OpenFOAM
|
|
|
|
wmake $targetType fileFormats
|
|
wmake $targetType surfMesh
|
|
wmake $targetType triSurface
|
|
wmake $targetType meshTools
|
|
|
|
# Decomposition methods needed by dummyThirdParty
|
|
# (dummy metisDecomp, scotchDecomp etc) needed by e.g. meshTools
|
|
parallel/decompose/AllwmakeLnInclude
|
|
dummyThirdParty/Allwmake $targetType $*
|
|
|
|
wmakeLnInclude fvOptions
|
|
|
|
wmake $targetType finiteVolume
|
|
wmake $targetType lagrangian/basic
|
|
wmake $targetType lagrangian/distributionModels
|
|
wmake $targetType genericPatchFields
|
|
|
|
wmake $targetType conversion
|
|
wmake $targetType mesh/extrudeModel
|
|
wmake $targetType dynamicMesh
|
|
wmake $targetType sampling
|
|
wmake $targetType dynamicFvMesh
|
|
wmake $targetType topoChangerFvMesh
|
|
|
|
# Compile scotchDecomp, metisDecomp etc.
|
|
parallel/Allwmake $targetType $*
|
|
|
|
wmake $targetType ODE
|
|
wmake $targetType randomProcesses
|
|
|
|
transportModels/Allwmake $targetType $*
|
|
thermophysicalModels/Allwmake $targetType $*
|
|
TurbulenceModels/Allwmake $targetType $*
|
|
wmake $targetType combustionModels
|
|
regionModels/Allwmake $targetType $*
|
|
lagrangian/Allwmake $targetType $*
|
|
mesh/Allwmake $targetType $*
|
|
renumber/Allwmake $targetType $*
|
|
fvAgglomerationMethods/Allwmake $targetType $*
|
|
|
|
wmake $targetType fvMotionSolver
|
|
wmake $targetType engine
|
|
wmake $targetType fvOptions
|
|
wmake $targetType regionCoupled
|
|
|
|
functionObjects/Allwmake $targetType $*
|
|
|
|
wmake $targetType sixDoFRigidBodyMotion
|
|
wmake $targetType rigidBodyDynamics
|
|
wmake $targetType rigidBodyMeshMotion
|
|
wmake $targetType waves
|
|
|
|
|
|
#------------------------------------------------------------------------------
|