- Timestamp:
- Nov 5, 2010, 3:45:55 PM (14 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/source/processes/hadronic/models/util/src/G4Fancy3DNucleus.cc
r1196 r1340 61 61 } 62 62 63 63 #if defined(NON_INTEGER_A_Z) 64 64 void G4Fancy3DNucleus::Init(G4double theA, G4double theZ) 65 { 66 G4int intZ = G4int(theZ); 67 G4int intA= ( G4UniformRand()>theA-G4int(theA) ) ? G4int(theA) : G4int(theA)+1; 68 // forward to integer Init() 69 Init(intA, intZ); 70 71 } 72 #endif 73 74 void G4Fancy3DNucleus::Init(G4int theA, G4int theZ) 65 75 { 66 76 // G4cout << "G4Fancy3DNucleus::Init(theA, theZ) called"<<G4endl; … … 70 80 theRWNucleons.clear(); 71 81 72 myZ = G4int(theZ);73 myA= ( G4UniformRand()>theA-G4int(theA) ) ? G4int(theA) : G4int(theA)+1;82 myZ = theZ; 83 myA= theA; 74 84 75 85 theNucleons = new G4Nucleon[myA]; … … 144 154 if (theRWNucleons.size() < 2 ) return; 145 155 146 s ort( theRWNucleons.begin(),theRWNucleons.end(),G4Fancy3DNucleusHelperForSortInZ);156 std::sort( theRWNucleons.begin(),theRWNucleons.end(),G4Fancy3DNucleusHelperForSortInZ); 147 157 148 158 // now copy sorted nucleons to theNucleons array. TheRWNucleons are pointers in theNucleons … … 169 179 170 180 if (theRWNucleons.size() < 2 ) return; 171 s ort( theRWNucleons.begin(),theRWNucleons.end(),G4Fancy3DNucleusHelperForSortInZ);181 std::sort( theRWNucleons.begin(),theRWNucleons.end(),G4Fancy3DNucleusHelperForSortInZ); 172 182 173 183 // now copy sorted nucleons to theNucleons array. TheRWNucleons are pointers in theNucleons
Note: See TracChangeset
for help on using the changeset viewer.