@@ -147,11 +147,11 @@ end
147
147
148
148
149
149
"""
150
- add_box!(Phase, Temp, Grid::AbstractGeneralGrid; xlim::NTuple{2, _T} = (20,100), [ylim::NTuple{2, _T} = (1,10)], zlim::NTuple{2, _T} = (10,80),
150
+ add_box!(Phase, Temp, Grid::AbstractGeneralGrid; xlim::Tuple = (20,100), [ylim::Tuple = (1,10)], zlim::Tuple = (10,80),
151
151
Origin=nothing, StrikeAngle=0, DipAngle=0,
152
152
phase = ConstantPhase(1),
153
153
T=nothing,
154
- cell=false ) where _T
154
+ cell=false )
155
155
156
156
Adds a box with phase & temperature structure to a 3D model setup. This simplifies creating model geometries in geodynamic models
157
157
@@ -206,11 +206,11 @@ julia> write_paraview(Grid,"LaMEM_ModelSetup") # Save model to paraview
206
206
```
207
207
"""
208
208
function add_box! (Phase, Temp, Grid:: AbstractGeneralGrid ; # required input
209
- xlim:: NTuple{2, _T} = (20 ,100 ), ylim= nothing , zlim:: NTuple{2, _T} = (10 ,80 ), # limits of the box
209
+ xlim:: Tuple = (20 ,100 ), ylim= nothing , zlim:: Tuple = (10 ,80 ), # limits of the box
210
210
Origin= nothing , StrikeAngle= 0 , DipAngle= 0 , # origin & dip/strike
211
211
phase = ConstantPhase (1 ), # Sets the phase number(s) in the box
212
212
T= nothing , # Sets the thermal structure (various functions are available)
213
- cell= false ) where _T # if true, Phase and Temp are defined on cell centers
213
+ cell= false ) # if true, Phase and Temp are defined on cell centers
214
214
215
215
# Retrieve 3D data arrays for the grid
216
216
X,Y,Z = coordinate_grids (Grid, cell= cell)
266
266
267
267
268
268
"""
269
- add_layer!(Phase, Temp, Grid::AbstractGeneralGrid; xlim::NTuple{2, _T} = (1,100), [ylim::NTuple{2, _T} = (0,20)], zlim::NTuple{2, _T} = (0,-100),
269
+ add_layer!(Phase, Temp, Grid::AbstractGeneralGrid; xlim::Tuple = (1,100), [ylim::Tuple = (0,20)], zlim::Tuple = (0,-100),
270
270
phase = ConstantPhase(1),
271
- T=nothing, cell=false ) where _T
271
+ T=nothing, cell=false )
272
272
273
273
274
274
Adds a layer with phase & temperature structure to a 3D model setup. The most common use would be to add a lithospheric layer to a model setup.
@@ -414,7 +414,7 @@ julia> write_paraview(Model3D,"LaMEM_ModelSetup") # Save model to para
414
414
function add_sphere! (Phase, Temp, Grid:: AbstractGeneralGrid ; # required input
415
415
cen:: NTuple{3, _T} = (0 ,0 ,- 1 ), radius:: Number , # center and radius of the sphere
416
416
phase = ConstantPhase (1 ), # Sets the phase number(s) in the sphere
417
- T= nothing , cell= false ) where _T # Sets the thermal structure (various functions are available)
417
+ T= nothing , cell= false ) where _T # Sets the thermal structure (various functions are available)
418
418
419
419
# Retrieve 3D data arrays for the grid
420
420
X,Y,Z = coordinate_grids (Grid, cell= cell)
@@ -484,7 +484,7 @@ function add_ellipsoid!(Phase, Temp, Grid::AbstractGeneralGrid; # required i
484
484
cen:: NTuple{3, _T} = (- 1 ,- 1 ,- 1 ), axes:: NTuple{3, _T} = (0.2 ,0.1 ,0.5 ), # center and semi-axes of the ellpsoid
485
485
Origin= nothing , StrikeAngle= 0 , DipAngle= 0 , # origin & dip/strike
486
486
phase = ConstantPhase (1 ), # Sets the phase number(s) in the box
487
- T= nothing , cell= false ) where _T # Sets the thermal structure (various functions are available)
487
+ T= nothing , cell= false ) where _T # Sets the thermal structure (various functions are available)
488
488
489
489
if Origin== nothing
490
490
Origin = cen # center
@@ -522,9 +522,9 @@ function add_ellipsoid!(Phase, Temp, Grid::AbstractGeneralGrid; # required i
522
522
end
523
523
524
524
"""
525
- add_cylinder!(Phase, Temp, Grid::AbstractGeneralGrid; base::NTuple{3, _T } = (-1,-1,-1.5), cap::NTuple{3, _T } = (-1,-1,-0.5), radius::Number,
525
+ add_cylinder!(Phase, Temp, Grid::AbstractGeneralGrid; base::NTuple{3, } = (-1,-1,-1.5), cap::NTuple{3, } = (-1,-1,-0.5), radius::Number,
526
526
phase = ConstantPhase(1),
527
- T=nothing, cell=false ) where _T
527
+ T=nothing, cell=false )
528
528
529
529
530
530
Adds a cylinder with phase & temperature structure to a 3D model setup. This simplifies creating model geometries in geodynamic models
@@ -566,9 +566,9 @@ julia> write_paraview(Model3D,"LaMEM_ModelSetup") # Save model to para
566
566
```
567
567
"""
568
568
function add_cylinder! (Phase, Temp, Grid:: AbstractGeneralGrid ; # required input
569
- base:: NTuple{3, _T } = (- 1 ,- 1 ,- 1.5 ), cap:: NTuple{3, _T } = (- 1 ,- 1 ,- 0.5 ), radius:: Number , # center and radius of the sphere
569
+ base:: NTuple{3, } = (- 1 ,- 1 ,- 1.5 ), cap:: NTuple{3, } = (- 1 ,- 1 ,- 0.5 ), radius:: Number , # center and radius of the sphere
570
570
phase = ConstantPhase (1 ), # Sets the phase number(s) in the sphere
571
- T= nothing , cell= false ) where _T # Sets the thermal structure (various functions are available)
571
+ T= nothing , cell= false ) # Sets the thermal structure (various functions are available)
572
572
573
573
# axis vector of cylinder
574
574
axVec = cap .- base
622
622
623
623
624
624
"""
625
- add_polygon!(Phase, Temp, Grid::AbstractGeneralGrid; xlim=(), ylim::NTuple{2, _T} = (0,0.8), zlim=(), phase = ConstantPhase(1), T=nothing, cell=false ) where _T
625
+ add_polygon!(Phase, Temp, Grid::AbstractGeneralGrid; xlim=(), ylim::Tuple = (0,0.8), zlim=(), phase = ConstantPhase(1), T=nothing, cell=false )
626
626
627
627
628
628
Adds a polygon with phase & temperature structure to a 3D model setup. This simplifies creating model geometries in geodynamic models
@@ -664,9 +664,9 @@ julia> write_paraview(Model3D,"LaMEM_ModelSetup") # Save model to para
664
664
665
665
"""
666
666
function add_polygon! (Phase, Temp, Grid:: AbstractGeneralGrid ; # required input
667
- xlim= (), ylim:: NTuple{2, _T} = (0 ,0.8 ), zlim= (), # limits of the box
667
+ xlim= (), ylim:: Tuple = (0 ,0.8 ), zlim= (), # limits of the box
668
668
phase = ConstantPhase (1 ), # Sets the phase number(s) in the box
669
- T= nothing , cell= false ) where _T # Sets the thermal structure (various functions are available)
669
+ T= nothing , cell= false ) # Sets the thermal structure (various functions are available)
670
670
671
671
672
672
xlim_ = Float64 .(collect (xlim))
0 commit comments