org.opensha.sha.magdist
Interface IncrementalMagFreqDistAPI

All Known Implementing Classes:
ArbIncrementalMagFreqDist, GaussianMagFreqDist, GutenbergRichterMagFreqDist, IncrementalMagFreqDist, SingleMagFreqDist, SummedMagFreqDist, TaperedGR_MagFreqDist, YC_1985_CharMagFreqDist

public interface IncrementalMagFreqDistAPI

Title: IncrementalMagFreqDistAPI

Description: this Interface gives the rate of EarthQuakes(number per year)in succession. This class has been made as a generalised API for others to implement depending on their functionality

Version:
1.0
Author:
:Nitin Gupta Date: July,26,2002

Method Summary
 double getCumRate(double mag)
          This function finds the cumulative Rate at a specified magnitude (the rate greater than and equal to that magnitude)
 double getCumRate(int index)
          This function finds the cumulative Rate at a specified index (the rate greater than and equal to that index)
 EvenlyDiscretizedFunc getCumRateDist()
          This returns the object of the class EvenlyDiscretizedFunc which contains all the points with Incr Rate Distribution (the rate greater than and equal to each magnitude)
 double getIncrRate(double mag)
          This function finds IncrRate for the given magnitude
 double getIncrRate(int index)
          This function finds the IncrRate at the given index
 double getMomentRate(double mag)
          This function finds the moment Rate at a specified magnitude
 double getMomentRate(int index)
          This function finds the moment Rate at a specified index
 EvenlyDiscretizedFunc getMomentRateDist()
          This returns the object of the class EvenlyDiscretizedFunc which contains all the points with Moment Rate Distribution
 double getTotalIncrRate()
          This function returns the sum of all the incremental rate as the double varibale
 double getTotalMomentRate()
          This function return the sum of all the moment rates as a double variable
 void normalizeByTotalRate()
          This function normalises the values of all the Incremental rate at each point, by dividing each one by the totalIncrRate, so that after normalization the sum addition of all incremental rate at each point comes to be 1.
 void scaleToCumRate(double mag, double rate)
          Using this function each data point is scaled to the ratio of the CumRate at a given magnitude and the specified rate.
 void scaleToCumRate(int index, double rate)
          Using this function each data point is scaled to the ratio of the CumRate at a given index and the specified rate
 void scaleToIncrRate(double mag, double newRate)
          Using this function each data point is scaled to the ratio of the IncrRate at a given magnitude and the specified newRate
 void scaleToIncrRate(int index, double newRate)
          Using this function each data point is scaled to the ratio of the IncrRate at a given index and the specified newRate
 void scaleToTotalMomentRate(double newTotMoRate)
          Using this function each data point is scaled to ratio of specified newTotalMomentRate and oldTotalMomentRate.
 

Method Detail

getIncrRate

double getIncrRate(double mag)
This function finds IncrRate for the given magnitude

Parameters:
mag -
Returns:

getIncrRate

double getIncrRate(int index)
This function finds the IncrRate at the given index

Parameters:
index -
Returns:

getCumRate

double getCumRate(double mag)
This function finds the cumulative Rate at a specified magnitude (the rate greater than and equal to that magnitude)

Parameters:
mag -
Returns:

getCumRate

double getCumRate(int index)
This function finds the cumulative Rate at a specified index (the rate greater than and equal to that index)

Parameters:
index -
Returns:

getMomentRate

double getMomentRate(double mag)
This function finds the moment Rate at a specified magnitude

Parameters:
mag -
Returns:

getMomentRate

double getMomentRate(int index)
This function finds the moment Rate at a specified index

Parameters:
index -
Returns:

getTotalMomentRate

double getTotalMomentRate()
This function return the sum of all the moment rates as a double variable

Returns:

getTotalIncrRate

double getTotalIncrRate()
This function returns the sum of all the incremental rate as the double varibale

Returns:

normalizeByTotalRate

void normalizeByTotalRate()
This function normalises the values of all the Incremental rate at each point, by dividing each one by the totalIncrRate, so that after normalization the sum addition of all incremental rate at each point comes to be 1.


getCumRateDist

EvenlyDiscretizedFunc getCumRateDist()
This returns the object of the class EvenlyDiscretizedFunc which contains all the points with Incr Rate Distribution (the rate greater than and equal to each magnitude)

Returns:

getMomentRateDist

EvenlyDiscretizedFunc getMomentRateDist()
This returns the object of the class EvenlyDiscretizedFunc which contains all the points with Moment Rate Distribution

Returns:

scaleToTotalMomentRate

void scaleToTotalMomentRate(double newTotMoRate)
Using this function each data point is scaled to ratio of specified newTotalMomentRate and oldTotalMomentRate.

Parameters:
newTotMoRate -

scaleToCumRate

void scaleToCumRate(double mag,
                    double rate)
Using this function each data point is scaled to the ratio of the CumRate at a given magnitude and the specified rate.

Parameters:
mag -
rate -

scaleToCumRate

void scaleToCumRate(int index,
                    double rate)
Using this function each data point is scaled to the ratio of the CumRate at a given index and the specified rate

Parameters:
index -
rate -

scaleToIncrRate

void scaleToIncrRate(double mag,
                     double newRate)
Using this function each data point is scaled to the ratio of the IncrRate at a given magnitude and the specified newRate

Parameters:
mag -
newRate -

scaleToIncrRate

void scaleToIncrRate(int index,
                     double newRate)
Using this function each data point is scaled to the ratio of the IncrRate at a given index and the specified newRate

Parameters:
index -
newRate -