Message: Re: Model a crossing muon in a ccd cell Not Logged In (login)
 Next-in-Thread Next-in-Thread
 Next-in-Forum Next-in-Forum

Question Re: Model a crossing muon in a ccd cell 

Forum: Space Applications
Re: None Model a crossing muon in a ccd cell (Pierre)
Date: 16 May, 2014
From: Pierre <Pierre>

Hello everyone,

I realized that it was better for me to use the GeneralParticleSource in order to simulate the radiative environment.

So here is my code :


G4VPrimaryGenerator* PrimaryGeneratorAction::InitializeGPS()
  G4GeneralParticleSource* gps = new G4GeneralParticleSource();

  // setup details easier via UI commands see gps.mac

  // particle type
  G4ParticleTable* particleTable = G4ParticleTable::GetParticleTable();
  G4ParticleDefinition* muon = particleTable->FindParticle("mu-");  

  // set energy distribution
  G4SPSEneDistribution* energy_distribution = gps->GetCurrentSource()->GetEneDist() ;
  energy_distribution->SetEnergyDisType("Mono"); // or gauss

  // set position distribution
  G4SPSPosDistribution* position_distribution = gps->GetCurrentSource()->GetPosDist();
  position_distribution->SetPosDisType("Beam");  // or Point,Plane,Volume,Beam

  // set angular distribution
  G4SPSAngDistribution* angular_distribution = gps->GetCurrentSource()->GetAngDist();
  angular_distribution->SetParticleMomentumDirection( G4ThreeVector(0., 0., 0.) );

  //valid options are:
  // iso, cos, user, planar, beam2d, beam1d

  return gps;



My question is how to modify the GPS in order to simulate a sphere (an isotropic source which contain a smaller detector) where particles are generated from and cross the inside in a random way ? And calculate the energy deposited in the detector by the particles which crossed the detector ?

Thank you in advance,


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

1 None: Re: Model a crossing muon in a ccd cell   (Pierre - 19 May, 2014)
(_ None: Re: Model a crossing muon in a ccd cell   (michel maire - 19 May, 2014)
(_ None: Re: Model a crossing muon in a ccd cell   (John Allison - 19 May, 2014)
 Add Message Add Message
to: "Re: Model a crossing muon in a ccd cell"

 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 ]