How to get information about the arbitrary position of an electron in the track of a drifting avalanche process

Hello!
I know get the information the end point of the electron like
aval.GetElectronEndpoint(j, xe1, ye1, ze1, te1, e1, xe2, ye2, ze2, te2, e2, status);
But I want to get information like x, y , z , energy, t about the arbitrary position of an electron in the track of a drifting avalanche process. Does Garfield++ allow us to do this?
Thanks for your help!

Hi,
yes, you can use call-back functions (“user handles”) for this purpose. As an illustration
In this example such a function is to plot the z-coordinates of all excitations in the avalanche.
Currently, there are hooks available for calling a function at every step, at every collision, and for specific types of collisions.

Hi,
Thank you for your reply.
I have found a function ( AvalancheMicroscopic::GetElectronDriftLinePoint) . In this function I can get the coordinates include x y, z , t in the avalanche .Does this function meet my needs?
Also I will give the functions(“user handles”) a try.
Best wishes!
Anqi

Hi,
yes, good point, GetElectronDriftLinePoint should work. Note that by default AvalancheMicroscopic doesn’t store every single collision but only every 100th. You can change that using SetCollisionSteps.

Hi,
Thank you for your note.
I try the function aval.SetUserHandleInelastic(userHandle), but I have some uncertainty of the z-coordinates getting form that function . Can you give it a explanation?
Best wishes!
Anqi

It’s the z coordinate (in cm) where the inelastic collision occurred.

PS: the example I linked to in my previous reply was only meant as an illustration. You’ll probably need to adapt it to your needs…

Hi,
Thank you for your reply. Now I understand its usage.

Thank you again!
Best wishes!
Anqi

This topic was automatically closed 14 days after the last reply. New replies are no longer allowed.