simulate_t2d: TELEMAC-2D model run

Description Usage Arguments Value Note

View source: R/t2d.R

Description

Conduct a TELEMAC-2D model run using the model's system command.

Usage

1
simulate_t2d(x, log = "run.log", res = NULL, vars = "all", exec)

Arguments

x

An object of class t2d.

log

character, a filename for logging of runtime messages to be created in the project directory (x$wdir). Default: run.log. Set to NULL if no logfile shall be created (in that case the runlog will not be checked for errors).

res

character, the results file (must be of type *_.slf). If NULL (default), the information from the existing steering file will be used or (if the file does not yet exist) will be extracted from x$res.

vars

Selection of variables to be imported after the simulation: either "all" (default) reading all variables, "none" giving only the header, a character vector of variable names, or a numeric vector of positions. Importing all variables may require large storage capacities (depending on the number of variables, mesh points, and specified output intervals).

exec

character, the TELEMAC-2D executable if not already specified in x.

Value

An object of class t2d with new or updated element res (an object of class t2d_res).

Note

In case the project directory or any of the mandatory input files do not yet exist, this function will first call write_t2d and then run the model.

TELEMAC-2D runs are often rather long. During simulation time this command will, by default, write nothing to console but store the output in the specified log file.

In case of large projects with expected long model runtimes it might make more sense to run TELEMAC-2D directly instead of using this function.


telemac documentation built on Feb. 7, 2022, 5:06 p.m.