# get DEM and make topography map data on GRASS wget ftp://edcftp.cr.usgs.gov/pub/data/gtopo30/global/e060n40.tar.gz wget ftp://edcftp.cr.usgs.gov/pub/data/gtopo30/global/e100n40.tar.gz tar zxvf e060n40.tar.gz tar zxvf e100n40.tar.gz # importing and exporting DEM to GRASS r.in.bin input=E060N40.DEM output=dummy1 west=60 east=100 south=-10 north=40 c=4800 r=6000 byte=2 anull=-9999 -b r.in.bin input=E100N40.DEM output=dummy2 west=100 east=140 south=-10 north=40 c=4800 r=6000 byte=2 anull=-9999 -b g.region w=93 e=112 s=5 n=22 res=0.025 r.mapcalc "elevation=max(if(isnull(dummy1),-1,dummy1), if(isnull(dummy2),-1,dummy2))" r.out.bin input=elevation output=elevation # create GMT format raster for DEM xyz2grd elevation -Dm/m/m/1/0/=/= -Gelevation.grd -R93/112/5/22 -I1.5m -N-1 -V -ZTLh -F # draw GMT map for DEM ### color pallette ### cat < height.cpt 0 186 223 255 250 183 254 162 250 183 254 162 500 240 234 162 500 240 234 162 750 238 204 173 750 238 204 173 1000 246 232 202 1000 246 232 202 1250 255 241 230 1250 255 241 230 1500 255 255 255 B 220 220 255 F 255 255 255 N 220 220 255 EOF out=elevation.ps psbasemap -Jm{SCALE} -R${REGION} -B${TICK} -X2.0 -Y10.0 -P -K -V > $out grdimage elevation.grd -R${REGION} -Jm -P -K -Cheight.cpt -O >> $out pscoast -Jm${SCALE} -R -Dh -P -V -K -N1/1/50/50/50 -W1/50/50/50 -I2/3/90/90/255 -O >> $out psxy -Jm -Sc0.2 -G250/0/0 -R -V -K -O < site.txt >> $out echo "93.5 12.5 13 0 0 0 elevation" | pstext -Jm -R -O -K >> $out echo "94.5 11.7 13 0 0 0 (m)" | pstext -Jm -R -O -K >> $out echo "98.9 16.0 13 0 0 0 Tak" | pstext -Jm -R -O -K >> $out echo "99.9 17.0 13 0 0 0 Sukhothai" | pstext -Jm -R -O -K >> $out echo "96.7 19.3 13 0 0 0 Kogma" | pstext -Jm -R -O -K >> $out echo "106 17 13 -55 0 0 Annamese-Mtns." | pstext -Jm -R -O -K >> $out echo "97.5 17.0 13 -77 0 0 Bilauktaung-Mtns." | pstext -Jm -R -O -K >> $out echo "105 15 13 -90 0 0 Mekong-Rv." | pstext -Jm -R -O -K >> $out echo "101 16 13 -90 0 0 Chao-Phraya-Rv." | pstext -Jm -R -O -K >> $out echo "103 9 13 0 0 0 Camau-Peninsula" | pstext -Jm -R -O -K >> $out psscale -Cheight.cpt -D0.2c/2.0c/3.0c/0.3c -O >> $out gv elevation.ps