mirror of
https://github.com/openmc-dev/openmc.git
synced 2026-07-27 21:55:41 -04:00
Addressing @aprilnovak's PR comments.
This commit is contained in:
parent
7cd3e388a4
commit
b982704d4f
4 changed files with 11 additions and 6 deletions
|
|
@ -276,7 +276,7 @@ should be set to:
|
|||
<filter type="azimuthal" bins="2" />
|
||||
|
||||
:mesh:
|
||||
The unique ID of a mesh to be tallied over.z
|
||||
The unique ID of a mesh to be tallied over.
|
||||
|
||||
:distribcell:
|
||||
The single cell which should be tallied uniquely for all instances.
|
||||
|
|
|
|||
|
|
@ -6,7 +6,6 @@
|
|||
|
||||
#include <array>
|
||||
#include <cstdint>
|
||||
#include <memory>
|
||||
#include <string>
|
||||
#include <unordered_set>
|
||||
#include <vector>
|
||||
|
|
|
|||
|
|
@ -82,9 +82,6 @@ if (!settings::LMI && !libMesh::initialized())
|
|||
#endif
|
||||
}
|
||||
|
||||
if (!settings::LMI) {
|
||||
fatal_error("libMesh::LibMeshInit object isn't set.");
|
||||
}
|
||||
#endif
|
||||
|
||||
// Start total and initialization timer
|
||||
|
|
|
|||
11
src/mesh.cpp
11
src/mesh.cpp
|
|
@ -2123,10 +2123,19 @@ LibMesh::LibMesh(const std::string& filename)
|
|||
|
||||
void LibMesh::initialize()
|
||||
{
|
||||
m_ = std::make_unique<libMesh::Mesh>(settings::LMI->comm(), 3);
|
||||
if (!settings::LMI) {
|
||||
fatal_error("Attempting to use an unstructured mesh without a libMesh::LibMeshInit object.");
|
||||
}
|
||||
|
||||
m_ = std::make_unique<libMesh::Mesh>(settings::LMI->comm(), n_dimension_);
|
||||
m_->read(filename_);
|
||||
m_->prepare_for_use();
|
||||
|
||||
// ensure that the loaded mesh is 3 dimensional
|
||||
if(m_->spatial_dimension() != n_dimension_) {
|
||||
fatal_error(fmt::format("Mesh file {} specified for use in an unstructured mesh is not a 3D mesh.", filename_));
|
||||
}
|
||||
|
||||
// create an equation system for storing values
|
||||
eq_system_name_ = "mesh_" + std::to_string(id_) + "_system";
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue