#!/bin/bash # IN1='brtptf_d1_51_400km_mgs_night_v2.xy' IN2='quartgrad.grd' IN3='brtp400_ABa-SPn-MOn_3B-3M_m23_h-20.014.xyz' OUT1='mag_comparisons_langlais_vs_correlv2_400km.ps' # gmtset COLOR_MODEL RGB PAPER_MEDIA letter+ gmtset MEASURE_UNIT inch BASEMAP_TYPE FANCY gmtset LABEL_FONT_SIZE 12p gmtset ANOT_FONT_SIZE 10p gmtset GRID_CROSS_SIZE 0 gmtset FRAME_WIDTH 0.03i gmtset BASEMAP_FRAME_RGB 0/0/0 # cat < mag.cpt # cpt file created by: grd2cpt tmpr1.grd -Crainbow -Z #COLOR_MODEL = +HSV # 0 0 0 0.5 1.5 300 0 0.6 1.5 300 0 0.6 2.5 270 1 1 2.5 270 1 1 3.5 240 1 1 3.5 240 1 1 4.5 210 1 1 4.5 210 1 1 5.5 150 1 1 5.5 150 1 1 8 120 1 1 8 120 1 1 11 90 1 1 11 90 1 1 17 60 1 1 17 60 1 1 30 30 1 1 30 30 1 1 210 0 1 1 B 0 0 0 F 0 0 1 N 0 0 0.501961 END # # Crater sizes # # longitude,latitude of the center of the ring of the largest # Martian craters (4 defined here), orientation of # major axis of ellipse (degrees E of N), length of major axis in km, # and length of minor axis in km # Ref: Frey et al., 2007, GRL. Crater Diameter multipled by 0.939 to account # for different planetary radius, and because the ellipse option of # psxy (-SE) requires the axis length, which is equivalent to the radius of # a circle -SE# = Re/2*Rm # cat < hellas.xy 66.4 -42.3 0 1944 1944 END cat < isidis.xy 87.8 13.4 0 1270 1270 END cat < utopia.xy 115.5 45.0 0 3174 3174 END cat < argyre.xy 317.5 -49.0 0 1235 1235 END # # B magnitude: Current study /bin/gawk '{print $1,$2,$6}' $IN1 >tmpr.xy xyz2grd -Rg -I2 tmpr.xy -Gtmpr1.grd #grd2cpt tmpr1.grd -Crainbow -Z > gam.cpt #grdhisteq tmpr1.grd -C10 -D >gam.d grdsample tmpr1.grd -I0.25 -F -Gtmpr1a.grd -Lg # Centered on equator grdimage tmpr1a.grd -Cmag.cpt -JQ180/5 -P \ -Bg90a90/g30a30WseN -R -K -Y2 -X3 -I$IN2 > $OUT1 psxy hellas.xy -R -JQ -SE -W2 -O -K >> $OUT1 psxy isidis.xy -R -JQ -SE -W2 -O -K >> $OUT1 psxy utopia.xy -R -JQ -SE -W2 -O -K >> $OUT1 psxy argyre.xy -R -JQ -SE -W2 -O -K >> $OUT1 # North pole on right grdcut tmpr1a.grd -R0/360/0/87 -Gtmpr1b.grd grdcut $IN2 -R -fg -Gtmptpb.grd grdimage tmpr1b.grd -Cmag.cpt -JE180/90/2 -P \ -Bg90a180/g30wSen -R -O -K -X5.25 -Itmptpb.grd >> $OUT1 psxy hellas.xy -R -JE -SE -W2 -O -K >> $OUT1 psxy isidis.xy -R -JE -SE -W2 -O -K >> $OUT1 psxy utopia.xy -R -JE -SE -W2 -O -K >> $OUT1 psxy argyre.xy -R -JE -SE -W2 -O -K >> $OUT1 # South pole on left grdcut tmpr1a.grd -R0/360/-87/0 -Gtmpr1b.grd grdcut $IN2 -R -fg -Gtmptpb.grd grdimage tmpr1b.grd -Cmag.cpt -JE180/-90/2 -P \ -Bg90a180/g30wseN -R -O -K -X-7.75 -Itmptpb.grd >> $OUT1 psxy hellas.xy -R -JE -SE -W2 -O -K >> $OUT1 psxy isidis.xy -R -JE -SE -W2 -O -K >> $OUT1 psxy utopia.xy -R -JE -SE -W2 -O -K >> $OUT1 psxy argyre.xy -R -JE -SE -W2 -O -K >> $OUT1 # # B magnitude: Langlais et al. 2004 /bin/gawk '{print $1,$2,sqrt($4^2+$5^2+$6^2)}' $IN3 >tmpt.xy surface -Rg -I2 tmpt.xy -T0.25 -Gtmpr1.grd grdsample tmpr1.grd -I0.25 -F -Gtmpr1a.grd -Lg # Centered on equator grdimage tmpr1a.grd -Cmag.cpt -JQ180/5 -P \ -Bg90a90/g30a30WseN -R -O -K -X2.5 -Y3.2 -I$IN2>> $OUT1 psxy hellas.xy -R -JQ -SE -W2 -O -K >> $OUT1 psxy isidis.xy -R -JQ -SE -W2 -O -K >> $OUT1 psxy utopia.xy -R -JQ -SE -W2 -O -K >> $OUT1 psxy argyre.xy -R -JQ -SE -W2 -O -K >> $OUT1 # North pole on right grdcut tmpr1a.grd -R0/360/0/87 -Gtmpr1b.grd grdcut $IN2 -R -fg -Gtmptpb.grd grdimage tmpr1b.grd -Cmag.cpt -JE180/90/2 -P \ -Bg90a180/g30wSen -R -O -K -X5.25 -Itmptpb.grd >> $OUT1 psxy hellas.xy -R -JE -SE -W2 -O -K >> $OUT1 psxy isidis.xy -R -JE -SE -W2 -O -K >> $OUT1 psxy utopia.xy -R -JE -SE -W2 -O -K >> $OUT1 psxy argyre.xy -R -JE -SE -W2 -O -K >> $OUT1 # South pole on left grdcut tmpr1a.grd -R0/360/-87/0 -Gtmpr1b.grd grdcut $IN2 -R -fg -Gtmptpb.grd grdimage tmpr1b.grd -Cmag.cpt -JE180/-90/2 -P \ -Bg90a180/g30wseN -R -O -K -X-7.75 -Itmptpb.grd >> $OUT1 psxy hellas.xy -R -JE -SE -W2 -O -K >> $OUT1 psxy isidis.xy -R -JE -SE -W2 -O -K >> $OUT1 psxy utopia.xy -R -JE -SE -W2 -O -K >> $OUT1 psxy argyre.xy -R -JE -SE -W2 -O -K >> $OUT1 # psscale -Cmag.cpt -D0.9/-0.2/4/0.2h -B:nT: -X4 -Y-3.3 -O -L -P >> $OUT1 # rm tmp*