We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
2 parents 38e625d + 5e63dcf commit f2b5e04Copy full SHA for f2b5e04
src/b-splines/cubic.jl
@@ -30,7 +30,7 @@ function define_indices_d{BC}(::Type{BSpline{Cubic{BC}}}, d, pad)
30
quote
31
# ensure that all of ix_d, ixm_d, ixp_d, and ixpp_d are in-bounds no
32
# matter the value of pad
33
- $symix = clamp(round(Int, $symx), $(2-pad), size(itp,$d)+$(pad-2))
+ $symix = clamp(floor(Int, $symx), $(2-pad), size(itp,$d)+$(pad-2))
34
$symfx = $symx - $symix
35
$symix += $pad # padding for oob coefficient
36
$symixm = $symix - 1
@@ -43,7 +43,7 @@ function define_indices_d(::Type{BSpline{Cubic{Periodic}}}, d, pad)
43
symix, symixm, symixp = symbol("ix_",d), symbol("ixm_",d), symbol("ixp_",d)
44
symixpp, symx, symfx = symbol("ixpp_",d), symbol("x_",d), symbol("fx_",d)
45
46
- $symix = clamp(round(Int, $symx), 1, size(itp,$d))
+ $symix = clamp(floor(Int, $symx), 1, size(itp,$d))
47
48
$symixm = mod1($symix - 1, size(itp,$d))
49
$symixp = mod1($symix + 1, size(itp,$d))
0 commit comments