This sensor from TPF collection
Article | |
---|---|
Collibration | |
Precision | |
Ranges | |
Renew sensors |
source("utilities_tpf.r"); sensors.p.grt_crd_sil_qtz_wells_1979_a <- function(Grt, Crd, Sil, Qtz, Temp, ...){ T <- Temp; Grt <- tpf.recalc_minaral("GRT",Grt); Crd <- tpf.recalc_minaral("CRD",Crd); X <- (Grt$Fe_p2_pfu + Grt$Fe_p3_pfu) / (Grt$Fe_p2_pfu + Grt$Fe_p3_pfu + Grt$Mg_pfu); Y <- (Crd$Fe_p2_pfu + Crd$Fe_p3_pfu) / (Crd$Fe_p2_pfu + Crd$Fe_p3_pfu + Crd$Mg_pfu); TT <- T + 273.15; P <- (1 + (21801 - 9.44 * TT - 6 * 1.98721 * TT * log(Y / X)) / 3.6481) / 1000; warning(" ONLY FE/(FE+MG) IN GRT AND CRD IS INVOLVED IN CALCULATIOS"); return(data.frame(Name=paste0(Crd$Name,"-", Grt$Name),Temp=Temp,P_calc=P)); } sensors.p.grt_crd_sil_qtz_wells_1979_a.args <- function(){ ars <- list(); ars$minerals <- c("Grt", "Crd", "Sil", "Qtz"); ars$ranges <- c("Temp"); return(ars); } #sensors.p.grt_crd_sil_qtz_wells_1979_a.test <- function(){ # #}