CFD Online Discussion Forums

CFD Online Discussion Forums (https://www.cfd-online.com/Forums/)
-   OpenFOAM Running, Solving & CFD (https://www.cfd-online.com/Forums/openfoam-solving/)
-   -   Waves2Foam usage for 2D wave in 3D domain (https://www.cfd-online.com/Forums/openfoam-solving/136045-waves2foam-usage-2d-wave-3d-domain.html)

erncyc May 22, 2014 00:31

Waves2Foam usage for 2D wave in 3D domain
 
Dear Foamers,

First I wish to thank all who take their time to help folk like us...special thanks to Niels for all his efforts.

I have a 3D domain with blockMeshDict shown below. I am simulating a 2D wave in a 3D domain, on the basis of the tutorial in waves2Foam. I am not sure whether I need to use the 3D waveflume or the 2D one. Currently I am using the latter.

My setting for the waveProperties are a bit suspect. When I run the case the wave initially appears in the whole domain for about 4 time steps then gradually disappears completely in the non-relaxed computational zone. The wave only remains in the inlet relaxation zone. My wave settings appear below. Please help me resolve this issue. Thanks.


*****************************BlockMeshDict******** **************************

/*--------------------------------*- C++ -*----------------------------------*\
| ========= | |
| \\ / F ield | OpenFOAM: The Open Source CFD Toolbox |
| \\ / O peration | Version: 2.0.1 |
| \\ / A nd | Web: www.OpenFOAM.com |
| \\/ M anipulation | |
\*---------------------------------------------------------------------------*/
FoamFile
{
version 2.0;
format ascii;
class dictionary;
object blockMeshDict;
}
// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
convertToMeters 1;
vertices
(
(0 -0.55 0)
(4.97025 -0.55 0)
(5.02975 -0.55 0)
(10 -0.55 0)
(0 -0.174 0)
(4.97025 -0.174 0)
(5.02975 -0.174 0)
(10 -0.174 0)
(0 -0.114 0)
(4.97025 -0.114 0)
(5.02975 -0.114 0)
(10 -0.114 0)
(0 0.45 0)
(4.97025 0.45 0)
(5.02975 0.45 0)
(10 0.45 0)
(0 -0.55 0.003)
(4.97025 -0.55 0.003)
(5.02975 -0.55 0.003)
(10 -0.55 0.003)
(0 -0.174 0.003)
(4.97025 -0.174 0.003)
(5.02975 -0.174 0.003)
(10 -0.174 0.003)
(0 -0.114 0.003)
(4.97025 -0.114 0.003)
(5.02975 -0.114 0.003)
(10 -0.114 0.003)
(0 0.45 0.003)
(4.97025 0.45 0.003)
(5.02975 0.45 0.003)
(10 0.45 0.003)
);
blocks
(
hex (0 1 5 4 16 17 21 20) (250 60 2) simpleGrading (0.020 0.020 1)
hex (1 2 6 5 17 18 22 21) (40 60 2) simpleGrading (1 0.020 1)
hex (2 3 7 6 18 19 23 22) (250 60 2) simpleGrading (50 0.020 1)
hex (4 5 9 8 20 21 25 24) (250 40 2) simpleGrading (0.020 1 1)
hex (5 6 10 9 21 22 26 25) (40 40 2) simpleGrading (1 1 1)
hex (6 7 11 10 22 23 27 26) (250 40 2) simpleGrading (50 1 1)
hex (8 9 13 12 24 25 29 28) (250 90 2) simpleGrading (0.020 50 1)
hex (9 10 14 13 25 26 30 29) (40 90 2) simpleGrading (1 50 1)
hex (10 11 15 14 26 27 31 30) (250 90 2) simpleGrading (50 50 1)
 
 
 
);
edges
(
);
patches
(
patch inlet
(
(8 24 28 12)
(4 20 24 8)
(0 16 20 4)
)
wall bottom
(
(0 1 17 16)
(1 2 18 17)
(2 3 19 18)
)
patch outlet
(
(3 7 23 19)
(7 11 27 23)
(11 15 31 27)
)
patch atmosphere
(
(12 28 29 13)
(13 29 30 14)
(14 30 31 15)
)

wall frontBack
(
(0 4 5 1)
(1 5 6 2)
(2 6 7 3)
(4 8 9 5)
(5 9 10 6)
(6 10 11 7)
(8 12 13 9)
(9 13 14 10)
(10 14 15 11)
(16 17 21 20)
(17 18 22 21)
(18 19 23 22)
(20 21 25 24)
(21 22 26 25)
(22 23 27 26)
(24 25 29 28)
(25 26 30 29)
(26 27 31 30)
)
);
mergePatchPairs
(
);



****************************End******************* *************


***************************waveProperties********* ***************


/*--------------------------------*- C++ -*----------------------------------*\
| ========= | |
| \\ / F ield | OpenFOAM: The Open Source CFD Toolbox |
| \\ / O peration | Version: 2.1.1 |
| \\ / A nd | Web: www.OpenFOAM.org |
| \\/ M anipulation | |
\*---------------------------------------------------------------------------*/
FoamFile
{
version 2.0;
format ascii;
class dictionary;
location "constant";
object waveProperties;
}
// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
timeShift 0;
seaLevel 0;
relaxationNames ( inlet outlet );
initializationName inlet;
pName p_rgh;
inletCoeffs
{
waveType stokesSecond;
Tsoft 0.55;
depth 0.55;
//period 0.86;
direction ( 1 0 0 );
phi 0;
//height 0.075;
debug off;
relaxationZone
{
relaxationScheme Spatial;
relaxationShape Rectangular;
beachType Empty;
relaxType INLET;
startX ( 0 0 -0.003 );
endX ( 3 0 0.003 );
orientation ( 1 0 0 );
}

waveNumber ( 5.46784 0 0 );
omega 7.30603;

 
//relaxationWeight Exponential; //Default and otherwise: FreePolynomial, ThirdOrderPolynomial
relaxationWeight SixthOrderPolynomial;
}
outletCoeffs
{
waveType potentialCurrent;
U ( 0 0 0 );
Tsoft 0.55;
relaxationZone
{
relaxationScheme Spatial;
relaxationShape Rectangular;
beachType Empty;
relaxType OUTLET;
startX ( 7.7 0 -0.003 );
endX ( 10 0 0.003 );
orientation ( 1 0 0 );
}
courantCorrection on;
}
 
// ************************************************** *********************** //


All times are GMT -4. The time now is 20:00.