Message: Re: Optical Physics List and G4exception Not Logged In (login)
 Next-in-Thread Next-in-Thread
 Next-in-Forum Next-in-Forum

Question Re: Optical Physics List and G4exception 

Forum: Physics List
Re: Question Optical Physics List and G4exception (Florian ITARD)
Re: None Re: Optical Physics List and G4exception (Florian ITARD)
Date: 26 Sep, 2008
From: Michael Fernald <Michael Fernald>

Hi,

I've had a very similar problem. When sending my program out to the cluster, I get the same error as you did. Unlike you, however, I have not been able to solve my problem.

Currently I'm using the G4LowEnergyPhotoElectric, G4LowEnergyRayleigh, G4LowEnergyCompton, and G4LowEnergyGammaConversion processes. I call them with AddDiscreteProcess().

Are there any ideas on how to solve this issue?

Below is my code. Beneath the code is the output from the cluster:

Thanks!

void VoxelPhantomPhysicsList::ConstructEM()
{
    theParticleIterator->reset();

    while( (*theParticleIterator)() )
    {
       G4ParticleDefinition* particle = theParticleIterator->value();
       G4ProcessManager* pmanager = particle->GetProcessManager();
       G4String particleName = particle->GetParticleName();

       //processes

       if (particleName == "gamma")
       {
          //gamma
          lowePhot = new  G4LowEnergyPhotoElectric("LowEnPhotoElec");
          pmanager->AddDiscreteProcess(new G4LowEnergyRayleigh);
          pmanager->AddDiscreteProcess(lowePhot);
          pmanager->AddDiscreteProcess(new G4LowEnergyCompton);
          pmanager->AddDiscreteProcess(new G4LowEnergyGammaConversion);
       }
       else if (particleName == "e-")
       {
          //electron
          loweIon  = new G4LowEnergyIonisation("LowEnergyIoni");
          loweBrem = new G4LowEnergyBremsstrahlung("LowEnBrem");
          loweBrem->SetAngularGenerator("tsai");

          pmanager->AddProcess(new G4MultipleScattering, -1, 1,1);
          pmanager->AddProcess(loweIon,     -1, 2,2);
          pmanager->AddProcess(loweBrem,    -1,-1,3);

       }
       else if (particleName == "e+")
       {
          //positron
          pmanager->AddProcess(new G4MultipleScattering, -1, 1,1);
          pmanager->AddProcess(new G4eIonisation,        -1, 2,2);
          pmanager->AddProcess(new G4eBremsstrahlung,    -1,-1,3);
          pmanager->AddProcess(new G4eplusAnnihilation,   0,-1,4);

       }
    }
}

=============================================================
 Run #: 0 starting.
 Number of events being processed : 86138
 Particle being used as source: gamma
 Percent completed: 0%
  G4ParticleChange::CheckIt    : the global time goes back  !!
  Difference:  0.003335641[ns] 
 G4ParticleChange::CheckIt 
      -----------------------------------------------
        G4ParticleChange Information  
      -----------------------------------------------
        # of 2ndaries       :                    0
      -----------------------------------------------
        Energy Deposit (MeV):                    0
        Non-ionizing Energy Deposit (MeV):                    0
        Track Status        :                Alive
        True Path Length (mm) :                   -1
        Stepping Control      :                    0
        Mass (GeV)   :            1.03e-318
        Charge (eplus)   :            1.03e-315
        MagneticMoment   :            1.03e-315
                :  =                    0*[e hbar]/[2 m]
        Position - x (mm)   :                  450
        Position - y (mm)   :                -95.1
        Position - z (mm)   :                 41.5
        Time (ns)           :             -0.00334
        Proper Time (ns)    :                    0
        Momentum Direct - x :               -0.512
        Momentum Direct - y :               -0.721
        Momentum Direct - z :                0.467
        Kinetic Energy (MeV):               0.0764
        Polarization - x    :                    0
        Polarization - y    :                    0
        Polarization - z    :                    0
        Touchable (pointer) :            0x40d5430

*** G4Exception : 200
      issued by : G4ParticleChange::CheckIt
momentum, energy, and/or time was illegal
*** Event Must Be Aborted 
Segmentation fault

 Add Message Add Message
to: "Re: Optical Physics List and G4exception"

 Subscribe Subscribe

This site runs SLAC HyperNews version 1.11-slac-98, derived from the original HyperNews


[ Geant 4 Home | Geant 4 HyperNews | Search | Request New Forum | Feedback ]