HArD::Core3D
Hybrid Arbitrary Degree::Core 3D - Library to implement 3D schemes with vertex, edge, face and cell polynomials as unknowns
Public Types | Public Member Functions | List of all members
HArDCore3D::Magnetostatics Struct Reference

Assemble a magnetostatic problem. More...

#include <ddr-magnetostatics.hpp>

Public Types

typedef Eigen::SparseMatrix< double > SystemMatrixType
 
typedef std::function< Eigen::Vector3d(const Eigen::Vector3d &)> ForcingTermType
 
typedef std::function< Eigen::Vector3d(const Eigen::Vector3d &)> SolutionPotentialType
 
typedef std::function< Eigen::Vector3d(const Eigen::Vector3d &)> SolutionCurlType
 
typedef IntegralWeight PermeabilityType
 
typedef Eigen::SparseMatrix< double > SystemMatrixType
 
typedef std::function< Eigen::Vector3d(const Eigen::Vector3d &)> ForcingTermType
 
typedef std::function< Eigen::Vector3d(const Eigen::Vector3d &)> SolutionPotentialType
 
typedef std::function< Eigen::Vector3d(const Eigen::Vector3d &)> SolutionCurlType
 
typedef IntegralWeight PermeabilityType
 

Public Member Functions

 Magnetostatics (const DDRCore &ddrcore, bool use_threads, std::ostream &output=std::cout)
 Constructor. More...
 
void assembleLinearSystem (const ForcingTermType &f, const PermeabilityType &mu, const SolutionPotentialType &u)
 Assemble the global system
More...
 
size_t dimensionSpace () const
 Returns the dimension of the magnetic field + potential space. More...
 
size_t nbSCDOFs () const
 Returns the number of statically condensed DOFs (here, the cell magnetic field DOFs) More...
 
size_t sizeSystem () const
 Returns the size of the statically condensed system. More...
 
const XCurl & xCurl () const
 Returns the space XCurl. More...
 
const XDiv & xDiv () const
 Returns the space XDiv. More...
 
const SystemMatrixType & systemMatrix () const
 Returns the linear system matrix. More...
 
SystemMatrixType & systemMatrix ()
 Returns the linear system matrix. More...
 
const Eigen::VectorXd & systemVector () const
 Returns the linear system right-hand side vector. More...
 
Eigen::VectorXd & systemVector ()
 Returns the linear system right-hand side vector. More...
 
const double & stabilizationParameter () const
 Returns the stabilization parameter. More...
 
double & stabilizationParameter ()
 Returns the stabilization parameter. More...
 
const SystemMatrixType & scMatrix () const
 Returns the static condensation recovery operator. More...
 
Eigen::VectorXd & scVector ()
 Returns the static condensation rhs. More...
 
std::vector< double > computeNorms (const std::vector< Eigen::VectorXd > &list_dofs) const
 Compute the discrete Hcurl \times Hdiv norm of a family of vectors representing the dofs. More...
 
 Magnetostatics (const DDRCore &ddrcore, bool use_threads, std::ostream &output=std::cout)
 Constructor. More...
 
void assembleLinearSystem (const ForcingTermType &f, const PermeabilityType &mu, const SolutionPotentialType &u)
 Assemble the global system
More...
 
size_t dimensionSpace () const
 Returns the dimension of the magnetic field + potential space. More...
 
size_t nbSCDOFs () const
 Returns the number of statically condensed DOFs (here, the cell magnetic field DOFs) More...
 
size_t sizeSystem () const
 Returns the size of the statically condensed system. More...
 
const SXCurl & sxCurl () const
 Returns the space SXCurl. More...
 
const SXDiv & sxDiv () const
 Returns the space SXDiv. More...
 
const SystemMatrixType & systemMatrix () const
 Returns the linear system matrix. More...
 
SystemMatrixType & systemMatrix ()
 Returns the linear system matrix. More...
 
const Eigen::VectorXd & systemVector () const
 Returns the linear system right-hand side vector. More...
 
Eigen::VectorXd & systemVector ()
 Returns the linear system right-hand side vector. More...
 
const double & stabilizationParameter () const
 Returns the stabilization parameter. More...
 
double & stabilizationParameter ()
 Returns the stabilization parameter. More...
 
const SystemMatrixType & scMatrix () const
 Returns the static condensation recovery operator. More...
 
Eigen::VectorXd & scVector ()
 Returns the static condensation rhs. More...
 
std::vector< double > computeNorms (const std::vector< Eigen::VectorXd > &list_dofs) const
 Compute the discrete Hcurl \times Hdiv norm of a family of vectors representing the dofs. More...
 

Detailed Description

Assemble a magnetostatic problem.

Constructor & Destructor Documentation

◆ Magnetostatics()

HArDCore3D::Magnetostatics::Magnetostatics ( const DDRCore &  ddrcore,
bool  use_threads,
std::ostream &  output = std::cout 
)

Constructor.

Parameters
ddrcoreCore for the DDR space sequence
use_threadsTrue for parallel execution, false for sequential execution
outputOutput stream to print status messages

Member Function Documentation

◆ assembleLinearSystem()

void HArDCore3D::Magnetostatics::assembleLinearSystem ( const ForcingTermType &  f,
const PermeabilityType &  mu,
const SolutionPotentialType &  u 
)

Assemble the global system

Parameters
fForcing term
muPermeability
uBoundary condition

◆ computeNorms()

std::vector<double> HArDCore3D::Magnetostatics::computeNorms ( const std::vector< Eigen::VectorXd > &  list_dofs) const

Compute the discrete Hcurl \times Hdiv norm of a family of vectors representing the dofs.

Parameters
list_dofsThe list of vectors representing the dofs

◆ dimensionSpace()

size_t HArDCore3D::Magnetostatics::dimensionSpace ( ) const
inline

Returns the dimension of the magnetic field + potential space.

◆ nbSCDOFs()

size_t HArDCore3D::Magnetostatics::nbSCDOFs ( ) const
inline

Returns the number of statically condensed DOFs (here, the cell magnetic field DOFs)

◆ scMatrix()

const SystemMatrixType& HArDCore3D::Magnetostatics::scMatrix ( ) const
inline

Returns the static condensation recovery operator.

◆ scVector()

Eigen::VectorXd& HArDCore3D::Magnetostatics::scVector ( )
inline

Returns the static condensation rhs.

◆ sizeSystem()

size_t HArDCore3D::Magnetostatics::sizeSystem ( ) const
inline

Returns the size of the statically condensed system.

◆ stabilizationParameter() [1/2]

double& HArDCore3D::Magnetostatics::stabilizationParameter ( )
inline

Returns the stabilization parameter.

◆ stabilizationParameter() [2/2]

const double& HArDCore3D::Magnetostatics::stabilizationParameter ( ) const
inline

Returns the stabilization parameter.

◆ systemMatrix() [1/2]

SystemMatrixType& HArDCore3D::Magnetostatics::systemMatrix ( )
inline

Returns the linear system matrix.

◆ systemMatrix() [2/2]

const SystemMatrixType& HArDCore3D::Magnetostatics::systemMatrix ( ) const
inline

Returns the linear system matrix.

◆ systemVector() [1/2]

Eigen::VectorXd& HArDCore3D::Magnetostatics::systemVector ( )
inline

Returns the linear system right-hand side vector.

◆ systemVector() [2/2]

const Eigen::VectorXd& HArDCore3D::Magnetostatics::systemVector ( ) const
inline

Returns the linear system right-hand side vector.


The documentation for this struct was generated from the following files: