water <- define_water(ph = 7, temp = 25, alk = 100, toc = 3.7, doc = 3.5, uv254 = .1)
dosed_water <- chemdose_ph(water, alum = 30) %>%
chemdose_toc(alum = 30, coeff = "Alum")
dosed_water <- chemdose_ph(water, alum = 10, h2so4 = 10) %>%
chemdose_toc(alum = 10, coeff = data.frame(
x1 = 280, x2 = -73.9, x3 = 4.96, k1 = -0.028, k2 = 0.23, b = 0.068
))
# \donttest{
example_df <- water_df %>%
define_water_chain() %>%
dplyr::mutate(FerricDose = seq(1, 12, 1)) %>%
chemdose_toc_chain(ferricchloride = FerricDose, coeff = "Ferric")
# Uncomment below to initialize parallel processing
# library(furrr)
# plan(multisession)
example_df <- water_df %>%
define_water_chain() %>%
dplyr::mutate(ferricchloride = seq(1, 12, 1)) %>%
chemdose_toc_chain(coeff = "Ferric")
# Optional: explicitly close multisession processing
# plan(sequential)
# }
# \donttest{
example_df <- water_df %>%
define_water_chain() %>%
chemdose_toc_once(input_water = "defined_water", alum = 30)
# }
Run the code above in your browser using DataLab