Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Material Interaction #282

Closed

Conversation

beomki-yeo
Copy link
Collaborator

No description provided.

@beomki-yeo beomki-yeo marked this pull request as draft July 18, 2022 21:39

struct pointwise_material_interactor : actor {

struct state {};
Copy link
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@niermann999
I am writing a material interactor inherited from actor
I need to access the tracking geometry information (material_store) in actor chain but propagation state doesn't have the tracking geometry information. What would be the ideal way to retrieve the geometry info?

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I think, it might be a good idea to move the detector pointer from the navigator into the navigator state and give it an access call. Then you could do smth like this: propagation._navigation.tracking_geometry(). Would that work for you?

@beomki-yeo beomki-yeo closed this Sep 16, 2022
@beomki-yeo beomki-yeo mentioned this pull request Sep 17, 2022
@beomki-yeo
Copy link
Collaborator Author

This PR is rewritten in #301, so let me it...

kodiakhq bot pushed a commit to acts-project/acts that referenced this pull request Apr 12, 2023
This PR fixes the Bethe energy loss function in `Interactions.cpp`

`Acts::computeEnergyLossBethe` and `Acts::computeEnergyLossLandau` is implemented from equation 33.5 and 33.11 of [Review in Particle Physics](https://journals.aps.org/prd/abstract/10.1103/PhysRevD.98.030001)

And their first term is computed with `computeEpsilon` function, following the notation of equation 33.11:

```c++
/// Compute epsilon energy pre-factor for RPP2018 eq. 33.11.
///
/// Defined as
///
///     (K/2) * (Z/A)*rho * x * (q²/beta²)
///
/// where (Z/A)*rho is the electron density in the material and x is the
/// traversed length (thickness) of the material.
inline float computeEpsilon(float molarElectronDensity, float thickness,
                            const RelativisticQuantities& rq) {
  return 0.5f * K * molarElectronDensity * thickness * rq.q2OverBeta2;
}
```

Problem is that the epsilon term of equation 33.5 for Bethe function doesnt have the `0.5f` term

Eq. 33.5
![image](https://user-images.githubusercontent.com/63090140/178590990-e4982315-42e2-4033-9bc7-84c6500b0b71.png)

Eq. 33.11
![image](https://user-images.githubusercontent.com/63090140/178591191-37bb33ba-93b9-424e-bb8b-9755c931d675.png)

If we are going to use the same epsilon term, we need to multiply 2 in the next term of Bethe energy loss function

After the change, the output of `Acts::computeEnergyLossBethe` gets consistent with Figure 33.2 of the reference.

### Update July 18th

Looks like there is a _literature_ error in Landau energy loss function (eq. 33.11).
It used the mass term of the incident particle (`m`), but I guess it should be the mass of electron (`m_e`) as equation 33.5.
**I need a cross-check from someone who can access [Straggling in thin silicon detectors](https://journals.aps.org/rmp/abstract/10.1103/RevModPhys.60.663), which I cannot** (Update: It is confirmed that it should be the rest mass of electron)

Finally, to get a consistent result of energy loss function, we need to fix the `computeDeltaHalf` term as well.
But this is already mentioned in the comment which says: "Should we use RPP2018 eq. 33.7 instead w/ tabulated constants?"

```c++
/// Compute the density correction factor delta/2.
///
/// Uses RPP2018 eq. 33.6 which is only valid for high energies.
///
/// @todo Should we use RPP2018 eq. 33.7 instead w/ tabulated constants?
inline float computeDeltaHalf(float meanExitationPotential,
                              float molarElectronDensity,
                              const RelativisticQuantities& rq) {
```

Yeah it does make big difference between 33.6 (valid for very high energy particles) and 33.7.
**I am not going to include delatHalf term correction in this PR**, but it is included in acts-project/detray#282


After fixing codes (including the deltaHalf term), the Bethe energy loss function matches to the value in ([PDG](https://pdg.lbl.gov/2022/AtomicNuclearProperties/index.html))

In the following figure, Bethe energy loss (dE/dx) in Silicon is compared for Acts main, this PR, acts-project/detray#282, and PDG value. The value from this PR is not accurate yet due to the incorrect deltaHalf term

<img src="https://user-images.githubusercontent.com/63090140/179622322-6c7170c9-7773-4eb4-a621-63e7429e3425.png" width="700">

For the most probable energy loss from Landau equation under the same condition of Figure 33.7 of [Review in Particle Physics](https://journals.aps.org/prd/abstract/10.1103/PhysRevD.98.030001)
, detray#282 got 0.526 MeV, which is very close to the value in the figure.
This PR got 0.739 MeV due to the incorrect delatHalf term
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants