changeset 253:396eadb652bd boundary_conditions

Rename function closureSize to closuresize
author Jonatan Werpers <jonatan@werpers.com>
date Thu, 27 Jun 2019 16:05:26 +0200
parents 9405c19b76bc
children 4ca3794fffef
files DiffOps/src/DiffOps.jl SbpOperators/src/constantstenciloperator.jl SbpOperators/src/d2.jl
diffstat 3 files changed, 9 insertions(+), 9 deletions(-) [+]
line wrap: on
line diff
--- a/DiffOps/src/DiffOps.jl	Thu Jun 27 14:43:57 2019 +0200
+++ b/DiffOps/src/DiffOps.jl	Thu Jun 27 16:05:26 2019 +0200
@@ -47,7 +47,7 @@
 
 # Maybe this should be split according to b3fbef345810 after all?! Seems like it makes performance more predictable
 function apply_region!(D::DiffOpCartesian{2}, u::AbstractArray{T,2}, v::AbstractArray{T,2}, r1::Type{<:Region}, r2::Type{<:Region}) where T
-    for I ∈ regionindices(D.grid.size, closureSize(D.op), (r1,r2))
+    for I ∈ regionindices(D.grid.size, closuresize(D.op), (r1,r2))
         @inbounds indextuple = (Index{r1}(I[1]), Index{r2}(I[2]))
         @inbounds u[I] = apply(D, v, indextuple)
     end
@@ -70,7 +70,7 @@
 
 using TiledIteration
 function apply_region_tiled!(D::DiffOpCartesian{2}, u::AbstractArray{T,2}, v::AbstractArray{T,2}, r1::Type{<:Region}, r2::Type{<:Region}) where T
-    ri = regionindices(D.grid.size, closureSize(D.op), (r1,r2))
+    ri = regionindices(D.grid.size, closuresize(D.op), (r1,r2))
     # TODO: Pass Tilesize to function
     for tileaxs ∈ TileIterator(axes(ri), padded_tilesize(T, (5,5), 2))
         for j ∈ tileaxs[2], i ∈ tileaxs[1]
--- a/SbpOperators/src/constantstenciloperator.jl	Thu Jun 27 14:43:57 2019 +0200
+++ b/SbpOperators/src/constantstenciloperator.jl	Thu Jun 27 16:05:26 2019 +0200
@@ -17,7 +17,7 @@
 end
 
 @inline function apply(op::ConstantStencilOperator, h::Real, v::AbstractVector, index::Index{Unknown})
-    cSize = closureSize(op)
+    cSize = closuresize(op)
     N = length(v)
 
     i = Int(index)
--- a/SbpOperators/src/d2.jl	Thu Jun 27 14:43:57 2019 +0200
+++ b/SbpOperators/src/d2.jl	Thu Jun 27 16:05:26 2019 +0200
@@ -1,4 +1,4 @@
-export D2, closureSize, readOperator, apply_e, apply_d, apply_e_T, apply_d_T
+export D2, closuresize, readOperator, apply_e, apply_d, apply_e_T, apply_d_T
 
 @enum Parity begin
     odd = -1
@@ -14,19 +14,19 @@
     parity::Parity
 end
 
-function closureSize(D::D2)::Int
+function closuresize(D::D2)::Int
     return length(D.quadratureClosure)
 end
 
 function apply_e_T(op::D2, v::AbstractVector, ::Type{Lower})
-    @boundscheck if length(v) < closureSize(op)
+    @boundscheck if length(v) < closuresize(op)
         throw(BoundsError())
     end
     apply(op.eClosure,v,1)
 end
 
 function apply_e_T(op::D2, v::AbstractVector, ::Type{Upper})
-    @boundscheck if length(v) < closureSize(op)
+    @boundscheck if length(v) < closuresize(op)
         throw(BoundsError())
     end
     apply(flip(op.eClosure),v,length(v))
@@ -48,14 +48,14 @@
 end
 
 function apply_d_T(op::D2, h_inv::Real, v::AbstractVector, ::Type{Lower})
-    @boundscheck if length(v) < closureSize(op)
+    @boundscheck if length(v) < closuresize(op)
         throw(BoundsError())
     end
     h_inv*apply(op.dClosure,v,1)
 end
 
 function apply_d_T(op::D2, h_inv::Real, v::AbstractVector, ::Type{Upper})
-    @boundscheck if length(v) < closureSize(op)
+    @boundscheck if length(v) < closuresize(op)
         throw(BoundsError())
     end
     -h_inv*apply(flip(op.dClosure),v,length(v))