ECCE @ EIC Software
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Groups Pages
ptwXY_convenient.cc File Reference
#include <stdlib.h>
#include <cmath>
#include <float.h>
#include "ptwXY.h"
+ Include dependency graph for ptwXY_convenient.cc:

Go to the source code of this file.

Macros

#define minEps   5e-16
 

Functions

static nfu_status ptwXY_createGaussianCenteredSigma1_2 (ptwXYPoints *ptwXY, double x1, double y1, double x2, double y2, int addX1Point)
 
ptwXPointsptwXY_getXArray (ptwXYPoints *ptwXY, nfu_status *status)
 
nfu_status ptwXY_dullEdges (ptwXYPoints *ptwXY, double lowerEps, double upperEps, int positiveXOnly)
 
nfu_status ptwXY_mergeClosePoints (ptwXYPoints *ptwXY, double epsilon)
 
ptwXYPointsptwXY_intersectionWith_ptwX (ptwXYPoints *ptwXY, ptwXPoints *ptwX, nfu_status *status)
 
nfu_status ptwXY_areDomainsMutual (ptwXYPoints *ptwXY1, ptwXYPoints *ptwXY2)
 
nfu_status ptwXY_tweakDomainsToMutualify (ptwXYPoints *ptwXY1, ptwXYPoints *ptwXY2, int epsilonFactor, double epsilon)
 
nfu_status ptwXY_mutualifyDomains (ptwXYPoints *ptwXY1, double lowerEps1, double upperEps1, int positiveXOnly1, ptwXYPoints *ptwXY2, double lowerEps2, double upperEps2, int positiveXOnly2)
 
nfu_status ptwXY_copyToC_XY (ptwXYPoints *ptwXY, int64_t index1, int64_t index2, int64_t allocatedSize, int64_t *numberOfPoints, double *xys)
 
nfu_status ptwXY_valueTo_ptwXAndY (ptwXYPoints *ptwXY, double **xs, double **ys)
 
ptwXYPointsptwXY_valueTo_ptwXY (double x1, double x2, double y, nfu_status *status)
 
ptwXYPointsptwXY_createGaussianCenteredSigma1 (double accuracy, nfu_status *status)
 
ptwXYPointsptwXY_createGaussian (double accuracy, double xCenter, double sigma, double amplitude, double xMin, double xMax, double, nfu_status *status)
 

Macro Definition Documentation

Function Documentation

nfu_status ptwXY_areDomainsMutual ( ptwXYPoints ptwXY1,
ptwXYPoints ptwXY2 
)

Definition at line 257 of file ptwXY_convenient.cc.

View newest version in sPHENIX GitHub at line 257 of file ptwXY_convenient.cc

References ptwXYPoints_s::length, n1, nfu_domainsNotMutual, nfu_empty, nfu_Okay, nfu_tooFewPoints, ptwXY_getPointAtIndex_Unsafely(), ptwXYPoints_s::status, ptwXYPoint_s::x, and ptwXYPoint_s::y.

Referenced by ptwXY_binary_ptwXY(), ptwXY_div_ptwXY(), and ptwXY_mutualifyDomains().

+ Here is the call graph for this function:

+ Here is the caller graph for this function:

nfu_status ptwXY_copyToC_XY ( ptwXYPoints ptwXY,
int64_t  index1,
int64_t  index2,
int64_t  allocatedSize,
int64_t *  numberOfPoints,
double *  xys 
)

Definition at line 424 of file ptwXY_convenient.cc.

View newest version in sPHENIX GitHub at line 424 of file ptwXY_convenient.cc

References d, Acts::index1, ptwXYPoints_s::length, nfu_insufficientMemory, nfu_Okay, ptwXYPoints_s::points, ptwXY_simpleCoalescePoints(), ptwXYPoints_s::status, ptwXYPoint_s::x, and ptwXYPoint_s::y.

+ Here is the call graph for this function:

ptwXYPoints* ptwXY_createGaussian ( double  accuracy,
double  xCenter,
double  sigma,
double  amplitude,
double  xMin,
double  xMax,
double  ,
nfu_status status 
)

