Message: Re: Arbitrary Position Distribution With G4GeneralParticleSource Not Logged In (login)
 Next-in-Thread Next-in-Thread
 Next-in-Forum Next-in-Forum

None Re: Arbitrary Position Distribution With G4GeneralParticleSource 

Forum: Event and Track Management
Re: Question Arbitrary Position Distribution With G4GeneralParticleSource
Re: None Re: Arbitrary Position Distribution With G4GeneralParticleSource (Marc Verderi)
Date: 23 Apr, 2015
From: <herr_apa>

Hi Marc,

> One thing is that you are able to get a 2D display of the source: does 
> it come from an analytic pattern, or an other simulation tool, etc. ? 
> The idea would be to exploit this (display, or analytical form, 
> whatever) as 2D input + intensity to sample your distribution.

The distribution comes from an experimental measurement, so it can't be described by an analytical formula. What I can do is to represent the source intensity as an n-by-m matrix, the value of each element being the intensity at a given position (let's call that position a pixel). If I understand you correctly, you are suggesting to model my source as a collection of n*m point sources. The position of each point source would be at the center of a pixel, and the intensity would be taken from the n-by-m matrix. That could work! Would this mean that the source would emit multiple particles per event? Or would it still just be one primary vertex per event, sampled according to the intensity distribution?

What do you think is the best way to implement this from a programmatic point of view? Right now, I'm configuring the GPS entirely via macro commands. Could I get away with defining the particle and energy/position distributions once, and then calling

/gps/source/add <intensity>

/gps/pos/centre <x y z>

once for each pixel? Or even better, could I move the addition of the pixels from the macro to the source? I imagine that I would read the n-by-m matrix from a file and then add the sources dynamically (whereas in a macro file I would have to hard-code them).

// Anders

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

1 None: Re: Arbitrary Position Distribution With G4GeneralParticleSource   (Marc Verderi - 23 Apr, 2015)
2 None: Re: Arbitrary Position Distribution With G4GeneralParticleSource   (michel maire - 23 Apr, 2015)
 Add Message Add Message
to: "Re: Arbitrary Position Distribution With G4GeneralParticleSource"

 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 ]