Skip to content

Commit 99d1c53

Browse files
committed
data_types.jl
1 parent fdd842d commit 99d1c53

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

54 files changed

+231
-231
lines changed

docs/src/man/Tutorial_AlpineData.md

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -126,10 +126,10 @@ units = unique(tag) #get different units
126126
We will use these units later to save the Moho data separately for each tectonic unit.
127127

128128
### 2.2 Converting the data to a `GMG` dataset
129-
To convert this data to a `GMG` dataset, we now have to interpolate it to a regular grid. You can generate the respective grid with the `GMG` function `LonLatDepthGrid`
129+
To convert this data to a `GMG` dataset, we now have to interpolate it to a regular grid. You can generate the respective grid with the `GMG` function `lonlatdepthGrid`
130130

131131
```julia
132-
Lon,Lat,Depth = LonLatDepthGrid(9.9:0.02:15.1,45.0:.02:49.0,0km);
132+
Lon,Lat,Depth = lonlatdepthGrid(9.9:0.02:15.1,45.0:.02:49.0,0km);
133133
nothing #hide
134134
```
135135

docs/src/man/Tutorial_Basic.md

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -156,7 +156,7 @@ search: CrossSection CrossSectionVolume CrossSectionPoints CrossSectionSurface F
156156
Example:
157157
≡≡≡≡≡≡≡≡
158158

159-
julia> Lon,Lat,Depth = LonLatDepthGrid(10:20,30:40,(-300:25:0)km);
159+
julia> Lon,Lat,Depth = lonlatdepthGrid(10:20,30:40,(-300:25:0)km);
160160
julia> Data = Depth*2; # some data
161161
julia> Vx,Vy,Vz = ustrip(Data*3),ustrip(Data*4),ustrip(Data*5);
162162
julia> Data_set3D = GeoData(Lon,Lat,Depth,(Depthdata=Data,LonData=Lon, Velocity=(Vx,Vy,Vz)));
@@ -209,7 +209,7 @@ First we need do define a `ProjectionPoint` around which we project the data
209209
```julia
210210
proj = ProjectionPoint(Lon=12.0,Lat =43)
211211

212-
Topo_cart = Convert2CartData(Topo_Alps, proj)
212+
Topo_cart = convert2CartData(Topo_Alps, proj)
213213
```
214214

215215
````
@@ -225,7 +225,7 @@ CartData
225225
And do the same with the tomography:
226226

227227
```julia
228-
Tomo_cart = Convert2CartData(Tomo_Alps, proj)
228+
Tomo_cart = convert2CartData(Tomo_Alps, proj)
229229
```
230230

231231
````
@@ -259,7 +259,7 @@ Yet, because of the curvature of the Earth, the resulting 3D model is not strict
259259
This can be achieved in a relatively straightforward manner, by creating a new 3D dataset that is slightly within the curved boundaries of the projected data set:
260260

261261
```julia
262-
Tomo_rect = CartData(XYZGrid(-550.0:10:600, -500.0:10:700, -600.0:5:-17));
262+
Tomo_rect = CartData(xyzGrid(-550.0:10:600, -500.0:10:700, -600.0:5:-17));
263263
```
264264

265265
the routine `projectCartData` will then project the data from the geographic coordinates to the new rectilinear grid:
@@ -281,7 +281,7 @@ CartData
281281
we can do the same with topography:
282282

283283
```julia
284-
Topo_rect = CartData(XYZGrid(-550.0:1:600, -500.0:1:700, 0))
284+
Topo_rect = CartData(xyzGrid(-550.0:1:600, -500.0:1:700, 0))
285285
Topo_rect = projectCartData(Topo_rect, Topo_Alps, proj)
286286
```
287287

docs/src/man/Tutorial_FaultDensity.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -76,7 +76,7 @@ data = faults.data[indlon,indlat]
7676
Create GeoData from restricted data
7777

7878
```julia
79-
Lon3D,Lat3D, Faults = LonLatDepthGrid(Lon,Lat,0);
79+
Lon3D,Lat3D, Faults = lonlatdepthGrid(Lon,Lat,0);
8080
Faults[:,:,1] = data
8181
Data_Faults = GeoData(Lon3D,Lat3D,Faults,(Faults=Faults,))
8282
```

