- Timestamp:
- Sep 30, 2010, 2:47:17 PM (14 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/source/processes/electromagnetic/xrays/src/G4Scintillation.cc
r1315 r1337 25 25 // 26 26 // 27 // $Id: G4Scintillation.cc,v 1.3 1 2010/05/27 20:49:40 gumExp $28 // GEANT4 tag $Name: geant4-09-04-beta- cand-01 $27 // $Id: G4Scintillation.cc,v 1.32 2010/06/16 15:34:15 gcosmo Exp $ 28 // GEANT4 tag $Name: geant4-09-04-beta-01 $ 29 29 // 30 30 //////////////////////////////////////////////////////////////////////// … … 71 71 #include "G4Scintillation.hh" 72 72 73 using namespace std;74 75 73 ///////////////////////// 76 74 // Class Implementation … … 214 212 if (MeanNumberOfPhotons > 10.) 215 213 { 216 G4double sigma = ResolutionScale * s qrt(MeanNumberOfPhotons);214 G4double sigma = ResolutionScale * std::sqrt(MeanNumberOfPhotons); 217 215 NumPhotons = G4int(G4RandGauss::shoot(MeanNumberOfPhotons,sigma)+0.5); 218 216 } … … 281 279 GetConstProperty("YIELDRATIO"); 282 280 if ( ExcitationRatio == 1.0 ) { 283 Num = G4int ( min(YieldRatio,1.0) * NumPhotons);281 Num = G4int (std::min(YieldRatio,1.0) * NumPhotons); 284 282 } 285 283 else { 286 Num = G4int ( min(ExcitationRatio,1.0) * NumPhotons);284 Num = G4int (std::min(ExcitationRatio,1.0) * NumPhotons); 287 285 } 288 286 ScintillationTime = aMaterialPropertiesTable-> … … 330 328 331 329 G4double cost = 1. - 2.*G4UniformRand(); 332 G4double sint = s qrt((1.-cost)*(1.+cost));330 G4double sint = std::sqrt((1.-cost)*(1.+cost)); 333 331 334 332 G4double phi = twopi*G4UniformRand(); 335 G4double sinp = s in(phi);336 G4double cosp = cos(phi);333 G4double sinp = std::sin(phi); 334 G4double cosp = std::cos(phi); 337 335 338 336 G4double px = sint*cosp; … … 355 353 356 354 phi = twopi*G4UniformRand(); 357 sinp = s in(phi);358 cosp = cos(phi);355 sinp = std::sin(phi); 356 cosp = std::cos(phi); 359 357 360 358 photonPolarization = cosp * photonPolarization + sinp * perp; … … 392 390 if (ScintillationRiseTime==0.0) { 393 391 deltaTime = deltaTime - 394 ScintillationTime * log( G4UniformRand() );392 ScintillationTime * std::log( G4UniformRand() ); 395 393 } else { 396 394 deltaTime = deltaTime + … … 633 631 // make sure the envelope function is 634 632 // always larger than the bi-exponential 635 G4double t = -1.0*tau2* log(1-ran1);633 G4double t = -1.0*tau2*std::log(1-ran1); 636 634 G4double g = d*single_exp(t,tau2); 637 635 if (ran2 <= bi_exp(t,tau1,tau2)/g) return t;
Note: See TracChangeset
for help on using the changeset viewer.