Skip to content

Commit 428fb96

Browse files
authored
Update tutorial_Polygon_structures.md
1 parent 937bbd2 commit 428fb96

File tree

1 file changed

+14
-20
lines changed

1 file changed

+14
-20
lines changed
Lines changed: 14 additions & 20 deletions
Original file line numberDiff line numberDiff line change
@@ -1,19 +1,18 @@
1-
# 13 - Setting up sedimentary basin, lithospheric thinning and accretionary prism
1+
# Adding complex geometries to a model setup including sedimentary basins, lithospheric thinning and an accretionary prism
22

33

44
## Goal
55

6-
This tutorial visualizes simplified geological as it is done here for a passive margin where lithospheric thinning, sedimentary basin and accretionary prism occur. The simplification is based on a polygon structure for a pseudo-3D model. While the structure can have a random shape in the x- and z-direction, in the y-direction only the extension is variable.
6+
This tutorial visualizes simplified geological as it is done here for a passive margin where lithospheric thinning, sedimentary basin and accretionary prism occur. The simplification is based on a polygon structure for a pseudo-3D model. While the structure can have a random shape in the `x`- and `z`-direction, in the `y`-direction only the extent is variable.
77

88
## Steps
99

1010
#### 1. Set up your simplified background model
11-
Before adding specific geological features, a general simplified model setup is necessary. The construction is made by using the addBox function. For the model the discontinuities are in 15, 45, 145, and 945 km depth.
11+
Before adding specific geological features, a general simplified model setup is necessary. The construction is made by using the `addBox!` function. For the model the discontinuities are in 15, 45, 145, and 945 km depth.
1212

1313
```julia
1414
using GeophysicalModelGenerator
1515

16-
1716
# number of cells in every direction
1817
nx = 100
1918
ny = 100
@@ -23,8 +22,7 @@ nz = 200
2322
x = LinRange(0.0,800.0,nx)
2423
y = LinRange(0.0,800.0,ny)
2524
z = LinRange(-660,50,nz)
26-
X,Y,Z = XYZGrid(x, y, z);
27-
Cart = CartData(X,Y,Z, (Data=Z,))
25+
Cart = CartData(XYZGrid(x, y, z))
2826

2927
# initialize phase and temperature matrix
3028
Phase = ones(Int32,size(X))
@@ -33,15 +31,13 @@ Temp = ones(Float64,size(X))*1350
3331
# add different phases: crust->2, Mantle Lithosphere->3 Mantle->1
3432
AddBox!(Phase, Temp, Cart; xlim=(0.0,800.0),ylim=(0.0,800.0), zlim=(-800.0,0.0), phase = LithosphericPhases(Layers=[15 30 100 800], Phases=[2 3 1 5], Tlab=1300 ), T=LinearTemp(Ttop=20, Tbot=1600))
3533

36-
3734
# add air phase 0
3835
AddBox!(Phase, Temp, Cart; xlim=(0.0,800.0),ylim=(0.0,800.0), zlim=(0.0,50.0), phase = ConstantPhase(0), T=ConstantTemp(20.0))
39-
40-
```
36+
```
4137

4238

4339
#### 2. Add polygon structure
44-
For including the geological structures of a passive margin into the model via the polygon function, depths down to 150 km are focused on. With the polygon function, it is possible to create different shapes. In the example, the sediment basin shows a more trapezial (2D in x-/z-direction) shape, while the thinning of the plate is a more triangular (2D in x-/z-direction). More complex structures are possible to build in the background model due to the non-limitation number of points in the x- and z-direction. In y-direction only the length can be varied and is set by two values. The shape is not changeable. The x- and z-values of the points need to be in the same order for selecting the correct point (P1(1/3), P2(2/2) --> xlim(1,2), ylim(3,2)).
40+
To include the geological structures of a passive margin into the model, we use polygons for depths of up to 150 km. In the example, the sediment basin shows a more trapezoidal (2D in `x`-/`z`-direction) shape, while the thinning of the plate has a more triangular (2D in `x`-/`z`-direction). More complex structures can be build using arbitrarily sized polygons in `x`- and `z`-direction, wheraes in the `y`-direction only the length can be varied (specified by two values). The `x`- and `z`-values of the points need to be in the same order for selecting the correct point (P1(1/3), P2(2/2) --> xlim(1,2), ylim(3,2)).
4541

4642

4743
```julia
@@ -51,28 +47,26 @@ For including the geological structures of a passive margin into the model via t
5147
# unlimited number of points possible to create the polygon
5248