Definition at line 566 of file ptwXY_convenient.cc.

View newest version in sPHENIX GitHub at line 566 of file ptwXY_convenient.cc

References BTOF::length, ptwXYPoints_s::length, ptwXYPoints_s::points, ptwXY_createGaussianCenteredSigma1(), ptwXY_free(), ptwXY_xSlice(), ptwXYPoint_s::x, and ptwXYPoint_s::y.

+ Here is the call graph for this function:

ptwXYPoints* ptwXY_createGaussianCenteredSigma1 ( double  accuracy,
nfu_status status 
)

Definition at line 492 of file ptwXY_convenient.cc.

View newest version in sPHENIX GitHub at line 492 of file ptwXY_convenient.cc

References ptwXYPoints_s::accuracy, e, G4Exp(), G4Log(), ptwXYPoints_s::length, n, nfu_Okay, Acts::UnitConstants::pm, ptwXYPoints_s::points, G4InuclParticleNames::pp, ptwXY_coalescePoints(), ptwXY_createGaussianCenteredSigma1_2(), ptwXY_free(), ptwXY_interpolationLinLin, ptwXY_new(), ptwXY_setValueAtX(), x1, x2, y1, and y2.

Referenced by ptwXY_createGaussian().

+ Here is the call graph for this function:

+ Here is the caller graph for this function:

static nfu_status ptwXY_createGaussianCenteredSigma1_2 ( ptwXYPoints ptwXY,
double  x1,
double  y1,
double  x2,
double  y2,
int  addX1Point 
)
static

Definition at line 549 of file ptwXY_convenient.cc.

View newest version in sPHENIX GitHub at line 549 of file ptwXY_convenient.cc

References ptwXYPoints_s::accuracy, G4Exp(), nfu_Okay, ptwXY_setValueAtX(), x, x2, and y.

Referenced by ptwXY_createGaussianCenteredSigma1().

+ Here is the call graph for this function:

+ Here is the caller graph for this function:

nfu_status ptwXY_dullEdges ( ptwXYPoints ptwXY,
double  lowerEps,
double  upperEps,
int  positiveXOnly 
)

Definition at line 42 of file ptwXY_convenient.cc.

View newest version in sPHENIX GitHub at line 42 of file ptwXY_convenient.cc

References dx, ptwXYPoints_s::interpolation, ptwXYPoints_s::length, minEps, nfu_invalidInterpolation, nfu_Okay, nfu_otherInterpolation, ptwXY_getPointAtIndex_Unsafely(), ptwXY_getValueAtX(), ptwXY_interpolatePoint(), ptwXY_interpolationFlat, ptwXY_interpolationOther, ptwXY_setValueAtX(), sign(), ptwXYPoints_s::status, ptwXYPoint_s::x, x1, x2, ptwXYPoint_s::y, y, y1, and y2.

Referenced by MCGIDI_reaction_fixDomains(), and ptwXY_mutualifyDomains().

+ Here is the call graph for this function:

+ Here is the caller graph for this function:

ptwXPoints* ptwXY_getXArray ( ptwXYPoints ptwXY,
nfu_status status 
)

Definition at line 24 of file ptwXY_convenient.cc.

View newest version in sPHENIX GitHub at line 24 of file ptwXY_convenient.cc

References ptwXPoints_s::length, ptwXYPoints_s::length, n, nfu_Okay, ptwXPoints_s::points, ptwXYPoints_s::points, ptwX_new(), ptwXY_simpleCoalescePoints(), ptwXYPoints_s::status, and ptwXYPoint_s::x.

+ Here is the call graph for this function:

ptwXYPoints* ptwXY_intersectionWith_ptwX ( ptwXYPoints ptwXY,
ptwXPoints ptwX,
nfu_status status 
)

Definition at line 194 of file ptwXY_convenient.cc.

View newest version in sPHENIX GitHub at line 194 of file ptwXY_convenient.cc

