Sei sulla pagina 1di 18

icoStructFoam

a fluid-structure interaction solver Philip Evegren

Cases
icoFoam icoFoam constant constant transportProperties transportProperties polyMesh polyMesh controlDict controlDict fvSchemes fvSchemes fvSolution fvSolution system system pp U U 00 solidDisplacementFoam solidDisplacementFoam constant constant mechanicalProperties mechanicalProperties polyMesh polyMesh thermalProperties thermalProperties controlDict controlDict fvSchemes fvSchemes fvSolution fvSolution system system D D TT 00

icoStructFoam icoStructFoam constant constant region1 region1 polyMesh polyMesh dynamicMeshDict dynamicMeshDict polyMesh polyMesh couplingParameters couplingParameters region2 region2 controlDict controlDict system system region1 region1 region2 region2 fvSchemes fvSchemes fvSolution fvSolution region1 region1 pp U U cellDisplacement cellDisplacement pointDisplacement pointDisplacement cellMotion cellMotion pointMotion pointMotion 00 region2 region2 D D TT

fvSchemes fvSchemes fvSolution fvSolution tetFemSolution tetFemSolution

transportProperties mechanicalProperties mechanicalProperties transportProperties thermalProperties thermalProperties transportProperties transportProperties

Solvers
solidDisplacementFoam solidDisplacementFoam solidDisplacementFoam.C solidDisplacementFoam.C createFields.H createFields.H Make Make createFields.H createFields.H files files Make Make options options files files options options readSolidDisplacementFoamControls.H readSolidDisplacementFoamControls.H readThermalProperties.H readThermalProperties.H readMechanicalProperties.H readMechanicalProperties.H calculateStress.H calculateStress.H icoFoam icoFoam icoFoam.C icoFoam.C

Solvers
icoStructFoam icoStructFoam icoStructFoam.C icoStructFoam.C createIcoFields.H createIcoFields.H Make Make files files options options readStressedFoamControls.H readStressedFoamControls.H readThermalProperties.H readThermalProperties.H readMechanicalProperties.H readMechanicalProperties.H calculateStress.H calculateStress.H continuityErrs.H continuityErrs.H courantNo.H courantNo.H createMeshes.H createMeshes.H createMeshMotion.H createMeshMotion.H createPhi.H createPhi.H createStructureFields.H createStructureFields.H readCoupling.H readCoupling.H readPISOControls.H readPISOControls.H readSIMPLEControls.H readSIMPLEControls.H write.H write.H tractionDisplacement tractionDisplacement tractionDisplacementFvPatchVectorField.H tractionDisplacementFvPatchVectorField.H tractionDisplacementFvPatchVectorField.C tractionDisplacementFvPatchVectorField.C

Source code

Source code

Source code

Source code

Source code

Running a case
Download the solver using: svn checkout https://openfoam-extend.svn.sourceforge.net/svnroot/openfoamextend/trunk/Breeder/solvers/other/IcoStructFoam/

Compile the solver using wmake

Run the blockMesh utility

Running a case
dimensions [0 1 -1 0 0 0 0]; internalField uniform (0 0 0); boundaryField { bottom { type value } top { type value }

Boundary & initial conditions region1 dimensions


boundaryField {

[0 2 -2 0 0 0 0];

internalField uniform 0;

fixedValue; uniform (0 0 0);

U
fixedValue; uniform (0 0 0);

bottom { type } top { type }

zeroGradient;

zeroGradient;

frontAndBack { type empty; } inlet { type value } outlet { type zeroGradient; } } }

frontAndBack { type empty; } inlet { type } outlet { type

fixedValue; uniform (0.005 0 0);

zeroGradient;

fixedValue; value uniform 0;

Running a case
dimensions [0 1 0 0 0 0 0]; internalField uniform (0 0 0); boundaryField { bottom { type value } top { // type type value } frontAndBack { type empty; } inlet { type } outlet { type } } } } zeroGradient; zeroGradient; fixedValue; uniform (0 0 0);

Boundary & initial conditions region1

dimensions

[0 1 0 0 0 0 0];

internalField uniform (0 0 0); boundaryField { bottom { type value } top { type // type // value }

fixedValue; uniform (0 0 0);

cD

pD

fixedValue; uniform (0 0 0);

zeroGradient; fixedValue; uniform (0 0 0);

frontAndBack { type empty; } inlet { type } outlet { type zeroGradient;

zeroGradient;

zeroGradient;

Running a case
dimensions [0 1 0 0 0 0 0]; internalField uniform (0 0 0); boundaryField { bottom { type traction pressure value } top { type

Boundary & initial conditions region2

tractionDisplacement; uniform (0 0 0); uniform 0; uniform (0 0 0);

couplingParameters D

fixedValue; value uniform (0 0 0);

} frontAndBack { type empty; } inlet { // type // traction // pressure

// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * // fluidSide top; solidSide bottom; startMeshMotion time [0 0 1 0 0 0 0] 0.1; motionRelaxation iTime [0 0 -1 0 0 0 0] 5;

value } outlet { type traction pressure value } }

tractionDisplacement; uniform (0 0 0); uniform 0; type fixedValue; uniform (0 0 0);

// ************************************************************************* //

tractionDisplacement; uniform (0 0 0); uniform 0; uniform (0 0 0);

Running a case
Other properties
// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * // applicationClass laplacianFoam; startFrom // * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * // twoDMotion //solver //diffusion yes; laplaceTetDecomposition; quadratic patchEnhanced; startTime stopAt startTime; 0; endTime; 1; 0.001; runTime;

dynamicMeshDict

endTime deltaT writeControl

//frozenDiffusion off; //distancePatches //( //); dynamicFvMesh dynamicMotionSolverFvMesh; motionSolverLibs ("libfvMotionSolvers.so"); // motionSolverLibs ("libfvMotionSolvers.dylib"); solver displacementLaplacian; diffusivity uniform;

writeInterval 0.01; cycleWrite 0; ascii;

controlDict

writeFormat

writePrecision 6; writeCompression uncompressed; timeFormat general;

// ************************************************************************* //

timePrecision 6; runTimeModifiable yes;

// ******************************************************************* ****** //

Running a case
Run by typing:

Post-processing
foamToVTK . icoStructFoamTest -mesh region1 foamToVTK . icoStructFoamTest -mesh region2

Launch paraview

Running a case
Displacement of solid region Displacement of fluid region

Running a case
Stress field of solid region Pressure field of fluid region

Running a case
Velocity field of fluid region

Potrebbero piacerti anche