Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Adding nlte_rate_equation_solver.py (#2140)
* added nlte_rate_equation_matrix * adding the rate_equation_matrix * moved rate_matrix into a class NLTERateEquationSolver * fixed a bug in rate_matrix_index, added an example for checking if rate matrix works properly * changed the initial electron density for now * added tests, fixed a small bug * added some doctrings * fixed a typo * added some doctrings * added some doctrings part 2 * added some docstrings part 3 * removed unnecessary import * Update tardis/plasma/properties/nlte_rate_equation_solver.py Co-authored-by: Christian Vogl <[email protected]> * changed how atomic number is created from rate_matrix_index * changed call of a function * got rid of unnecessary if statement in set_nlte_ion_rate * renamed last_row to charge_conservation_row * switched 0, 1 to atomic_number and ion_number to make it more readable * swtihed from rates to coefficients * changed the matrix set up to only keep necessary row for nlte_ion * ran black * fixing some doctrings * swtiched from using numbers to index names * switched the return statement to NotImplementedError * changed groupby from 0, 1 to atomic number, ion number * fixed an issue in the test * ran black Co-authored-by: Christian Vogl <[email protected]>
- Loading branch information