References ptwXYPoints_s::interpolation, ptwXYPoints_s::length, n, nfu_Okay, nfu_otherInterpolation, ptwXPoints_s::points, ptwXYPoints_s::points, ptwX_length(), ptwXY_clone(), ptwXY_free(), ptwXY_getValueAtX(), ptwXY_interpolationOther, ptwXY_setValueAtX(), ptwXY_simpleCoalescePoints(), ptwXPoints_s::status, ptwXYPoints_s::status, ptwXYPoint_s::x, x, and y.

Referenced by ptwXY_groupOneFunction(), ptwXY_groupThreeFunctions(), and ptwXY_groupTwoFunctions().

+ Here is the call graph for this function:

+ Here is the caller graph for this function:

nfu_status ptwXY_mergeClosePoints ( ptwXYPoints ptwXY,
double  epsilon 
)

Definition at line 141 of file ptwXY_convenient.cc.

View newest version in sPHENIX GitHub at line 141 of file ptwXY_convenient.cc

References DBL_EPSILON, k, ptwXYPoints_s::length, n, nfu_Okay, ptwXYPoints_s::points, ptwXY_simpleCoalescePoints(), ptwXYPoints_s::status, ptwXYPoint_s::x, x, ptwXYPoint_s::y, and y.

Referenced by ptwXY_union().

+ Here is the call graph for this function:

+ Here is the caller graph for this function:

nfu_status ptwXY_mutualifyDomains ( ptwXYPoints ptwXY1,
double  lowerEps1,
double  upperEps1,
int  positiveXOnly1,
ptwXYPoints ptwXY2,
double  lowerEps2,
double  upperEps2,
int  positiveXOnly2 
)

Definition at line 368 of file ptwXY_convenient.cc.

View newest version in sPHENIX GitHub at line 368 of file ptwXY_convenient.cc

References ptwXYPoints_s::interpolation, ptwXYPoints_s::length, n1, nfu_domainsNotMutual, nfu_empty, nfu_invalidInterpolation, nfu_Okay, nfu_otherInterpolation, ptwXY_areDomainsMutual(), ptwXY_dullEdges(), ptwXY_getPointAtIndex_Unsafely(), ptwXY_interpolationFlat, ptwXY_interpolationOther, ptwXYPoint_s::x, and ptwXYPoint_s::y.

+ Here is the call graph for this function:

nfu_status ptwXY_tweakDomainsToMutualify ( ptwXYPoints ptwXY1,
ptwXYPoints ptwXY2,
int  epsilonFactor,
double  epsilon 
)

Definition at line 295 of file ptwXY_convenient.cc.

View newest version in sPHENIX GitHub at line 295 of file ptwXY_convenient.cc

References DBL_EPSILON, ptwXYPoints_s::length, n1, nfu_domainsNotMutual, nfu_empty, nfu_Okay, nfu_tooFewPoints, ptwXY_getPointAtIndex_Unsafely(), ptwXYPoints_s::status, sum, ptwXYPoint_s::x, and ptwXYPoint_s::y.

Referenced by ptwXY_groupThreeFunctions(), and ptwXY_groupTwoFunctions().

+ Here is the call graph for this function:

+ Here is the caller graph for this function:

nfu_status ptwXY_valueTo_ptwXAndY ( ptwXYPoints ptwXY,
double **  xs,
double **  ys 
)

Definition at line 450 of file ptwXY_convenient.cc.

View newest version in sPHENIX GitHub at line 450 of file ptwXY_convenient.cc

References BTOF::length, nfu_mallocError, nfu_Okay, ptwXYPoints_s::points, ptwXY_length(), ptwXY_simpleCoalescePoints(), ptwXYPoints_s::status, ptwXYPoint_s::x, and ptwXYPoint_s::y.

+ Here is the call graph for this function:

ptwXYPoints* ptwXY_valueTo_ptwXY ( double  x1,
double  x2,
double  y,
nfu_status status 
)

Definition at line 477 of file ptwXY_convenient.cc.

View newest version in sPHENIX GitHub at line 477 of file ptwXY_convenient.cc

References n, nfu_Okay, nfu_XNotAscending, ptwXY_interpolationLinLin, ptwXY_maxBiSectionMax, ptwXY_minAccuracy, ptwXY_new(), and ptwXY_setValueAtX().

+ Here is the call graph for this function: