Nicholson Canyon Simulation

From Gerris

(Difference between revisions)
Jump to: navigation, search
Revision as of 23:00, 4 August 2011
EmilyMLane (Talk | contribs)
(Nicholson benchmark moved to Nicholson Canyon Simulation: The Nicholson Canyon work is not a benchmark but a simulation)
← Previous diff
Revision as of 23:02, 4 August 2011
EmilyMLane (Talk | contribs)
(Creating Solid Block)
Next diff →
Line 5: Line 5:
awk -f nic holson.awk > points.tmp awk -f nic holson.awk > points.tmp
# Delaunay triangulation and transformation using gts tools # Delaunay triangulation and transformation using gts tools
-( wc point s.tmp | awk '{print $1" 0 0"}'; cat points.tmp ) | gtsdelaunay -d | gtstransform --rx=-90 > nichol_test.gts+( wc points.tmp | awk '{print $1" 0 0"}'; cat points.tmp ) | gtsdelaunay -d | gtstransform --rx=-90 > nichol_test.gts
# Shifting points to the domain boundary # Shifting points to the domain boundary
sed -e "s/ -0.0168/0/g" < nichol_test.gts > nichol_testout.gts sed -e "s/ -0.0168/0/g" < nichol_test.gts > nichol_testout.gts

Revision as of 23:02, 4 August 2011

Creating Solid Block

# Generating points using .awk file
awk -f nic holson.awk > points.tmp
# Delaunay triangulation and transformation using gts tools
( wc points.tmp | awk '{print $1" 0 0"}'; cat points.tmp ) | gtsdelaunay -d | gtstransform --rx=-90 > nichol_test.gts
# Shifting points to the domain boundary
sed -e "s/ -0.0168/0/g" < nichol_test.gts > nichol_testout.gts


The .awk file used to generate the points is

BEGIN {
a=0.272
b=1.7
alpha=atan2(a,b);
h=a*cos(alpha);
l1=b*cos(alpha);
l2=a*sin(alpha);
 
for (k=0; k <= 100; k++) {
for (i=-1; i <= 100; i++) { printf("%5.4f %5.4f %5.4f\n",l1*i/100, -
0.85+1.7*k/100 , h*i/100) }
for (i=1; i <= 101; i++) { printf("%5.4f %5.4f %5.4f\n",l1+l2*i/100,
-0.85+1.7*k/100, h*(1-i/100)) }
}
 
 
dx=1.0e-4
k=0.
j=-1.
for (i=-1; i <= 100; i++) { printf("%5.4f %5.4f %5.4f\n",l1*i/100, -0.
85+1.7*k/100-dx,h*j/100) }
for (i=1; i <= 101; i++) { printf("%5.4f %5.4f %5.4f\n",l1+l2*i/100, -
0.85+1.7*k/100-dx,h*j/100) }
 
k=100.
for (i=-1; i <= 100; i++) { printf("%5.4f %5.4f %5.4f\n",l1*i/100, -0.
85+1.7*k/100+dx,h*j/100) }
for (i=1; i <= 101; i++) { printf("%5.4f %5.4f %5.4f\n",l1+l2*i/100, -
0.85+1.7*k/100+dx,h*j/100) }
}
Personal tools
communication