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

flex2d.sh 997 B

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
39
40
41
42
43
44
45
46
47
  1. #!/usr/bin/env bash
  2. # Test gmtflexure for basic functionality
  3. flex () { # $1 is width, $2 is Te, $3 is dy build a 4.05 km tall ridge and compute flexure
  4. gmt math -T-800/800/1 T ABS $1 LT 4.05 MUL = topo.txt
  5. gmt flexure -Qttopo.txt -D3300/2700/2300/1030 -E${2}k -Mx > flex.txt
  6. R=$(gmt info -I100/1 flex.txt topo.txt)
  7. gmt psxy $R -JX3i/1.4i -O -K -W1p flex.txt -Y1.65i -Bafg1000 $3
  8. gmt psxy -R -J -O -K -Ggray topo.txt
  9. gmt pstext -R -J -O -K -F+cTR+f9p+jTR+t"Te = $2, W = $1" -Dj0.03i
  10. }
  11. ps=flex2d.ps
  12. cat << EOF > Te.txt
  13. 0
  14. 2
  15. 5
  16. 15
  17. 25
  18. 50
  19. EOF
  20. cat << EOF > W.txt
  21. 10
  22. 20
  23. 50
  24. 80
  25. 100
  26. 200
  27. EOF
  28. # Plot variability with Te for fixed W = 50
  29. row=0
  30. gmt psxy -R0/6/0/9 -Jx1 -P -X1i -K -T -Y-1.0i > $ps
  31. B=-BWSne
  32. while read Te; do
  33. flex 50 $Te $B >> $ps
  34. let row=row+1
  35. B=-BWsne
  36. done < Te.txt
  37. gmt psxy -R0/6/0/9 -Jx1 -O -K -T -Y-9.9i -X3.4i >> $ps
  38. # Plot variability with W for fixed Te = 20
  39. row=0
  40. B=-BwSnE
  41. while read W; do
  42. flex $W 20 $B >> $ps
  43. let row=row+1
  44. B=-BwsnE
  45. done < W.txt
  46. gmt psxy -R -J -O -T >> $ps
Tip!

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

Comments

Loading...