Skip to content

Commit

Permalink
Add Pipe and PTBL to test and examples
Browse files Browse the repository at this point in the history
  • Loading branch information
rfj82982 committed Jan 14, 2025
1 parent 80cdc29 commit 045e81d
Show file tree
Hide file tree
Showing 9 changed files with 288 additions and 12 deletions.
1 change: 1 addition & 0 deletions examples/CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -14,6 +14,7 @@ add_subdirectory(Gravity-current)
add_subdirectory(MHD)
add_subdirectory(Mixing-layer)
add_subdirectory(Periodic-hill)
add_subdirectory(Pipe-Flow)
add_subdirectory(TBL-Turbulent-Boundary-Layer)
add_subdirectory(TGV-Taylor-Green-vortex)
add_subdirectory(Wind-Turbine)
9 changes: 9 additions & 0 deletions examples/Pipe-Flow/CMakeLists.txt
Original file line number Diff line number Diff line change
@@ -0,0 +1,9 @@
# Pipe-Flow
set(case "Pipe-Flow")
set(example_files "")
list(APPEND example_files "adios2_config.xml")
list(APPEND example_files "input_DNS_Re1000_LR.i3d")
list(APPEND example_files "input_DNS_Re5300_HR.i3d")
AddExample("${examples_dir}" "${case}" "${example_files}")


51 changes: 51 additions & 0 deletions examples/Pipe-Flow/adios2_config.xml
Original file line number Diff line number Diff line change
@@ -0,0 +1,51 @@
<?xml version="1.0"?>
<adios-config>
<io name="solution-io">
<engine type="BP4">
</engine>
<transport type="File">
<parameter key="Library" value="fstream"/>
<parameter key="ProfileUnits" value="Milliseconds"/>
</transport>
</io>
<io name="in-outflow-io">
<engine type="BP4">
</engine>
<transport type="File">
<parameter key="Library" value="fstream"/>
<parameter key="ProfileUnits" value="Milliseconds"/>
</transport>
</io>
<io name="turb-io">
<engine type="BP4">
</engine>
<transport type="File">
<parameter key="Library" value="fstream"/>
<parameter key="ProfileUnits" value="Milliseconds"/>
</transport>
</io>
<io name="restart-io">
<engine type="BP4">
</engine>
<transport type="File">
<parameter key="Library" value="fstream"/>
<parameter key="ProfileUnits" value="Milliseconds"/>
</transport>
</io>
<io name="statistics-io">
<engine type="BP4">
</engine>
<transport type="File">
<parameter key="Library" value="fstream"/>
<parameter key="ProfileUnits" value="Milliseconds"/>
</transport>
</io>
<io name="restart-forces-io">
<engine type="BP4">
</engine>
<transport type="File">
<parameter key="Library" value="fstream"/>
<parameter key="ProfileUnits" value="Milliseconds"/>
</transport>
</io>
</adios-config>
1 change: 1 addition & 0 deletions tests/CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -26,6 +26,7 @@ if (${BUILD_TESTING_FULL})
add_subdirectory(Mixing-layer)
add_subdirectory(Particle-Tracking)
add_subdirectory(Periodic-hill)
add_subdirectory(Pipe-Flow)
add_subdirectory(TBL-Turbulent-Boundary-Layer)
add_subdirectory(Wind-Turbine)
endif (${BUILD_TESTING_FULL})
Expand Down
6 changes: 6 additions & 0 deletions tests/Pipe-Flow/CMakeLists.txt
Original file line number Diff line number Diff line change
@@ -0,0 +1,6 @@
# Pipe-Flow
set(case "Pipe-FLow")
set(input_file "input_test.i3d")
set(additional_inputs "")
CreateMPITest(${test_dir} ${case} ${input_file} "${additional_inputs}")

51 changes: 51 additions & 0 deletions tests/Pipe-Flow/adios2_config.xml
Original file line number Diff line number Diff line change
@@ -0,0 +1,51 @@
<?xml version="1.0"?>
<adios-config>
<io name="solution-io">
<engine type="BP4">
</engine>
<transport type="File">
<parameter key="Library" value="fstream"/>
<parameter key="ProfileUnits" value="Milliseconds"/>
</transport>
</io>
<io name="in-outflow-io">
<engine type="BP4">
</engine>
<transport type="File">
<parameter key="Library" value="fstream"/>
<parameter key="ProfileUnits" value="Milliseconds"/>
</transport>
</io>
<io name="turb-io">
<engine type="BP4">
</engine>
<transport type="File">
<parameter key="Library" value="fstream"/>
<parameter key="ProfileUnits" value="Milliseconds"/>
</transport>
</io>
<io name="restart-io">
<engine type="BP4">
</engine>
<transport type="File">
<parameter key="Library" value="fstream"/>
<parameter key="ProfileUnits" value="Milliseconds"/>
</transport>
</io>
<io name="statistics-io">
<engine type="BP4">
</engine>
<transport type="File">
<parameter key="Library" value="fstream"/>
<parameter key="ProfileUnits" value="Milliseconds"/>
</transport>
</io>
<io name="restart-forces-io">
<engine type="BP4">
</engine>
<transport type="File">
<parameter key="Library" value="fstream"/>
<parameter key="ProfileUnits" value="Milliseconds"/>
</transport>
</io>
</adios-config>
Original file line number Diff line number Diff line change
Expand Up @@ -12,24 +12,24 @@ p_row=0 ! Row partition
p_col=0 ! Column partition

! Mesh
nx=8 ! X-direction nodes
ny=320 ! Y-direction nodes
nz=320 ! Z-direction nodes
nx=128 ! X-direction nodes
ny=64 ! Y-direction nodes
nz=64 ! Z-direction nodes
istret = 0 ! y mesh refinement (0:no, 1:center, 2:both sides, 3:bottom)
beta = 0.0 ! Refinement parameter (beta)

! Domain
xlx = 1.25 ! Lx (Size of the box in x-direction)
xlx = 5. ! Lx (Size of the box in x-direction)
yly = 1.6 ! Ly (Size of the box in y-direction)
zlz = 1.6 ! Lz (Size of the box in z-direction)

! Flow parameters
re = 1500. ! nu=1/re (Kinematic Viscosity)
re = 1000. ! nu=1/re (Kinematic Viscosity)

! Time stepping
dt = 0.0004 ! Time step
dt = 0.00025 ! Time step
ifirst = 1 ! First iteration
ilast = 1000000 ! Last iteration
ilast = 100 ! Last iteration

! Enable modelling tools
ilesmod=0 ! if 0 then DNS
Expand All @@ -40,7 +40,7 @@ iibm=2 ! Flag for immersed boundary method
iin = 1 ! Inflow conditions (1: classic, 2: turbinit, 4: SEM)
u1 = 1. ! u1 (max velocity) (for inflow condition)
u2 = 1. ! u2 (min velocity) (for inflow condition)
init_noise = 0.0 ! Turbulence intensity (1=100%) !! Initial condition
init_noise = 3.0 ! Turbulence intensity (1=100%) !! Initial condition
inflow_noise = 0.0 ! Turbulence intensity (1=100%) !! Inflow condition

nclx1 = 0
Expand Down Expand Up @@ -76,8 +76,8 @@ cnu = 0.44 ! Ratio between hypervisvosity at k_m=2/3pi and k_c= pi

! Basic I/O
irestart = 0 ! Read initial flow field ?
icheckpoint = 50000 ! Frequency for writing backup file
ioutput = 10000 ! Frequency for visualization
icheckpoint = 100 ! Frequency for writing backup file
ioutput = 50 ! Frequency for visualization
ilist = 25 ! Frequency for writing to screen
nvisu = 1 ! Size for visualisation collection

Expand All @@ -90,7 +90,7 @@ nvisu = 1 ! Size for visualisation collection
wrotation = 0.12 ! rotation speed to trigger turbulence
spinup_time = 5000 ! number of time steps with a rotation to trigger turbulence
nstat = 1 ! Size arrays for statistic collection
initstat = 50 ! Time steps after which statistics are collected
initstat = 100001 ! Time steps after which statistics are collected

/End

Expand All @@ -104,7 +104,7 @@ initstat = 50 ! Time steps after which statistics are collected

rai=0.50 ! when simulating a pipe, inner radius
rao=0.70 ! when simulating a pipe, outer radius (defines wall thickness)
nraf=10000 !level of refinement for iibm==2 to find the surface of the immersed object
nraf=1000 !level of refinement for iibm==2 to find the surface of the immersed object
nobjmax=2 !number of immersed objects (DO NOT USE ZERO OBJECTS)
iforces=0

Expand Down
5 changes: 5 additions & 0 deletions tests/TBL-Turbulent-Boundary-Layer/CMakeLists.txt
Original file line number Diff line number Diff line change
@@ -1,4 +1,9 @@
# TBL
set(case "PTBL-Periodic-Turbulent-Boundary-Layer")
set(input_file "input_LR_PTBL_test.i3d")
set(additional_inputs "")
CreateMPITest(${test_dir} ${case} ${input_file} "${additional_inputs}")
#
set(case "TBL-Turbulent-Boundary-Layer")
set(input_file "input_test.i3d")
set(additional_inputs "")
Expand Down
152 changes: 152 additions & 0 deletions tests/TBL-Turbulent-Boundary-Layer/input_LR_PTBL_test.i3d
Original file line number Diff line number Diff line change
@@ -0,0 +1,152 @@
! -*- mode: f90 -*-
!===================
&BasicParam
!===================
! Flow type (1=Lock-exchange, 2=TGV, 3=Channel, 4=Periodic hill, 5=Cylinder, 6=dbg-schemes, 9=Turbulent-Boundary-Layer)
itype = 15

