#!/bin/bash xyz2grd topo2.dat -Gtopo.grd -I80 -R504080/508960/1395040/1399920 makecpt -Chaxby -T0/1000/10 > topo.cpt grdimage topo.grd -Jx0.0005i -Ctopo.cpt -Y3.0i -X1.5i -P -E100 -K > topo.ps grdcontour topo.grd -Jx0.0005i -C25 -A100 -B2000WSne -W0.25p -P -O -K >> topo.ps psscale -D1i/-1i/3i/0.25ih -Ctopo.cpt -B200:"Elevation (meters)": -O -P -V -K >> topo.ps # # # makecpt -Crainbow -T-0.02/.001/0.0002 > grd.cpt grdmath topo.grd DDX = ddx.grd grdmath topo.grd DDY = ddy.grd grdmath ddy.grd ddx.grd R2 SQRT = slope.grd grdmath slope.grd R2D = slope_degrees.grd grdinfo slope_degrees.grd makecpt -Crainbow -T0/30/5 > slope.cpt grdimage slope_degrees.grd -Jx0.0005i -Cslope.cpt -X3.75i -P -E100 -K -O >> topo.ps grdcontour topo.grd -Jx0.0005i -C25 -A100 -B2000WSne -W0.25p -P -O -K >> topo.ps psscale -D1i/-1i/3i/0.25ih -Cslope.cpt -B5:"Slope (degrees)": -O -P -V >> topo.ps #draw the image gv topo.ps