Package edu.sc.seis.TauP
Class SphericalSModel
- java.lang.Object
-
- edu.sc.seis.TauP.SlownessModel
-
- edu.sc.seis.TauP.SphericalSModel
-
- All Implemented Interfaces:
java.io.Serializable
public class SphericalSModel extends SlownessModel implements java.io.Serializable
This class provides storage and methods for generating slowness-depth pairs in a spherical earth model.- See Also:
- Serialized Form
-
-
Field Summary
-
Fields inherited from class edu.sc.seis.TauP.SlownessModel
allowInnerCoreS, criticalDepths, DEBUG, DEFAULT_SLOWNESS_TOLERANCE, fluidLayerDepths, highSlownessLayerDepthsP, highSlownessLayerDepthsS, maxDeltaP, maxDepthInterval, maxInterpError, maxRangeInterval, minDeltaP, PLayers, PWAVE, radiusOfEarth, SLayers, slownessTolerance, SWAVE, vectorLength, verbose, vMod
-
-
Constructor Summary
Constructors Constructor Description SphericalSModel(double radiusOfEarth, VelocityModel vMod, java.util.List<CriticalDepth> criticalDepths, java.util.List<DepthRange> highSlownessLayerDepthsP, java.util.List<DepthRange> highSlownessLayerDepthsS, java.util.List<DepthRange> fluidLayerDepths, java.util.List<SlownessLayer> pLayers, java.util.List<SlownessLayer> sLayers, double minDeltaP, double maxDeltaP, double maxDepthInterval, double maxRangeInterval, double maxInterpError, boolean allowInnerCoreS, double slownessTolerance)SphericalSModel(VelocityModel vMod)SphericalSModel(VelocityModel vMod, double minDeltaP, double maxDeltaP, double maxDepthInterval, double maxRangeInterval, double maxInterpError, boolean allowInnerCoreS, double slownessTolerance)
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description doubleinterpolate(double p, double topVelocity, double topDepth, double slope)Returns the depth for a slowness given a velocity gradient.TimeDistlayerTimeDist(double sphericalRayParam, int layerNum, boolean isPWave, boolean downgoing)Calculates the time and distance increments accumulated by a ray of spherical ray parameter p when passing through layer layerNum.TimeDistlayerTimeDistAllowTurn(double sphericalRayParam, int layerNum, boolean isPWave, boolean downgoing)doubletoSlowness(double velocity, double depth)Returns the slowness for a velocity at a depth.SlownessLayertoSlownessLayer(VelocityLayer vLayer, boolean isPWave)Converts a velocity layer into a slowness layer.java.lang.StringtoString()doubletoVelocity(double slowness, double depth)Returns the velocity for a slowness at a depth.booleanvalidate()Performs consistency check on the velocity model.-
Methods inherited from class edu.sc.seis.TauP.SlownessModel
addSlowness, approxDistance, coarseSample, depthIncCheck, depthInFluid, depthInFluid, depthInHighSlowness, depthInHighSlowness, distanceCheck, findCriticalPoints, findDepth, findDepth, findDepth, fixCriticalPoints, getAllSlownessLayers, getCriticalDepth, getHighSlowness, getMaxDeltaP, getMaxDepthInterval, getMaxInterpError, getMaxRangeInterval, getMinDeltaP, getMinRayParam, getMinTurnRayParam, getMinTurnRayParam, getNumCriticalDepths, getNumLayers, getRadiusOfEarth, getSlownessLayer, getSlownessTolerance, getVelocityModel, isAllowInnerCoreS, layerAbove, layerBelow, layerNumberAbove, layerNumberBelow, layerNumForDepth, layerTimeDist, printGMT, printGMT, rayParamIncCheck, setAllowInnerCoreS, setMaxDeltaP, setMaxDepthInterval, setMaxInterpError, setMaxRangeInterval, setMinDeltaP, setRadiusOfEarth, setSlownessTolerance, splitLayer, splitLayerForNewRayParam, validateRPCompatibility
-
-
-
-
Constructor Detail
-
SphericalSModel
public SphericalSModel(VelocityModel vMod) throws NoSuchLayerException, SlownessModelException
-
SphericalSModel
public SphericalSModel(VelocityModel vMod, double minDeltaP, double maxDeltaP, double maxDepthInterval, double maxRangeInterval, double maxInterpError, boolean allowInnerCoreS, double slownessTolerance) throws NoSuchLayerException, SlownessModelException
-
SphericalSModel
public SphericalSModel(double radiusOfEarth, VelocityModel vMod, java.util.List<CriticalDepth> criticalDepths, java.util.List<DepthRange> highSlownessLayerDepthsP, java.util.List<DepthRange> highSlownessLayerDepthsS, java.util.List<DepthRange> fluidLayerDepths, java.util.List<SlownessLayer> pLayers, java.util.List<SlownessLayer> sLayers, double minDeltaP, double maxDeltaP, double maxDepthInterval, double maxRangeInterval, double maxInterpError, boolean allowInnerCoreS, double slownessTolerance)
-
-
Method Detail
-
toSlowness
public double toSlowness(double velocity, double depth) throws SlownessModelExceptionReturns the slowness for a velocity at a depth.- Specified by:
toSlownessin classSlownessModel- Throws:
SlownessModelException- if velocity is zero.
-
toVelocity
public double toVelocity(double slowness, double depth) throws SlownessModelExceptionReturns the velocity for a slowness at a depth.- Specified by:
toVelocityin classSlownessModel- Throws:
SlownessModelException- if slowness is zero.
-
toSlownessLayer
public SlownessLayer toSlownessLayer(VelocityLayer vLayer, boolean isPWave)
Converts a velocity layer into a slowness layer.- Specified by:
toSlownessLayerin classSlownessModel
-
interpolate
public double interpolate(double p, double topVelocity, double topDepth, double slope) throws SlownessModelExceptionReturns the depth for a slowness given a velocity gradient.- Specified by:
interpolatein classSlownessModel- Throws:
SlownessModelException- if the velocity gradient exactly balances the spherical decrease in slowness.
-
layerTimeDist
public TimeDist layerTimeDist(double sphericalRayParam, int layerNum, boolean isPWave, boolean downgoing) throws SlownessModelException
Calculates the time and distance increments accumulated by a ray of spherical ray parameter p when passing through layer layerNum. for the easy cases of zero ray parameter, the center of the earth, and constant velocity layers. Note that this gives 1/2 of the true range and time increments since there will be both an up going and a downgoing path.- Specified by:
layerTimeDistin classSlownessModel- Throws:
SlownessModelException- occurs if the ray with the given spherical ray parameter cannot propagate within this layer, or if the ray turns within this layer but not at the bottom.
-
layerTimeDistAllowTurn
public TimeDist layerTimeDistAllowTurn(double sphericalRayParam, int layerNum, boolean isPWave, boolean downgoing) throws SlownessModelException
- Specified by:
layerTimeDistAllowTurnin classSlownessModel- Throws:
SlownessModelException
-
validate
public boolean validate() throws SlownessModelExceptionPerforms consistency check on the velocity model.- Overrides:
validatein classSlownessModel- Returns:
- true if successful, throws SlownessModelException otherwise.
- Throws:
SlownessModelException- if any check fails
-
toString
public java.lang.String toString()
- Overrides:
toStringin classSlownessModel
-
-