SparsityOracleGIHAWP

About the SparsityOracleGIHAWP class

The WaveBlocks Project

@author: R. Bourquin @copyright: Copyright (C) 2010, 2011, 2012, 2013, 2014, 2015, 2016 R. Bourquin @license: Modified BSD License

Inheritance diagram

Inheritance diagram of SparsityOracleGIHAWP

Class documentation

class WaveBlocksND.SparsityOracleGIHAWP(threshold=1e-08)[source]

This class implements an oracle by looking at Gaussian integrals.

__init__(threshold=1e-08)[source]

Initialize an oracle for estimating if a specific overlap integral \langle \Psi_k | O | \Psi_l \rangle is approximately zero. The oracle works by approximating \langle \Psi_k | \Psi_l \rangle with a Gaussian integral. If

\langle \Psi_k | \Psi_l \rangle \approx \langle \Psi_k^G | \Psi_l^G \rangle \leq \tau

the value \langle \Psi_k | O | \Psi_l \rangle is considered to be zero. Of course this may fail depending on the form of the operator O or the basis shape \mathfrak{K}.

Warning

This code is highly experimental.

Parameters:threshold – The threshold \tau in the Gaussian integral criterion. The default value of 10^{-8} should be reasonable in most cases.
is_not_zero(pacbra, packet, component=None)[source]

Try to estimate if the overlap integral \langle \Psi_k | \Psi_l \rangle is zero or at least negligible.

Parameters:
  • pacbra – The packet \Psi_k that is used for the ‘bra’ part.
  • packet – The packet \Psi_l that is used for the ‘ket’ part.
  • component – The component of the packet that is considered.
Returns:

True or False whether the inner product is negligible.