QMol_TDCI_abs_CAP_space - fmauger1/QMol-grid GitHub Wiki

QMol_TDCI_abs_CAP_space

Complex absorbing potential type damping matrix for TDCI calculations built from the spatial extension of configuration states.

Description

Use QMol_TDCI_abs_CAP_space to build complex-absorbing potential (CAP) damping matrix for TDCI calculations based on the spatial overlap between the CI molecular-orbital basis and a spatial mask. The overlap mask is characterized by (i) the distance from the origin at which it starts, (ii) its width, (iii) its maximum amplitude, and (iv) its shape.

The CAP damping matrix is added to the CI matrix and thus automatically scales with the propagation time step.

Class properties

Complex absorbing potential (CAP)

The QMol_TDCI_abs_CAP_space class defines the following public get-access properties; each can be changed using the set method:

amplitude (V0)

Maximum amplitude of the CAP mask [ positive scalar (default 0.5) ]

  • When constructing the CAP, the selected shape is multiplied by the specified amplitude (including for user-defined shapes).

length (L)

Length of the CAP mask [ positive scalar (default 10) | positive vector [lengthLeft lengthRight] ]

  • Scalar length defines a CAP with the same length on both sides of the discretization domain.
  • length = [lengthLeft, lengthRight] independently specifies the CAP length on each side of the domain.
  • Note: Unlike for TDSE and TDDFT, the CAP is defined outward from the position $x=0$ of the Configuration interaction model discretization domain, one should therefore budget for this.

distance (D)

Distance from the origin for the beginning of the CAP mask [ positive scalar | positive vector [distLeft distRight] | (default []) ]

  • Scalar distance defines a CAP starting at the same distance from both sides of $x=0$ .
  • distance = [distLeft, distRight] independently specifies the starting distance CAP on each side of $x=0$ .

shape

Shape of the CAP mask [ 'sin^1/8' (default) | 'sin' | 'sin^2' | function handle ]

  • 'sin^1/8' uses a $\sin^{1/8}$ -shaped CAP mask.
  • 'sin' uses a $\sin$ -shaped CAP mask.
  • 'sin^2' uses a $\sin^2$ -shaped CAP mask.
  • A function handle enables user-defined CAPs, with the signature @(x) fun(x), where fun(0)=0 and fun(1)=V_max return the values for the CAP at the beginning and end of the absorbing domain, respectively (the absorbing domain on either side of $x=0$ are linearly mapped to the segment [0 1] when calling the CAP function). fun must be real valued and positive; the sign and complex coefficients are internally handeled by the QMol-grid package. We recommend setting V_max to 1 and using the amplitude property to control the CAP height.

Other properties

These properties cannot be edited with the set method.

isInitialized (isInit)

Whether the absorbing-boundary CAP object is properly initialized. This is used throughout the QMol-grid package to check that the absorber object holds meaningful information and is ready for use.

Class methods

Creation

constructor

Create an absorbing-boundary CAP object with empty class properties.

obj = QMol_TDCI_abs_CAP_space;

Create an absorbing-boundary CAP object with the name properties set to the specified value. Several name-value pairs can be specified consecutively. Suitable name is any of the CAP properties and is case insensitive.

obj = QMol_TDCI_abs_CAP_space(name1,value1);
obj = QMol_TDCI_abs_CAP_space(name1,value1,name2,value2,___);

Changing class properties

set

Update the name properties of an absorbing-boundary CAP object to the specified value. Several name-value pairs can be specified consecutively. Suitable name is any of the CAP properties and is case insensitive.

obj.set(name1,value1);
obj.set(name1,value1,name2,value2,___);

This is the common name-value pair assignment method used throughout the QMol-grid package. The set method also reset the class. After running, the set property updates the isInitialized flag to a false value.

reset

Reset the object by deleting/re-initializing all run-time properties of the class and updating the isInitialized flag to false.

obj.reset;
  • This is the common reset method available to all classes throughout the QMol-grid package.

clear

Clear all class properties.

obj.clear;

Clear a specific set of the class properties. Suitable name is any of the CAP properties and is case insensitive.

obj.clear(name1,name2,___);

This is the common clear method available to all classes throughout the QMol-grid package. The clear method also reset the class.

Initializing the object

initialize

Initialize a QMol_TDCI_abs_CAP_space object and set the isInitialized flag to true.

obj.initialize(CI);

Using the CAP damping matrix

getDampingMatrix

Get the CAP damping matrix with

M = obj.getDampingMatrix()
  • The object must be properly initialized.

Run-time documentation

getMemoryProfile

Get an estimate of the memory held by a QMol_TDCI_abs_CAP_space object with either

mem = obj.getMemoryProfile;
mem = obj.getMemoryProfile(false);
  • The object must be properly initialized.
  • The output mem is the estimated size in bytes.

Additionally display the detail of the memory footprint with

mem = obj.getMemoryProfile(true);

showDocumentation

Display the run-time documentation for the specific configuration of a QMol_TDCI_abs_CAP_space object.

ref = obj.showDocumentation;
  • The output ref is a cell vector containing the list of references to be included in the bibliography.

Test suite

Run the test suite for the class in normal or summary mode respectively with

QMol_test.test('TDCI_abs_CAP_space');
QMol_test.test('-summary','TDCI_abs_CAP_space');

Notes

  • QMol_TDCI_abs_CAP_space was introduced in version 01.23.