All Packages  Class Hierarchy  This Package  Previous  Next  Index

Class edu.sc.seis.TauP.SlownessModel

edu.sc.seis.TauP.SlownessModel

public abstract class SlownessModel
This class provides storage and methods for generating slowness-depth pairs.


Variable Index

 o DEBUG
True to enable debugging output.
 o PWAVE
Just useful for calling methods that need to know whether to use P or S waves.
 o SWAVE
Just useful for calling methods that need to know whether to use P or S waves.
 o verbose
True to enable verbose output.

Constructor Index

 o SlownessModel()

Method Index

 o approxDistance(int, double, boolean)
generate approximate distance, in radians, for a ray from a surface source that turns at the bottom of the given slowness layer.
 o clone()
 o createSample(VelocityModel)
This method takes a velocity model and creates a vector containing slowness-depth layers that, hopefully, adequately sample both slowness and depth so that the travel time as a function of distance can be reconstructed from the theta function.
 o depthInFluid(double)
Determines if the given depth is contained within a fluid zone.
 o depthInFluid(double, DepthRange)
Determines if the given depth is contained within a fluid zone.
 o depthInHighSlowness(double, double, boolean)
Determines if the given depth and corresponding slowness is contained within a high slowness zone.
 o depthInHighSlowness(double, double, DepthRange, boolean)
Determines if the given depth and corresponding slowness is contained within a high slowness zone.
 o findDepth(double, boolean)
Finds a depth corresponding to a slowness over the whole VelocityModel.
 o findDepth(double, double, double, boolean)
Finds a depth corresponding to a slowness between two given depths in the Velocity Model.
 o findDepth(double, int, int, boolean)
Finds a depth corresponding to a slowness between two given velocity layers, including the top and the bottom.
 o getCriticalDepth(int)
 o getHighSlowness(boolean)
 o getMaxDeltaP()
 o getMaxDepthInterval()
 o getMaxInterpError()
gets the maximum value of the estimated error due to linear interpolation.
 o getMaxRangeInterval()
 o getMinDeltaP()
 o getMinRayParam(double, boolean)
 o getMinTurnRayParam(double, boolean)
 o getNumCriticalDepths()
 o getNumLayers(boolean)
 o getRadiusOfEarth()
 o getSlownessLayerClone(int, boolean)
 o getSlownessTolerance()
 o interpolate(double, double, double, double)
 o isAllowInnerCoreS()
 o layerNumberAbove(double, boolean)
Finds the index of the slowness layer that contains the given depth Note that if the depth is a layer boundary, it returns the shallower of the two or possibly more (since total reflections are zero thickness layers) layers.
 o layerNumberBelow(double, boolean)
Finds the index of the slowness layer that contains the given depth Note that if the depth is a layer boundary, it returns the deeper of the two or possibly more (since total reflections are zero thickness layers) layers.
 o layerTimeDist(double, int, boolean)
 o setAllowInnerCoreS(boolean)
 o setMaxDeltaP(double)
 o setMaxDepthInterval(double)
 o setMaxInterpError(double)
sets the maximum value of the estimated error due to linear interpolation.
 o setMaxRangeInterval(double)
sets the maximum range interval for surface focus turning waves between slowness samples, input in degrees.
 o setMinDeltaP(double)
 o setRadiusOfEarth(double)
 o setSlownessTolerance(double)
 o splitLayer(double, boolean)
 o toSlowness(double, double)
 o toSlownessLayer(VelocityLayer, boolean)
 o toString()
 o toVelocity(double, double)
 o validate()
Performs consistency check on the slowness model.

Variables

 o DEBUG
 public transient boolean DEBUG
True to enable debugging output.

 o verbose
 public transient boolean verbose
True to enable verbose output.

 o PWAVE
 public static final boolean PWAVE
Just useful for calling methods that need to know whether to use P or S waves.

 o SWAVE
 public static final boolean SWAVE
Just useful for calling methods that need to know whether to use P or S waves.

Constructors

 o SlownessModel
 public SlownessModel()

Methods

 o setRadiusOfEarth
 public void setRadiusOfEarth(double radiusOfEarth)
 o setMinDeltaP
 public void setMinDeltaP(double minDeltaP)
 o setMaxDeltaP
 public void setMaxDeltaP(double maxDeltaP)
 o setMaxDepthInterval
 public void setMaxDepthInterval(double maxDepthInterval)
 o setMaxRangeInterval
 public void setMaxRangeInterval(double maxRangeInterval)
sets the maximum range interval for surface focus turning waves between slowness samples, input in degrees.

 o setMaxInterpError
 public void setMaxInterpError(double maxInterpError)
sets the maximum value of the estimated error due to linear interpolation. Care should be taken not to set this too small as a very large number of samples may be required. Note also that this is only an estimate of the error, and thus the bound is by no means assured.

 o setAllowInnerCoreS
 public void setAllowInnerCoreS(boolean allowInnerCoreS)
 o setSlownessTolerance
 public void setSlownessTolerance(double slownessTolerance)
 o getRadiusOfEarth
 public final double getRadiusOfEarth()
 o getMinDeltaP
 public final double getMinDeltaP()
 o getMaxDeltaP
 public final double getMaxDeltaP()
 o getMaxDepthInterval
 public final double getMaxDepthInterval()
 o getMaxRangeInterval
 public final double getMaxRangeInterval()
Returns:
s the maximum range interval for surface focus turning waves between slowness samples output in degrees.
 o getMaxInterpError
 public final double getMaxInterpError()
gets the maximum value of the estimated error due to linear interpolation. Care should be taken not to set this too small as a very large number of samples may be required. Note also that this is only an estimate of the error, and thus the bound is by no means assured.

 o isAllowInnerCoreS
 public final boolean isAllowInnerCoreS()
 o getSlownessTolerance
 public final double getSlownessTolerance()
 o getNumCriticalDepths
 public final int getNumCriticalDepths()
 o getCriticalDepth
 public final CriticalDepth getCriticalDepth(int i)
 o getNumLayers
 public final int getNumLayers(boolean isPWave)
 o getMinTurnRayParam
 public double getMinTurnRayParam(double depth,
                                  boolean isPWave) throws NoSuchLayerException, SlownessModelException
Returns:
s the minimum ray parameter that turns, but is not reflected, at or above the given depth. Normally this is the slowness sample at the given depth, but if the depth is within a high slowness zone, then it may be smaller.
 o getMinRayParam
 public double getMinRayParam(double depth,
                              boolean isPWave) throws NoSuchLayerException, SlownessModelException
Returns:
s the minimum ray parameter that turns or is reflected at or above the given depth. Normally this is the slowness sample at the given depth, but if the depth is within a high slowness zone, then it may be smaller. Also, at first order discontinuities, there may be many slowness samples at the same depth.
 o getHighSlowness
 public DepthRange[] getHighSlowness(boolean isPWave)
Returns:
s the DepthRange objects for all high slowness zones within the slowness model.
 o getSlownessLayerClone
 public SlownessLayer getSlownessLayerClone(int layerNum,
                                            boolean isPWave)
Returns:
s a clone of the requested waveType slowness layer. Note that as this is a clone, no changes made to the layer will be incorporated into the slowness model.
 o toSlowness
 public abstract double toSlowness(double velocity,
                                   double depth) throws SlownessModelException
 o toVelocity
 public abstract double toVelocity(double slowness,
                                   double depth) throws SlownessModelException
 o layerTimeDist
 public abstract TimeDist layerTimeDist(double rayParam,
                                        int layerNum,
                                        boolean isPWave) throws SlownessModelException
 o toSlownessLayer
 public abstract SlownessLayer toSlownessLayer(VelocityLayer vLayer,
                                               boolean isPWave) throws SlownessModelException
 o interpolate
 public abstract double interpolate(double p,
                                    double topVelocity,
                                    double topDepth,
                                    double slope) throws SlownessModelException
 o approxDistance
 public TimeDist approxDistance(int slownessTurnLayer,
                                double p,
                                boolean isPWave) throws NoSuchLayerException, SlownessModelException
generate approximate distance, in radians, for a ray from a surface source that turns at the bottom of the given slowness layer.

Throws: NoSuchLayerException
occurs if no layer in the velocity model contains the given depth.
Throws: SlownessModelException
occurs if getNumLayers() == 0 as we cannot compute a distance without a layer.
 o depthInHighSlowness
 public boolean depthInHighSlowness(double depth,
                                    double rayParam,
                                    boolean isPWave)
Determines if the given depth and corresponding slowness is contained within a high slowness zone. Whether the high slowness zone includes its upper boundary and its lower boundaries depends upon the ray parameter. The slowness at the depth is needed because if depth happens to correspond to a discontinuity that marks the bottom of the high slowness zone but the ray is actually a total reflection then it is not part of the high slowness zone. Calls depthInHighSlowness(double, double, DepthRange).

