Skip to content

Commit

Permalink
coord_type typo (#1408)
Browse files Browse the repository at this point in the history
Co-authored-by: Victor Mateevitsi <[email protected]>
  • Loading branch information
mvictoras and Victor Mateevitsi authored Nov 20, 2024
1 parent 2278f4d commit 21f3349
Showing 1 changed file with 8 additions and 8 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -160,7 +160,7 @@ PointTopology<T, N>::PointTopology(const std::string &topo_name,
<< " which has type '" << this->topo_type << "'.");
}

if(this->coord_type == "uniform")
if(this->coords_type == "uniform")
{
const conduit::Node &n_coords = domain["coordsets/" + this->coords_name];
const conduit::Node &n_dims = n_coords["dims"];
Expand All @@ -177,7 +177,7 @@ PointTopology<T, N>::PointTopology(const std::string &topo_name,
num_cells *= dims[i] - 1;
}
}
else if(this->coord_type == "rectilinear")
else if(this->coords_type == "rectilinear")
{
const conduit::Node &values =
domain["coordsets/" + this->coords_name + "/values"];
Expand All @@ -189,7 +189,7 @@ PointTopology<T, N>::PointTopology(const std::string &topo_name,
num_points *= coords[i].dtype().number_of_elements();
}
}
else if(this->coord_type == "explicit")
else if(this->coords_type == "explicit")
{
const conduit::Node &values =
domain["coordsets/" + this->coords_name + "/values"];
Expand All @@ -203,7 +203,7 @@ PointTopology<T, N>::PointTopology(const std::string &topo_name,
else
{
ASCENT_ERROR("Unknown coordinate type '"
<< this->coord_type << "' for point topology '" << topo_name
<< this->coords_type << "' for point topology '" << topo_name
<< "' in domain " << domain.name() << ".");
}
}
Expand All @@ -213,15 +213,15 @@ std::array<conduit::float64, 3>
PointTopology<T, N>::vertex_location(const size_t index) const
{
std::array<conduit::float64, 3> loc{};
if(this->coord_type == "uniform")
if(this->coords_type == "uniform")
{
auto l_index = detail::logical_index(index, dims);
for(size_t i = 0; i < N; ++i)
{
loc[i] = origin[i] + l_index[i] * spacing[i];
}
}
else if(this->coord_type == "rectilinear")
else if(this->coords_type == "rectilinear")
{
std::array<size_t, N> dims;
for(size_t i = 0; i < N; ++i)
Expand All @@ -234,7 +234,7 @@ PointTopology<T, N>::vertex_location(const size_t index) const
loc[i] = coords[i][l_index[i]];
}
}
else if(this->coord_type == "explicit")
else if(this->coords_type == "explicit")
{
for(size_t i = 0; i < N; ++i)
{
Expand All @@ -244,7 +244,7 @@ PointTopology<T, N>::vertex_location(const size_t index) const
else
{
ASCENT_ERROR("Unknown coordinate type '"
<< this->coord_type << "' for point topology '" << topo_name
<< this->coords_type << "' for point topology '" << topo_name
<< "' in domain " << domain.name() << ".");
}
return loc;
Expand Down

0 comments on commit 21f3349

Please sign in to comment.