docs/src/man/Tutorial_Jura.md

Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -109,7 +109,7 @@ proj = ProjectionPoint(Lon=6, Lat=46.5)
109109
We can simply transfer the TopoGeology map to Cartesian values with:
110110

111111
```julia
112-
Convert2CartData(Topo,proj)
112+
convert2CartData(Topo,proj)
113113
```
114114

115115
```julia
@@ -127,7 +127,7 @@ It is therefore better to use the `projectCartData` to project the `GeoData` str
127127
Let's first create this structure by using `x`,`y` coordinates that are slightly within the ranges given above:
128128

129129
```julia
130-
TopoGeology_cart = CartData(XYZGrid(range(-70,150,length=3500), range(-105,130,length=2500), 0.0))
130+
TopoGeology_cart = CartData(xyzGrid(range(-70,150,length=3500), range(-105,130,length=2500), 0.0))
131131
```
132132

133133
```julia
@@ -170,10 +170,10 @@ CartData
170170
```
171171

172172
Finally, we can also transfer the cross-section to cartesian coordinates. As this is just for visualization, we will
173-
use `Convert2CartData` in this case
173+
use `convert2CartData` in this case
174174

175175
```julia
176-
CrossSection_1_cart = Convert2CartData(CrossSection_1,proj)
176+
CrossSection_1_cart = convert2CartData(CrossSection_1,proj)
177177
```
178178

179179
for visualization, it is nice if we can remove the part of the cross-section that is above the topography.
@@ -219,8 +219,8 @@ We create both a surface and a 3D block
219219
```julia
220220
nx, ny, nz = 1024, 1024, 128
221221
x,y,z = range(-100,180,nx), range(-50,70,ny), range(-8,4,nz)
222-
ComputationalSurf = CartData(XYZGrid(x,y,0))
223-
ComputationalGrid = CartData(XYZGrid(x,y,z))
222+
ComputationalSurf = CartData(xyzGrid(x,y,0))
223+
ComputationalGrid = CartData(xyzGrid(x,y,z))
224224
```
225225

226226
Re-interpolate the rotated to the new grid:

docs/src/man/Tutorial_LaPalma.md

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -71,16 +71,16 @@ proj = ProjectionPoint(Lon=-17.84, Lat=28.56)
7171
Once this is done you can convert the topographic data to the cartesian reference frame
7272

7373
```julia
74-
EQ_cart = Convert2CartData(data_all_EQ, proj);
75-
Topo_cart = Convert2CartData(Topo, proj)
74+
EQ_cart = convert2CartData(data_all_EQ, proj);
75+
Topo_cart = convert2CartData(Topo, proj)
7676
```
7777

7878
It is important to realize that the cartesian coordinates of the topographic grid is no longer strictly orthogonal after this conversion. You don't notice that in the current example, as the model domain is rather small.
7979
In other cases, however, this is quite substantial (e.g., India-Asia collision zone).
8080
LaMEM needs an orthogonal grid of topography, which we can create with:
8181

8282
```julia
83-
Topo_model = CartData(XYZGrid(-35:.1:30,-15:.2:45,0));
83+
Topo_model = CartData(xyzGrid(-35:.1:30,-15:.2:45,0));
8484
nothing #hide
8585
```
8686

@@ -102,7 +102,7 @@ It is useful to plot the earthquake density in 3D, which indicates where most ac
102102
For this, we first create a 3D grid of the region:
103103

104104
```julia
105-
Grid_3D = CartData(XYZGrid(-35:.3:30,-15:.25:45,-50:.5:5))
105+
Grid_3D = CartData(xyzGrid(-35:.3:30,-15:.25:45,-50:.5:5))
106106
```
107107

108108
Next we check how many earthquakes are around the grid points:

docs/src/man/Tutorial_MohoTopo_Spada.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -108,7 +108,7 @@ data_Moho_combined = GeoData(lon, lat, depth, (MohoDepth=depth*km,))
108108
Next, we define a regular lon/lat grid
109109

110110
```julia
111-
Lon, Lat, Depth = LonLatDepthGrid(4.1:0.1:11.9,42.5:.1:49,-30km)
111+
Lon, Lat, Depth = lonlatdepthGrid(4.1:0.1:11.9,42.5:.1:49,-30km)
112112
```
113113

114114
We will use a nearest neighbor interpolation method to fit a surface through the data, which has the advantage that it will take the discontinuities into account.

docs/src/man/datastructures.md

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -9,7 +9,7 @@ GeoData
99
CartData
1010
UTMData
1111
ParaviewData
12-
LonLatDepthGrid
13-
XYZGrid
12+
lonlatdepthGrid
13+
xyzGrid
1414
ProjectionPoint
1515
```

