OGS6
OGS6.RdConstructor for the OGS6 base class
Active bindings
sim_nameSimulation name.
valuemust be stringsim_pathSimulation path.
valuemust be stringlogfileLogfile path.
valuemust be stringgml.gml. read-onlygeometry.prjgeometrytag.valuemust be stringmeshes.prjmeshestag.valuemust be list of stringsvtus.vtus.valuemust be list ofOGS6_vtuobjectspython_script.prjpython_scripttag.valuemust be stringsearch_length_algorithm.prjsearch_length_algorithmtag.valuemust beprj_search_length_algorithmobjectprocesses.prjprocessestag.valuemust be list ofprj_processobjectstime_loop.prjtime_looptag.valuemust beprj_time_loopobjectlocal_coordinate_system.prjlocal_coordinate_systemtag.valuemust beprj_local_coordinate_systemobjectmedia.prjmediatag.valuemust be list ofprj_mediumobjectsparameters.prjparameterstag.valuemust be list ofprj_parameterobjectschemical_system.prjchemical_systemtag.valuemust beprj_chemical_systemobjectcurves.prjcurvestag.valuemust be list ofprj_curveobjectsprocess_variables.prjprocess_variablestag.valuemust be list ofprj_process_variableobjectsnonlinear_solvers.prjnonlinear_solverstag.valuemust be list ofprj_nonlinear_solverobjectslinear_solvers.prjlinear_solverstag.valuemust be list ofprj_linear_solverobjectstest_definition.prjtest_definitiontag.valuemust be list ofprj_vtkdiffobjectsinsitu.prjinsitutag.valuemust beprj_insituobjectpvds.pvds.valuemust be list ofOGS6_pvdobjectsh5sh5svaluemust be of classH5IdComponentas returned byrhdf5::h5read().mshsmshsvaluemust be an object of classOGS6_msh.includeincludevaluemust be a string.rasters.prjrasterstag.valuemust be list ofprj_rasterobjects
Methods
Method new()
Creates new OGS6 object
Usage
OGS6$new(sim_name, sim_path)Arguments
sim_namestring: Simulation name
sim_pathstring: Path where all files for the simulation will be saved
Examples
ogs6_obj <- OGS6$new(sim_name = "my_sim", sim_path = "my/path")Method add()
Adds a .prj simulation component
Examples
ogs6_obj <- OGS6$new(sim_name = "my_sim", sim_path = "my/path")
ogs6_obj$add(prj_parameter(name = "foo", type = "bar"))Method add_mesh()
Adds a reference to a .vtu file and optionally, a OGS6_vtu
object
Method update_component()
Update a component of the OGS6 object.
Method get_status()
Checks if the OGS6 object has all necessary parameters for
starting a simulation
Examples
ogs6_obj <- OGS6$new(sim_name = "my_sim", sim_path = "my/path")
ogs6_obj$get_status()Examples
## ------------------------------------------------
## Method `OGS6$new`
## ------------------------------------------------
ogs6_obj <- OGS6$new(sim_name = "my_sim", sim_path = "my/path")
## ------------------------------------------------
## Method `OGS6$add`
## ------------------------------------------------
ogs6_obj <- OGS6$new(sim_name = "my_sim", sim_path = "my/path")
ogs6_obj$add(prj_parameter(name = "foo", type = "bar"))
## ------------------------------------------------
## Method `OGS6$add_gml`
## ------------------------------------------------
ogs6_obj <- OGS6$new(sim_name = "my_sim", sim_path = "my/path")
ogs6_obj$add_gml("this_works.gml")
if (FALSE) ogs6_obj$add_gml("this_doesnt.oops")
## ------------------------------------------------
## Method `OGS6$add_mesh`
## ------------------------------------------------
ogs6_obj <- OGS6$new(sim_name = "my_sim", sim_path = "my/path")
ogs6_obj$add_mesh("this_works.vtu")
if (FALSE) ogs6_obj$add_mesh("this_doesnt.oops")
## ------------------------------------------------
## Method `OGS6$update_component`
## ------------------------------------------------
if (FALSE) ogs6_obj$update_component(list(
list("ogs6_obj$parameters[[1]]$value", 2.3),
list("ogs6_obj$media[[1]]$properties[[2]]$value",
1.0e-3)))
## ------------------------------------------------
## Method `OGS6$get_status`
## ------------------------------------------------
ogs6_obj <- OGS6$new(sim_name = "my_sim", sim_path = "my/path")
ogs6_obj$get_status()
#> ✗ 'processes' has at least one element
#> ✗ 'time_loop' is defined
#> ✗ 'nonlinear_solvers' has at least one element
#> ✗ 'linear_solvers' has at least one element
#> ✗ 'parameters' has at least one element
#> ✗ 'process_variables' has at least one element
#> ✗ 'mesh' is defined
#> ✗ 'geometry' is defined
#> ✗ 'media' has at least one element
#> ✗ 'test_definition' has at least one element
#> ✗ 'curves' has at least one element
#> ✗ 'meshes' has at least one element
#> ✗ 'local_coordinate_system' is defined
#> ✗ 'search_length_algorithm' is defined
#> ✗ 'chemical_system' is defined
#> ✗ 'python_script' is defined
#> ✗ 'insitu' is defined