triqs.dos.dos.dos_from_file

triqs.dos.dos.dos_from_file(Filename, name='', single_orbital=None)[source]

Read a (multi-)orbital DOS from a whitespace-separated text file.

Parameters:
Filenamestr

Path to the text file containing the DOS data.

namestr, optional

Name to attach to the resulting DOS object(s). Default ''.

single_orbitalint, optional

If given, return only the DOS for the single_orbital-th column (1-based). If None (default), return one DOS per orbital column.

Returns:
DOS or list of DOS

A single DOS when single_orbital is set, otherwise a list with one DOS per orbital column (even when there is only one orbital).

Notes

The file format has N_orbitals + 1 whitespace-separated columns per row: the first column holds energy values \(\epsilon_i\) and the remaining columns hold the DOS values for each orbital.