Problem 1968

Summary: Bug in G4Ions::FloatLevelBase(G4int flbIdx)
Product: Geant4 Reporter: pldrouin
Component: particlesAssignee: asai
Status: RESOLVED FIXED    
Severity: major CC: asai
Priority: P4    
Version: 10.3   
Hardware: All   
OS: All   

Description pldrouin 2017-05-01 20:13:53 CEST
The order of the floating levels is wrong in G4Ions::FloatLevelBase(G4int flbIdx). X, Y and Z should come before U, V, W, similarly to G4Ions::FloatLevelBaseChar(G4Ions::G4FloatLevelBase flb):

inline
 G4Ions::G4FloatLevelBase G4Ions::FloatLevelBase(G4int flbIdx)
{ 
  static G4Ions::G4FloatLevelBase flb[] =
  { noFloat,
    plusU, plusV, plusW, plusX, plusY, plusZ,
    plusR, plusS, plusT, plusA, plusB, plusC, plusD, plusE };
  return flb[flbIdx];
}

inline
 char G4Ions::FloatLevelBaseChar(G4Ions::G4FloatLevelBase flb)
{ 
  static char flbChar[] = {'\0','X','Y','Z','U','V','W',
                                'R','S','T','A','B','C','D','E'};
  return flbChar[static_cast<G4int>(flb)];
}
Comment 1 asai 2017-05-01 20:37:41 CEST
Thank you for reporting this issue. We will fix it. The fix will be included in the next patch release.
Kind regards,
Makoto