Skip to content

Numerical improvements#232

Draft
daanboer wants to merge 41 commits intomainfrom
better-integrals
Draft

Numerical improvements#232
daanboer wants to merge 41 commits intomainfrom
better-integrals

Conversation

@daanboer
Copy link
Member

@daanboer daanboer commented Aug 12, 2025

This patch aims to implement a multitude of numerical improvements. I have opened this draft PR to track the progress, I might split the PR into multiple smaller PRs later down the line.

  • Analytical evaluation of the collision integrals
    • by assuming logarithmic decay of the EEDF between cells (similar to the strategy of BOLSIG+),
    • by assuming linear decay of the EEDF between cells (in theory less potent than the previous strategy, with the upside that it does not require iteration).
    • These strategies should be less sensitive to alignment of the threshold region of inelastic processes to the grid, but this is still to be tested thoroughly.
  • Scharfetter-Gummel discretization for the flux terms.
  • A total flux boundary condition (there is also some experimentation with a logarithmic decay boundary condition).
  • A Newton-Raphson based solving procedure for the nonlinear growth + ee terms.
  • The implementation supports nonuniform discretization.

Resolves #197
Relates to #205

@daanboer daanboer added the enhancement New feature or request label Aug 12, 2025
@daanboer daanboer mentioned this pull request Oct 1, 2025
@daanboer daanboer force-pushed the better-integrals branch 3 times, most recently from 9adb19d to f54e8a1 Compare December 5, 2025 12:53
@daanboer daanboer force-pushed the better-integrals branch 3 times, most recently from b14e760 to 36f0f46 Compare February 16, 2026 08:12
The function computes an analytic solution to the u*sig*f collision integrals,
assuming sig to be locally linearly dependent on u, and f to the locally
exponentially dependent on u.
Adds functions `collision_integral_sink` and `collision_integral_source` that
do the piecewise integration of the inelastic source terms.
This function uses the new method of computing the inelastic
collision integrals. The solution now requires iteration, hence
the new function. The nonconservative terms have been temporarily
disabled in `invertLinearMatrix`, to allow for comparison between
the two functions.
These functions directly interpolate the given cross section
from the raw data (skipping an interpolation onto the grid
faces). These functions are a bit more involved, as the
cross section grid needs to be taken into account when
splitting up the energy domain for integration.
Done to compare the original solution to the solution
proposed on this branch. This currently includes growth
schemes, ionization, attachment and e-e collisions.
To compare to the Scharfetter-Gummel scheme.
There is a bug in the source term.
Change perspective of u_start to upper energy.
This is used as a test case for integrating different quantities.
Currently it only computes the mobility in two different ways.
The idea is that using this machinery we can easily build expressions that
fold the EEDF with other quantities, while also easily being able to switch
between the different interpolating expressions for the EEDF.
These functions use the new iterator/integrator machinery.
The grid iterator sometimes got stuck when integrating the superelastic
source on (very) large grids. This is fixed by adding a small epsilon
in the lhs of the predicate.
The procedures now use a linear integrator.
The new `InterpolatingIterator` machinery only work for cross
sections that start their energy domain at zero energy for now.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

enhancement New feature or request

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Implement a single flux-boundary condition

2 participants