grogupy._core.get_number_of_electrons
- grogupy._core.get_number_of_electrons(dm: str | DensityMatrix) int[source]
Determines the number of electrons in the system from the density matrix.
Parameters
- dmUnion[str, sisl.DensityMatrix]
The path to the fdf file or the sisl density matrix
Returns
- enumint
Number of electrons in the system
Raises
- Exception
Number of electrons could not be determined!