OpendTect-6_4  6.4
Classes | Namespaces | Macros | Functions | Variables
arrayndalgo.h File Reference
Include dependency graph for arrayndalgo.h:
This graph shows which files directly or indirectly include this file:

Go to the source code of this file.

Classes

class  ArrayNDWindow
 Tapers the N-dimentional ArrayND with a windowFunction. More...
 
class  Array2DCopier< T >
 Transfers the common samples from one 2D array to another. More...
 
class  Array3DCopier< T >
 Transfers the common samples from one 3D array to another. More...
 
class  PolyTrend
 Polynomial trend with order 0 (mean), 1 (linear) or 2 (parabolic) The trend is derived from a set of values with positions and can be applied thereafter on any other position. More...
 
class  ArrayMath::ArrayOperExecSetup
 
class  ArrayMath::CumArrOperExec< RT, AT >
 Parallel task for computing the sum of element wise operations of one array and optionally a second input array. Should not be used directly, instead call getSum(const ArrayND) More...
 
class  ArrayMath::ArrOperExec< OperType, ArrType >
 Parallel task for computing the element wise operations of one array and optionally a second input array. Should not be used directly, instead call getSum(const ArrayND) More...
 
class  ArrayMath::CumSumExec< T >
 
class  ArrayUdfValReplacer< T >
 
class  ArrayUdfValRestorer< T >
 
class  Array3DUdfTrcRestorer< T >
 
class  MuteArrayExtracter< T >
 

Namespaces

 ArrayMath
 

Macros

#define mComputeTrendAandB(sz)
 
#define mGetInfo()
 
#define mSetResAndContinue(res)
 

Functions

template<class T , class fT >
bool removeLinPart (const ArrayND< T > &in_, ArrayND< T > *out, bool trend)
 [do not use, helper function] More...
 
template<class T , class fT >
bool removeBias (ArrayND< T > &inout)
 Removes the bias from an ArrayND. More...
 
template<class T , class fT >
bool removeBias (const ArrayND< T > &in, ArrayND< T > &out)
 Fills an ArrayND with an unbiased version of another. More...
 
template<class T , class fT >
bool removeTrend (ArrayND< T > &inout)
 Removes a linear trend from an ArrayND. More...
 
template<class T , class fT >
bool removeTrend (const ArrayND< T > &in, ArrayND< T > &out)
 Fills an ArrayND with a de-trended version of another. More...
 
template<class T >
getAverage (const ArrayND< T > &in)
 returns the average of all defined values in the Arrray1D. Returns UDF if empty or only udfs encountered. More...
 
template<class T >
getMax (const ArrayND< T > &in)
 returns the Maximum of all defined values in the ArrrayND. Returns UDF if empty or only udfs encountered. More...
 
template<class T >
getMin (const ArrayND< T > &in)
 returns the Minimum of all defined values in the ArrrayND. Returns UDF if empty or only udfs encountered. More...
 
template<class fT >
bool hasUndefs (const Array1D< fT > &in)
 Returns whether there are undefs in the Array1D. More...
 
template<class fT >
bool interpUdf (Array1D< fT > &in, typename BendPointBasedMathFunction< fT, fT >::InterpolType ipoltyp=BendPointBasedMathFunction< fT, fT >::Poly)
 
template<class T >
Array3DInterpolate (const Array3D< T > &array, float p0, float p1, float p2, bool posperiodic=false)
 
template<class T >
bool ArrayNDCopy (ArrayND< T > &dest, const ArrayND< T > &src, const TypeSet< int > &copypos, bool srcperiodic=false)
 
template<class T >
bool Array3DCopy (Array3D< T > &dest, const Array3D< T > &src, int p0, int p1, int p2, bool srcperiodic=false)
 
template<class T >
bool ArrayNDPaste (ArrayND< T > &dest, const ArrayND< T > &src, const TypeSet< int > &pastepos, bool destperiodic=false)
 
template<class T >
bool Array2DPaste (Array2D< T > &dest, const Array2D< T > &src, int p0, int p1, bool destperiodic=false)
 
template<class T >
bool Array3DPaste (Array3D< T > &dest, const Array3D< T > &src, int p0, int p1, int p2, bool destperiodic=false)
 
template<class T >
ArrayMath::getSum (const ArrayND< T > &in, bool noudf, bool parallel)
 returns the sum of all defined values in the Array. Returns UDF if empty or only udfs encountered. More...
 
