Geant4
10.01.p03
|
#include "Randomize.hh"
#include <float.h>
#include <stdio.h>
#include <stdlib.h>
#include <string.h>
#include <cmath>
#include <tpia_target.h>
#include <tpia_misc.h>
#include <string>
Go to the source code of this file.
Classes | |
struct | ZSymbol |
Functions | |
int | tpia_misc_NumberOfZSymbols (void) |
const char * | tpia_misc_ZToSymbol (int iZ) |
int | tpia_misc_symbolToZ (const char *Z) |
int | tpia_miscNameToZAm (statusMessageReporting *smr, const char *name, int *Z, int *A, int *m) |
char * | tpia_misc_pointerToAttributeIfAllOk (statusMessageReporting *smr, xData_element *element, const char *path, int required, xData_attributionList *attributes, const char *name, const char *file, int line) |
int | tpia_misc_setMessageError_Element (statusMessageReporting *smr, void *userInterface, xData_element *element, const char *file, int line, int code, const char *fmt,...) |
xData_Int | tpia_misc_binarySearch (xData_Int n, double *ds, double d) |
double * | tpia_misc_get2dx_y_data (statusMessageReporting *smr, xData_element *element, xData_Int *length) |
double * | tpia_misc_get2dxindex_y_data (statusMessageReporting *smr, xData_element *element, xData_Int *start, xData_Int *end, double *xValues) |
double * | tpia_misc_get2d_xShared_yHistogram_data (statusMessageReporting *smr, xData_element *element, xData_Int *start, xData_Int *end, xData_Int *length) |
int | tpia_misc_get2d_xShared_yHistogram_data_Grouped (statusMessageReporting *smr, xData_element *element, tpia_1dData *group) |
double | tpia_misc_getPointwiseCrossSectionAtE (statusMessageReporting *, tpia_1dData *crossSection, double *energyGrid, xData_Int index, double e_in) |
tpia_EqualProbableBinSpectrum * | tpia_misc_getEqualProbableBin (statusMessageReporting *smr, xData_element *parent, xData_Int *n, xData_Int *nBins) |
tpia_EqualProbableBinSpectrum * | tpia_misc_getEqualProbableBins (statusMessageReporting *smr, xData_element *parent, const char *name, xData_Int nBins, xData_Int *n) |
double | tpia_misc_drng (double(*rng)(void *), void *rngState) |
int | tpia_misc_sampleEqualProbableBin (statusMessageReporting *, tpia_decaySamplingInfo *decaySamplingInfo, double e_in, int nBins, tpia_EqualProbableBinSpectra *binned, double *value_) |
Variables | |
static const struct ZSymbol | ZSymbols [] |
xData_Int tpia_misc_binarySearch | ( | xData_Int | n, |
double * | ds, | ||
double | d | ||
) |
Definition at line 210 of file tpia_misc.cc.
References imax.
Referenced by tpia_target_heated_getEIndex().
double tpia_misc_drng | ( | double(*)(void *) | rng, |
void * | rngState | ||
) |
Definition at line 405 of file tpia_misc.cc.
Referenced by G4GIDI_target::sampleChannelCrossSectionAtE(), tpia_decayChannel_sampleProductsAtE(), tpia_Legendre_SampleEp(), and tpia_misc_sampleEqualProbableBin().
double* tpia_misc_get2d_xShared_yHistogram_data | ( | statusMessageReporting * | smr, |
xData_element * | element, | ||
xData_Int * | start, | ||
xData_Int * | end, | ||
xData_Int * | length | ||
) |
Definition at line 270 of file tpia_misc.cc.
References xData_2d_xShared_yHistogram_copyData(), xData_addToAccessed(), and xData_getOneElementByTagName().
Referenced by tpia_misc_get2d_xShared_yHistogram_data_Grouped().
int tpia_misc_get2d_xShared_yHistogram_data_Grouped | ( | statusMessageReporting * | smr, |
xData_element * | element, | ||
tpia_1dData * | group | ||
) |
Definition at line 291 of file tpia_misc.cc.
References tpia_misc_get2d_xShared_yHistogram_data().
Referenced by _tpia_product_getDepositionEnergy(), tpia_channel_getFromElement(), and tpia_multiplicity_getFromElement().
double* tpia_misc_get2dx_y_data | ( | statusMessageReporting * | smr, |
xData_element * | element, | ||
xData_Int * | length | ||
) |
Definition at line 230 of file tpia_misc.cc.
References xData_2d_xy_allocateCopyData(), xData_addToAccessed(), xData_getOneElementByTagName(), and xData_is_2d_xy().
Referenced by tpia_multiplicity_getFromElement().
double* tpia_misc_get2dxindex_y_data | ( | statusMessageReporting * | smr, |
xData_element * | element, | ||
xData_Int * | start, | ||
xData_Int * | end, | ||
double * | xValues | ||
) |
Definition at line 250 of file tpia_misc.cc.
References xData_2d_xindex_y_toFilledYs(), xData_addToAccessed(), xData_getOneElementByTagName(), and xData_is_2d_xindex_y().
Referenced by tpia_channel_getFromElement().
tpia_EqualProbableBinSpectrum* tpia_misc_getEqualProbableBin | ( | statusMessageReporting * | smr, |
xData_element * | parent, | ||
xData_Int * | n, | ||
xData_Int * | nBins | ||
) |
Definition at line 319 of file tpia_misc.cc.
References tpia_misc_getEqualProbableBins(), tpia_misc_setMessageError_Element(), xData_addToAccessed(), xData_convertAttributeTo_xData_Int(), and xData_getOneElementByTagName().
Referenced by _tpia_Legendre_getOrder(), and tpia_angular_getFromElement().
tpia_EqualProbableBinSpectrum* tpia_misc_getEqualProbableBins | ( | statusMessageReporting * | smr, |
xData_element * | parent, | ||
const char * | name, | ||
xData_Int | nBins, | ||
xData_Int * | n | ||
) |
Definition at line 335 of file tpia_misc.cc.
References tpia_misc_setMessageError_Element(), xData_1d_x_copyData(), xData_addToAccessed(), xData_convertAttributeTo_xData_Int(), xData_convertAttributeToDouble(), xData_free(), xData_freeElementList(), xData_getElements_xDataElement(), and xData_getElementsByTagNameAndSort().
Referenced by tpia_angularEnergy_getFromElement(), and tpia_misc_getEqualProbableBin().
double tpia_misc_getPointwiseCrossSectionAtE | ( | statusMessageReporting * | , |
tpia_1dData * | crossSection, | ||
double * | energyGrid, | ||
xData_Int | index, | ||
double | e_in | ||
) |
Definition at line 300 of file tpia_misc.cc.
Referenced by tpia_channel_getCrossSectionAtE(), and tpia_target_heated_getTotalCrossSectionAtE().
int tpia_misc_NumberOfZSymbols | ( | void | ) |
Definition at line 78 of file tpia_misc.cc.
Referenced by tpia_misc_symbolToZ(), and tpia_misc_ZToSymbol().
char* tpia_misc_pointerToAttributeIfAllOk | ( | statusMessageReporting * | smr, |
xData_element * | element, | ||
const char * | path, | ||
int | required, | ||
xData_attributionList * | attributes, | ||
const char * | name, | ||
const char * | file, | ||
int | line | ||
) |
Definition at line 165 of file tpia_misc.cc.
References smr_isOk(), smr_setMessageError(), tpia_misc_setMessageError_Element(), and xData_getAttributesValue().
int tpia_misc_sampleEqualProbableBin | ( | statusMessageReporting * | , |
tpia_decaySamplingInfo * | decaySamplingInfo, | ||
double | e_in, | ||
int | nBins, | ||
tpia_EqualProbableBinSpectra * | binned, | ||
double * | value_ | ||
) |
Definition at line 422 of file tpia_misc.cc.
References FLT_MAX, P12, P23, and tpia_misc_drng().
Referenced by tpia_angular_SampleMu(), tpia_angularEnergy_SampleEp(), and tpia_Legendre_SampleEp().
int tpia_misc_setMessageError_Element | ( | statusMessageReporting * | smr, |
void * | userInterface, | ||
xData_element * | element, | ||
const char * | file, | ||
int | line, | ||
int | code, | ||
const char * | fmt, | ||
... | |||
) |
Definition at line 185 of file tpia_misc.cc.
References smr_setMessageError(), smr_vallocateFormatMessage(), and smr_vsetMessageError().
Referenced by _tpia_Legendre_getOrder(), _tpia_product_checkRequiredData(), _tpia_product_getDepositionEnergy(), _tpia_product_getMultiplicityFromElement(), _tpia_product_getProductOutgoingData(), tpia_angularEnergy_getFromElement(), tpia_frame_setFromElement(), tpia_Legendre_getFromElement(), tpia_misc_getEqualProbableBin(), tpia_misc_getEqualProbableBins(), tpia_misc_pointerToAttributeIfAllOk(), tpia_multiplicity_getFromElement(), tpia_multiplicity_getTimeScaleFromElement(), tpia_product_getFromElement(), tpia_target_heated_read(), and tpia_target_read().
int tpia_misc_symbolToZ | ( | const char * | Z | ) |
Definition at line 94 of file tpia_misc.cc.
References n, symbol, and tpia_misc_NumberOfZSymbols().
Referenced by tpia_miscNameToZAm().
const char* tpia_misc_ZToSymbol | ( | int | iZ | ) |
Definition at line 85 of file tpia_misc.cc.
References symbol, and tpia_misc_NumberOfZSymbols().
Referenced by G4GIDI_Misc_Z_A_m_ToName().
int tpia_miscNameToZAm | ( | statusMessageReporting * | smr, |
const char * | name, | ||
int * | Z, | ||
int * | A, | ||
int * | m | ||
) |
Definition at line 107 of file tpia_misc.cc.
References n, s, smr_isOk(), smr_setMessageError(), and tpia_misc_symbolToZ().
Referenced by G4GIDI_Misc_channelCompound(), and tpia_particle_getInternalID().
|
static |
Definition at line 61 of file tpia_misc.cc.