PointListIC

This test is for the point list initial condition. It tests the IC by placing a rotated NACA 9612 airfoil on in the domain. The point list IC works with one or more closed polygons that can be rotated counter-clockwise about a center of rotation. See below for example figure

../_images/alpha_ic_img.png

Each line of the input file gives a point as x y z ObjNum. The ObjNum column is optional; if it is omitted, every point in the file is treated as a single polygon. When it is present, a new polygon starts wherever ObjNum changes by more than obj_num_threshold (default 0.5) from the previous point.

By default every polygon is unioned together (via a pointwise max) to form the solid field. Individual polygons can instead be marked as void/negative regions using the invert parameter, which takes one entry per polygon (nonzero = void). Void polygons are unioned separately and then multiplied into the solid field, cutting holes wherever they overlap it. invert_all is a separate, single flag that flips the whole finished field (solid field with voids cut out) at the end, e.g. to make the IC 1 outside the solid region instead of inside it.

2D-serial

Two-dimensional

Serial

Validated using check script

./bin/alamo-2d-g++ tests/PointListIC/input  stop_time="0.0001" alpha.ic.pointlist.file.name="tests/PointListIC/NACA9612.xy" alpha.ic.pointlist.mult="0.9" alpha.ic.pointlist.invert="0" alpha.ic.pointlist.x0="0.05_m 0.05_m 0.0_m" alpha.ic.pointlist.rotation.center="0.1_m 0.1_m 0.1_m" alpha.ic.pointlist.rotation.angle="45_deg" alpha.ic.pointlist.eps="0.03_m"

2D-parallel

Two-dimensional

Parallel (2 procs)

Validated using check script

mpiexec -np 2 ./bin/alamo-2d-g++ tests/PointListIC/input  stop_time="0.0001" alpha.ic.pointlist.file.name="tests/PointListIC/NACA9612.xy" alpha.ic.pointlist.mult="0.9" alpha.ic.pointlist.invert="0" alpha.ic.pointlist.x0="0.05_m 0.05_m 0.0_m" alpha.ic.pointlist.rotation.center="0.1_m 0.1_m 0.1_m" alpha.ic.pointlist.rotation.angle="45_deg" alpha.ic.pointlist.eps="0.03_m"

2D-serial-three-objs

Two-dimensional

Serial

Validated using check script

./bin/alamo-2d-g++ tests/PointListIC/input  stop_time="0.0001" alpha.ic.pointlist.file.name="tests/PointListIC/three_objs.xyzo" alpha.ic.pointlist.invert="0 0 0 1" alpha.ic.pointlist.invert_all="1" alpha.ic.pointlist.eps="0.03_m" alpha.ic.pointlist.mult="0.4"
Input file (../../tests/PointListIC/input)
#@  [2D-serial]
#@  dim    = 2
#@  nprocs = 1
#@  check  = true
#@  check-file = reference/reference-2d-serial.csv
#@  args = stop_time=0.0001
#@  args = alpha.ic.pointlist.file.name = tests/PointListIC/NACA9612.xy
#@  args = alpha.ic.pointlist.mult = 0.9
#@  args = alpha.ic.pointlist.invert = 0
#@  args = alpha.ic.pointlist.x0 = 0.05_m 0.05_m 0.0_m
#@  args = alpha.ic.pointlist.rotation.center = 0.1_m 0.1_m 0.1_m
#@  args = alpha.ic.pointlist.rotation.angle = 45_deg
#@  args = alpha.ic.pointlist.eps = 0.03_m

#@  [2D-parallel]
#@  dim    = 2
#@  nprocs = 2
#@  check  = true
#@  check-file = reference/reference-2d-parallel.csv
#@  args   = stop_time=0.0001
#@  args = alpha.ic.pointlist.file.name = tests/PointListIC/NACA9612.xy
#@  args = alpha.ic.pointlist.mult = 0.9
#@  args = alpha.ic.pointlist.invert = 0
#@  args = alpha.ic.pointlist.x0 = 0.05_m 0.05_m 0.0_m
#@  args = alpha.ic.pointlist.rotation.center = 0.1_m 0.1_m 0.1_m
#@  args = alpha.ic.pointlist.rotation.angle = 45_deg
#@  args = alpha.ic.pointlist.eps = 0.03_m

#@  [2D-serial-three-objs]
#@  dim    = 2
#@  nprocs = 1
#@  check  = true
#@  check-file = reference/reference-2d-serial-three-objs.csv
#@  args   = stop_time=0.0001
#@  args = alpha.ic.pointlist.file.name = tests/PointListIC/three_objs.xyzo
#@  args = alpha.ic.pointlist.invert = 0 0 0 1
#@  args = alpha.ic.pointlist.invert_all = 1
#@  args = alpha.ic.pointlist.eps = 0.03_m
#@  args = alpha.ic.pointlist.mult = 0.4

alamo.program = allencahn

### OUTPUT ###

plot_file = tests/PointListIC/output

### MESHING ###

amr.plot_int = 1
amr.max_level = 3
amr.max_grid_size = 500000
amr.blocking_factor = 2
amr.grid_eff = 0.8
amr.n_cell = 16 16 0

geometry.prob_lo = -0.1_m -0.2_m 0.0_m # [ m ] 
geometry.prob_hi =  0.9_m  0.8_m 0.0_m # [ m ]
geometry.is_periodic = 0 0 0

timestep  = 0.0001
stop_time = 0.0001

alpha.bc.constant.type.xlo = neumann
alpha.bc.constant.type.xhi = neumann
alpha.bc.constant.type.ylo = neumann
alpha.bc.constant.type.yhi = neumann
alpha.bc.constant.val.xlo = 0.0
alpha.bc.constant.val.xhi = 0.0
alpha.bc.constant.val.ylo = 0.0
alpha.bc.constant.val.yhi = 0.0

alpha.ic.type = pointlist
alpha.ic.pointlist.file.unit = m
# alpha.ic.pointlist.file.name = tests/PointListIC/NACA9612.xy
# alpha.ic.pointlist.file.name = tests/PointListIC/three_objs.xyzo
# alpha.ic.pointlist.verbose = 0
# alpha.ic.pointlist.mult = 1.0 # Scaling factor on polygon size, happens BEFORE rotation
# alpha.ic.pointlist.invert = 0 0 0 1 # Don't invert the initial field
# alpha.ic.pointlist.x0 = 0.0_m 0.0_m 0.0_m # X-offset
# alpha.ic.pointlist.rotation.center = 0.0_m 0.0_m 0.0_m # Center of rotation of the polygon
# alpha.ic.pointlist.rotation.angle = 0_deg # Rotatation angle of polygon
# alpha.ic.pointlist.eps = 0.03_m # Diffuse boundary thickness

ch.direction_tstart = 0.0
ch.direction = 0
ch.L = 0.0
ch.kappa = 0.0001_J/m
ch.lambda = 1.0_Pa