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

paste_gridreg_underlap_bf.sh 1.1 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
  1. #!/usr/bin/env bash
  2. #
  3. # Paste grid registered grids that do NOT share a row/column along X & Y edges
  4. # We simulate this by creating pastable pixreg grids and toggle their registration
  5. # This version tests for the non-netCDF format
  6. ps=paste_gridreg_underlap_bf.ps
  7. # The final grid is just f(x,y) = x*y
  8. gmt grdmath -R-14.75/14.75/-14.75/14.75 -I0.5 X Y MUL = lixo.grd=bf
  9. # The 4 pieces to assemble into final grid
  10. gmt grdmath -R-15/0/-15/0 -I0.5 X Y MUL -r = lixo_x1.grd=bf
  11. gmt grdedit lixo_x1.grd=bf -T
  12. gmt grdmath -R0/15/-15/0 -I0.5 X Y MUL -r = lixo_x2.grd=bf
  13. gmt grdedit lixo_x2.grd=bf -T
  14. gmt grdmath -R-15/0/0/15 -I0.5 X Y MUL -r = lixo_y1.grd=bf
  15. gmt grdedit lixo_y1.grd=bf -T
  16. gmt grdmath -R0/15/0/15 -I0.5 X Y MUL -r = lixo_y2.grd=bf
  17. gmt grdedit lixo_y2.grd=bf -T
  18. gmt grdpaste lixo_x1.grd=bf lixo_x2.grd=bf -Glixo_x.grd=bf
  19. gmt grdpaste lixo_y1.grd=bf lixo_y2.grd=bf -Glixo_y.grd=bf
  20. gmt grdpaste lixo_x.grd=bf lixo_y.grd=bf -Glixo_xy.grd=bf
  21. # Top is single source, bottom is assembled
  22. gmt grdcontour lixo_xy.grd=bf -JX10c -C10 -B5 -P -K -Xc > $ps
  23. gmt grdcontour lixo.grd=bf -J -C10 -B5 -O -Y12c >> $ps
Tip!

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

Comments

Loading...