Status of Emc fast simulation: o PacEmc package: - PacEmcDigi (modified from Babar's EmcDigi) private: // Data members double _energy; const TwoCoordIndex* _tci; double _thetaReal; double _phiReal; HepPoint *_where; ** Babar's EmcDigi has other information such as time and calibration. - PacEmcCluster (modified from Babar's EmcCluster) private: // Members std::vector< PacEmcDigi* > *_pacEmcDigis; unsigned _nbumps; std::vector< GTrack > *_gtracks; // Cachable data mutable bool _energyValid; mutable double _energy; mutable bool _whereValid; mutable HepPoint* _where; mutable PacEmcClusterEnergySums* _theClusEnergySums; mutable PacEmcXClMoments* _theClusXClMoments; - PacEmcClusterEnergySums for calculating e1, e9, e25, e1/e9, e9/e25. - PacEmcXClMoments for calculating secondMoment, lat, zernike moments. - PacEmcClusterMeas class PacEmcClusterMeas : public PacMeasurement has one method: void createCluster(const PacSimHit& hit, PacEmcCluster *cluster) const; in which it simply request for a PacEmcShowerLib from the global environment and sample a cluster given a PacSimHit: const PacEmcShowerLib* showerlib= Ifd< PacEmcShowerLib >::get(gblPEnv, SOMEKEY ); cluster= showerlib->sample_cluster(&hit); - PacEmcShowerLib The shower library interface class, providing pure virtual methods which are the interface to the underlying shower library. o Design of the shower library storage: - Use TTrees stored in root files. - Each TTree contains N entries, each represents an EMC cluster. - Each TTree represents cluster samples in a certain bin of momentum/[other binning quantities such as incident angle] for each particle type : will have a lot of trees. - A cluster is represented by theta/phi local coordinates (integers) and energies, each represents the crystal location relative to the crystal intersect with the GTrack. The actual implemetation can either be a new class (e.g., TCluster) that has three std::vector<> member lists, or a TClonesArray of a crystal class (e.g., TCrystal), which has three numbers as its members, or simply three parallel branches, just like what we got when using HTValOrderedVector to create an ntuple with beta. o At the start up of the program, we have to find all trees and create a map so that for a given PacSimHit we can find the corresponding tree, but we don't want to load the tree until we want to create a cluster.