Localized Orbital Scaling Correction (LOSC) C library
LoscLocalizerV2 Struct Reference

The C interface for LOSC localizer version 2. More...

#include <localization.h>

Public Attributes

LoscLocalizerBasep_base
 A pointer to a LoscLocalizerBase variable. More...
 

Detailed Description

The C interface for LOSC localizer version 2.

LOSC localization version 2 is defined in Eq. 7 in the LOSC2 paper (J. Phys. Chem. Lett. 2020, 11, 4, 1528–1535).

See also
losc_localizer_v2_create(): create a LoscLocalizerV2.
losc_localizer_v2_create(): free a LoscLocalizerV2.

Member Data Documentation

LoscLocalizerBase* LoscLocalizerV2::p_base

A pointer to a LoscLocalizerBase variable.

Use this variable to call functions that are provided in the LoscLocalizerBase.

Example
Demo of calling functions that provided in the LoscLocalizerBase. Assume a variable pLocalizer exists with type of LoscLocalizerV1 *.
// Demo: Set maximum iteration number to be 100.
pLocalizer->p_base->set_max_iter(pLocalizer, 100);
// Demo: calculate LOs and U matrix.
// allocate LO coefficient matrix and U guess.
losc_matrix *L = losc_matrix_create(nbasis, nlo);
// assume U_data stores a unitary matrix.
losc_matrix *U = losc_matrix_create(nlo, nlo, U_data);
// calculate LO coefficient matrix and update U matrix.
pLocalizer->p_base->lo_U(pLocalizer->p_base, L, U);
See also
LoscLocalizerBase: see all the functions provided in the localizer base structure.