From a97110f8ef52df0d300342b7b7ae2df3a0f55da5 Mon Sep 17 00:00:00 2001
From: Peter Powers <pmpowers@usgs.gov>
Date: Tue, 10 Dec 2024 12:40:50 -0700
Subject: [PATCH] exposing ask14 nonlin sigma components

---
 .../nshmp/gmm/AbrahamsonEtAl_2014.java        | 23 +++++++++++++++----
 1 file changed, 18 insertions(+), 5 deletions(-)

diff --git a/src/main/java/gov/usgs/earthquake/nshmp/gmm/AbrahamsonEtAl_2014.java b/src/main/java/gov/usgs/earthquake/nshmp/gmm/AbrahamsonEtAl_2014.java
index e2f5ba9b..431dc1d6 100644
--- a/src/main/java/gov/usgs/earthquake/nshmp/gmm/AbrahamsonEtAl_2014.java
+++ b/src/main/java/gov/usgs/earthquake/nshmp/gmm/AbrahamsonEtAl_2014.java
@@ -81,6 +81,9 @@ public class AbrahamsonEtAl_2014 implements GroundMotionModel {
     COEFFS_PRVI = new CoefficientContainer("ASK14_PRVI.csv");
   }
 
+  static final double VS_RK = 1180.0;
+  static final double PHI_AMP_SQ = 0.16;
+
   private static final double A3 = 0.275;
   private static final double A4 = -0.1;
   private static final double A5 = -0.41;
@@ -89,12 +92,11 @@ public class AbrahamsonEtAl_2014 implements GroundMotionModel {
   private static final double C4 = 4.5;
   private static final double A = pow(610, 4);
   private static final double B = pow(1360, 4) + A;
-  private static final double VS_RK = 1180.0;
+
   private static final double A2_HW = 0.2;
   private static final double H1 = 0.25;
   private static final double H2 = 1.5;
   private static final double H3 = -0.75;
-  private static final double PHI_AMP_SQ = 0.16;
   private static final double CY_CSIM = 0.1;
 
   private static final Interpolator SITE_INTERPOLATOR = Interpolator.builder().build();
@@ -401,9 +403,20 @@ public class AbrahamsonEtAl_2014 implements GroundMotionModel {
     return Mw < 5.0 ? s3 : Mw > 7.0 ? s4 : s3 + ((s4 - s3) / 2) * (Mw - 5.0);
   }
 
-  // -- Equation 30
-  private static final double get_dAmp(double b, double c, double vLin,
-      double vs30, double saRock) {
+  /*
+   * -- Equation 30
+   *
+   * Return the partial derivative of the natural log of soil amplification
+   * relative to a hard rock site condition ln(SA[Vs30=1180]). This method is
+   * exposed for use in other GMM aleatory variability models.
+   */
+  public static final double get_dAmp(
+      double b,
+      double c,
+      double vLin,
+      double vs30,
+      double saRock) {
+
     if (vs30 >= vLin) {
       return 0.0;
     }
-- 
GitLab