Skip to content

Commit

Permalink
Define CommonSpaces module
Browse files Browse the repository at this point in the history
  • Loading branch information
charleskawczynski committed Nov 20, 2024
1 parent 68cc581 commit d05f90a
Show file tree
Hide file tree
Showing 7 changed files with 607 additions and 8 deletions.
21 changes: 14 additions & 7 deletions NEWS.md
Original file line number Diff line number Diff line change
Expand Up @@ -4,16 +4,23 @@ ClimaCore.jl Release Notes
main
-------

- We've added new convenience constructors for spaces PR [2082](https://github.com/CliMA/ClimaCore.jl/pull/2082). Here are links to the new constructors:
- [ExtrudedCubedSphereSpace]()
- [CubedSphereSpace]()
- [ColumnSpace]()
- [Box3DSpace]()
- [SliceXZSpace]()
- [RectangleXYSpace]()

v0.14.20
-------

- We've added new convenience constructors for grids PR [1848](https://github.com/CliMA/ClimaCore.jl/pull/1848). Here are links to the new constructors:
- [ExtrudedCubedSphereGrid]()
- [CubedSphereGrid]()
- [ColumnGrid]()
- [Box3DGrid]()
- [SliceXZGrid]()
- [RectangleXYGrid]()
- [ExtrudedCubedSphereGrid](https://github.com/CliMA/ClimaCore.jl/blob/cbb193042fac3b4bef33251fbc0f232427bfe506/src/CommonGrids/CommonGrids.jl#L85-L144)
- [CubedSphereGrid](https://github.com/CliMA/ClimaCore.jl/blob/cbb193042fac3b4bef33251fbc0f232427bfe506/src/CommonGrids/CommonGrids.jl#L200-L235)
- [ColumnGrid](https://github.com/CliMA/ClimaCore.jl/blob/cbb193042fac3b4bef33251fbc0f232427bfe506/src/CommonGrids/CommonGrids.jl#L259-L281)
- [Box3DGrid](https://github.com/CliMA/ClimaCore.jl/blob/cbb193042fac3b4bef33251fbc0f232427bfe506/src/CommonGrids/CommonGrids.jl#L303-L378)
- [SliceXZGrid](https://github.com/CliMA/ClimaCore.jl/blob/cbb193042fac3b4bef33251fbc0f232427bfe506/src/CommonGrids/CommonGrids.jl#L441-L498)
- [RectangleXYGrid](https://github.com/CliMA/ClimaCore.jl/blob/cbb193042fac3b4bef33251fbc0f232427bfe506/src/CommonGrids/CommonGrids.jl#L547-L602)

- A `strict = true` keyword was added to `rcompare`, which checks that the types match. If `strict = false`, then `rcompare` will return `true` for `FieldVector`s and `NamedTuple`s with the same properties but permuted order. For example:
- `rcompare((;a=1,b=2), (;b=2,a=1); strict = true)` will return `false` and
Expand Down
14 changes: 14 additions & 0 deletions docs/src/api.md
Original file line number Diff line number Diff line change
Expand Up @@ -180,6 +180,8 @@ Topologies.ghost_neighboring_elements
## Grids

```@docs
Grids.CellFace
Grids.CellCenter
Grids.ColumnGrid
Grids.FiniteDifferenceGrid
Grids.ExtrudedFiniteDifferenceGrid
Expand Down Expand Up @@ -247,6 +249,18 @@ Spaces.SpectralElementSpaceSlab
Spaces.node_horizontal_length_scale
```

## CommonSpaces

```@docs
CommonSpaces
CommonSpaces.ExtrudedCubedSphereSpace
CommonSpaces.CubedSphereSpace
CommonSpaces.ColumnSpace
CommonSpaces.Box3DSpace
CommonSpaces.SliceXZSpace
CommonSpaces.RectangleXYSpace
```

### Quadratures


Expand Down
1 change: 1 addition & 0 deletions src/ClimaCore.jl
Original file line number Diff line number Diff line change
Expand Up @@ -24,6 +24,7 @@ include("Limiters/Limiters.jl")
include("InputOutput/InputOutput.jl")
include("Remapping/Remapping.jl")
include("CommonGrids/CommonGrids.jl")
include("CommonSpaces/CommonSpaces.jl")

include("deprecated.jl")

Expand Down
11 changes: 10 additions & 1 deletion src/CommonGrids/CommonGrids.jl
Original file line number Diff line number Diff line change
Expand Up @@ -269,7 +269,16 @@ end
)
A convenience constructor, which builds a
[`Grids.FiniteDifferenceGrid`](@ref).
[`Grids.FiniteDifferenceGrid`](@ref) given:
- `FT` the floating-point type (defaults to `Float64`) [`Float32`, `Float64`]
- `z_elem` the number of z-points
- `z_min` the domain minimum along the z-direction.
- `z_max` the domain maximum along the z-direction.
- `device` the `ClimaComms.device`
- `context` the `ClimaComms.context`
- `stretch` the mesh `Meshes.StretchingRule` (defaults to [`Meshes.Uniform`](@ref))
- `z_mesh` the vertical mesh, defaults to an `Meshes.IntervalMesh` along `z` with given `stretch`
# Example usage
Expand Down
Loading

0 comments on commit d05f90a

Please sign in to comment.