chemcoord.Zmat.subs
- Zmat.subs(*args, **kwargs)
Substitute a symbolic expression in
['bond', 'angle', 'dihedral']
This is a wrapper around the substitution mechanism of sympy. Any symbolic expression in the columns
['bond', 'angle', 'dihedral']
ofself
will be substituted with value.Note
This function is not side-effect free. If all symbolic expressions are evaluated and are concrete numbers and
perform_checks
is True, a check for the transformation to cartesian coordinates is performed. If noInvalidReference
exceptions are raised, the resulting cartesian is written toself._metadata['last_valid_cartesian']
.- Parameters:
symb_expr (sympy expression)
value
perform_checks (bool) – If
perform_checks is True
, it is asserted, that the resulting Zmatrix can be converted to cartesian coordinates. Dummy atoms will be inserted automatically if necessary.
- Returns:
Zmatrix with substituted symbolic expressions. If all resulting sympy expressions in a column are numbers, the column is recasted to 64bit float.
- Return type: