# Can Garfield++ simulate multiple particles?

**URL:** <https://root-forum.cern.ch/t/can-garfield-simulate-multiple-particles/53528>\
**Category:** Garfield++\
**Created:** [February 8, 2023, 12:31pm UTC](https://root-forum.cern.ch/t/can-garfield-simulate-multiple-particles/53528 "2023-02-08T12:31:08Z")\
**Posts on this page:** 5\
**Page:** 1

<div class="post-metadata">

**Author:** ![Zhixuan\_He](https://root-forum.cern.ch/user_avatar/root-forum.cern.ch/zhixuan_he/32/23812_2.png) [@Zhixuan\_He](https://root-forum.cern.ch/u/Zhixuan_He)\
**Post date:** [February 8, 2023, 12:31pm UTC](https://root-forum.cern.ch/t/can-garfield-simulate-multiple-particles/53528/1 "2023-02-08T12:31:09Z")

</div>

I would like to simulate the ionization and collection of electrons using Garfield++ by assigning a trigger (or event) where two or more charged particles enter the same drift cell and produce tracks. Can Garfield++ simulate the production of tracks by multiple particles at the same time?

---

<div class="post-metadata">

**Author:** ![hschindl](https://root-forum.cern.ch/letter_avatar_proxy/v4/letter/h/977dab/32.png) [@hschindl](https://root-forum.cern.ch/u/hschindl)\
**Post date:** [February 8, 2023, 5:34pm UTC](https://root-forum.cern.ch/t/can-garfield-simulate-multiple-particles/53528/2 "2023-02-08T17:34:26Z")

</div>

Yes, you can superimpose the signals from multiple tracks in one “event”. The “Sensor” class will accumulate all induced signals between calls to the function “NewSignal”.

---

<div class="post-metadata">

**Author:** ![Zhixuan\_He](https://root-forum.cern.ch/user_avatar/root-forum.cern.ch/zhixuan_he/32/23812_2.png) [@Zhixuan\_He](https://root-forum.cern.ch/u/Zhixuan_He)\
**Post date:** [February 9, 2023, 2:50am UTC](https://root-forum.cern.ch/t/can-garfield-simulate-multiple-particles/53528/3 "2023-02-09T02:50:56Z")

</div>

Thank you!!! I added one new track successfully to the “Track”, and the amplitude of the signal is higher. The “call to the function NewSignal” process don’t need to be written in the main program by me, right?

---

<div class="post-metadata">

**Author:** ![hschindl](https://root-forum.cern.ch/letter_avatar_proxy/v4/letter/h/977dab/32.png) [@hschindl](https://root-forum.cern.ch/u/hschindl)\
**Post date:** [February 9, 2023, 2:38pm UTC](https://root-forum.cern.ch/t/can-garfield-simulate-multiple-particles/53528/4 "2023-02-09T14:38:24Z")

</div>

Hi,  
I’m not sure I understood the question, but you **do** need to call `Sensor::NewSignal` if you want to start a “new event” (i. e. reset the signal).

---

<div class="post-metadata">

**Author:** ![system](https://root-forum.cern.ch/uploads/default/original/3X/e/f/efe4f24398fd8ffeb76bccb6ecc46d9d9c003376.png) [@system](https://root-forum.cern.ch/u/system)\
**Post date:** [February 23, 2023, 2:39pm UTC](https://root-forum.cern.ch/t/can-garfield-simulate-multiple-particles/53528/5 "2023-02-23T14:39:22Z")

</div>

Closed on February 23, 2023, 2:39pm UTC

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