Skip to content

Commit

Permalink
resolved merge conflicts
Browse files Browse the repository at this point in the history
  • Loading branch information
quffaro committed Jan 5, 2024
2 parents 57cf75e + 3395d01 commit 41d8b9b
Show file tree
Hide file tree
Showing 34 changed files with 796 additions and 1,552 deletions.
5 changes: 1 addition & 4 deletions .github/workflows/TagBot.yml
Original file line number Diff line number Diff line change
Expand Up @@ -27,7 +27,4 @@ jobs:
steps:
- uses: JuliaRegistries/TagBot@v1
with:
token: ${{ secrets.GITHUB_TOKEN }}
# Edit the following line to reflect the actual name of the GitHub Secret containing your private key
ssh: ${{ secrets.DOCUMENTER_KEY }}
# ssh: ${{ secrets.NAME_OF_MY_SSH_PRIVATE_KEY_SECRET }}
token: ${{ secrets.SERVICE_TOKEN }}
16 changes: 10 additions & 6 deletions Project.toml
Original file line number Diff line number Diff line change
@@ -1,24 +1,23 @@
name = "Decapodes"
uuid = "679ab3ea-c928-4fe6-8d59-fd451142d391"
authors = ["James Fairbanks", "Andrew Baas", "Evan Patterson", "Luke Morris", "George Rauta"]
version = "0.4.0"
version = "0.5.0"

[deps]
ACSets = "227ef7b5-1206-438b-ac65-934d6da304b8"
Artifacts = "56f22d72-fd6d-98f1-02f0-08ddc0907c33"
Catlab = "134e5e36-593f-5add-ad60-77f754baafbe"
CombinatorialSpaces = "b1c52339-7909-45ad-8b6a-6e388f7c67f2"
ComponentArrays = "b0b7db55-cfe3-40fc-9ded-d10e2dbeff66"
DataStructures = "864edb3b-99cc-5e75-8d2d-829cb0a9cfe8"
DiagrammaticEquations = "6f00c28b-6bed-4403-80fa-30e0dc12f317"
Distributions = "31c24e10-a181-5473-b8eb-7969acd0382f"
FileIO = "5789e2e9-d7fb-5bc7-8068-2c6fae9b9549"
GLMakie = "e9467ef8-e4e7-5192-8a1a-b1aee30e663a"
GeometryBasics = "5c1252a2-5f33-56bf-86c9-59e7332b4326"
JLD2 = "033835bb-8acc-5ee8-8aae-3f567f8a3819"
JSON = "682c06a0-de6a-54ab-a142-c8b1cf79cde6"
LinearAlgebra = "37e2e46d-f89d-539d-b4ee-838fcccc9c8e"
MLStyle = "d8e11817-5142-5d16-987a-aa16d5891078"
MultiScaleArrays = "f9640e96-87f6-5992-9c3b-0743c6a49ffa"
OrdinaryDiffEq = "1dea7af3-3e70-54e6-95c3-0bf5283fa5ed"
PreallocationTools = "d236fae5-4411-538c-8e31-a6e3d9e00b46"
Requires = "ae029012-a4dd-5104-9daa-d747884805df"
Expand All @@ -27,25 +26,30 @@ Unicode = "4ec0a83e-493e-50e2-b9ac-8f72acf5a8f5"
[compat]
ACSets = "0.2"
CombinatorialSpaces = "0.5, 0.6"
Artifacts = "1"
Catlab = "0.15, 0.16"
CombinatorialSpaces = "0.5, 0.6"
ComponentArrays = "0.15"
DataStructures = "0.18.13"
Distributions = "0.25"
FileIO = "1.16"
GLMakie = "0.8"
GeometryBasics = "0.4.2"
JLD2 = "0.4"
JSON = "0.21"
LinearAlgebra = "1.9"
MLStyle = "0.4.17"
MultiScaleArrays = "1.10"
OrdinaryDiffEq = "6.47"
PreallocationTools = "0.4"
Requires = "1.3"
Unicode = "1.9"
julia = "1.9"

