|
[Sponsors] |
June 25, 2021, 07:34 |
Waterhammer sonicLiquidFoam
|
#1 |
New Member
Victor
Join Date: Mar 2019
Posts: 5
Rep Power: 7 |
I’m trying to model the water hammer effect using sonicLiquidFoam. I’ve changed the tutorial example to have an inlet with constant pressure (1 bar) on top of the tank. The pipe out from the tank has been lengthen to 0.3m.
On the end of the outlet pipe (nozzle) I change the speed from 1m/s to 0 m/s in 0.0001s. I am expecting it to run “normally” up to the velocity change then show a pressure wave in the pipe. Any ideas how to do this? Guessing I’m doing the inlet wrong? P: Code:
dimensions [1 -1 -2 0 0 0 0]; internalField uniform 100000; // 1 bar boundaryField { outerWall { type zeroGradient; } axis { type symmetryPlane; } nozzle { type zeroGradient; } back { type empty; } front { type empty; } inlet { type fixedValue; value uniform 100000; // 1 bar } } Code:
dimensions [0 1 -1 0 0 0 0]; internalField uniform (0 0 0); boundaryField { outerWall { type noSlip; } axis { type symmetryPlane; } nozzle { type uniformFixedValue; uniformValue table ( (0 (1 0 0)) (0.0001 (1 0 0)) (0.0002 (0 0 0)) ); } back { type empty; } front { type empty; } inlet { type zeroGradient; } } Code:
scale 0.1; vertices ( (0 0 -0.1) (1 0 -0.1) (0 0.5 -0.1) (1 0.5 -0.1) (4 0.5 -0.1) (0 0.6 -0.1) (1 0.6 -0.1) (4 0.6 -0.1) (0 3 -0.1) (1 3 -0.1) (0 0 0.1) (1 0 0.1) (0 0.5 0.1) (1 0.5 0.1) (4 0.5 0.1) (0 0.6 0.1) (1 0.6 0.1) (4 0.6 0.1) (0 3 0.1) (1 3 0.1) ); blocks ( hex (0 1 3 2 10 11 13 12) (30 20 1) simpleGrading (1 1 1) // top part of tank hex (2 3 6 5 12 13 16 15) (30 5 1) simpleGrading (1 1 1) // inside tank downstream inlet hex (3 4 7 6 13 14 17 16) (200 5 1) simpleGrading (1 1 1) // inlet hex (5 6 9 8 15 16 19 18) (30 20 1) simpleGrading (1 1 1) // lower part of tank ); // Fine mesh // blocks // ( // hex (0 1 3 2 10 11 13 12) (120 80 1) simpleGrading (1 1 1) // top part of tank // hex (2 3 6 5 12 13 16 15) (120 20 1) simpleGrading (1 1 1) // inside tank downstream inlet // hex (3 4 7 6 13 14 17 16) (800 20 1) simpleGrading (1 1 1) // inlet // hex (5 6 9 8 15 16 19 18) (120 380 1) simpleGrading (1 1 1) // lower part of tank // ); edges ( ); boundary ( inlet { type patch; faces ( (9 8 18 19) ); } outerWall { type wall; faces ( (0 1 11 10) (1 3 13 11) (3 4 14 13) (7 6 16 17) (6 9 19 16) // (9 8 18 19) ); } axis { type symmetryPlane; faces ( (0 10 12 2) (2 12 15 5) (5 15 18 8) ); } nozzle { type patch; faces ( (4 7 17 14) ); } back { type empty; faces ( (0 2 3 1) (2 5 6 3) (3 6 7 4) (5 8 9 6) ); } front { type empty; faces ( (10 11 13 12) (12 13 16 15) (13 14 17 16) (15 16 19 18) ); } ); mergePatchPairs ( ); |
|
Tags |
sonicliquidfoam, waterhammer |
|
|
Similar Threads | ||||
Thread | Thread Starter | Forum | Replies | Last Post |
sonicLiquidFoam and turbulence model | rcastilla | OpenFOAM Programming & Development | 4 | February 3, 2020 06:08 |
Temperature dependant properties for sonicLiquidFoam | sgopal1 | OpenFOAM Running, Solving & CFD | 0 | April 18, 2019 13:51 |
BC waveTransmissive in sonicLiquidFoam | philferdinand | OpenFOAM Running, Solving & CFD | 5 | December 3, 2018 04:51 |
compressibleInterFoam versus sonicLiquidFoam | supvika | OpenFOAM | 0 | January 21, 2011 19:16 |
Waterhammer software | Andris Skattebo | Main CFD Forum | 1 | July 18, 1998 21:01 |