tcutility.analysis.vdd package#

Submodules#

tcutility.analysis.vdd.charge module#

class VDDCharge(atom_index, atom_symbol, charge, frag_index)[source]#

Bases: object

atom_index: int#
atom_symbol: str#
charge: float#
frag_index: int#
change_unit(ratio)[source]#

tcutility.analysis.vdd.manager module#

change_unit_decorator(func)[source]#
create_vdd_charge_manager(results)[source]#

Create a VDDChargeManager from a Result object.

Return type:

VDDChargeManager

class VDDChargeManager(vdd_charges, is_fragment_calculation, calc_dir, mol_charge)[source]#

Bases: object

Class to manage the VDD charges. It can be used to print the VDD charges in a nice table and write them to a text file or excel file.

vdd_charges: Dict[str, List[VDDCharge]]#
is_fragment_calculation: bool#
calc_dir: Path#
mol_charge: int#
name: str#
unit: str#
irreps: List[str]#
charge_is_conserved()[source]#

Check if the total charge of the molecule is conserved. The total charge is the sum of the VDD charges.

Return type:

bool

change_unit(new_unit)[source]#

Change the unit of the VDD charges. Available units are “me” (mili-electrons) and “e” (electrons).

Return type:

None

get_vdd_charges()[source]#

Get the VDD charges in the specified unit ([me] or [e]).

Return type:

Dict[str, List[VDDCharge]]

get_summed_vdd_charges(irreps=None)[source]#

Get the summed VDD charges per fragment for the specified unit ([me] or [e]).

Return type:

Dict[str, Dict[str, float]]

get_vdd_charges_dataframe()[source]#

Get the VDD charges as a pandas DataFrame in a specified unit ([me] or [e]).

Return type:

DataFrame

get_summed_vdd_charges_dataframe()[source]#

Get the summed VDD charges as a pandas DataFrame in a specified unit ([me] or [e]).

Return type:

DataFrame

get_vdd_charges_table()[source]#
Return type:

str

get_summed_vdd_charges_table()[source]#
Return type:

str

static write_to_txt(output_dir, managers, unit='me')[source]#

Write the VDD charges to a text file. It is a static method because multiple managers can be written to the same file.

Return type:

None

write_to_excel(output_file=None)[source]#

Write the VDD charges to an excel file. Results are written to two sheets: “VDD charges” and “Summed VDD charges”.

Return type:

None

plot_vdd_charges_per_atom(output_file=None, unit='me')[source]#

Plot the VDD charges as a bar graph for each irrep.

Return type:

None

Module contents#