diff --git a/man/OGS6.Rd b/man/OGS6.Rd index ce0bb931a7e8503cb7cfd3e48943b4bd15f6dca6..1e4eb531c327f56faa146db04013bf4d53611666 100644 --- a/man/OGS6.Rd +++ b/man/OGS6.Rd @@ -59,7 +59,7 @@ Constructor for the OGS6 base class \subsection{Public methods}{ \itemize{ \item \href{#method-new}{\code{OGS6$new()}} -\item \href{#method-add_component}{\code{OGS6$add_component()}} +\item \href{#method-add}{\code{OGS6$add()}} \item \href{#method-add_gml}{\code{OGS6$add_gml()}} \item \href{#method-add_vtu}{\code{OGS6$add_vtu()}} \item \href{#method-add_python_script}{\code{OGS6$add_python_script()}} @@ -109,18 +109,21 @@ validated. Unless you're a dev, please don't touch.} } } \if{html}{\out{<hr>}} -\if{html}{\out{<a id="method-add_component"></a>}} -\if{latex}{\out{\hypertarget{method-add_component}{}}} -\subsection{Method \code{add_component()}}{ +\if{html}{\out{<a id="method-add"></a>}} +\if{latex}{\out{\hypertarget{method-add}{}}} +\subsection{Method \code{add()}}{ Adds a simulation component (WIP) \subsection{Usage}{ -\if{html}{\out{<div class="r">}}\preformatted{OGS6$add_component(x)}\if{html}{\out{</div>}} +\if{html}{\out{<div class="r">}}\preformatted{OGS6$add(x, component_name = "")}\if{html}{\out{</div>}} } \subsection{Arguments}{ \if{html}{\out{<div class="arguments">}} \describe{ -\item{\code{x}}{OGS6_*: An object of a class listed in get_implemented_classes()} +\item{\code{x}}{An object of any class listed in addable_components(). If `x` is +not of a proprietary `r2ogs6` class, `component_name` must be +supplied. E.g. If you're adding a `python_script` which is a string, you +would call `your_ogs6_obj$add("some_script.py", "python_script")`} } \if{html}{\out{</div>}} } @@ -419,7 +422,7 @@ Prints logfile to console (if it exists) \subsection{Method \code{clear()}}{ Clears components from the OGS6 object \subsection{Usage}{ -\if{html}{\out{<div class="r">}}\preformatted{OGS6$clear(which = names(get_implemented_classes()))}\if{html}{\out{</div>}} +\if{html}{\out{<div class="r">}}\preformatted{OGS6$clear(which = names(addable_prj_components()))}\if{html}{\out{</div>}} } \subsection{Arguments}{ @@ -427,7 +430,7 @@ Clears components from the OGS6 object \describe{ \item{\code{which}}{character: The names of the components (all by default). If you want to delete only some components, run -names(get_implemented_classes()) for the available options.} +names(addable_prj_components()) for the available options.} } \if{html}{\out{</div>}} } diff --git a/man/OGS6_vtu.Rd b/man/OGS6_vtu.Rd index ee7efcf47a5dc6c8216ec2069551ecf8d1888977..bbf865e33c74eccf40ac28dd6d09bd09ffd11187 100644 --- a/man/OGS6_vtu.Rd +++ b/man/OGS6_vtu.Rd @@ -35,6 +35,7 @@ Constructor for the OGS6_vtu base class \subsection{Public methods}{ \itemize{ \item \href{#method-new}{\code{OGS6_vtu$new()}} +\item \href{#method-get_data_arrays}{\code{OGS6_vtu$get_data_arrays()}} \item \href{#method-clone}{\code{OGS6_vtu$clone()}} } } @@ -76,6 +77,26 @@ Creates new OGS6_vtu object } } \if{html}{\out{<hr>}} +\if{html}{\out{<a id="method-get_data_arrays"></a>}} +\if{latex}{\out{\hypertarget{method-get_data_arrays}{}}} +\subsection{Method \code{get_data_arrays()}}{ +Gets specified DataArrays +\subsection{Usage}{ +\if{html}{\out{<div class="r">}}\preformatted{OGS6_vtu$get_data_arrays(Names = character(), categories = character())}\if{html}{\out{</div>}} +} + +\subsection{Arguments}{ +\if{html}{\out{<div class="arguments">}} +\describe{ +\item{\code{Names}}{character: Optional: Select `DataArray` by `Name`} + +\item{\code{categories}}{character: Optional: One or more of +`get_valid_vtu_categories()`} +} +\if{html}{\out{</div>}} +} +} +\if{html}{\out{<hr>}} \if{html}{\out{<a id="method-clone"></a>}} \if{latex}{\out{\hypertarget{method-clone}{}}} \subsection{Method \code{clone()}}{ diff --git a/man/addable_prj_components.Rd b/man/addable_prj_components.Rd new file mode 100644 index 0000000000000000000000000000000000000000..7845a8084abc8c7b0b29f8027354335657292122 --- /dev/null +++ b/man/addable_prj_components.Rd @@ -0,0 +1,19 @@ +% Generated by roxygen2: do not edit by hand +% Please edit documentation in R/utils.R +\name{addable_prj_components} +\alias{addable_prj_components} +\title{addable_prj_components} +\usage{ +addable_prj_components() +} +\value{ +character: Named vector of `OGS6` top level .prj components (names) +along with their respective class names (values) +} +\description{ +Returns all possible `OGS6` top level .prj components (names) +along with their respective class names (values). +Change this if you implement new `OGS6` .prj components or delete old ones! +If you implement a new components, you add the following to the `class_names` +vector: `name_of_prj_component = "name_of_your_class"` +} diff --git a/man/coerce_string_to_numeric.Rd b/man/coerce_string_to_numeric.Rd index 93de4e7af61ab79f618363a0f33b9ebda6d60ad9..33eee9b5393e9b765525956cbf9ed89b9a6ec74b 100644 --- a/man/coerce_string_to_numeric.Rd +++ b/man/coerce_string_to_numeric.Rd @@ -4,21 +4,15 @@ \alias{coerce_string_to_numeric} \title{coerce_string_to_numeric} \usage{ -coerce_string_to_numeric(obj, split = FALSE) +coerce_string_to_numeric(obj) } \arguments{ \item{obj}{An object to check} - -\item{split}{flag: Should object be split at ' ' (whitespace) if it is a -string?} } \value{ The object as a numeric type (if 'obj' was a string, else the unchanged 'obj') } \description{ -If an object is of type string, coerces it to a numeric type: -A double if 'split' is FALSE as per default, a numeric vector otherwise. -If 'split' is set to true the string will be split at ' ' (whitespace) -characters. +If an object is of type string, coerces it to a numeric type } diff --git a/man/decode_appended_data.Rd b/man/decode_appended_data.Rd new file mode 100644 index 0000000000000000000000000000000000000000..5b47001344f6bab47aebcf8eb7100fb3bc505f3c --- /dev/null +++ b/man/decode_appended_data.Rd @@ -0,0 +1,20 @@ +% Generated by roxygen2: do not edit by hand +% Please edit documentation in R/read_in_vtu.R +\name{decode_appended_data} +\alias{decode_appended_data} +\title{decode_appended_data} +\usage{ +decode_appended_data(appended_data, compressor = "") +} +\arguments{ +\item{appended_data}{character: AppendedData} + +\item{compressor}{string: Optional: How the data was compressed, this is the +`compressor` attribute of *VTKFile*} +} +\value{ +list: DataArrays with `data` element which is the decoded data +} +\description{ +Decodes AppendedData +} diff --git a/man/generate_all_benchmark_scripts.Rd b/man/generate_all_benchmark_scripts.Rd index 0f1bf40d0e2d53e3d0beeb2f819b4620b4fb11cb..eebd7e23f3f0e1a626de9f0f3d94580c42222c2f 100644 --- a/man/generate_all_benchmark_scripts.Rd +++ b/man/generate_all_benchmark_scripts.Rd @@ -8,10 +8,10 @@ generate_all_benchmark_scripts( path, sim_path, scripts_path, - starting_from_prj_path = "", - skip_prj_paths = character(), + read_in_gmls, read_in_vtus = FALSE, - read_in_gmls = TRUE + starting_from_prj_path = "", + skip_prj_paths = character() ) } \arguments{ @@ -21,15 +21,15 @@ generate_all_benchmark_scripts( \item{scripts_path}{string: Path where benchmark scripts will be saved} -\item{starting_from_prj_path}{string: Optional:} - -\item{skip_prj_paths}{character: Optional: .prj paths to skip} +\item{read_in_gmls}{flag: Optional: Should .gml files just be copied or read +in too?} \item{read_in_vtus}{flag: Optional: Should .vtu files just be copied or read in too?} -\item{read_in_gmls}{flag: Optional: Should .gml files just be copied or read -in too?} +\item{starting_from_prj_path}{string: Optional:} + +\item{skip_prj_paths}{character: Optional: .prj paths to skip} } \description{ Wrapper function to generate benchmark scripts from all .prj diff --git a/man/generate_benchmark_script.Rd b/man/generate_benchmark_script.Rd index 03126b37ab49b07c25160bbde2c3fb99ce403b50..cdd5d1da7a9dae69389a23e3471d8d8c903ca81b 100644 --- a/man/generate_benchmark_script.Rd +++ b/man/generate_benchmark_script.Rd @@ -9,8 +9,8 @@ generate_benchmark_script( sim_path, ogs_bin_path, script_path, - read_in_vtu = FALSE, - read_in_gml = TRUE + read_in_gml, + read_in_vtu = FALSE ) } \arguments{ @@ -22,10 +22,10 @@ generate_benchmark_script( \item{script_path}{string: Path where benchmark script will be saved} -\item{read_in_vtu}{flag: Optional: Should .vtu file(s) just be copied or read +\item{read_in_gml}{flag: Optional: Should .gml file just be copied or read in too?} -\item{read_in_gml}{flag: Optional: Should .gml file just be copied or read +\item{read_in_vtu}{flag: Optional: Should .vtu file(s) just be copied or read in too?} } \description{ diff --git a/man/get_class_args.Rd b/man/get_class_args.Rd new file mode 100644 index 0000000000000000000000000000000000000000..82debcba03ce2a6143a6185d2aa0bd3cec85e3e3 --- /dev/null +++ b/man/get_class_args.Rd @@ -0,0 +1,17 @@ +% Generated by roxygen2: do not edit by hand +% Please edit documentation in R/read_in_utils.R +\name{get_class_args} +\alias{get_class_args} +\title{get_class_args} +\usage{ +get_class_args(class_name) +} +\arguments{ +\item{class_name}{string: The name of a class} +} +\value{ +character: Named vector of class arguments +} +\description{ +Gets class arguments +} diff --git a/man/get_valid_vtu_categories.Rd b/man/get_valid_vtu_categories.Rd new file mode 100644 index 0000000000000000000000000000000000000000..9cda3000f81068d1d14f0eb103ce5da8da2219c7 --- /dev/null +++ b/man/get_valid_vtu_categories.Rd @@ -0,0 +1,14 @@ +% Generated by roxygen2: do not edit by hand +% Please edit documentation in R/utils.R +\name{get_valid_vtu_categories} +\alias{get_valid_vtu_categories} +\title{get_valid_vtu_categories} +\usage{ +get_valid_vtu_categories() +} +\value{ +character: `OGS6_vtu` categories +} +\description{ +Returns all valid `OGS6_vtu` categories. +} diff --git a/man/get_vtu_data_arrays_from_file.Rd b/man/get_vtu_data_arrays_from_file.Rd new file mode 100644 index 0000000000000000000000000000000000000000..f812aaa72b0aa505b20057b61e024e57e0e8018a --- /dev/null +++ b/man/get_vtu_data_arrays_from_file.Rd @@ -0,0 +1,25 @@ +% Generated by roxygen2: do not edit by hand +% Please edit documentation in R/read_in_vtu.R +\name{get_vtu_data_arrays_from_file} +\alias{get_vtu_data_arrays_from_file} +\title{get_vtu_data_arrays_from_file} +\usage{ +get_vtu_data_arrays_from_file( + vtu_path, + Names = character(), + categories = character() +) +} +\arguments{ +\item{vtu_path}{string: .vtu file path} + +\item{Names}{character: Optional: Select `DataArray` elements by `Name` +attribute} + +\item{categories}{character: Optional: One or more of `FieldData`, `PointData`, +`CellData`, `Points` or `Cells`. If left empty, will get `DataArray` +elements from whole XML document.} +} +\description{ +Reads DataArray elements from a .vtu file +} diff --git a/man/node_to_object.Rd b/man/node_to_object.Rd new file mode 100644 index 0000000000000000000000000000000000000000..4538056132c74cb2854adc02ba40363db39531fd --- /dev/null +++ b/man/node_to_object.Rd @@ -0,0 +1,29 @@ +% Generated by roxygen2: do not edit by hand +% Please edit documentation in R/read_in_utils.R +\name{node_to_object} +\alias{node_to_object} +\title{node_to_object} +\usage{ +node_to_object(xml_node, xpath_expr = "", subclasses_names = character()) +} +\arguments{ +\item{xml_node}{xml2::xml_node: XML node} + +\item{xpath_expr}{string: Optional: XPath expression (for subclass +differentiation)} + +\item{subclasses_names}{character: Optional: Names of `r2ogs6` subclasses +(`r2ogs6` classes without a OGS6$add method)} +} +\description{ +Returns representation of an XML node. This is a recursive +function. +ASSUMPTIONS: +1) Leaf nodes will never be r2ogs6_* objects +2) If there are multiple occurrences of r2ogs6_* class (and subclass) +elements on the same level, they have a wrapper node as their parent +(e.g. <processes>, <properties>) which will contain ONLY elements of this +type +3) Wrapper nodes are represented as lists +4) Parent nodes whose children have no children are represented as lists +} diff --git a/man/node_to_r2ogs6_class_object.Rd b/man/node_to_r2ogs6_class_object.Rd new file mode 100644 index 0000000000000000000000000000000000000000..51a782e6b3ab414ba0867dc8da1a26c8a6fc9384 --- /dev/null +++ b/man/node_to_r2ogs6_class_object.Rd @@ -0,0 +1,23 @@ +% Generated by roxygen2: do not edit by hand +% Please edit documentation in R/read_in_utils.R +\name{node_to_r2ogs6_class_object} +\alias{node_to_r2ogs6_class_object} +\title{node_to_r2ogs6_class_object} +\usage{ +node_to_r2ogs6_class_object( + xml_node, + xpath_expr, + subclasses_names = character() +) +} +\arguments{ +\item{xml_node}{xml2::xml_node: XML node} + +\item{xpath_expr}{string: XPath expression (for subclass differentiation)} + +\item{subclasses_names}{character: Optional: Names of r2ogs6 subclasses +(r2ogs6 classes without a method for input_add)} +} +\description{ +Takes an XML node and turns it into a class object +} diff --git a/man/order_parameters.Rd b/man/order_parameters.Rd index e6fb230a414295addb332e3f86672444064814fd..8d18945c48dc4266482d8e82045c9c0488830a50 100644 --- a/man/order_parameters.Rd +++ b/man/order_parameters.Rd @@ -11,6 +11,9 @@ order_parameters(parameters, class_name) \item{class_name}{string: The name of a class} } +\value{ +list: Parameters ordered by argument order of class +} \description{ Orders a list of parameters corresponding to the argument order of a class diff --git a/man/r2ogs6_phase.Rd b/man/r2ogs6_phase.Rd index a88c61c309daf80f26c1bb0f53fe7ff021ae0393..af754f8466ad5a54c5dd582b4dca491af49e4672 100644 --- a/man/r2ogs6_phase.Rd +++ b/man/r2ogs6_phase.Rd @@ -4,7 +4,7 @@ \alias{r2ogs6_phase} \title{r2ogs6_phase} \usage{ -r2ogs6_phase(type, properties, components = NULL) +r2ogs6_phase(type, properties = NULL, components = NULL) } \arguments{ \item{type}{string: Phase type diff --git a/man/r2ogs6_pr_property.Rd b/man/r2ogs6_pr_property.Rd index 285a52ddeb88b307efc7d6f22c7b6de667bcd4d0..5028f3fbf977565b610e7b2b3ba8c9c6ae21e916 100644 --- a/man/r2ogs6_pr_property.Rd +++ b/man/r2ogs6_pr_property.Rd @@ -16,67 +16,97 @@ r2ogs6_pr_property( independent_variable = NULL, curve = NULL, minimum_relative_permeability_liquid = NULL, + initial_permeability = NULL, + maximum_permeability = NULL, lambda = NULL, cutoff_value = NULL, - initial_permeability = NULL, + intrinsic_permeability = NULL, + initial_aperture = NULL, + mean_frac_distance = NULL, + threshold_strain = NULL, + fracture_normal = NULL, reference_permeability = NULL, fitting_factor = NULL, cohesion = NULL, friction_angle = NULL, - maximum_permeability = NULL, tensile_strength_parameter = NULL, + b1 = NULL, + b2 = NULL, + b3 = NULL, + minimum_permeability = NULL, + initial_porosity = NULL, entry_pressure = NULL, min_relative_permeability_liquid = NULL, min_relative_permeability_gas = NULL ) } \arguments{ -\item{name}{string: Property name} +\item{name}{string:} -\item{type}{string: Property type} +\item{type}{string:} -\item{value}{Optional: string | double: ...} +\item{value}{Optional:} -\item{parameter_name}{Optional: string:} +\item{parameter_name}{Optional:} -\item{exponent}{Optional: string | double:} +\item{exponent}{Optional:} -\item{residual_liquid_saturation}{Optional: string | double:} +\item{residual_liquid_saturation}{Optional:} -\item{residual_gas_saturation}{Optional: string | double:} +\item{residual_gas_saturation}{Optional:} -\item{p_b}{Optional: string | double: string | double:} +\item{p_b}{Optional:} -\item{independent_variable}{Optional: string} +\item{independent_variable}{Optional:} -\item{curve}{Optional: string:} +\item{curve}{Optional:} \item{minimum_relative_permeability_liquid}{Optional:} -\item{lambda}{Optional: string | double:} +\item{initial_permeability}{Optional:} + +\item{maximum_permeability}{Optional:} + +\item{lambda}{Optional:} + +\item{cutoff_value}{Optional:} + +\item{intrinsic_permeability}{Optional:} + +\item{initial_aperture}{Optional:} + +\item{mean_frac_distance}{Optional:} + +\item{threshold_strain}{Optional:} + +\item{fracture_normal}{Optional:} + +\item{reference_permeability}{Optional:} + +\item{fitting_factor}{Optional:} -\item{cutoff_value}{Optional: string | double:} +\item{cohesion}{Optional:} -\item{initial_permeability}{Optional: string:} +\item{friction_angle}{Optional:} -\item{reference_permeability}{Optional: string | double:} +\item{tensile_strength_parameter}{Optional:} -\item{fitting_factor}{Optional: string | double:} +\item{b1}{Optional:} -\item{cohesion}{Optional: string | double:} +\item{b2}{Optional:} -\item{friction_angle}{Optional: string | double:} +\item{b3}{Optional:} -\item{maximum_permeability}{Optional: string | double:} +\item{minimum_permeability}{Optional:} -\item{tensile_strength_parameter}{Optional: string | double:} +\item{initial_porosity}{Optional:} -\item{entry_pressure}{Optional: string | double:} +\item{entry_pressure}{Optional:} -\item{min_relative_permeability_liquid}{Optional: string | double:} +\item{min_relative_permeability_liquid}{Optional:} -\item{min_relative_permeability_gas}{Optional: string | double:} +\item{min_relative_permeability_gas}{Optional:} } \description{ -tag: property, a constitutive property +tag: property } diff --git a/man/read_in_output.Rd b/man/read_in_output.Rd index e4f663791c31a988b9993cc039d846887bc63472..17d3f0ebd532fc01c3cf3b4ee686a5a1537fe50e 100644 --- a/man/read_in_output.Rd +++ b/man/read_in_output.Rd @@ -7,7 +7,7 @@ read_in_output(ogs6_obj) } \arguments{ -\item{ogs6_obj}{A OGS6 class object} +\item{ogs6_obj}{OGS6: Simulation object} } \description{ After a OGS6 simulation was run, reads in the generated .vtu diff --git a/man/read_in_prj.Rd b/man/read_in_prj.Rd index f4fb4f84d894718d8284d13545653bef0e98fe8a..9633b096ba25d56becfd350054d81a16a8f88822 100644 --- a/man/read_in_prj.Rd +++ b/man/read_in_prj.Rd @@ -4,16 +4,19 @@ \alias{read_in_prj} \title{read_in_prj} \usage{ -read_in_prj(ogs6_obj, prj_path, read_in_vtu = FALSE, read_in_gml = TRUE) +read_in_prj(ogs6_obj, prj_path, read_in_gml, read_in_vtu = FALSE) } \arguments{ \item{ogs6_obj}{OGS6: Simulation object} \item{prj_path}{string: Path to the project file that should be read in} -\item{read_in_vtu}{flag: Should .vtu file just be copied or read in too?} +\item{read_in_gml}{flag: Optional: Should .gml file just be copied or read in +too? If this parameter is missing and the .gml file contains <= the +number of lines in `options("r2ogs6.max_lines_gml")`, the .gml will be read +in. Else, only the geometry reference will be saved.} -\item{read_in_gml}{flag: Should .gml file just be copied or read in too?} +\item{read_in_vtu}{flag: Should .vtu file just be copied or read in too?} } \description{ Wrapper function to read in a whole .prj file diff --git a/man/read_in_pvd.Rd b/man/read_in_pvd.Rd new file mode 100644 index 0000000000000000000000000000000000000000..4f17da094a440227d827623d3125b183914a8d32 --- /dev/null +++ b/man/read_in_pvd.Rd @@ -0,0 +1,17 @@ +% Generated by roxygen2: do not edit by hand +% Please edit documentation in R/read_in_vtu.R +\name{read_in_pvd} +\alias{read_in_pvd} +\title{read_in_pvd} +\usage{ +read_in_pvd(pvd_path) +} +\arguments{ +\item{pvd_path}{string: Path to .pvd file that should be read in} +} +\value{ +character: Vector containing .vtu paths +} +\description{ +Function to read in a .pvd file +} diff --git a/man/read_in_vtu.Rd b/man/read_in_vtu.Rd index 929b7bd4433b04a5b97fdd8798c321aa59d9da08..1f2df677e1ac09aec76a07ff14035915c830c21a 100644 --- a/man/read_in_vtu.Rd +++ b/man/read_in_vtu.Rd @@ -13,5 +13,6 @@ read_in_vtu(vtu_path) OGS6_vtu: Mesh object } \description{ -Wrapper function to read in a whole .vtu file +Wrapper function to read in a whole .vtu file as a OGS6_vtu +class object }