! Domain decomposition
p_row = 0 ! Row partition
p_col = 0 ! Column partition

! Mesh
nx = 96 ! X-direction nodes
ny = 129 ! Y-direction nodes
nz = 32 ! Z-direction nodes
istret = 3 ! y mesh refinement (0:no, 1:center, 2:both sides, 3:bottom)
beta = 0.889579572304913 ! Refinement parameter (beta)

! Domain
xlx = 30.0 ! Lx (Size of the box in x-direction)
yly = 30.0 ! Ly (Size of the box in y-direction)
zlz = 10.0 ! Lz (Size of the box in z-direction)

! Boundary conditions
nclx1 = 0
nclxn = 0
ncly1 = 2
nclyn = 2
nclz1 = 0
nclzn = 0
FreeStream = 0 ! 0 FreeStream off 1 FreeStream on

! Flow parameters
re = 1000 ! nu=1/re (Kinematic Viscosity)
iin = 2 ! Inflow conditions (1: classic, 2: turbinit)
u1 = 1.0 ! u1 (max velocity) (for inflow condition)
u2 = 1.0 ! u2 (min velocity) (for inflow condition)
init_noise = 0.02 ! Turbulence intensity (1=100%) !! Initial condition
inflow_noise = 0.0 ! Turbulence intensity (1=100%) !! Inflow condition

! Time stepping
dt = 0.004 ! Time step
ifirst = 1 ! First iteration
ilast = 100 ! Last iteration

! Enable modelling tools
ilesmod = 0 ! if 0 then DNS

/End

!====================
&NumOptions
!====================
! Spatial derivatives
ifirstder = 4 ! (1->2nd central, 2->4th central, 3->4th compact, 4-> 6th compact)
isecondder = 5 ! (1->2nd central, 2->4th central, 3->4th compact, 4-> 6th compact, 5->hyperviscous 6th)
ipinter = 2 ! interpolation scheme (1: classic, 2: optimized, 3: optimized agressive)

! Time scheme
iimplicit = 2 ! Implicit scheme for y-diffusive term
itimescheme = 3 ! Time integration scheme

! Dissipation control
nu0nu = 4.0 ! Ratio between hyperviscosity/viscosity at nu
cnu = 0.44 ! Ratio between hypervisvosity at k_m=2/3pi and k_c= pi

/End

!=================
&InOutParam
!=================
! Basic I/O
irestart = 0 ! Read initial flow field ?
icheckpoint = 100 ! Frequency for writing backup file
ioutput = 50 ! Frequency for visualization
ilist = 25 ! Frequency for writing to screen
nvisu = 1 ! Size for visualisation collection

/End

!=================
&Statistics
!=================
nstat = 1 ! Size arrays for statistic collection
initstat = 100000 ! Time steps after which statistics are collected

/End

!#############################
! OPTIONAL PARAMETERS
!#############################
!================
&LESModel
!================
jles = 0 ! LES Model (1: Phys Smag, 2: Phys WALE, 3: Phys dyn. Smag, 4: iSVV, 5: dyn SEV)

/End

!#############################
! Theta dot Computation
!#############################
!================
&ThetaDotModel
!================
jtheta_dot = 0 ! Theta dot Model (0: Biau, 1: Andy)
jthickness = 0 ! Model based on (0: Momentum Thickness, 1: Displacement Thickness)
Method_FT = 1 ! (0: old, 1: New)
K_theta = 1.0 ! K coefficient for e(theta)
H_12 = 2.4144 ! The ratio of displacement thickness to momentum thickness (laminar flow)

/End

!#############################
! Blowing
!#############################
!================
&BlowingModel
!================
Blowing = 0 ! Blowing (0: Off, 1: On)
A_Blowing = 0.0 ! Blowing Power
Xst_Blowing = 17.5 ! Start Control Region
Xen_Blowing = 22.5 ! End Control Region
Range_Smooth = 0.5 ! Adjust this value to control the smoothness of the transition

/End

!#############################
! Adverse Pressure Gradient
!#############################
!================
&AdversePresGrad
!================
APG = 0 ! Adverse Pressure Gradient (0: Off, 1: V1 (APG_DpDX), 2:V2 (Beta) (not working at the moment) )
APG_DpDX = 2.e-3 ! Pressure gradient
APG_Beta = 0.01 ! Beta

/End

!#############################
! Probe for Spectra
!#############################
!================
&ProbeSpectra
!================
Pro_Spectra = 0 ! Probe (0: Off, 1: On)
X_Pro_Spectra = 20 ! X Location
Z_Pro_Spectra = 7.5 ! Z Location

/End

&CASE
/End

0 comments on commit 045e81d

Please sign in to comment.