problem with surface

Added by Marcos 2 months ago

Hi,
I am trying to interpolate a data with surface.
But the result is showing up like that.
The routine that I am using is below:

What is wrong?
I also tried other interpolation functions like triangulate, and so on...but did not work...

—--—--–
#!/bin/bash
clear
rm -rf *.ps
rm -rf *.pdf

GMT set PS_MEDIA A2 # definindo tamanho do papel

  1. definindo o que é fixo

#entrada="Grav_geog.txt"
entrada="Bouguer_geo.dat"

arq1="mapa_Grav.ps"
#arq2="Bouguer_recorte.ps"

proj="-JM15"

area="-R36.786/36.83412/31.01388/31.07998/"

Z="-T-71/-57/5"

GMT surface $entrada $area -I.00002 -T0.2 -GBouguer.grd

GMT makecpt -Crainbow $Z > paleta_Bouguer.cpt

GMT grdimage Bouguer.grd $proj -Cpaleta_Bouguer.cpt > $arq1

GMT ps2raster $arq1 -A -Tf

#######
chmod +x Mapa_Bouguer.sh

#open mapa_Grav.pdf
open mapa_Grav.pdf


Replies (10)

RE: problem with surface - Added by Andreas 2 months ago

Long shot; try

-R36.78446/36.83566/31.01238/31.0815

RE: problem with surface - Added by Marcos 2 months ago

It is still giving something wrong, like the file attached.
What is going on with the colors?
Thanks,
Marcos

RE: problem with surface - Added by Andreas 2 months ago

What does

grdinfo Bouguer.grd

say?

RE: problem with surface - Added by Marcos 2 months ago

grdinfo just returns the information about the grid, like number of cells, and so on.

RE: problem with surface - Added by Joaquim 2 months ago

Are you sure that you want to compute a Bouger anomaly grid with an increment of ~2 meters?? (-I.00002)

RE: problem with surface - Added by Andreas 2 months ago

Given your makecpt command, you should get three colors. Thats what you asked for.

makecpt -T-71/-57/5 -Crainbow
# COLOR_MODEL = hsv
-71     250-1-1 -66     250-1-1
-66     150-1-1 -61     150-1-1
-61     50-1-1  -56     50-1-1
B       0-0-0
F       0-0-1
N       0-0-0.5

Hence my question about what grdinfo says about the z-range.

RE: problem with surface - Added by Marcos 2 months ago

Hi Joaquim,
data are in degrees, not in meters.Anything wrong?

RE: problem with surface - Added by Marcos 2 months ago

Hi Andreas,
now I got your question.
Grdinfo says:

Bouguer.grd: Title: Data gridded with continuous surface splines in tension
Bouguer.grd: Command:
Bouguer.grd: Remark:
Bouguer.grd: Gridline node registration used [Cartesian grid]
Bouguer.grd: Grid file format: nf = GMT netCDF format (32-bit float), COARDS, CF-1.5
Bouguer.grd: x_min: 36.78446 x_max: 36.83566 x_inc: 2e-05 name: x nx: 2561
Bouguer.grd: y_min: 31.01238 y_max: 31.0815 y_inc: 2e-05 name: y ny: 3457
Bouguer.grd: z_min: -71.0696258545 z_max: -57.9101753235 name: z
Bouguer.grd: scale_factor: 1 add_offset: 0
Bouguer.grd: format: netCDF-4 chunk_size: 129,129 shuffle: on deflation_level: 3

RE: problem with surface - Added by Joaquim 2 months ago

data are in degrees, not in meters.

And that is why -I0.00002 is approximately equal to 2 meters.

Anything wrong?

I would say, yes.

RE: problem with surface - Added by Andreas 2 months ago

So maybe e.g.

makecpt -T-71/58/2 -Z

gives a better colormap.

(1-10/10)