Skip to content

Commit

Permalink
Removed parent's periodicity for smview.
Browse files Browse the repository at this point in the history
  • Loading branch information
SimonCan committed Nov 22, 2023
1 parent 1c7a833 commit 607b623
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions src/meshes/structured_mesh_view.jl
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,6 @@ mutable struct StructuredMeshView{NDIMS, RealT <: Real} <: AbstractMesh{NDIMS}
mapping::Any # Not relevant for performance
index_min::NTuple{NDIMS, Int}
index_max::NTuple{NDIMS, Int}
periodicity::NTuple{NDIMS, Bool}
end

function StructuredMeshView(parent::StructuredMesh{NDIMS, RealT};
Expand All @@ -16,7 +15,7 @@ function StructuredMeshView(parent::StructuredMesh{NDIMS, RealT};
@assert index_max <= size(parent)

return StructuredMeshView{NDIMS, RealT}(parent, parent.mapping, index_min,
index_max, periodicity)
index_max)
end

function StructuredMeshView(parent::StructuredMesh{NDIMS, RealT}) where {NDIMS, RealT}
Expand All @@ -28,6 +27,7 @@ function isperiodic(mesh::StructuredMeshView)
@unpack parent = mesh
return isperiodic(parent) && size(parent) == size(mesh)
end

function isperiodic(mesh::StructuredMeshView, dimension)
@unpack parent, index_min, index_max = mesh
return (isperiodic(parent, dimension) &&
Expand Down

0 comments on commit 607b623

Please sign in to comment.