[extras]
AlgebraicPetri = "4f99eebe-17bf-4e98-b6a1-2c4f205a959b"
Distributions = "31c24e10-a181-5473-b8eb-7969acd0382f"
GeometryBasics = "5c1252a2-5f33-56bf-86c9-59e7332b4326"
Random = "9a3f8284-a2c9-5f02-9a11-845980a1fd5c"
Test = "8dfed614-e22c-5e08-85e1-65c5234f0b40"

[targets]
test = ["AlgebraicPetri", "Test", "Random", "GeometryBasics"]
test = ["AlgebraicPetri", "Distributions", "Test", "Random", "GeometryBasics"]
6 changes: 4 additions & 2 deletions docs/Project.toml
Original file line number Diff line number Diff line change
@@ -1,19 +1,21 @@
[deps]
AlgebraicPetri = "4f99eebe-17bf-4e98-b6a1-2c4f205a959b"
AlgebraicRewriting = "725a01d3-f174-5bbd-84e1-b9417bad95d9"
CairoMakie = "13f3f980-e62b-5c42-98c6-ff1f3baf88f0"
Catlab = "134e5e36-593f-5add-ad60-77f754baafbe"
CombinatorialSpaces = "b1c52339-7909-45ad-8b6a-6e388f7c67f2"
ComponentArrays = "b0b7db55-cfe3-40fc-9ded-d10e2dbeff66"
Decapodes = "679ab3ea-c928-4fe6-8d59-fd451142d391"
Distributions = "31c24e10-a181-5473-b8eb-7969acd0382f"
Documenter = "e30172f5-a6a5-5a46-863b-614d45cd2de4"
DynamicalSystems = "61744808-ddfa-5f27-97ff-6e42cc95d634"
FileIO = "5789e2e9-d7fb-5bc7-8068-2c6fae9b9549"
GeometryBasics = "5c1252a2-5f33-56bf-86c9-59e7332b4326"
HTTP = "cd3eb016-35fb-5094-929b-558a96fad6f3"
Interpolations = "a98d9a8b-a2ab-59e6-89dd-64a1c18fca59"
JLD2 = "033835bb-8acc-5ee8-8aae-3f567f8a3819"
JSON = "682c06a0-de6a-54ab-a142-c8b1cf79cde6"
Literate = "98b081ad-f1c9-55d3-8b20-4c87d4299306"
MultiScaleArrays = "f9640e96-87f6-5992-9c3b-0743c6a49ffa"
MLStyle = "d8e11817-5142-5d16-987a-aa16d5891078"
OrdinaryDiffEq = "1dea7af3-3e70-54e6-95c3-0bf5283fa5ed"
PrettyTables = "08abe8d2-0d0c-5749-adfa-8a2ac140af0d"
StaticArrays = "90137ffa-7385-5640-81b9-e52037218182"
1 change: 1 addition & 0 deletions docs/make.jl
Original file line number Diff line number Diff line change
Expand Up @@ -48,6 +48,7 @@ makedocs(
"Misc Features" => "bc_debug.md",
"Pipe Flow" => "poiseuille.md",
"Glacial Flow" => "ice_dynamics.md",
"Grigoriev Ice Cap" => "grigoriev.md",
"Budyko-Sellers-Halfar" => "budyko_sellers_halfar.md",
# "Examples" => Any[
# "examples/cfd_example.md"
Expand Down
Binary file added docs/src/Icethickness_Grigoriev_ice_cap_2021.tif
Binary file not shown.
10 changes: 5 additions & 5 deletions docs/src/bc_debug.md
Original file line number Diff line number Diff line change
Expand Up @@ -126,7 +126,7 @@ modified initial condition is shown below:

```@example Debug
using LinearAlgebra
using MultiScaleArrays
using ComponentArrays
using MLStyle
using CombinatorialSpaces.DiscreteExteriorCalculus: ∧
include("../../examples/boundary_helpers.jl")
Expand Down Expand Up @@ -167,16 +167,16 @@ fₘ = sim(plot_mesh_dual, generate)
velocity(p) = [-0.5, 0.0, 0.0]
v = ♭(plot_mesh_dual, DualVectorField(velocity.(plot_mesh_dual[triangle_center(plot_mesh_dual),:dual_point]))).data
u₀ = construct(PhysicsState, [VectorForm(c)], Float64[], [:C])
u₀ = ComponentArray(C=c)
params = (V = v,)
prob = ODEProblem(fₘ, u₀, (0.0, 100.0), params)
sol = solve(prob, Tsit5());
# Plot the result
times = range(0.0, 100.0, length=150)
colors = [findnode(sol(t), :C) for t in times]
colors = [sol(t).C for t in times]
extrema
# Initial frame
fig, ax, ob = mesh(plot_mesh, color=colors[1], colorrange = extrema(vcat(colors...)))
ax.aspect = AxisAspect(3.0)
Expand All @@ -185,7 +185,7 @@ framerate = 30
# Animation
record(fig, "diff_adv_right.gif", range(0.0, 100.0; length=150); framerate = 30) do t
ob.color = findnode(sol(t), :C)
ob.color = sol(t).C
end
```

Expand Down
26 changes: 11 additions & 15 deletions docs/src/budyko_sellers_halfar.md
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@ using Decapodes
# External Dependencies
using MLStyle
using MultiScaleArrays
using ComponentArrays
using LinearAlgebra
using OrdinaryDiffEq
using JLD2
Expand Down Expand Up @@ -167,12 +167,8 @@ lines(map(x -> x[1], point(s′)), h₀)

``` @example DEC
# Store these values to be passed to the solver.
u₀ = construct(PhysicsState, [
VectorForm(Tₛ₀),
VectorForm(h₀),
], Float64[], [
:Tₛ,
:halfar_h])
u₀ = ComponentArray(Tₛ=Tₛ₀,halfar_h=h₀)
constants_and_parameters = (
budyko_sellers_absorbed_radiation_α = α,
budyko_sellers_outgoing_radiation_A = A,
Expand Down Expand Up @@ -277,12 +273,12 @@ We can save the solution file to examine later.

Quickly examine the final conditions for temperature.
``` @example DEC
lines(map(x -> x[1], point(s′)), findnode(soln(tₑ), :Tₛ))
lines(map(x -> x[1], point(s′)), soln(tₑ).Tₛ)
```

Quickly examine the final conditions for ice height.
``` @example DEC
lines(map(x -> x[1], point(s′)), findnode(soln(tₑ), :halfar_h))
lines(map(x -> x[1], point(s′)), soln(tₑ).halfar_h)
```

Create animated GIFs of the temperature and ice height dynamics.
Expand All @@ -291,31 +287,31 @@ begin
# Initial frame
frames = 100
fig = Figure(resolution = (800, 800))
ax1 = Axis(fig[1,1])
ax1 = CairoMakie.Axis(fig[1,1])
xlims!(ax1, extrema(map(x -> x[1], point(s′))))
ylims!(ax1, extrema(findnode(soln(tₑ), :Tₛ)))
ylims!(ax1, extrema(soln(tₑ).Tₛ))
Label(fig[1,1,Top()], "Surface temperature, Tₛ, [C°]")
Label(fig[2,1,Top()], "Line plot of temperature from North to South pole, every $(tₑ/frames) time units")
# Animation
record(fig, "budyko_sellers_halfar_T.gif", range(0.0, tₑ; length=frames); framerate = 15) do t
lines!(fig[1,1], map(x -> x[1], point(s′)), findnode(soln(t), :Tₛ))
lines!(fig[1,1], map(x -> x[1], point(s′)), soln(t).Tₛ)
end
end
begin
# Initial frame
frames = 100
fig = Figure(resolution = (800, 800))
ax1 = Axis(fig[1,1])
ax1 = CairoMakie.Axis(fig[1,1])
xlims!(ax1, extrema(map(x -> x[1], point(s′))))
ylims!(ax1, extrema(findnode(soln(tₑ), :halfar_h)))
ylims!(ax1, extrema(soln(tₑ).halfar_h))
Label(fig[1,1,Top()], "Ice height, h")
Label(fig[2,1,Top()], "Line plot of ice height from North to South pole, every $(tₑ/frames) time units")
# Animation
record(fig, "budyko_sellers_halfar_h.gif", range(0.0, tₑ; length=frames); framerate = 15) do t
lines!(fig[1,1], map(x -> x[1], point(s′)), findnode(soln(t), :halfar_h))
lines!(fig[1,1], map(x -> x[1], point(s′)), soln(t).halfar_h)
end
end
```
Expand Down
Loading

0 comments on commit 41d8b9b

Please sign in to comment.