Grt-Opx-Pl-Qtz: Perkins, Chipera, 1985 <A>

Details

This sensor from TPF collection

Article
Collibration
Precision
Ranges
Renew sensors

Использовать Проверить

  • заголовок
  • краткое описание
  • статья
  • ссылка
  • карточка
  • подробное описание
  • код
  • тест

Source

source("utilities_tpf.r");

sensors.p.grt_opx_pl_qtz_perkins_chipera_1985_a <- function(Grt, Opx, Pl, Qtz, Temp, ...){
T <- Temp;
    Opx <- tpf.recalc_minaral("OPX",Opx);
    Pl <- tpf.recalc_minaral("PL",Pl);
    Grt <- tpf.recalc_minaral("GRT",Grt);

    A <- (1 - (Opx$Al_c4_pfu + Opx$Al_c6_pfu) / 2 - Opx$Ti_pfu - Opx$Cr_pfu - Opx$Fe_p3_pfu) * Opx$Mg_pfu;
    B <- (1 - Opx$Mn_pfu - Opx$Ca_pfu - Opx$Na_pfu) * Opx$Mg_pfu;
    C <- (1 - (Opx$Al_c4_pfu + Opx$Al_c6_pfu) / 2 - Opx$Ti_pfu - Opx$Cr_pfu - Opx$Fe_p3_pfu) * Opx$Fe_p2_pfu;
    D <- 1 - (Opx$Al_c4_pfu + Opx$Al_c6_pfu) / 2 - Opx$Ti_pfu - Opx$Cr_pfu - Opx$Fe_p3_pfu + 1 - Opx$Mn_pfu - Opx$Ca_pfu - Opx$Na_pfu;
    W <- (1 - Opx$Mn_pfu - Opx$Ca_pfu - Opx$Na_pfu) * Opx$Fe_p2_pfu;
    J <- Opx$Fe_p2_pfu / (Opx$Fe_p2_pfu + Opx$Mg_pfu);
    X <- Grt$Ca_pfu / (Grt$Ca_pfu + Grt$Mg_pfu + Grt$Fe_p3_pfu + Grt$Fe_p2_pfu + Grt$Mn_pfu);
    Y <- Grt$Mg_pfu / (Grt$Ca_pfu + Grt$Mg_pfu + Grt$Fe_p3_pfu + Grt$Fe_p2_pfu + Grt$Mn_pfu);
    E <- Grt$Mn_pfu / (Grt$Ca_pfu + Grt$Mg_pfu + Grt$Fe_p3_pfu + Grt$Fe_p2_pfu + Grt$Mn_pfu);
    F <- (Grt$Fe_p3_pfu + Grt$Fe_p2_pfu) / (Grt$Ca_pfu + Grt$Mg_pfu + Grt$Fe_p3_pfu + Grt$Fe_p2_pfu + Grt$Mn_pfu);
    Z <- Pl$Ca_pfu / (Pl$Ca_pfu + Pl$Na_pfu + Pl$K_pfu);
    G <- Pl$Na_pfu / (Pl$Ca_pfu + Pl$Na_pfu + Pl$K_pfu);
    K <- exp(X^2 * (1.52 - 5.17 * F) + Y^2 * (0.1 + 2.26 * F) +      X * Y * (0.4 - 1.45 * F + 1.5 * X - 1.5 * Y) + X * E * (0.23 - 2.58 * F) + Y * E * (0.66 + 1.13 * F));
    L <- exp(Y^2 * (1.24 - 3 * X) + F^2 * ( - 1.07 + 5.16 * X) +      Y * F * (0.05 + 1.08 * X + 1.13 * Y - 1.13 * F) + Y * E * ( - 0.99 - 1.5 * X) + F * E * (0.23 + 2.58 * X));
    M <- exp(F^2 * (1.23 - 2.26 * Y) + X^2 * ( - 0.26 + 3 * Y) + F * X *      (0.92 + 0.37 * Y + 2.53 * F - 2.53 * X) + F * E * (2.14 - 1.13 * Y) + E^2 * 1.48 + X * E * (1.96 + 1.5 * Y));
    H <- A * B / D / D;
    I <- C * W / D / D;
    S <- exp(G^2 * (1.009 + 4.62 * Z));
    K <- (K * F)^3;
    L <- (L * X)^3;
    M <- (M * Y)^3;
    S <- S * (Z * (1 + Z)^2) / 4;
    if (J<0.5) {
    P <- 6.1346 - 0.3471 * log(H^3 * S^3 / L / M^2) + 0.0136 * T - 0.00114 * T * log(H^3 * S^3 / L / M^2);
    }
    if (J>0.5) {
    warning(" CANNOT BE USED FOR FE/(FE+MG) IN OPX >0.5");
    }
    return(data.frame(Name=paste0(Pl$Name,"-", Grt$Name,"-", Opx$Name),Temp=Temp,P_calc=P));
}

sensors.p.grt_opx_pl_qtz_perkins_chipera_1985_a.args <- function(){
    ars <- list();
    ars$minerals <- c("Grt", "Opx", "Pl", "Qtz");
    ars$ranges <- c("Temp");
    return(ars);
}

#sensors.p.grt_opx_pl_qtz_perkins_chipera_1985_a.test <- function(){
#
#}
, , ,