Skip to content

Commit

Permalink
Removed unecessary files. Tested if examples work
Browse files Browse the repository at this point in the history
  • Loading branch information
mochell committed Sep 17, 2024
1 parent 2f0c987 commit 0e2a201
Show file tree
Hide file tree
Showing 43 changed files with 253 additions and 1,240 deletions.
3 changes: 3 additions & 0 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -54,6 +54,9 @@ To run the `T04_2D_reg_test.jl` file from the command line, follow these steps:
```
5. The test will run and display the results in the terminal.

This will create some .gifs in the local folder plots/tests/


## Basic model structure
PiCLES follows the modular model structure from [Oceananigans.jl](https://clima.github.io/OceananigansDocumentation/stable/), but it does not currently share objects. Functionality from Oceananigans does not work in PiCLES.

Expand Down
115 changes: 0 additions & 115 deletions examples/_example_eq_v3.jl

This file was deleted.

118 changes: 0 additions & 118 deletions examples/_example_eq_v4.jl

This file was deleted.

2 changes: 1 addition & 1 deletion tests/B01_1D_regtest_wave_growth.jl
Original file line number Diff line number Diff line change
Expand Up @@ -68,7 +68,7 @@ mkpath(save_path)

# %%
# function to define constants
Revise.retry()

ODEpars, Const_ID, Const_Scg = PW.ODEParameters(r_g=0.85)

# @info "org. gamma gamma= " Const_ID.γ
Expand Down
2 changes: 1 addition & 1 deletion tests/B02_2D_regtest_netCDF.jl
Original file line number Diff line number Diff line change
Expand Up @@ -81,7 +81,7 @@ end



Revise.retry()

# Default initial conditions based on timestep and chaeracteristic wind velocity
WindSeamin = FetchRelations.MinimalWindsea(U10, V10, DT)
default_particle = ParticleDefaults(WindSeamin["lne"], WindSeamin["cg_bar_x"], WindSeamin["cg_bar_y"], 0.0, 0.0)
Expand Down
4 changes: 2 additions & 2 deletions tests/B03_2D_regtest_moving_fetch_netCDF.jl
Original file line number Diff line number Diff line change
Expand Up @@ -52,7 +52,7 @@ DT = 30minutes

# Define basic ODE parameters
ODEpars, Const_ID, Const_Scg = PW.ODEParameters(r_g=0.85)
Revise.retry()


function interpolate_winds(ds, multiplyer=0)

Expand All @@ -78,7 +78,7 @@ end
# define ODE system and parameters
#particle_system = PW.particle_equations(u, v, γ=Const_ID.γ, q=Const_ID.q);

Revise.retry()

# Default initial conditions based on timestep and chaeracteristic wind velocity
WindSeamin = FetchRelations.MinimalWindsea(2, 2, DT)

Expand Down
4 changes: 2 additions & 2 deletions tests/T01_test_PIC_1D.jl
Original file line number Diff line number Diff line change
Expand Up @@ -81,7 +81,7 @@ function convert_store_to_tuple(p_collect, grid1d)
end

# %%
Revise.retry()

n_particles = 101
eta_min, eta_max =0, 20
grid1d = OneDGrid(eta_min, eta_max, n_particles)
Expand Down Expand Up @@ -167,7 +167,7 @@ animate(x_collect, p_collect, grid1d, path=plot_path_base, name="T01_PIC_1D_back


# %% diverging sin
Revise.retry()

xp = grid1dnotes.x .+ grid1dnotes.dx * 1.5 #+ rand(n_particles)/5
#charges_1d = rand(n_particles)* 0 .+ 1
charges_1d = sin.(xp) *0.4 .+0.2
Expand Down
10 changes: 5 additions & 5 deletions tests/T02_single_particle_1d.jl
Original file line number Diff line number Diff line change
Expand Up @@ -37,7 +37,7 @@ T = 24 * 2 * 60 * 60 # seconds
## u must be always a function of x and t !!!
u(x, t) = x .* 0 + t * 0 + U10

Revise.retry()

particle_system = PW5.particle_equations(u, γ=γ)

# define variables based on particle equation
Expand All @@ -61,7 +61,7 @@ cb = ContinuousCallback(condition, affect!)
WindSeamin = FetchRelations.get_initial_windsea(u(0, 0), 5minutes)
#WindSeamin = FetchRelations.MinimalWindsea( u(0, 0), 5minutes)

Revise.retry()


ODE_settings = PW5.ODESettings(
Parameters=default_ODE_parameters,
Expand Down Expand Up @@ -213,7 +213,7 @@ using Oceananigans.Units
using PiCLES.Simulations
using PiCLES.Plotting

Revise.retry()


u10 = 10
u(x, t) = x .* 0 + t * 0 + u10
Expand Down Expand Up @@ -244,7 +244,7 @@ savefig(joinpath(plot_path_base, "PW4_u$(u10)_per_" * string(wave_model.periodic

# %%
@info "experiment 1: positive winds, non-periodic \n"
Revise.retry()


wave_model.periodic_boundary = false
# reset boundary array in model
Expand Down Expand Up @@ -275,7 +275,7 @@ Plotting.plot_results(wave_simulation, title="$u10 m/s, periodic=" * string(wave
savefig(joinpath(plot_path_base, "PW4_u$(u10)_per_" * string(wave_model.periodic_boundary) * ".png"))

# %%
#Revise.retry()
#
@info "experiment 1: nagative winds, non-perodic \n"
u10 = -10
u(x, t) = x .* 0 + t * 0 + u10
Expand Down
Loading

0 comments on commit 0e2a201

Please sign in to comment.