template<>
float_complex ArrayMath::getSum (const ArrayND< float_complex > &in, bool noudf, bool parallel)
 
template<class T >
T mDeprecated ArrayMath::getSum (const ArrayND< T > &in, bool noudf)
 will be removed after 6.0 More...
 
template<class T >
ArrayMath::getAverage (const ArrayND< T > &in, bool noudf, bool parallel)
 returns the average amplitude of the array More...
 
template<class T >
T mDeprecated ArrayMath::getAverage (const ArrayND< T > &in, bool noudf)
 will be removed after 6.0 More...
 
template<>
float_complex ArrayMath::getAverage< float_complex > (const ArrayND< float_complex > &in, bool noudf, bool parallel)
 Specialization for complex numbers. More...
 
template<>
float_complex mDeprecated ArrayMath::getAverage< float_complex > (const ArrayND< float_complex > &in, bool noudf)
 will be removed after 6.0 More...
 
template<class T >
 ArrayMath::mDefParallelCalc5Pars (ScalingExec, od_static_tr("ScalingExec","Array scaler executor"), const T *, arrin, T *, arrout, T, fact, T, shift, bool, noudf) mDefParallelCalcBody(
 
 ArrayMath::if (!noudf_ &&(mIsUdf(inpval)))
 
template<class T >
void ArrayMath::getScaledArray (const ArrayND< T > &in, ArrayND< T > *out_, double fact, double shift, bool noudf, bool parallel)
 returns a scaled array More...
 
template<class T >
mDeprecated void ArrayMath::getScaled (const ArrayND< T > &in, ArrayND< T > *out_, T fact, T shift, bool noudf, bool parallel)
 will be removed after 6.0 More...
 
template<class T >
mDeprecated void ArrayMath::getScaled (const ArrayND< T > &in, ArrayND< T > *out_, T fact, T shift, bool noudf)
 will be removed after 6.0 More...
 
template<class T >
 ArrayMath::mDefParallelCalc6Pars (SumExec, od_static_tr("SumExec","Array addition executor"), const T *, arr1, const T *, arr2, T *, out, T, fact1, T, fact2, bool, noudf) mDefParallelCalcBody(
 
 ArrayMath::if (!noudf_ &&(mIsUdf(val1)||mIsUdf(val2)))
 
template<class T >
void ArrayMath::getSumArrays (const ArrayND< T > &in1, const ArrayND< T > &in2, ArrayND< T > &out, double fact1, double fact2, bool noudf, bool parallel)
 computes the sum array between two arrays with scaling More...
 
template<class T >
mDeprecated void ArrayMath::getSum (const ArrayND< T > &in1, const ArrayND< T > &in2, ArrayND< T > &out, T fact1, T fact2, bool noudf, bool parallel)
 will be removed after 6.0 More...
 
template<class T >
mDeprecated void ArrayMath::getSum (const ArrayND< T > &in1, const ArrayND< T > &in2, ArrayND< T > &out, T fact1, T fact2, bool noudf)
 will be removed after 6.0 More...
 
template<class T >
 ArrayMath::mDefParallelCalc4Pars (ProdExec, od_static_tr("ProdExec","Array product executor"), const T *, arr1, const T *, arr2, T *, out, bool, noudf) mDefParallelCalcBody(
 
template<class T >
void ArrayMath::getProduct (const ArrayND< T > &in1, const ArrayND< T > &in2, ArrayND< T > &out, bool noudf, bool parallel)
 computes the product array between two arrays More...
 
template<class T >
mDeprecated void ArrayMath::getProduct (const ArrayND< T > &in1, const ArrayND< T > &in2, ArrayND< T > &out, bool noudf)
 will be removed after 6.0 More...
 
template<class T >
void ArrayMath::getSum (const ArrayND< T > &in1, const ArrayND< T > &in2, ArrayND< T > &out, bool noudf, bool parallel)
 computes the sum array between two arrays More...
 
template<class T >
mDeprecated void ArrayMath::getSum (const ArrayND< T > &in1, const ArrayND< T > &in2, ArrayND< T > &out, bool noudf)
 will be removed after 6.0 More...
 
template<class T >
ArrayMath::getSumProduct (const ArrayND< T > &in1, const ArrayND< T > &in2, bool noudf, bool parallel)
 returns the sum of product amplitudes between two vectors More...
 
template<class T >
double ArrayMath::getSumProductD (const ArrayND< T > &in1, const ArrayND< T > &in2, bool noudf, bool parallel)
 
template<class T >
mDeprecated void ArrayMath::getSumProduct (const ArrayND< T > &in1, const ArrayND< T > &in2, bool noudf)
 will be removed after 6.0 More...
 
template<class T >
ArrayMath::getSumSq (const ArrayND< T > &in, bool noudf, bool parallel)
 returns the sum of squarred amplitudes of the array More...
 
template<class T >
mDeprecatedArrayMath::getSumSq (const ArrayND< T > &in, bool noudf)
 will be removed after 6.0 More...
 
template<class T >
ArrayMath::getNorm2 (const ArrayND< T > &in, bool noudf, bool parallel)
 return the Norm-2 of the array More...
 
template<class T >
double ArrayMath::getNorm2D (const ArrayND< T > &in, bool noudf, bool parallel)
 
template<class T >
mDeprecatedArrayMath::getNorm2 (const ArrayND< T > &in, bool noudf)
 will be removed after 6.0 More...
 
template<class T >
ArrayMath::getRMS (const ArrayND< T > &in, bool noudf, bool parallel)
 return the RMS of the array More...
 
template<class T >
mDeprecatedArrayMath::getRMS (const ArrayND< T > &in, bool noudf)
 will be removed after 6.0 More...
 
template<class T >
ArrayMath::getResidual (const ArrayND< T > &in1, const ArrayND< T > &in2, bool noudf, bool parallel)
 returns the residual differences of two arrays More...
 
template<class T >
mDeprecatedArrayMath::getResidual (const ArrayND< T > &in1, const ArrayND< T > &in2, bool noudf)
 will be removed after 6.0 More...
 
template<class T >
ArrayMath::getSumXMY2 (const ArrayND< T > &in1, const ArrayND< T > &in2, bool noudf, bool parallel)
 returns the sum of squarred differences of two arrays More...
 
template<class T >
T mDeprecated ArrayMath::getSumXMY2 (const ArrayND< T > &in1, const ArrayND< T > &in2, bool noudf)
 will be removed after 6.0 More...
 
template<class T >
ArrayMath::getSumX2PY2 (const ArrayND< T > &in1, const ArrayND< T > &in2, bool noudf, bool parallel)
 returns the sum of summed squarred amplitudes of two arrays More...
 
template<class T >
T mDeprecated ArrayMath::getSumX2PY2 (const ArrayND< T > &in1, const ArrayND< T > &in2, bool noudf)
 will be removed after 6.0 More...
 
template<class T >
ArrayMath::getSumX2MY2 (const ArrayND< T > &in1, const ArrayND< T > &in2, bool noudf, bool parallel)
 returns the sum of subtracted squarred amplitudes of two arrays More...
 
template<class T >
T mDeprecated ArrayMath::getSumX2MY2 (const ArrayND< T > &in1, const ArrayND< T > &in2, bool noudf)
 will be removed after 6.0 More...
 
template<class T , class fT >
bool ArrayMath::getInterceptGradient (const ArrayND< T > &iny, const ArrayND< T > *inx_, T &intercept, T &gradient)
 returns the intercept and gradient of two arrays More...
 
void convertUndefinedIndexList (const TrcKeyZSampling &tkzsin, const TrcKeyZSampling &tkzsout, LargeValVec< od_uint64 > &)
 

Variables

const T ArrayMath::inpval = arrin_[idx]
 
 ArrayMath::arrout_ [idx] = fact_ * inpval + shift_
 
const T ArrayMath::val1 = arr1_[idx]
 
const T ArrayMath::val2 = arr2_[idx]
 
 ArrayMath::out_ [idx] = fact1_ * val1 + fact2_ * val2
 

Macro Definition Documentation

#define mComputeTrendAandB (   sz)
Value:
{ \
aval = mCast(T,( (fT)sz * crosssum - sum * sumindexes ) / \
( (fT)sz * sumsqidx - sumindexes * sumindexes ) );\
bval = mCast(T,( sum * sumsqidx - sumindexes * crosssum ) / \
( (fT)sz * sumsqidx - sumindexes * sumindexes ) ); }
#define mCast(tp, v)
Definition: commondefs.h:124
#define mGetInfo ( )
Value:
const Array3DInfoImpl infoin( tkzsin_.hsamp_.nrLines(), \
tkzsin_.hsamp_.nrTrcs(), tkzsin_.nrZ() ); \
const Array3DInfoImpl infoout( tkzsout_.hsamp_.nrLines(), \
tkzsout_.hsamp_.nrTrcs(), tkzsout_.nrZ() );
Implementation of Array3DInfo.
Definition: arrayndinfo.h:193
#define mSetResAndContinue (   res)
Value:
{ \
if ( outvals ) \
outvals[idx] = res; \
else if ( outstor ) \
outstor->setValue( idx, res );\
else \
outarr_.setND( outiter->getPos(), res ); \
if ( xiter ) xiter->next(); \
if ( yiter ) yiter->next(); \
if ( outiter ) outiter->next(); \
}
if(!noudf_ &&(mIsUdf(val1)||mIsUdf(val2)))
Definition: arrayndalgo.h:1700

Function Documentation

template<class T >
bool Array2DPaste ( Array2D< T > &  dest,
const Array2D< T > &  src,
int  p0,
int  p1,
bool  destperiodic = false 
)
inline
template<class T >
bool Array3DCopy ( Array3D< T > &  dest,
const Array3D< T > &  src,
int  p0,
int  p1,
int  p2,
bool  srcperiodic = false 
)
inline
template<class T >
T Array3DInterpolate ( const Array3D< T > &  array,
float  p0,
float  p1,
float  p2,
bool  posperiodic = false 
)
inline
template<class T >
bool Array3DPaste ( Array3D< T > &  dest,
const Array3D< T > &  src,
int  p0,
int  p1,
int  p2,
bool  destperiodic = false 
)
inline
template<class T >
bool ArrayNDCopy ( ArrayND< T > &  dest,
const ArrayND< T > &  src,
const TypeSet< int > &  copypos,
bool  srcperiodic = false 
)
inline
template<class T >
bool ArrayNDPaste ( ArrayND< T > &  dest,
const ArrayND< T > &  src,
const TypeSet< int > &  pastepos,
bool  destperiodic = false 
)
inline
void convertUndefinedIndexList ( const TrcKeyZSampling tkzsin,
const TrcKeyZSampling tkzsout,
LargeValVec< od_uint64 > &   
)

Replaces undefined values back to an ND array

template<class T >
T getAverage ( const ArrayND< T > &  in)
inline

returns the average of all defined values in the Arrray1D. Returns UDF if empty or only udfs encountered.

template<class T >
T getMax ( const ArrayND< T > &  in)
inline

returns the Maximum of all defined values in the ArrrayND. Returns UDF if empty or only udfs encountered.

template<class T >
T getMin ( const ArrayND< T > &  in)
inline

returns the Minimum of all defined values in the ArrrayND. Returns UDF if empty or only udfs encountered.

template<class fT >
bool hasUndefs ( const Array1D< fT > &  in)
inline

Returns whether there are undefs in the Array1D.

template<class fT >
bool interpUdf ( Array1D< fT > &  in,
typename BendPointBasedMathFunction< fT, fT >::InterpolType  ipoltyp = BendPointBasedMathFunction<fT,fT>::Poly 
)
inline

The function interpUdf fills all the undefined values in a Array1D by using an inter- or extrapolation from the defined values. It uses the BendPointBasedMathFunction for this. Note that even if there is only one defined value, this function will fill the entire array by this value.

Returns whether any substitution was made.

template<class T , class fT >
bool removeBias ( ArrayND< T > &  inout)
inline

Removes the bias from an ArrayND.

template<class T , class fT >
bool removeBias ( const ArrayND< T > &  in,
ArrayND< T > &  out 
)
inline

Fills an ArrayND with an unbiased version of another.

template<class T , class fT >
bool removeLinPart ( const ArrayND< T > &  in_,
ArrayND< T > *  out,
bool  trend 
)
inline

[do not use, helper function]

template<class T , class fT >
bool removeTrend ( ArrayND< T > &  inout)
inline

Removes a linear trend from an ArrayND.

template<class T , class fT >
bool removeTrend ( const ArrayND< T > &  in,
ArrayND< T > &  out 
)
inline

Fills an ArrayND with a de-trended version of another.


Generated at for the OpendTect seismic interpretation project. Copyright (C): dGB Beheer B. V. 2019