Nicholson Canyon Simulation

From Gerris

(Difference between revisions)
Jump to: navigation, search
Revision as of 04:05, 9 August 2011
EmilyMLane (Talk | contribs)
(Creating Solid Block)
← Previous diff
Revision as of 04:33, 9 August 2011
EmilyMLane (Talk | contribs)
(Creating Solid Block)
Next diff →
Line 1: Line 1:
-== Creating Solid Block ==+== Problem Definition ==
 + 
 +== Two-Dimensional Simulations ==
 +=== Creating Solid Block ===
<source lang=bash> <source lang=bash>
Line 44: Line 47:
} }
</source> </source>
 +
 +=== Creating Probes ===

Revision as of 04:33, 9 August 2011

Contents

Problem Definition

Two-Dimensional Simulations

Creating Solid Block

# Generating points using .awk file
awk -f nicholson.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) }
}

Creating Probes

Personal tools
communication