5349
# add sediment basin
54-
addPolygon!(Phase, Temp, Cart; xlim=[0.0,0.0, 160.0, 200.0],ylim=[100.0,300.0], zlim=[0.0,-10.0,-20.0,0.0], phase = ConstantPhase(8), T=LinearTemp(Ttop=20, Tbot=30))
50+
addPolygon!(Phase, Temp, Cart; xlim=[0.0,0.0, 160.0, 200.0],ylim=[100.0,300.0], zlim=[0.0,-10.0,-20.0,0.0], phase = ConstantPhase(8), T=LinearTemp(Ttop=20, Tbot=30));
5551

5652
# add thinning of the continental crust attached to the slab and its thickness
57-
addPolygon!(Phase, Temp, Cart; xlim=[0.0, 200.0, 0.0],ylim=[500.0,800.0], zlim=[-100.0,-150.0,-150.0], phase = ConstantPhase(5), T=LinearTemp(Ttop=1000, Tbot=1100))
53+
addPolygon!(Phase, Temp, Cart; xlim=[0.0, 200.0, 0.0],ylim=[500.0,800.0], zlim=[-100.0,-150.0,-150.0], phase = ConstantPhase(5), T=LinearTemp(Ttop=1000, Tbot=1100));
5854

5955
# add accretionary prism
60-
addPolygon!(Phase, Temp, Cart; xlim=[800.0, 600.0, 800.0],ylim=[100.0,800.0], zlim=[0.0,0.0,-60.0], phase = ConstantPhase(8), T=LinearTemp(Ttop=20, Tbot=30))
61-
62-
```
56+
addPolygon!(Phase, Temp, Cart; xlim=[800.0, 600.0, 800.0],ylim=[100.0,800.0], zlim=[0.0,0.0,-60.0], phase = ConstantPhase(8), T=LinearTemp(Ttop=20, Tbot=30));
57+
```
6358

6459
#### 3. Export final model setup to a paraview file
6560
For visualisation and comparison to actual measured data, the mode setup is saved to a paraview file.
6661

6762
```julia
6863
# # Save data to paraview:
69-
Data_Final = CartData(X,Y,Z,(Phase=Phase,Temp=Temp))
70-
Write_Paraview(Data_Final, "Sedimentary_basin")
71-
72-
```
64+
Data_Final = CartData(X,Y,Z,(Phase=Phase,Temp=Temp));
65+
Write_Paraview(Data_Final, "Sedimentary_basin");
66+
```
7367

7468
After importing and looking at the file to paraview, some unresolved areas might be visible as they are visible in this model. That is due to the resolution and shape of the polygon. To reduce those artefacts an increase in resolution or a change of the polygon angle might help.
7569

7670
![Tutorial_Polygon_structures](../assets/img/Tutorial_Polygon_structures.png)
7771

78-
If you want to run the entire example, you can find the .jl code [here](https://github.com/JuliaGeodynamics/GeophysicalModelGenerator.jl/blob/main/tutorial/Tutorial_polygon_geometry.jl)
72+
If you want to run the entire example, you can find the .jl code [here](https://github.com/JuliaGeodynamics/GeophysicalModelGenerator.jl/blob/main/tutorial/Tutorial_polygon_geometry.jl)

0 commit comments

Comments
 (0)