GLAST / LAT > DAQ and FSW > FSW > Doxygen Index> GRBP / V1-0-4 > grbpsiu / rhel6-64


Interface   Data Structures   File List   Data Fields   Globals  

GRBP_clusterList.h File Reference

Cluster List management routines, interface. More...

#include <GRBP_probability.h>

Classes

struct  _GRBP_clusterUpdateList
 Describes which clusters have been updated after a new photon has been added. By implication, these are the only clusters that need to be checked. More...
struct  _GRBP_clusterList
 Describes a array/circular list of clusters. More...
struct  _GRBP_clusterPrms
 Parameters/constants controlling the adding of a photon to a cluster presented in a form used directly by the code. More...

Defines

#define GRBP_clusterListCheck(_clusterList, _clusterPrms, _nrange)

Typedefs

typedef struct _GRBP_cluster GRBP_cluster
typedef struct _GRBP_DB_clusterList GRBP_DB_clusterList
typedef struct
_GRBP_clusterUpdateList 
GRBP_clusterUpdateList
 Typedef for struct _GRBP_clusterUpdateList.
typedef struct _GRBP_clusterList GRBP_clusterList
 Typedef for struct _GRBP_clusterList.
typedef struct _GRBP_clusterPrms GRBP_clusterPrms

Functions

int GRBP_clusterListSizeof (int clusterCount, int photonCount)
 Calculates the size, in bytes, to hold a cluster list with cluster_count clusters and a cross-reference array of for photon_count photons.
unsigned char * GRBP_clusterListConstruct (GRBP_clusterList *clusterList, const GRBP_DB_clusterList *cfg, int photonCount, unsigned char *ptr)
 Constructs the cluster list according to the specified values.
void GRBP_clusterListAdd (GRBP_clusterList *clusterList, const GRBP_clusterPrms *prms, double time, double energy, double dx, double dy, double dz)
 Adds photon to the clusterList using prms as the source of the parameters which control the calculation of the probabilities, both temporal and spatial, as well as the admittance criteria to call a photon a neighbor of another photon.
void GRBP_clusterListReset (GRBP_clusterList *clusterList)
 Resets the specified cluster list.


Detailed Description

Cluster List management routines, interface.

Author:
JJRussell - russell@slac.stanford.edu

   CVS $Id: GRBP_clusterList.h,v 1.3 2011/03/30 22:11:51 russell Exp $

Function Documentation

void GRBP_clusterListAdd ( GRBP_clusterList clusterList,
const GRBP_clusterPrms prms,
double  time,
double  energy,
double  dx,
double  dy,
double  dz 
)

Adds photon to the clusterList using prms as the source of the parameters which control the calculation of the probabilities, both temporal and spatial, as well as the admittance criteria to call a photon a neighbor of another photon.

Parameters:
clusterList The target cluster list.
prms The parameters controlling the promotion of a photon into a cluster.
time The time associated with the photon being added
energy The energy, in Mev, of the photon
dx The x direction cosine
dy The y direction cosine
dz The y direction cosine

References _GRBP_probabilityPrms::background_rate, _GRBP_clusterList::beg, bit_list_clear(), bit_list_init(), _GRBP_neighborList::bl, calc_spatial(), calc_temporal(), _GRBP_clusterList::clusters, _GRBP_clusterUpdateList::cnt, _GRBP_clusterList::cnt, _GRBP_probabilityPrms::costhetamax, _GRBP_clusterPrms::costwosigdist, _GRBP_clusterList::cur, _GRBP_neighborList::info, _GRBP_neighborList::last, _GRBP_clusterUpdateList::list, _GRBP_probabilityPrms::log10_costhetamax, _GRBP_clusterList::max, _GRBP_clusterPrms::probability, _GRBP_probabilityPrms::psc, _GRBP_probabilityPrms::ptc, _GRBP_neighborList::rsumlog10pdists, _GRBP_neighborList::rsumlog10pdts, _GRBP_neighborInfo::sum_log10_pdists, _GRBP_neighborInfo::sum_log10_pdts, _GRBP_neighborList::time, _GRBP_clusterList::upd, and wrap_hi().

Referenced by GRBP_cacheAdd().

unsigned char * GRBP_clusterListConstruct ( GRBP_clusterList clusterList,
const GRBP_DB_clusterList *  cfg,
int  photonCount,
unsigned char *  ptr 
)

Constructs the cluster list according to the specified values.

Returns:
A pointer to the next available memory location
Parameters:
clusterList The cluster list to construct
cfg The cluster list configuration
photonCount The number of photons on the master photon list. This is used to for a cross-reference list between a photon and a cluster member
ptr Pointer to the memory to carve the dynamically allocated arrays from.

References bit_list_sizeof(), _GRBP_clusterList::clusters, GRBP_clusterListReset(), _GRBP_clusterUpdateList::list, _GRBP_clusterList::max, and _GRBP_clusterList::upd.

Referenced by GRBP_cacheConstruct().

void GRBP_clusterListReset ( GRBP_clusterList clusterList  ) 

Resets the specified cluster list.

Parameters:
clusterList The cluster list to reset

References _GRBP_clusterList::beg, cluster_reset(), _GRBP_clusterList::clusters, _GRBP_clusterList::cnt, _GRBP_clusterList::cur, and _GRBP_clusterList::max.

Referenced by GRBP_cacheReset(), and GRBP_clusterListConstruct().

int GRBP_clusterListSizeof ( int  cluster_count,
int  photon_count 
)

Calculates the size, in bytes, to hold a cluster list with cluster_count clusters and a cross-reference array of for photon_count photons.

Returns:
The number of bytes to hold the specified cluster list.
Parameters:
cluster_count The number of clusters and, implicitly, the size of each cluster (i.e. the number of neighbors), of the cluster list
photon_count The number of photons on the master photon list. This is used to for a cross-reference list between a photon and a cluster member

References neighbor_list_sizeof().

Referenced by GRBP_cacheSizeof().


Generated on Tue Nov 29 17:07:16 2011 by  doxygen 1.5.8