edu.sc.seis.TauP
Class TauBranch
java.lang.Object
|
+--edu.sc.seis.TauP.TauBranch
- All Implemented Interfaces:
- java.lang.Cloneable, java.io.Serializable
- public class TauBranch
- extends java.lang.Object
- implements java.io.Serializable, java.lang.Cloneable
provides storage and methods for distance, time and tau increments for
a branch. A branch is a group of layers bounded by discontinuities or
reversals in slowness gradient.
- See Also:
- Serialized Form
Field Summary |
boolean |
DEBUG
Turns on debugging output. |
Constructor Summary |
TauBranch(double topDepth,
double botDepth,
boolean isPWave)
|
Methods inherited from class java.lang.Object |
equals, getClass, hashCode, notify, notifyAll, wait, wait, wait |
DEBUG
public transient boolean DEBUG
- Turns on debugging output.
TauBranch
public TauBranch(double topDepth,
double botDepth,
boolean isPWave)
getTopDepth
public double getTopDepth()
getBotDepth
public double getBotDepth()
getMaxRayParam
public double getMaxRayParam()
getMinTurnRayParam
public double getMinTurnRayParam()
getMinRayParam
public double getMinRayParam()
getDist
public double[] getDist()
getTime
public double[] getTime()
getTau
public double[] getTau()
createBranch
public void createBranch(SlownessModel sMod,
double minPSoFar,
double[] rayParams)
throws NoSuchLayerException,
SlownessModelException,
TauModelException
- Calculates tau for this branch, between slowness layers
topLayerNum and botLayerNum, inclusive.
- Throws:
NoSuchLayerException
- if a needed slowness layer
cannot be found.SlownessModelException
- if there is a problem with the
slowness modelTauModelException
- if the slownessmodel and taumodel are
not compatible
calcTimeDist
public TimeDist calcTimeDist(SlownessModel sMod,
int topLayerNum,
int botLayerNum,
double p)
throws NoSuchLayerException,
SlownessModelException
- calculates the time and distance increments for the given
ray parameter. The topDepth and botDepth must be correct as
they determine the bounds on the integration/summing.
- Throws:
NoSuchLayerException
- if topLayerNum or botLayerNum
are not in the slowness model.SlownessModelException
- if the ray with ray parameter p
turns within a layer instead of at the bottom.
shiftBranch
public void shiftBranch(int index)
path
public TimeDist[] path(double rayParam,
boolean downgoing,
SlownessModel sMod)
throws SlownessModelException
writeToStream
public void writeToStream(java.io.DataOutputStream dos)
throws java.io.IOException
readFromStream
public static TauBranch readFromStream(java.io.DataInputStream dis)
throws java.io.IOException,
java.lang.ClassNotFoundException,
java.lang.InstantiationException,
java.lang.IllegalAccessException
clone
public java.lang.Object clone()
- Returns a clone of this TauBranch object. Note that super.clone()
handles all normal variables while the arrays need to be cloned
separately to generate a new array as opposed to a new reference
to the old array.
- See Also:
Cloneable
toString
public java.lang.String toString()
- Overrides:
toString
in class java.lang.Object