rmt_create_tob creates an RMT3DMS tob object

rmt_create_tob(
  locations = NULL,
  time_series = NULL,
  btn,
  outnam = "output",
  save_binary = FALSE,
  cscale = 1,
  ioutcobs = TRUE,
  iconclog = FALSE,
  iconcintp = TRUE,
  mlayw = rmt_create_array(1, dim = c(btn$nrow, btn$ncol, btn$nlay)),
  fscale = 1,
  ioutflux = TRUE,
  fluxobs = NULL,
  fluxcells = NULL,
  unique_obsnam = FALSE,
  prj = RMODFLOW::rmf_get_prj(btn),
  inconcobs = 61,
  influxobs = 62,
  insaveobs = 63
)

Arguments

locations

data.frame or sf POINT object with the name, x and y coordinates (if data.frame), and top and bottom of the monitoring well filter

time_series

data.frame with the name of the monitoring well filter, icomp, weight and the observation time and concentration

btn

RMT3DMS btn object

outnam

character specifying the basename of the output files. Defaults to 'output'.

save_binary

logical specifying if the calculated concentrations and mass fluxes should be saved to an unformatted output file outnam.PST. Defaults to FALSE.

cscale

scaling factor for the observed concentrations. Defaults to 1.

ioutcobs

logical specifying if the residual errors between calculated and observed concentrations should be written to the output file. Defaults to TRUE.

iconclog

logical specifying if the calculated and observed concentrations should be converted to the common logarithm (log10) before computing statistics. Defaults to FALSE.

iconcintp

logical indicating if the calculated concentrations at observation locations should be interpolated (bilinear) from neighboring nodal points. Defaults to TRUE.

mlayw

3d array containing weights for the proportioning of multilayer concentration observations. Defaults to 1 for all cells.

fscale

scaling factor for the observed mass fluxes. Defaults to 1.

ioutflux

logical indicating if the residual errors between calculated and observed mass fluxes should be written to the output file. Defaults to TRUE.

fluxobs

data.frame with name, icomp, time, weight, flux, group & iss columns. The group specifies the FluxGroup which the observation is part of. iss specifies the sink/source type and should be unique for each group.

fluxcells

data.frame with k, i, j, factor and group columns. The group specifies the FluxGroup which the observation is part of and is used to link to corresponding groups in fluxobs.

unique_obsnam

logical; should an ID number be added to obsnam for filters with concentration observations at different times prefixed with an underscore? Defaults to FALSE.

prj

RMODFLOW prj object; provide if coordinates in locations are real world coordinates

inconcobs

integer specifying the unit number to save the OCN output file to when locations & time_series are defined. Defaults to 61.

influxobs

integer specifying the unit number to save the MFX output file to when fluxobs & fluxcells are defined. Defaults to 62.

insaveobs

integer specifying the unit number to save the binary PST output file to when locations & time_series and/or fluxobs & fluxcells are defined and when save_binary = TRUE. Defaults to 63.

The locations data.frame must have columns named name, x, y, top, bottom. Names should be unique. The time_series data.frame must have columns named name, icomp, weight, time, concentration.

The fluxobs data.frame must have columns named name, icomp, weight, time, flux, group, iss. The fluxcells data.frame must have columns named k, i, j, factor, group.

Value

Object of class tob

See also

Examples

btn <- rmt_create_btn() locations <- data.frame(x = c(766, 123), y = c(880, 245), top = -5, bottom = c(-6, -16), name = c('well.a', 'well.b')) time_series <- data.frame(time = c(1, 0.2, 1), icomp = 1, weight = 1, name = c('well.a', 'well.b', 'well.b'), concentration = c(25, 30, 35)) fluxobs <- data.frame(name = c('chd', 'riv', 'riv'), icomp = 1, time = c(-1, 0.5, 1), weight = 1, flux = c(500, -22.5, -33.2), group = c(1, 2, 2), iss = c(1, 4, 4)) fluxcells <- data.frame(k = 1, i = c(1, 10, 10, 10, 10), j = c(1, 7, 8, 9, 10), factor = 1, group = c(1, 2, 2, 2, 2)) rmt_create_tob(locations, time_series, btn, fluxobs = fluxobs, fluxcells = fluxcells, unique_obsnam = TRUE)
#> $maxconcobs #> [1] 3 #> #> $maxfluxobs #> [1] 3 #> #> $maxfluxcells #> [1] 5 #> #> $outnam #> [1] "output" #> #> $inconcobs #> [1] 61 #> #> $influxobs #> [1] 61 #> #> $insaveobs #> [1] 0 #> #> $nconcobs #> [1] 3 #> #> $cscale #> [1] 1 #> #> $ioutcobs #> [1] 1 #> #> $iconclog #> [1] 0 #> #> $iconcintp #> [1] 1 #> #> $concentrations #> cobsnam layer pr row column icomp timeobs roff coff weight cobs #> 1 well.a_1 1 1 2 8 1 1.0 -0.30 0.16 1 25 #> 2 well.b_1 1, 2 0.454545.... 8 2 1 0.2 0.05 -0.27 1 30 #> 3 well.b_2 1, 2 0.454545.... 8 2 1 1.0 0.05 -0.27 1 35 #> #> $nfluxgroup #> [1] 2 #> #> $fscale #> [1] 1 #> #> $ioutflux #> [1] 1 #> #> $nfluxtimeobs #> [1] 1 2 #> #> $ncells #> [1] 1 4 #> #> $isstype #> [1] 1 4 #> #> $fluxobs #> fobsnam icomp fluxtimeobs weight_fobs fluxobs group iss #> 1 chd_1 1 -1.0 1 500.0 1 1 #> 2 riv_1 1 0.5 1 -22.5 2 4 #> 3 riv_2 1 1.0 1 -33.2 2 4 #> #> $fluxcells #> k i j factor group #> 1 1 1 1 1 1 #> 2 1 10 7 1 2 #> 3 1 10 8 1 2 #> 4 1 10 9 1 2 #> 5 1 10 10 1 2 #> #> attr(,"class") #> [1] "tob" "rmt_package"