# No medium at initial position

**URL:** <https://root-forum.cern.ch/t/no-medium-at-initial-position/46130>\
**Category:** Garfield++\
**Tags:** root\
**Created:** [August 2, 2021, 4:05pm UTC](https://root-forum.cern.ch/t/no-medium-at-initial-position/46130 "2021-08-02T16:05:22Z")\
**Posts on this page:** 4\
**Page:** 1

<div class="post-metadata">

**Author:** ![Christian](https://root-forum.cern.ch/letter_avatar_proxy/v4/letter/c/b2d939/32.png) [@Christian](https://root-forum.cern.ch/u/Christian)\
**Post date:** [August 2, 2021, 4:05pm UTC](https://root-forum.cern.ch/t/no-medium-at-initial-position/46130/1 "2021-08-02T16:05:23Z")

</div>

Hi! I didn’t find any related topic so I’m gonna post a new one.  
So, I run my program with a geometry using `ComponentElmer` and load the initial ionization positions from a ROOT file. But I keep getting the following error message just before the execution of the avalanche `AvalancheMicroscopic::TransportElectron: No medium at initial position.`  
I tryed to exagerate the the sensor area at Garfield but it still doesn’t work.  
Actually the beginning of the log is this:

```auto
Heed:
    Database path: /home/christian/Programas/garfield/Heed/heed++/database/
MediumMagboltz::SetComposition:
    Ar/CO2 (70/30)
MediumMagboltz::EnablePenningTransfer:
    Global Penning transfer parameters set to:
    r = 0.6
    lambda = 0 cm
MediumMagboltz::EnablePenningTransfer:
    Warning: present gas table has no ionisation rates.
    Ignore this message if you are using microscopic tracking only.
MediumMagboltz::EnablePenningTransfer:
    Updated Penning transfer parameters for 44 excitation cross-sections.
ComponentElmer::Initialise:
    Read 107042 nodes and 68734 elements from file thgem/mesh.header.
ComponentElmer::Initialise:
    Set material 0 of 4 to eps 1.
ComponentElmer::Initialise:
    Set material 1 of 4 to eps 1.
ComponentElmer::Initialise:
    Set material 2 of 4 to eps 3.4.
ComponentElmer::Initialise:
    Set material 3 of 4 to eps 1.
ComponentElmer::Initialise: Finished.
ComponentElmer::PrintRange:
        Dimensions of the elementary block
                     -0.025 < x < 0.025 cm,
                 -0.0866025 < y < 0.0866025 cm,
                     -0.526 < z < 0.526 cm,
                      -3700 < V < 0 V.
        Periodicities
            x: mirror with length 0.05 cm
            y: simple with length 0.173205 cm
            z: none
Sensor::SetTimeWindow: Resetting all signals.
ComponentElmer::FindElement13:
    Caching the bounding boxes of all elements... done.
ComponentElmer::InitializeTetrahedralTree: Success.
AvalancheMicroscopic::TransportElectron: No medium at initial position.
X coordinate: 0.26
Y coordinate: 0
Z coordinate: 0
Avalanche number 1 is done.
AvalancheMicroscopic::TransportElectron: No medium at initial position.
X coordinate: 0.345388
Y coordinate: 0.668792
Z coordinate: -2.50047
Avalanche number 2 is done.

```

My code compiles fine, and that message appears for all avalanches.  
[gem.C](https://root-forum.cern.ch/uploads/short-url/fgfqU4ek4mGQIazhQeEF22RDzpv.C) (6.5 KB)  
I have a very similar code that works fine, and I tried to rebuild my new code using the previous one many times, and it still doesn’t work.

I could really use some help, many thanks if some give me some enlightening.

---

<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:** [August 2, 2021, 4:30pm UTC](https://root-forum.cern.ch/t/no-medium-at-initial-position/46130/2 "2021-08-02T16:30:26Z")

</div>

Hi,  
your field map seems to contain four regions/materials? What do they correspond to? Are you sure that material 0 is the gas?

---

<div class="post-metadata">

**Author:** ![Christian](https://root-forum.cern.ch/letter_avatar_proxy/v4/letter/c/b2d939/32.png) [@Christian](https://root-forum.cern.ch/u/Christian)\
**Post date:** [August 2, 2021, 7:07pm UTC](https://root-forum.cern.ch/t/no-medium-at-initial-position/46130/3 "2021-08-02T19:07:17Z")

</div>

Hi! I just found out what was the issue, there was a region with kapton material that was of no interest propagating for me, and I forgot about that. Thanks for the help anyway!

---

<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:** [August 16, 2021, 7:07pm UTC](https://root-forum.cern.ch/t/no-medium-at-initial-position/46130/4 "2021-08-16T19:07:35Z")

</div>

Closed on August 16, 2021, 7:07pm UTC

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