Solvents#

class autode.solvent.solvents.ImplicitSolvent(name: str, smiles: str | None = None, aliases: List[str] | None = None, **kwargs)#

Implicit solvent

property atoms: Atoms | None#

Atoms in this solvent

property is_implicit: bool#

Is this solvent implicit?

Returns:

True

Return type:

(bool)

to_explicit(num: int) ExplicitSolvent#

Convert this implicit solvent into an explicit one

Raises:

(IOError) – If the expected 3D structure cannot be located

Returns:

Solvent

Return type:

(autode.solvent.explicit_solvent.ExplicitSolvent)

class autode.solvent.solvents.Solvent(name: str, smiles: str | None = None, aliases: List[str] | None = None, **kwargs)#
__eq__(other)#

Determine if two solvents are the same based on name and SMILES

__init__(name: str, smiles: str | None = None, aliases: List[str] | None = None, **kwargs)#

Abstract base class for a solvent. As electronic structure methods implement implicit solvation without a unique list of solvents there needs to be conversion between them, while also allowing for user specifying one possibility from a list of aliases

Parameters:
  • smiles (str | None) – SMILES string

  • aliases (list(str) | None) – Different names for the same solvent e.g. water and H2O. If None then will only use the name as an alias

Keyword Arguments:

kwargs (str) – Name of the solvent in the electronic structure package e.g. Solvent(…, orca=’water’)

__str__()#

Return str(self).

abstract property atoms: Atoms | None#

Atoms in this solvent

copy() Solvent#

Return a copy of this solvent

property dielectric: float | None#

Dielectric constant (ε) of this solvent. Used in implicit solvent models to determine the electrostatic interaction

Returns:

Dielectric, or None if unknown

Return type:

(float | None)

property is_explicit: bool#

Is this solvent explicit i.e. has atoms in space

abstract property is_implicit: bool#

Is this solvent implicit and just defined by a dielectric

randomise_around(solute: Species) None#
to_explicit(num: int) ExplicitSolvent#
autode.solvent.solvents.get_solvent(solvent_name: str | None, kind: str, num: int | None = None) Solvent | None#

For a named solvent return the Solvent which matches one of the aliases

Parameters:

num – Number of solvent molecules to include in the explicit solvent

Returns:

Solvent

Return type:

(autode.solvent.solvents.Solvent | None)

Raises:

(ValueError) – If both explicit and implicit solvent are selected