Register
Login
Resources
Docs Blog Datasets Glossary Case Studies Tutorials & Webinars
Product
Data Engine LLMs Platform Enterprise
Pricing Explore
Connect to our Discord channel

gspline_4.sh 1.2 KB

You have to be logged in to leave a comment. Sign In
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
  1. #!/usr/bin/env bash
  2. # Updated version to handle direct writing of sliced grids
  3. ps=gspline_4.ps
  4. # Figure 5 in Wessel, P. (2009), A general-purpose Green's function-based
  5. # interpolator, Computers & Geosciences, 35, 1247-1254.
  6. R2D=12/32/0/6
  7. Z=5/10
  8. R3D=$R2D/$Z
  9. dz=0.25
  10. view=200/25
  11. method=r
  12. tens=0.85
  13. # Write a single 3-D data cube
  14. gmt greenspline -R$R3D -I$dz -G3D_cube.grd @Table_5_23.txt -S${method}${tens} -Z5 -D+x"x-distance [km]"+y"y-distance [km]"+z"z-distance [km]"+d"Uranium Oxide [%]"+v"uoxide"
  15. # Make a list of the cube z-levels
  16. gmt math -T${Z}/${dz} -o0 T = t.lis
  17. gmt psbasemap -R$R2D/$Z -JX6i/3i -JZ2.5i -p$view -Bx5f1g1 -By1g1 -Bz2f1 -BWSneZ+b -P -K > $ps
  18. # Plot small cube symbols at the data points
  19. gmt psxyz -R -JX -JZ -p$view -O -K @Table_5_23.txt -Su0.05i -Gblack -Wfaint >> $ps
  20. # Loop over the z-levels and draw the 10 % contour only
  21. while read z; do
  22. gmt grdcontour -JX "3D_cube.grd?($z)" -C10 -L9/11 -S8 -D | gmt psxyz -R$R2D/$Z -JX -JZ -p$view -O -K -Gp39+r300+fgray+b- -Wthin -i0,1,2+s0+o${z} >> $ps
  23. done < t.lis
  24. echo "12 6 Volume exceeding 10% UO@-2@- concentration" | gmt pstext -R$R2D/$Z -JX -JZ -p$view -F+jLT+f16p -O -K -Z10 -Dj0.1i >> $ps
  25. gmt psxyz -R -JX -JZ -p$view -O -Wthin << EOF >> $ps
  26. >
  27. 12 0 5
  28. 12 0 10
  29. >
  30. 12 0 10
  31. 12 6 10
  32. >
  33. 12 0 10
  34. 32 0 10
  35. EOF
Tip!

Press p or to see the previous file or, n or to see the next file

Comments

Loading...