Skip to content
Snippets Groups Projects
Commit a6493e7b authored by wenqing's avatar wenqing
Browse files

[AsmL] Add number of global unknowns to DOF table.

parent 4a5e5e15
No related branches found
No related tags found
No related merge requests found
...@@ -71,6 +71,12 @@ public: ...@@ -71,6 +71,12 @@ public:
/// Returns total number of degrees of freedom. /// Returns total number of degrees of freedom.
std::size_t dofSize() const; std::size_t dofSize() const;
/// Returns total number of global degrees of freedom for DDC.
std::size_t dofSizeGlobal() const
{
return _mesh_component_map.getNGlobalUnknowns();
}
std::size_t size() const; std::size_t size() const;
RowColumnIndices operator[](std::size_t const mesh_item_id) const; RowColumnIndices operator[](std::size_t const mesh_item_id) const;
......
...@@ -115,6 +115,12 @@ public: ...@@ -115,6 +115,12 @@ public:
std::vector<GlobalIndexType> getGlobalIndicesByComponent( std::vector<GlobalIndexType> getGlobalIndicesByComponent(
const std::vector<Location>& ls) const; const std::vector<Location>& ls) const;
/// Get the number of global unknowns.
std::size_t getNGlobalUnknowns() const
{
return _num_global_dof;
}
/// A value returned if no global index was found for the requested /// A value returned if no global index was found for the requested
/// location/component. The value is implementation dependent. /// location/component. The value is implementation dependent.
static GlobalIndexType const nop; static GlobalIndexType const nop;
...@@ -150,6 +156,9 @@ private: ...@@ -150,6 +156,9 @@ private:
private: private:
detail::ComponentGlobalIndexDict _dict; detail::ComponentGlobalIndexDict _dict;
/// Number of global unknowns.
std::size_t _num_global_dof = 0;
}; };
} // namespace AssemblerLib } // namespace AssemblerLib
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment