ROL
Public Member Functions | Private Attributes | List of all members
FiniteDifference< Real > Class Template Reference

#include <FiniteDifference.hpp>

Public Member Functions

 FiniteDifference (int n, double dx)
 
void solve (ROL::Ptr< const std::vector< Real > > fp, ROL::Ptr< std::vector< Real > > up)
 Given f, compute -u''=f.
 
void solve (ROL::Ptr< std::vector< Real > > up)
 Same as above but with overwrite in place.
 
void apply (ROL::Ptr< const std::vector< Real > > up, ROL::Ptr< std::vector< Real > > fp)
 Given u, compute f = -u''.
 
void apply (ROL::Ptr< std::vector< Real > > fp)
 Same as above but with overwrite in place.
 

Private Attributes

int n_
 
double dx2_
 
Teuchos::LAPACK< int, Real > lapack_
 
std::vector< Real > dl_
 
std::vector< Real > d_
 
std::vector< Real > du_
 
std::vector< Real > du2_
 
std::vector< int > ipiv_
 
int info_
 

Detailed Description

template<class Real>
class FiniteDifference< Real >

Definition at line 7 of file FiniteDifference.hpp.

Constructor & Destructor Documentation

◆ FiniteDifference()

template<class Real >
FiniteDifference< Real >::FiniteDifference ( int n,
double dx )
inline

Member Function Documentation

◆ solve() [1/2]

template<class Real >
void FiniteDifference< Real >::solve ( ROL::Ptr< const std::vector< Real > > fp,
ROL::Ptr< std::vector< Real > > up )
inline

◆ solve() [2/2]

template<class Real >
void FiniteDifference< Real >::solve ( ROL::Ptr< std::vector< Real > > up)
inline

◆ apply() [1/2]

template<class Real >
void FiniteDifference< Real >::apply ( ROL::Ptr< const std::vector< Real > > up,
ROL::Ptr< std::vector< Real > > fp )
inline

Given u, compute f = -u''.

Definition at line 58 of file FiniteDifference.hpp.

References FiniteDifference< Real >::dx2_, and FiniteDifference< Real >::n_.

◆ apply() [2/2]

template<class Real >
void FiniteDifference< Real >::apply ( ROL::Ptr< std::vector< Real > > fp)
inline

Same as above but with overwrite in place.

Definition at line 68 of file FiniteDifference.hpp.

References FiniteDifference< Real >::dx2_, and FiniteDifference< Real >::n_.

Member Data Documentation

◆ n_

template<class Real >
int FiniteDifference< Real >::n_
private

◆ dx2_

template<class Real >
double FiniteDifference< Real >::dx2_
private

◆ lapack_

template<class Real >
Teuchos::LAPACK<int,Real> FiniteDifference< Real >::lapack_
private

◆ dl_

template<class Real >
std::vector<Real> FiniteDifference< Real >::dl_
private

◆ d_

template<class Real >
std::vector<Real> FiniteDifference< Real >::d_
private

◆ du_

template<class Real >
std::vector<Real> FiniteDifference< Real >::du_
private

◆ du2_

template<class Real >
std::vector<Real> FiniteDifference< Real >::du2_
private

◆ ipiv_

template<class Real >
std::vector<int> FiniteDifference< Real >::ipiv_
private

◆ info_

template<class Real >
int FiniteDifference< Real >::info_
private

The documentation for this class was generated from the following file: