HArD::Core2D
Hybrid Arbitrary Degree::Core 2D - Library to implement 2D schemes with edge and cell polynomials as unknowns
|
#include <thread>
#include <Eigen/Sparse>
Go to the source code of this file.
Namespaces | |
namespace | HArDCore2D |
Functions | |
static std::pair< std::vector< int >, std::vector< int > > | HArDCore2D::distributeLoad (size_t nb_elements, unsigned nb_threads) |
Function to distribute elements (considered as jobs) over threads. It returns a pair of vectors indicating the start and end element of each thread. | |
static void | HArDCore2D::parallel_for (unsigned nb_elements, std::function< void(size_t start, size_t end)> functor, bool use_threads=true, unsigned nb_threads_max=1e9) |
Generic function to execute threaded processes. | |
static std::pair< Eigen::SparseMatrix< double >, Eigen::VectorXd > | HArDCore2D::parallel_assembly_system (size_t nb_elements, size_t size_system, std::function< void(size_t start, size_t end, std::list< Eigen::Triplet< double > > *triplets, Eigen::VectorXd *rhs)> batch_local_assembly, bool use_threads=true) |
Function to assemble global matrix and right-hand side from a procedure that computes local triplets and rhs contributions. | |
static std::tuple< Eigen::SparseMatrix< double >, Eigen::VectorXd, Eigen::SparseMatrix< double > > | HArDCore2D::parallel_assembly_system (size_t nb_elements, size_t size_system1, std::pair< size_t, size_t > size_Mat2, std::function< void(size_t start, size_t end, std::list< Eigen::Triplet< double > > *triplets1, Eigen::VectorXd *vec1, std::list< Eigen::Triplet< double > > *triplets2)> batch_local_assembly, bool use_threads=true) |
Function to assemble two global matrices and one vector (such as: system matrix+vector and matrix for BC) from a procedure that computes local triplets and rhs contributions. | |
static std::tuple< Eigen::SparseMatrix< double >, Eigen::VectorXd, Eigen::SparseMatrix< double >, Eigen::VectorXd > | HArDCore2D::parallel_assembly_system (size_t nb_elements, size_t size_system1, std::pair< size_t, size_t > size_Mat2, size_t size_b2, std::function< void(size_t start, size_t end, std::list< Eigen::Triplet< double > > *triplets1, Eigen::VectorXd *vec1, std::list< Eigen::Triplet< double > > *triplets2, Eigen::VectorXd *vec2)> batch_local_assembly, bool use_threads=true) |
Function to assemble two global matrices and vectors (such as: system and static condensation operator) from a procedure that computes local triplets and rhs contributions. | |