See Also:
 o depthInHighSlowness
 public boolean depthInHighSlowness(double depth,
                                    double rayParam,
                                    DepthRange highSZoneDepth,
                                    boolean isPWave)
Determines if the given depth and corresponding slowness is contained within a high slowness zone. Whether the high slowness zone includes its upper boundary and its lower boundaries depends upon the ray parameter. The slowness at the depth is needed because if depth happens to correspond to a discontinuity that marks the bottom of the high slowness zone but the ray is actually a total reflection then it is not part of the high slowness zone. The ray parameter that delimits the zone, ie it can turn at the top and the bottom, is in the zone at the top, but out of the zone at the bottom.

 o depthInFluid
 public boolean depthInFluid(double depth)
Determines if the given depth is contained within a fluid zone. The fluid zone includes its upper boundary but not its lower boundary. Calls depthInFluid(double, DepthRange).

See Also:
depthInFluid
 o depthInFluid
 public boolean depthInFluid(double depth,
                             DepthRange fluidZoneDepth)
Determines if the given depth is contained within a fluid zone. The fluid zone includes its upper boundary but not its lower boundary. The top and bottom of the fluid zone are returned in DepthRange.

 o splitLayer
 public SplitLayerInfo splitLayer(double depth,
                                  boolean isPWave) throws SlownessModelException, NoSuchLayerException
 o findDepth
 public double findDepth(double rayParam,
                         boolean isPWave) throws SlownessModelException
Finds a depth corresponding to a slowness over the whole VelocityModel. Calls findDepth(double, int, int, char).

 o findDepth
 public double findDepth(double rayParam,
                         double topDepth,
                         double botDepth,
                         boolean isPWave) throws SlownessModelException
Finds a depth corresponding to a slowness between two given depths in the Velocity Model. Calls findDepth(double, int, int, char).

 o findDepth
 public double findDepth(double p,
                         int topCriticalLayer,
                         int botCriticalLayer,
                         boolean isPWave) throws SlownessModelException
Finds a depth corresponding to a slowness between two given velocity layers, including the top and the bottom. We also check to see if the slowness is less than the bottom slowness of these layers but greater than the top slowness of the next deeper layer. This corresponds to a total reflection. In this case a check needs to be made to see if this is an S wave reflecting off of a fluid layer, use P velocity below in this case. We assume that slowness is monotonic within these layers and therefore there is only one depth with the given slowness. This means we return the first depth that we find.

Throws: SlownessModelException
occurs if topCriticalLayer > botCriticalLayer because there are no layers to search, or if there is an increase in slowness, ie a negative velocity gradient, that just balances the decrease in slowness due to the spherical earth, or if the ray parameter p is not contained within the specified layer range.
 o createSample
 public void createSample(VelocityModel velModel) throws SlownessModelException, NoSuchMatPropException, NoSuchLayerException
This method takes a velocity model and creates a vector containing slowness-depth layers that, hopefully, adequately sample both slowness and depth so that the travel time as a function of distance can be reconstructed from the theta function. It catches NoSuchLayerException which might be generated in the velocity model. This shouldn't happen though.

Throws: SlownessModelException
occurs if the validation on the velocity model fails, or if the velocity model has no layers.
Throws: NoSuchMatPropException
occurs if wavetype is not recognized.
See Also:
VelocityModel
 o layerNumberAbove
 public int layerNumberAbove(double depth,
                             boolean isPWave) throws NoSuchLayerException
Finds the index of the slowness layer that contains the given depth Note that if the depth is a layer boundary, it returns the shallower of the two or possibly more (since total reflections are zero thickness layers) layers.

Returns:
the layer number.
Throws: NoSuchLayerException
occurs if no layer in the slowness model contains the given depth.
 o layerNumberBelow
 public int layerNumberBelow(double depth,
                             boolean isPWave) throws NoSuchLayerException
Finds the index of the slowness layer that contains the given depth Note that if the depth is a layer boundary, it returns the deeper of the two or possibly more (since total reflections are zero thickness layers) layers.

Returns:
the layer number.
Throws: NoSuchLayerException
occurs if no layer in the slowness model contains the given depth.
 o validate
 public boolean validate() throws SlownessModelException
Performs consistency check on the slowness model.

Returns:
true if successful, throws SlownessModelException otherwise.
Throws: SlownessModelException
if any check fails
 o clone
 public Object clone()
 o toString
 public String toString()

All Packages  Class Hierarchy  This Package  Previous  Next  Index