docs/src/man/projection.md

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -47,7 +47,7 @@ ProjectionPoint(37.5, 17.3, 703311.4380385976, 4.152826288024972e6, 33, true)
4747

4848
Projecting the `GeoData` set using this projection point is done with:
4949
```julia
50-
julia> Convert2UTMzone(Topo,p)
50+
julia> convert2UTMzone(Topo,p)
5151
UTMData
5252
UTM zone : 33-33 North
5353
size : (165, 75, 1)
@@ -61,7 +61,7 @@ Whereas this is now in UTM Data (in meters), it is distorted.
6161

6262
Often it is more convenient to have this in `CartData`, which is done in a similar manner:
6363
```julia
64-
julia> Topo_Cart = Convert2CartData(Topo,p)
64+
julia> Topo_Cart = convert2CartData(Topo,p)
6565
CartData
6666
size : (165, 75, 1)
6767
x ϵ [ -2778.3805979523936 km : 2878.039855346856 km]
@@ -77,7 +77,7 @@ Whereas this is ok to look at and compare with a LaMEM model setup, we cannot us
7777
#### 2. Projecting data
7878
For use with LaMEM, you would need an orthogonal cartesian grid. From the last command above we get some idea on the area, so we can create this:
7979
```julia
80-
julia> Topo_Cart_orth = CartData(XYZGrid(-2000:20:2000,-1000:20:1000,0))
80+
julia> Topo_Cart_orth = CartData(xyzGrid(-2000:20:2000,-1000:20:1000,0))
8181
CartData
8282
size : (201, 101, 1)
8383
x ϵ [ -2000.0 km : 2000.0 km]
@@ -104,7 +104,7 @@ You can do similar projections with full 3D data sets or pointwise data.
104104
#### 3. List of relevant functions
105105

106106
```@docs
107-
GeophysicalModelGenerator.Convert2CartData
107+
GeophysicalModelGenerator.convert2CartData
108108
GeophysicalModelGenerator.projectCartData
109-
GeophysicalModelGenerator.Convert2UTMzone
109+
GeophysicalModelGenerator.convert2UTMzone
110110
```

docs/src/man/tools.md

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -15,8 +15,8 @@ InterpolateTopographyOnPlane
1515
ParseColumns_CSV_File
1616
RotateTranslateScale!
1717
pointData2NearestGrid
18-
Convert2UTMzone
19-
Convert2CartData
18+
convert2UTMzone
19+
convert2CartData
2020
projectCartData
2121
drape_on_topo
2222
LithostaticPressure!

docs/src/man/tutorial_Coastlines.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -20,7 +20,7 @@ The parameter resolution should be either `c`,`l`,`i`,`h` or `f` (standing for c
2020

2121
##### 1.2 Save in Paraview
2222
```julia
23-
julia> Lon,Lat,Depth = LonLatDepthGrid(lon[ind_lon],lat[ind_lat],0km);
23+
julia> Lon,Lat,Depth = lonlatdepthGrid(lon[ind_lon],lat[ind_lat],0km);
2424
julia> data_surf = zeros(size(Lon));
2525
julia> data_surf[:,:,1] = data[ind_lon,ind_lat]
2626
julia> data_surface = GeoData(Lon, Lat, Depth, (SurfaceType=data_surf,))

0 commit comments

Comments
 (0)