Skip to content

request_file

Ludovic Lepers edited this page Jan 16, 2025 · 1 revision

Request file

The request file contains information about the switches and properties of the simulation.

When there is value and keys, the value value must be an integer between 1 and the number of elements in value. This integer will represent the option used in the list of option. Boolean field means that the field can either contains 1, meaning that the process will be activated or 0, meaning that the process will be deactivated. When there is value and units, the value is expected to be in the units of the field.

Fields starting by iopt means that this is an integer to choose between options (at least 2).

The value showed in this wiki is the default value (most of the time)

File structure

{
    time_info:{...},
    drifter_parameters:{...},
    release:{...},
    drift:{...},
    rng:{...}

}

Time info

"start_time":"2023/01/01;01:00:00"

Start of the simulation YYYY/MM/DD/;HH:mm:ss.


"end_time":"2023/01/01;23:00:00"

End of the simulation YYYY/MM/DD/;HH:mm:ss, if nothing stops the simulation before the end.


"iopt_backtrack":{
    "value":0,
    "keys":[
        "forward",
        "backward"
    ]
}

If the simulation is forward or backtrack in time. The start and end time should be flipped when this switch is activated.

"drift_coefficient":{
    "dwl":{
        "min":0.0,
        "max":0.0
    },
    "cwl":{
        "min":0.0,
        "max":0.0
    }
}

Downwind dwl and crosswind cwl coefficient. They are used with the wind. Each particle will received a random value uniformly distributed between the min and max values.

Release

"nopart":1000

Number of particles for the simulation. It should be equals to the number of particle defined in the file with the initial particle location.

"iopt_gen_cld":0

Boolean field, will generate a cloud of particle if put at 1, but this is deprecated. It is better to provide the cloud of particle in another file and let this field at 0.

Drift

"iopt_3D":1

Boolean field, if the particles will be able to drift in the water column, or should stays at the surface.


"iopt_wind_drift":1

Boolean field, if the particle will drift because of the wind


"iopt_cur_drift":1

Boolean field, if the particle will drift because of the current


"iopt_wave_drift":1

Boolean field, if the particle will drift because of the wave


"iopt_stranding":1

Boolean field, if activated a particle hitting the shore will be stuck and his state will be at stranded. Otherwise, the particle will be stuck in place and go back toward the sea when the current switch direction


"iopt_resurfacing":1

Boolean field, if activated, the particle in the water column state will switch to the surface state when they get a a depth of 0. This will only be read when "iopt_3D":1


"iopt_leeway":1

Boolean field, if activated, the cwl will randomly switch from positive to negative for each particle


"timestep_duration":{
    "value":600,
    "units":"s"
}

duration of a timestep


"tmstp_per_outtmstp":{
    "value":1
}

The number of model timestep per model output. For instance, a value of 2 means that every other timestep will be produced. The initial simulation state is always produced.


"iopt_force_last_output":1

Boolean field, if activated, the last timestep will always be produced, regardless of the tmstp_per_outtmstp.


"nbr_subtmstp_vertical":{
    "value":10
}

The number of subtimestep for the vertical processes, only used when "iopt_3D":1


Resuspension

This section is only read when "iopt_3D":1

"resuspension":{
    "iopt_part_resuspension":0,
    "min_speed":{
        "value":0,
        "units":"m/s"
    },
    "height":{
        "value":0.0,
        "units":"m"
    }
}

The Boolean field iopt_part_resuspension activate the resuspension. If activated the particle at the seabed will be resuspended in the water column at the height when the speed of the wave induced drift and the current at the bottom summed together are above min_speed. Theses two field are only read when the resuspension is activated.


Diffusion

There is no diffusion for the first particle.

"iopt_dif_coef_v":{
    "value":0,
    "keys":[
        "null_values",
        "values_from_request.json",
        "values_from_hydro_model",
        "values_from_Johanssen_1982"
    ]
}

If the particle will be subject to the vertical diffusion. It can either be deactivated (0), use the value defined in the request file (1), from the hydrodynamic model (2), or from Johanssen 1982 (3), the last one needs the waves to works. It is only used when "iopt_3D":1, and for the particle that are in the water column, dissolved, degraded or dispersed.

"diffusivity_coefficients":{
    "K_dif_x":{
        "value":0,
        "units":"m\u00b2\/s"
    },
    "K_dif_y":{
        "value":0,
        "units":"m\u00b2\/s"
    },
    "K_dif_z":{
        "value":0,
        "units":"m\u00b2\/s"
    }
}

The diffusivity coefficient K_dif_x and K_dif_y are only read when iopt_dif_coef_h is 1, the K_dif_z is only read when iopt_dif_coef_v is 1.

"iopt_prevent_dif_seabed":0

The Boolean field iopt_prevent_dif_seabed will prevent the particle to reach the bottom due to the vertical diffusion. If the particle reach the seabed, but the distance traveled would not be enough without the vertical diffusion, the vertical diffusion part is removed from the displacement. Only read when iopt_dif_coef_v is not 0.

"iopt_prevent_dif_surface":0

The Boolean field iopt_prevent_dif_surface will prevent the particle to reach the surface due to the vertical diffusion. If the particle reach the surface, but the distance traveled would not be enough without the vertical diffusion, the vertical diffusion part is removed from the displacement. Only read when iopt_dif_coef_v is not 0 and iopt_resurfacing is not 0 too (no point to do this check if the particle cant go to the surface).


"w_imposed":{
    "value":0,
    "units":"m\/s"
}

The value of this parameters will be added to the vertical velocity of all drifting particles. Positive means toward the surface and negative means towards the bottom. This will only be read when "iopt_3D":1.


"iopt_lag_scheme":{
    "value":1,
    "keys":[
        "Euler",
        "R-K"
    ]
}

Scheme used for the horizontal advection. It can be Euler (iopt_lag_scheme is 0) or Runge-Kutta 4 (iopt_lag_scheme is 1).

rng

OSERIT use some random number generator, for the diffusion for instance. THese are based on two seeds:

"rng":{
    "iopt_set_seed":1,
    "seed1":123456789,
    "seed2":123456789
}

If the Boolean field iopt_set_seed is set to 0, the seeds will be generated by OSERIT on the fly using the current time of the system. If it is set to 1, the model will then read the seed1 and seed2 field, and use them as seeds. They should be different from each other (ideally) adn must be insteger.

Clone this wiki locally