---
name: "sc_MolEnergyConvergence"
section: "3"
platform: "linux"
package: "libsc-doc"
version: "2.3.1-22"
release: "Debian 12 (Bookworm)"
platforms: ["linux"]
url: "https://new.carta.tech/sc_MolEnergyConvergence"
---

# sc\_MolEnergyConvergence(3)

## NAME

sc::MolEnergyConvergence

## SYNOPSIS

Inherits **sc::Convergence**.

### Public Member Functions

**MolEnergyConvergence** (**StateIn** &)\
 **MolEnergyConvergence** (const **Ref**\< **KeyVal** \> &)\
 The **KeyVal** constructor.  void **save\_data\_state** (**StateOut** &)\
 Save the base classes (with save\_data\_state) and the members in the same order that the **StateIn** CTOR initializes them.  void **get\_grad** (const **Ref**\< **Function** \> &)\
 Set the current gradient and displacement.  void **get\_x** (const **Ref**\< **Function** \> &)\
 void **set\_nextx** (const **RefSCVector** &)\
 int **converged** ()\
 Return nonzero if the optimization has converged.

### Protected Member Functions

void **set\_defaults** ()\

### Protected Attributes

**Ref**\< **MolecularEnergy** \> **mole\_**\
 int **cartesian\_**\

### Additional Inherited Members

## Constructor & Destructor Documentation

### sc::MolEnergyConvergence::MolEnergyConvergence (const Ref\< KeyVal \> &)

The **KeyVal** constructor. In addition to the keywords read by **Convergence**, the following keywords are examined:

- `energy`

  The **MolecularEnergy** object. This is required.

- `cartesian`

  If true, cartesian displacements and gradients will be compared to the convergence criteria. The default is true.

## Member Function Documentation

### int sc::MolEnergyConvergence::converged ()` [virtual]`

Return nonzero if the optimization has converged.

Reimplemented from **sc::Convergence**.

### void sc::MolEnergyConvergence::get\_grad (const Ref\< Function \> &)` [virtual]`

Set the current gradient and displacement.

Reimplemented from **sc::Convergence**.

### void sc::MolEnergyConvergence::get\_x (const Ref\< Function \> &)` [virtual]`

Reimplemented from **sc::Convergence**.

### void sc::MolEnergyConvergence::save\_data\_state (StateOut &)` [virtual]`

Save the base classes (with save\_data\_state) and the members in the same order that the **StateIn** CTOR initializes them. This must be implemented by the derived class if the class has data.

Reimplemented from **sc::SavableState**.

### void sc::MolEnergyConvergence::set\_nextx (const RefSCVector &)` [virtual]`

Reimplemented from **sc::Convergence**.

## Author

Generated automatically by Doxygen for MPQC from the source code.
