Version: | 0.1.1 |
Type: | Package |
Date: | 2020-6-05 |
Title: | Treatment of Membrane-Transport Data |
Author: | Cristhian Paredes [aut, cre], Eduardo Rodríguez de San Miguel [aut] |
Maintainer: | Cristhian Paredes <craparedesca@unal.edu.co> |
Description: | Treatment and visualization of membrane (selective) transport data. Transport profiles involving up to three species are produced as publication-ready plots and several membrane performance parameters (e.g. separation factors as defined in Koros et al. (1996) <doi:10.1351/pac199668071479> and non-linear regression parameters for the equations described in Rodriguez de San Miguel et al. (2014) <doi:10.1016/j.jhazmat.2014.03.052>) can be obtained. Many widely used experimental setups (e.g. membrane physical aging) can be easily studied through the package's graphical representations. |
License: | GPL-2 | GPL-3 [expanded from: GPL (≥ 2)] |
URL: | https://CRAN.R-project.org/package=transmem |
BugReports: | https://github.com/Crparedes/transmem/issues |
Encoding: | UTF-8 |
LazyData: | true |
RoxygenNote: | 7.0.2.9000 |
Depends: | R (≥ 3.5.0) |
Imports: | cmna, ggformula, ggplot2, plot3D |
Suggests: | knitr, rmarkdown |
NeedsCompilation: | no |
Packaged: | 2020-06-05 05:24:26 UTC; cris |
Repository: | CRAN |
Date/Publication: | 2020-06-05 10:10:02 UTC |
transmem: Treatment of membrane-transport data.
Description
Treatment and visualization of membrane (selective) transport data. Transport profiles involving up to three species are produced as publication-ready plots and several membrane performance parameters (e.g. separation factors as defined in Koros et al. (1996) <doi:10.1351/pac199668071479> and non-linear regression parameters for the equations described in Rodriguez de San Miguel et al. (2014) <doi:10.1016/j.jhazmat.2014.03.052>) can be obtained. Many widely used experimental setups (e.g. membrane physical aging) can be easily studied through the package's graphical representations.
Author(s)
Cristhian Paredes, craparedesca@unal.edu.co
Eduardo Rodriguez de San Miguel, erdsmg@unam.mx
References
C. Paredes, E. Rodriguez de San Miguel, Polymer inclusion membrane for the recovery and concentration of lithium from seawater. Master thesis, Universidad Nacional Autónoma de México, México City, México, 2020.
Calculates regression curve for external standard calibration.
Description
Polinomial regression curves for external standard calibration are calculated to later convert signals into concentration values.
Usage
calibCurve(curve, order = 1, badpoint = NULL, intercept = TRUE, plot = TRUE)
Arguments
curve |
Data frame of numeric vectors named 'Conc' and 'Signal' containing the concentrations and the signals, respectively. |
order |
Regression curve order. 1 for linear (default) and 2 for quadratic. |
badpoint |
Numeric vector with the points to be ignored in the regresion. This allows the easy elimination of outliers without losing the stored measurement information. |
intercept |
Logical. If |
plot |
Logical. If |
Details
A linear method (i.e lm()
) is applied to obtain the
regression curve.
Value
Model of the calibration curve.
Author(s)
Cristhian Paredes, craparedesca@unal.edu.co
Eduardo Rodriguez de San Miguel, erdsmg@unam.mx
See Also
calibPlane
when using more than one explanatory
variable.
Examples
data(curvelithium)
model1 <- calibCurve(curve = curvelithium, order = 1)
model2 <- calibCurve(curve = curvelithium, order = 2)
summary(model1)
summary(model2)
Calculates regression plane for external standard calibration.
Description
A bivariated regression plane for external standard calibration is
calculated to later convert signals into concentration values.
It differs from calibCurve
in the number of explanatory
variables, 2 in this case. This function is useful when some
interference effect is being considered such as the magnification of
the interest species signal due to the presence of another (known) species
in the same sample.
Usage
calibPlane(plane, badpoint = NULL, plot = TRUE, lines = 13, theta = -30,
phi = 40, xlab = "Species 1", ylab = "Species 2", zlab = "Signal",
pch = 18, cex = 2)
Arguments
plane |
Data frame of numeric vectors named 'Conc', 'Conc.S' and 'Signal'. The vectors must contain the concentrations of the main species (the one whose concentration in the samples is to be known) and the secondary species (the interferent), and the standard's signals, respectively. |
badpoint |
Numeric vector with the points to be ignored in the regresion. This allows the easy elimination of outliers without losing the stored measurement information. |
plot |
Logical. If |
lines |
Number of lines to use in the mesh of the plane in the plot. |
theta |
Azimuthal angle at which the plane is visualized. |
phi |
Altitude angle at which the plane is visualized. |
xlab |
Label for X axis (main species concentration). |
ylab |
Label for Y axis (secondary species concentration). |
zlab |
Label for Z axis (response). |
pch |
Plotting symbols available in R. |
cex |
The size of pch symbols. |
Details
A linear method (i.e lm()
) is applied to obtain the
regression equation. The user must verify model assumptions
such as normal distribution of residuals.
Value
Model of the calibration plane
Author(s)
Cristhian Paredes, craparedesca@unal.edu.co
Eduardo Rodriguez de San Miguel, erdsmg@unam.mx
Examples
data(planelithium)
planeModel <- calibPlane(plane = planelithium)
summary(planeModel$model)
Creates a data frame as a complete self-contained transport data set
Description
The function transforms the data contained in concentration vectors of feed and strip phases to a data frame that contains the complete data of a transport process. This new data frame can be used by several functions inside the package. The output data frame may contain normalized fractions remaining in the feed and already transported to the strip phase, or the original data provided in concentration units.
Usage
conc2frac(feed, strip, time = NULL, correct.strip = FALSE, normalize = TRUE)
Arguments
feed |
Numeric vector with concentrations in the feed phase. |
strip |
Numeric vector with concentrations in the strip phase. |
time |
Numeric vector with time at which the aliquots were sampled. It is an optional parameter. If not provided, regular unitary time intervals are assumed. |
correct.strip |
Logical. If |
normalize |
Logical. If |
Details
The change in concentration of species in the feed and strip phases as a function of time are the main magnitudes being measured in processes involving transport across membranes. The best form to deal with such data is inside a dataframe containing the information about the concentration of given species in both phases and the time transcurred.
Usually, this function is required after using signal2conc
wich convert instrumental signals to concentrations.
Value
Data frame with the transport proccess information
Author(s)
Cristhian Paredes, craparedesca@unal.edu.co
Eduardo Rodriguez de San Miguel, erdsmg@unam.mx
Examples
transData <- conc2frac(feed = c(0.200, 0.169, 0.152, 0.141, 0.138),
strip = c(0.000, 0.035, 0.045, 0.062, 0.069),
time = c(0, 2, 4, 6, 8))
print(transData)
Lithium concentration results using a membrane
Description
A list of 5 datasets, each of one with the transport data of each cycle in a concentration experiment of lithium using a polymer inclusion membrane.
Usage
concentrationcycles
Format
A list of 5 data frames with 10 rows and 3 variables:
- Time
Time in hours of each aliquot taken during the experiment
- Phase
Phase of corresponding aliquot, Feed or Strip
- Fraction
Remaining lithium concentration in the feed solution or transported lithium concentration to the strip solution
Source
Paredes, C. and Rodríguez de San Miguel, E., Selective lithium extraction and concentration from diluted alkaline aqueous media by a polymer inclusion membrane and application to seawater, Desalination, Volume 487, 2020, 114500, https://doi.org/10.1016/j.desal.2020.114500.
External standard calibration curve for lithium in water.
Description
A dataset containing the concentrations and emission signals of aqueous lithium standards measured by Flame Atomic Emission Spectrometry (FAES) at a Perkin-Elmer 3100 Atomic Absorption Spectrometer.
Usage
curvelithium
Format
A data frame with 8 rows and 2 variables:
- Conc
lithium concentration in the standards, in mg/kg
- Signal
emission signal of lithium at 670.8 nm, in arbitrary units
Source
Paredes, C. and Rodríguez de San Miguel, E., Selective lithium extraction and concentration from diluted alkaline aqueous media by a polymer inclusion membrane and application to seawater, Desalination, Volume 487, 2020, 114500, https://doi.org/10.1016/j.desal.2020.114500.
Plots transport profiles for processes involving several cycles
Description
Given the data (data frames) of a transport process that was carried in several cycles (e.g. membrane reuse or metal concentration studies), plots the transport profiles like in a continuous experiment indicating the end of each cycle
Usage
cyclesPlot(trans, xlab = "Time (h)", ylab = expression(Phi), xlim = NULL,
ylim = NULL, xbreaks = NULL, ybreaks = NULL, size = 1.8,
legend = FALSE)
Arguments
trans |
List containing the (ordered) transport data of each cycle.
Each data frame must be generated using
|
xlab |
Label to be used for x axis. Text and expression allowed. |
ylab |
Label to be used for y axis. Text and expression allowed. |
xlim |
Numeric vector of limits for X-axis. |
ylim |
Numeric vector of limits for X-axis. |
xbreaks |
Numeric vector of x-axis breaks. |
ybreaks |
Numeric vector of x-axis breaks. |
size |
Size used for points in the plot. |
legend |
Logical. If |
Details
If a concentration experiment has been made through the cycles, it is
recommended the y-axis to be in concentration scale instead of fractions.
To get the transport data frame in concentration units use
conc2frac(..., normalize = FALSE)
. For more details see
conc2frac
.
Most transmem
graphical representations are made using the package
ggplot2
so the function returns a ggplot2 object that can be
assigned to a variable for further modification.
Value
Plot of the transport process carried in several cycles
Author(s)
Cristhian Paredes, craparedesca@unal.edu.co
Eduardo Rodriguez de San Miguel, erdsmg@unam.mx
References
Wickham H (2016). ggplot2: Elegant Graphics for Data Analysis. Springer-Verlag New York. ISBN 978-3-319-24277-4, https://ggplot2.tidyverse.org.
Interpolates secondary species concentration at missing time values
Description
If the secondary species concentration is determined in just a fraction of the aliquots and for some reason, the concentration in all the aliquots is required or desired, the function fits a polynomial trend line to the existing data and interpolates the concentration in missing aliquots.
Usage
fixSecondary(conc, time, compTime, order = 2)
Arguments
conc |
Species concentration original vector. |
time |
Times at which given concentrations were determined. |
compTime |
Times at which the given species concentration must be interpolated. |
order |
Order of the polynomial to be fitted to data (1 or 2). Default to 2. |
Value
Vector of interpolated concentrations at times provided in
compTime
.
Author(s)
Cristhian Paredes, craparedesca@unal.edu.co
Eduardo Rodriguez de San Miguel, erdsmg@unam.mx
Plots several single-phase transport profiles overlayed
Description
Given a list of several complete transport data, the function overlays the transport profiles in a defined phase. The function is useful in membrane reuse experiments as transport profile deterioration is easily visualized.
Usage
multiPlotSP(trans, phase = "strip", trend = NULL, legend = FALSE,
xlab = "Time (h)", ylab = expression(Phi), xlim = NULL, ylim = NULL,
xbreaks = NULL, ybreaks = NULL, size = 3, plot = TRUE, shape = 15,
bw = FALSE, arw = FALSE, arw.pos = NULL, arw.txt = NULL,
txt.pos = NULL, txt.size = NULL)
Arguments
trans |
List of data frames with the complete transport
information of interest species. Must be generated
using |
phase |
Phase to be represented in the plot: |
trend |
List of Non-linear regression models of the main species
transport profil. Generated using |
legend |
Logical. If |
xlab |
Label to be used for x axis. Text and expression allowed. |
ylab |
Label to be used for y axis. Text and expression allowed. |
xlim |
Numeric vector of limits for X-axis. |
ylim |
Numeric vector of limits for X-axis. |
xbreaks |
Numeric vector of x-axis breaks. |
ybreaks |
Numeric vector of x-axis breaks. |
size |
Size used for points in the plot. |
plot |
Logical. If |
shape |
Shape to use in the points to be plotted. |
bw |
Logical, if |
arw |
Logical default to |
arw.pos |
Numeric vector of the coordinates of the arrow if
|
arw.txt |
Text to be (optionally) printed alongside the arrow. |
txt.pos |
Numeric vector of the position of the center of the text
provided in |
txt.size |
Size of the text accompanying the arrow. |
Details
Most transmem
graphical representations are made using the package
ggplot2
so the function returns a ggplot2 object that can be
assigned to a variable for further modification.
Value
Plot with the overlayed transport profiles for a single phase
Author(s)
Cristhian Paredes, craparedesca@unal.edu.co
Eduardo Rodriguez de San Miguel, erdsmg@unam.mx
Examples
data(reusecycles)
# First step is to get trend lines for each cycle:
trend <- list()
for (i in 1:length(reusecycles)) {
trend[[i]] <- transTrend(trans = reusecycles[[i]])
}
# Default plot using colors:
multiPlotSP(trans = reusecycles, trend = trend, legend = TRUE)
# Black and white plot including an arrow:
multiPlotSP(trans = reusecycles, trend = trend, legend = TRUE, bw = TRUE,
arw = TRUE, arw.pos = c(6.1, 6.1, 0.8, 0.6),
arw.txt = 'Cycle', txt.pos = c(6.15, 0.7))
Calculates permeability coefficients
Description
Permeability coefficients across a membrane as derived from integrated Fick's law can be obtained from transport data according to the equation
\ln{\Bigg(\frac{C}{C^0}\Bigg)}=
-\frac{P~a}{V}t
where P
is the permeability coefficient, a
is
the membrane exposed area, C
and C^0
are
the species concentrations at any time and at initial time in the feed phase,
respectively, and V
is solution volume.
Usage
permcoef(trans, vol, area, units = c("cm^3", "cm^2", "h"), conc0 = NULL,
plot = FALSE)
Arguments
trans |
Data frame with the complete transport information of
interest species. Must be generated using
|
vol |
Volume of the feed solution. |
area |
Membrane exposed area to the feed solution. |
units |
Units in which volume, area and time are provided. Volume
and area are function's parameters while the time is
extracted from the |
conc0 |
Initial concentration of the species in the feed solution. The
value may be extracted from transport information if the data
frame provided in |
plot |
logical default to |
Details
Species concentration units may be arbitrary as long as the permeability coefficient is calculated using the change in concentration ratio which is, as most ratios, adimensional
Value
A numeric vector with the permeability coefficient and it's standard uncertainty from the regression. Units are meters per second.
Author(s)
Cristhian Paredes, craparedesca@unal.edu.co
Eduardo Rodriguez de San Miguel, erdsmg@unam.mx
Bivariated calibration plane for lithium in prescence of sodium.
Description
A dataset containing the concentrations of lithium and sodium combined standards and absorbance signals measured by Flame Atomic Absorption Spectrometry (FAAS) at a Perkin-Elmer 3100 Atomic Absorption Spectrometer.
Usage
planelithium
Format
A data frame with 40 rows and 3 variables:
- Conc
lithium concentration in the standards, in mg/kg
- Signal
absorbance signal of lithium at 670.8 nm, in absorbance units
- Conc.S
sodium concentration in the standards, in mg/kg
Source
Paredes, C. and Rodríguez de San Miguel, E., Selective lithium extraction and concentration from diluted alkaline aqueous media by a polymer inclusion membrane and application to seawater, Desalination, Volume 487, 2020, 114500, https://doi.org/10.1016/j.desal.2020.114500.
Membrane reuse capability to transport lithium
Description
A list of 10 datasets, each of one with the transport data of each cycle in a reuse capability experiment of a polimeric inclusion membrane selective to lithium ions.
Usage
reusecycles
Format
A list of 10 data frames with 10 rows and 3 variables:
- Time
Time in hours of each aliquot taken during the cycle
- Phase
Phase of corresponding aliquot, Feed or Strip
- Fraction
Remaining lithium fraction in the feed solution or transported lithium fraction to the strip solution
Source
Paredes, C. and Rodríguez de San Miguel, E., Selective lithium extraction and concentration from diluted alkaline aqueous media by a polymer inclusion membrane and application to seawater, Desalination, Volume 487, 2020, 114500, https://doi.org/10.1016/j.desal.2020.114500.
Lithium, sodium and potassium transport profiles across a membrane
Description
A list of 6 datasets containing by duplicate the transport profiles for lithium, sodium, and potassium from a synthetic simplified seawater matrix using a polymer inclusion membrane selective to lithium. Lithium samples were taken every 45 minutes during 4.5 hours while sodium and potassium determinations were made in samples taken every 1.5 hours.
Usage
seawaterLiNaK
Format
A list of 6 data frames (two for each lithium, sodium, and potassium) with 14 or 8 rows and 3 variables:
- Time
Time in hours of each aliquot taken during the experiment
- Phase
Phase of corresponding aliquot, Feed or Strip
- Fraction
Remaining lithium concentration in the feed solution or transported lithium concentration to the strip solution
Source
Paredes, C. and Rodríguez de San Miguel, E., Selective lithium extraction and concentration from diluted alkaline aqueous media by a polymer inclusion membrane and application to seawater, Desalination, Volume 487, 2020, 114500, https://doi.org/10.1016/j.desal.2020.114500.
Calculates separation factors between two transported species
Description
Given the transport data frames of two species, the function calculates
the separation factors of the main species A against a secondary species B
for each sample taken. If the dataset of secondary species is
smaller than that of the main species (e.g. if secondary species were
determined in only half the aliquots), the transport profile is completed
using fixSecondary
function and a message will be printed.
Usage
sepfactor(main, secon, order = 2, mode = "batch", plot = TRUE)
Arguments
main |
Main species transport data. Must be a data frame generated
using |
secon |
Undesired species transport data. Must be a data frame
generated using |
order |
Gives the polinomia order to be used if the secondary species information needs to be corrected due to missing data. |
mode |
Operation mode of the membranse system. Only |
plot |
Logical. If |
Details
Separation factor for batch systems at any time different from zero is defined as
SF_{A/B}(t)=\frac{C_a/C_b}{C_a^0/C_b^0}
where C_a
and C_b
are the concentrations of A and B, respectively, in the
strip solution at a time t
, and C_a^0
and C_b^0
are
the concentrations of A and B, respectively, in the feed phase at
t=0
(Chen et al., 2018).
For continuous or semicontinuous systems, the separation factor is calculated according to the equation
SF_{A/B}(t)\frac{C_{a,~s}/C_{b,~s}}{C_{a,~f}/C_{b,~f}}
where
C_{a,~s}
, C_{b,~s}
are A and B concentrations in the
strip phase at a time t
and C_{a,~f}
, C_{b,~f}
are
the concentrations of A and B in the feed solution at a time t
(Koros and Shimidzu, 1996). Separation factor at t=0
equals 1
indicating that no species separation has occurred yet.
Value
Data frame with two variables: Time in the same units as provided data and SF with the separation factors at each time.
Author(s)
Cristhian Paredes, craparedesca@unal.edu.co
Eduardo Rodriguez de San Miguel, erdsmg@unam.mx
References
Q. B. Chen, Z. Y. Ji, J. Liu, Y. Y. Zhao, S. Z. Wang, J. S. Yuan, Development of recovering lithium from brines by selective-electrodialysis: Effect of coexisting cations on the migration of lithium, Journal of Membrane Science 548 (2018) 408-420. doi:10.1016/j.memsci.2017.11.040.505
J. Koros, H. Ma, T. Shimidzu, Terminology for membranes and membrane processes (iupac recommendations 1996), Pure and Applied Chemistry 68 (7) (1996) 1479-1489. doi:10.1351/pac199668071479.
Examples
data(seawaterLiNaK)
sepfactor(main = seawaterLiNaK$Lithium.1,
secon = seawaterLiNaK$Sodium.1)
sepfactor(main = seawaterLiNaK$Lithium.1,
secon = seawaterLiNaK$Potassium.1)
Converts signals into concentration by using given model.
Description
After a calibration model is established (either by using
calibCurve
or calibPlane
), the function
interpolates the signals of samples to get the associated concentrations.
Usage
signal2conc(signal, model, dilution = NULL, planar = FALSE, Conc.S = NULL)
Arguments
signal |
Numeric vector of signals to be interpolated. |
model |
Regression model of the calibration. Must be obtained
using |
dilution |
Numeric vector of dilution factors applied to samples before measurement |
planar |
Logical, default to |
Conc.S |
Numeric vector of the concentrations of the interferent
species to be considered when a planar calibration model is
provided to |
Value
Numeric vector of species concentrations.
Author(s)
Cristhian Paredes, craparedesca@unal.edu.co
Eduardo Rodriguez de San Miguel, erdsmg@unam.mx
Examples
# A regression model is needed:
data(curvelithium)
model <- calibCurve(curve = curvelithium, order = 2)
signal <- c(0.395, 0.259, 0.188, 0.141, 0.110, 0.095, 0.084)
(conc <- signal2conc(signal = signal, model = model))
Plots transport profiles of single run experiments
Description
Given the transport complete information of the interest species and,
optionally, secondary and tertiary species, the function plots transport
profiles including (if given) non-linear regression models that can be
obtained using transTrend
.
Usage
transPlot(trans, trend = NULL, secondary = NULL, tertiary = NULL,
sec.trend = "spline", lin.secon = FALSE, span = 0.75, legend = FALSE,
xlab = "Time (h)", ylab = expression(Phi), xlim = NULL, ylim = NULL,
xbreaks = NULL, ybreaks = NULL, size = 2.8, bw = FALSE, srs = NULL,
plot = TRUE)
Arguments
trans |
Data frame with the complete transport information of
interest species. Must be generated using
|
trend |
Non-linear regression model of the main transport profile
generated using |
secondary |
Secondary species transport data frame (see
|
tertiary |
Tertiaty species transport data frame (see
|
sec.trend |
Type of trend line to be used for secondary and tertiary
species data. Default is |
lin.secon |
Deprecated. Use |
span |
Amount of smoothing when |
legend |
Logical. If |
xlab |
Label to be used for x axis. Text and expression allowed. |
ylab |
Label to be used for y axis. Text and expression allowed. |
xlim |
Numeric vector of limits for X-axis. |
ylim |
Numeric vector of limits for X-axis. |
xbreaks |
Numeric vector of x-axis breaks. |
ybreaks |
Numeric vector of x-axis breaks. |
size |
Size used for points in the plot. |
bw |
Logical, if |
srs |
Deprecated. |
plot |
Logical. If |
Details
Most transmem
graphical representations are made using the package
ggplot2
so the function returns a ggplot2 object that can be
assigned to a variable for further modification.
This function has a version that uses replicated experiments and
may be useful to illustrate repeateability. For more information see
transPlotWR
.
Value
Plot of the transport profile considering all provided species.
Author(s)
Cristhian Paredes, craparedesca@unal.edu.co
Eduardo Rodriguez de San Miguel, erdsmg@unam.mx
References
Wickham H (2016). ggplot2: Elegant Graphics for Data Analysis. Springer-Verlag New York. ISBN 978-3-319-24277-4, https://ggplot2.tidyverse.org.
Examples
data(seawaterLiNaK)
trend <- transTrend(trans = seawaterLiNaK$Lithium.1, model = 'paredes')
transPlot(trans = seawaterLiNaK$Lithium.1, trend = trend,
secondary = seawaterLiNaK$Sodium.1,
tertiary = seawaterLiNaK$Potassium.1)
transPlot(trans = seawaterLiNaK$Lithium.1, trend = trend,
secondary = seawaterLiNaK$Sodium.1,
tertiary = seawaterLiNaK$Potassium.1, bw = TRUE)
Plots transport profiles of replicated experiments
Description
The function works the same way as transPlot
but requires
several experimental data sets that must be concatenated in lists.
This allows the process reproducibility to be evaluated in the analysis
of the results.
Usage
transPlotWR(trans, trend = NULL, secondary = NULL, tertiary = NULL,
legend = FALSE, xlab = "Time (h)", ylab = expression(Phi),
xlim = NULL, ylim = NULL, xbreaks = NULL, ybreaks = NULL,
lin.secon = FALSE, sec.trend = "spline", span = 0.75,
explicit = FALSE, size = 3, plot = TRUE, bw = FALSE, srs = NULL)
Arguments
trans |
List of data frames with the complete transport
information of interest species. Must be generated
using |
trend |
List of Non-linear regression models of the main species
transport profil. Generated using |
secondary |
List of secondary species transport data frame (see
|
tertiary |
List of tertiary species transport data frame (see
|
legend |
Logical. If |
xlab |
Label to be used for x axis. Text and expression allowed. |
ylab |
Label to be used for y axis. Text and expression allowed. |
xlim |
Numeric vector of limits for X-axis. |
ylim |
Numeric vector of limits for X-axis. |
xbreaks |
Numeric vector of x-axis breaks. |
ybreaks |
Numeric vector of x-axis breaks. |
lin.secon |
Deprecated. Use |
sec.trend |
Type of trend line to be used for secondary and tertiary
species data. Default is |
span |
Amount of smoothing when |
explicit |
Logical, if |
size |
Size used for points in the plot. |
plot |
Logical. If |
bw |
Logical, if |
srs |
Deprecated. |
Details
Most transmem
graphical representations are made using the package
ggplot2
so the function returns a ggplot2 object that can be
assigned to a variable for further modification.
Value
Plot of replicated transport profiles including all provided species
Author(s)
Cristhian Paredes, craparedesca@unal.edu.co
Eduardo Rodriguez de San Miguel, erdsmg@unam.mx
References
Wickham H (2016). ggplot2: Elegant Graphics for Data Analysis. Springer-Verlag New York. ISBN 978-3-319-24277-4, https://ggplot2.tidyverse.org.
Examples
data(seawaterLiNaK)
# Transport data frames and transport NLS regresions must be in lists
lithium <- list(seawaterLiNaK$Lithium.1, seawaterLiNaK$Lithium.2)
sodium <- list(seawaterLiNaK$Sodium.1, seawaterLiNaK$Sodium.2)
potassium <- list(seawaterLiNaK$Potassium.1, seawaterLiNaK$Potassium.2)
trend <- list(transTrend(trans = seawaterLiNaK$Lithium.1),
transTrend(trans = seawaterLiNaK$Lithium.2))
transPlotWR(trans = lithium, trend = trend, secondary = sodium,
tertiary = potassium, bw = TRUE)
Fits trend equations that model transport profiles
Description
Given a transport profile dataset, the results may be studied and compared in terms of empirical functions that describe the transport process in terms of regression parameters that can be asociated with the performance of the membrane system. The parameters are obtained by non-linear regression and are independent for each solution at both sides of the membrane. This is particularly useful when performing system optimizations since the parameters can be used as response variables depending on the optimization goal.
Usage
transTrend(trans, model = "paredes", eccen = 1)
Arguments
trans |
Data frame with the complete transport information of
interest species. Must be generated using
|
model |
Model to be used in the regression. Default to
|
eccen |
Eccentricity factor ( |
Details
Two empirical equations have been implemented in the function. In the
'rodriguez'
model (Rodriguez de San Miguel et al., 2014), the
fractions (\Phi
) in feed or
strip phases as a function of time (t
) are fitted to
\Phi(t)=Ae^{-t/d}+y_0
where A
, d
and y_0
are the
parameters to be found. In this model, parameter d
determines the
steepness of the species concentration change in time, y_0
reflects
the limiting value to which the profiles tend to at long pertraction
times and A
is not supposed to play an important role in the
transport description. The parameters of each phase are summarized in
the functions G_{feed}
and G_{strip}
for the feed and
strip phases:
G_{feed}=\frac{1}{y_0d},\qquad G_{strip}=\frac{y_0}{d}
The bigger each G
function, the better the transport process.
In the 'paredes'
model (Paredes and Rodriguez de San Miguel, 2020),
the transported fractions to the strip solution and from the feed solution
are adjusted to the equations:
\Phi_s(t)=\frac{\alpha_s t^\gamma}{\beta_s^{-1}+t^\gamma}
\Phi_f(t)=1-\frac{\alpha_f t^\gamma}{\beta_f^{-1}+t^\gamma}
respectively. In those equations, adjustable parameters \alpha
and
\beta
relates the
maximum fraction transported at long pertraction times and the steepness
of the concentration change, respectively. \gamma
is an excentricity
factor to improve the adjustment and does not need to be changed for
systems under similar conditions. The subscripts s
and f
means strip and feed phases, respectively.
The later model has the disadvantage over the former that the equation
to use depends on the phase to be modeled but has the great advantage
that if no significant accumulation is presented in the membrane,
the parameters \alpha
and \beta
should be quite similar for
both phases and a consensus value can be obtained in various simple ways,
while the other model yields quite diferent parameters for each phase.
Paredes parameters are combined by using meta-analysis tools that consider
the associated uncertainty of each one due to lack of fit to get summarized,
lower-uncertainty results. Besides, once the \gamma
parameter
has been chosen, the later model uses only two parameters and while
comparing models with similar performance, the simpler the better.
Value
A list of 4 or 5 components (depending on the model chosen) with
the regression information for each phase, the eccentricity factor
(only in Paredes model), the name of the model used, and the
sumarized results of the regression: G_{feed}
and
G_{strip}
values for the Rodriguez model or summarized
\alpha
and \beta
parameters with asocciated uncertainty
for the Paredes model.
Author(s)
Cristhian Paredes, craparedesca@unal.edu.co
Eduardo Rodriguez de San Miguel, erdsmg@unam.mx
References
E. Rodriguez de San Miguel, X. Vital, J. de Gyves, Cr(vi) transport via a
sup ported ionic liquid membrane containing cyphos il101 as carrier:
System analysis and optimization through experimental design strategies,
Journal of Hazardous Materials 273 (2014) 253 - 262.
doi:10.1016/j.jhazmat.2014.03.052.
C. Paredes, E. Rodriguez de San Miguel, Polymer inclusion membrane for the recovery and concentration of lithium from seawater. Master thesis, Universidad Nacional Autónoma de México, México City, México, 2020.