-
Notifications
You must be signed in to change notification settings - Fork 7
Lagrangian particle simulation
###Lagrangian particle simulation
The model is currently setup for the Southern Ocean State Estimate (SOSE). But it can be easily modified to fit a ny MITgcm output or any C-grid model output. To run the code, first make sure the model knows where to find your model output and correctly reads them.
- Edit the parameters in src/size.h to fit the data you have.
- Edit cpp_options.h to include or exclude features. Make sure isArgo is turned off in cpp_options.h: * #undef isArgo*
- Within src/ folder. Compile the code using
make
You will get an executable file named O.particle.
-
Prepare the initialization file using scritps/init_particl_xyz.py. Copy the binary file to src/.
-
If you run particle with the SOSE 1/6th degree simulation, download necessary binary files:
bash sync_data.sh
otherwise, go to scripts folder and run
python gen_data.py
to generate the binary files.
-
After running gen_data.py, you should get a list of binary files in your pth_data_out folder specified in data.nml including
-
reflect_x.bin
-
reflect_y.bin
-
z_to_k_lookup_table.bin
-
k_to_z_lookup_table.bin.
-
Set parameters in the namelist file data.nml. The parameters are explained line by line in src/data.nml .explained.
-
In the src/ folder, run the model
./O.particle
-
Outputs are saved in the folder output_dir specified in data.nml.