... | ... | @@ -108,8 +108,8 @@ Add the boundary condition |
|
|
```python
|
|
|
eqTracer.set_boundary_coast("coast")
|
|
|
eqTracer.set_boundary_coast("island")
|
|
|
eqTracer.set_boundary_open("mexico", pre_data_dir + "concentration_mexico.nc")
|
|
|
eqTracer.set_boundary_open("atlantic", pre_data_dir + "concentration_atlantic.nc")
|
|
|
eqTracer.set_boundary_open("mexico", (pre_data_dir + "concentration_atlantic.nc",'tracer'))
|
|
|
eqTracer.set_boundary_open("atlantic", (pre_data_dir + "concentration_atlantic.nc",'tracer'))
|
|
|
```
|
|
|
- ```boundary_coast``` condition for coast (no flux condition)
|
|
|
- ```boundary_open``` impose the external condition
|
... | ... | @@ -184,8 +184,8 @@ Add the boundary condition |
|
|
```python
|
|
|
eqTracer.set_boundary_coast("coast")
|
|
|
eqTracer.set_boundary_coast("island")
|
|
|
eqTracer.set_boundary_open("mexico", pre_data_dir + "concentration_mexico.nc")
|
|
|
eqTracer.set_boundary_open("atlantic", pre_data_dir + "concentration_atlantic.nc")
|
|
|
eqTracer.set_boundary_open("mexico", (pre_data_dir + "concentration_atlantic.nc",'tracer'))
|
|
|
eqTracer.set_boundary_open("atlantic", (pre_data_dir + "concentration_atlantic.nc",'tracer'))
|
|
|
```
|
|
|
- ```boundary_coast``` condition for coast (no flux condition)
|
|
|
- ```boundary_open``` impose the external condition
|
... | ... | @@ -196,3 +196,12 @@ Compute the total mass of tracer in the domain |
|
|
```python
|
|
|
eqTracer.compute_mass("tracer.dat")
|
|
|
```
|
|
|
|
|
|
Create the temporal solver and set the time_step offline (i.e., the time step of the hydrodynamic run)
|
|
|
|
|
|
```python
|
|
|
loop=slim.Loop(maximum_time_step = dt, export_time = 4*dt,path="output")
|
|
|
loop.add_equation(eqTracer)
|
|
|
loop.set_time_step_offline(dt, periodic = False)
|
|
|
loop.run()
|
|
|
``` |