Message: Re: Why Be7 isotope does not exist in geant4.5.0? Not Logged In (login)
 Next-in-Thread Next-in-Thread
 Next-in-Forum Next-in-Forum

None Re: Why Be7 isotope does not exist in geant4.5.0? 

Forum: Particles
Re: Question Why Be7 isotope does not exist in geant4.5.0? (Arkadiusz Bubak)
Re: None Re: Why Be7 isotope does not exist in geant4.5.0? (Vladimir Ivanchenko)
Re: Question Re: Why Be7 isotope does not exist in geant4.5.0? (Arkadiusz Bubak)
Date: 21 Jan, 2003
From: Vladimir Ivanchenko <Vladimir Ivanchenko>

On Tue, 21 Jan 2003, Arkadiusz Bubak wrote:

> *** Discussion title: Particles
> Email replies to PublicHyperNews@slac.stanford.edu must include:
>   In-Reply-To: <"/particles/14/1/1"@geant4-hn.slac.stanford.edu>
>   Subject: ...change this to be about your reply.
> 
> As I understand the problem appear during lowEnergyIonisation process.
> Belowe I enclose whole subfuntion which I use inside my PhysicsList. And
> what the problem is?
> 
> void pisaPhysicsList::ConstructEM() {
> 
>   theParticleIterator->reset();
>   while((*theParticleIterator)() )
>     {
>       G4ParticleDefinition* particle = theParticleIterator->value();
>       G4ProcessManager* pmanager = particle->GetProcessManager();
>       G4String particleName = particle->GetParticleName();
>       G4String particleType = particle->GetParticleType();
>       G4double charge = particle->GetPDGCharge();
> 

=====> should be removed
>       //processes
>       G4LowEnergyPhotoElectric  *lowePhot      = new G4LowEnergyPhotoElectric();
>       G4LowEnergyIonisation     *loweIon       = new G4LowEnergyIonisation();
>       G4LowEnergyBremsstrahlung *loweBrem      = new G4LowEnergyBremsstrahlung();
>       G4MultipleScattering      *aMultipleScattering = new G4MultipleScattering();
>       G4hLowEnergyIonisation    *ahadronLowEIon = new G4hLowEnergyIonisation();
=====>

These lines should be removed! They do not provide crash of the code or
wrong results but leackage and mess -> for each particles all these 5
processes are created. Below I will show where to put "new" statements.

> 
>       // note LowEIon uses proton as basis for its data-base, therefore
>       // cannot specify different LowEnergyIonisation models for different
>       // particles, but can change model globally for Ion, Alpha and Proton.
> 
>       if (particleName == "gamma") {
>         //gamma

   G4LowEnergyPhotoElectric  *lowePhot = new G4LowEnergyPhotoElectric();


>         pmanager->AddDiscreteProcess(new G4LowEnergyRayleigh());
>         pmanager->AddDiscreteProcess(lowePhot);
>         pmanager->AddDiscreteProcess(new G4LowEnergyCompton());
>         pmanager->AddDiscreteProcess(new G4LowEnergyGammaConversion());
> 
>       } else if (particleName == "e-") {
>         //electron
>         // process ordering: AddProcess(name, at rest, along step, post step)
>         // -1 = not implemented, then ordering............

   G4LowEnergyIonisation *loweIon = new G4LowEnergyIonisation();
   G4LowEnergyBremsstrahlung *loweBrem = new G4LowEnergyBremsstrahlung();
   G4MultipleScattering *aMultipleScattering = new G4MultipleScattering();
   loweIon->ActivateFluorecsence(false);

>         pmanager->AddProcess(aMultipleScattering,  -1, 1,1);
>         pmanager->AddProcess(loweIon,              -1, 2,2);
>         pmanager->AddProcess(loweBrem,             -1,-1,3);
> 
>       } else if (particleName == "e+") {
>         //positron

   G4MultipleScattering *aMultipleScattering = new G4MultipleScattering();

>         pmanager->AddProcess(aMultipleScattering,        -1, 1,1);
>         pmanager->AddProcess(new G4eIonisation(),        -1, 2,2);
>         pmanager->AddProcess(new G4eBremsstrahlung(),    -1,-1,3);
>         pmanager->AddProcess(new G4eplusAnnihilation(),   0,-1,4);      
> 
>       } else if( particleName == "mu+" || 
>                  particleName == "mu-"    ) {
>         //muon  

   G4MultipleScattering *aMultipleScattering = new G4MultipleScattering();

>         pmanager->AddProcess(aMultipleScattering, -1, 1, 1);
>         pmanager->AddProcess(new G4MuIonisation(), -1, 2, 2);
>         pmanager->AddProcess(new G4MuBremsstrahlung(), -1, -1, 3);
>         pmanager->AddProcess(new G4MuPairProduction(), -1, -1, 4);
>         pmanager->AddProcess(new G4MuonMinusCaptureAtRest(),0,-1,-1);
> 
>       } else if (particleName == "GenericIon" || 
>                  (particleType == "nucleus" && charge != 0)) {
>         // OBJECT may be dynamically created as either a GenericIon or a nucleus
>         // G4Nucleus exists and therefore has particle type nucleus
>         // genericIon:

   G4MultipleScattering *aMultipleScattering = new G4MultipleScattering();
   G4hLowEnergyIonisation  *ahadronLowEIon = new G4hLowEnergyIonisation();

>         pmanager->AddProcess(aMultipleScattering,-1,1,1);
>         pmanager->AddProcess(ahadronLowEIon,-1,2,2); 
> 
>       } else if (particleName == "Alpha") {
>         // alpha:       

   G4MultipleScattering *aMultipleScattering = new G4MultipleScattering();
   G4hLowEnergyIonisation  *ahadronLowEIon = new G4hLowEnergyIonisation();

>         pmanager->AddProcess(aMultipleScattering,-1,1,1);
>         pmanager->AddProcess(ahadronLowEIon,-1,2,2);
> 
>       } else if (particleName == "Proton") {    

   G4MultipleScattering *aMultipleScattering = new G4MultipleScattering();
   G4hLowEnergyIonisation  *ahadronLowEIon = new G4hLowEnergyIonisation();

>         pmanager->AddProcess(aMultipleScattering,-1,1,1);
>         pmanager->AddProcess(ahadronLowEIon,-1,2,2);
> 
>       } else if (particleName == "deuteron"  
>                  || particleName == "triton"  
>                  || particleName == "He3") {

   G4MultipleScattering *aMultipleScattering = new G4MultipleScattering();
   G4hLowEnergyIonisation  *ahadronLowEIon = new G4hLowEnergyIonisation();


>         pmanager->AddProcess(aMultipleScattering,-1,1,1);
>         pmanager->AddProcess(ahadronLowEIon,-1,2,2);
> 

=====> These should be removed

>       } else if ((!particle->IsShortLived()) &&
>                  (particle->GetPDGCharge() != 0.0)) {
>         //all others charged particles
>         pmanager->AddProcess(aMultipleScattering,-1,1,1);
>         pmanager->AddProcess(ahadronLowEIon,       -1,2,2);      
>       }
> 
>       ahadronLowEIon->SetNuclearStoppingOn() ;
> 
>       //fluorescence switch off for hadrons (for now):
>       ahadronLowEIon->SetFluorescence(false);
> 
>       //fluorescence apply specific cut for flourescence from photons, electrons
>       //and bremsstrahlung photons:
>       G4double cut = 250*eV;
>       lowePhot->SetCutForLowEnSecPhotons(cut);
>       loweIon->SetCutForLowEnSecPhotons(cut);
>       loweBrem->SetCutForLowEnSecPhotons(cut);
> 
>       //ahadronLowEIon->SetNuclearStoppingOff() ;
> 
=========>
>     }
> 
> }
> 

Should work.

VI

Inline Depth:
 1 1
 All All
Outline Depth:
 1 1
 2 2
 All All
Add message: (add)

 Add Message Add Message
to: "Re: Why Be7 isotope does not exist in geant4.5.0?"

 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 ]