added subdomain indexing for outer edges, for use in robin BC

This commit is contained in:
jakob.schratter 2026-01-24 14:26:22 +01:00
commit 99b46ad7ec
5 changed files with 143 additions and 33 deletions

View file

@ -394,6 +394,20 @@ class FEM_Matrix: public CRS_Matrix
*/
void ApplyDirichletBC(std::vector<double> const &u, std::vector<double> &f);
/**
* Applies Robin boundary conditions to stiffness matrix and to load vector @p f
* for multiple subdomains
* The <a href="https://www.jstor.org/stable/2005611?seq=1#metadata_info_tab_contents">penalty method</a>
* is used for incorporating the given values @p u.
*
* @param[in] u (global) vector with Dirichlet data
* @param[in] u_out outside temperature
* @param[in,out] f load vector
*/
void ApplyRobinBC_mult(std::vector<double> const &u, std::vector<double> &f, const double u_out);
double Heat_transfer_coefficient(const int subdomain);
/**
* Extracts the diagonal elements of the sparse matrix.
*