Skip to content

Commit 2e7cb8c

Browse files
format
1 parent 2297067 commit 2e7cb8c

File tree

3 files changed

+20
-16
lines changed

3 files changed

+20
-16
lines changed

src/dense/interpolants.jl

Lines changed: 15 additions & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -3000,23 +3000,26 @@ end
30003000
@dprkn6pre0
30013001
halfsize = length(y₀) ÷ 2
30023002
isfirsthalf = idxs .<= halfsize
3003-
secondhalf = idxs .> halfsize
3003+
secondhalf = idxs .> halfsize
30043004
firstidxs = idxs[isfirsthalf]
30053005
secondidxs_shifted = idxs[secondhalf]
30063006
secondidxs = secondidxs_shifted .- halfsize
30073007

30083008
@views @.. broadcast=false out[secondhalf]=uprev[secondidxs] +
3009-
dt * Θ *
3010-
(duprev[secondidxs] +
3011-
dt * Θ *
3012-
(b1Θ * k1[secondidxs] +
3013-
b3Θ * k3[secondidxs] +
3014-
b4Θ * k4[secondidxs] + b5Θ * k5[secondidxs] +
3015-
b6Θ * k6[secondidxs]))
3009+
dt * Θ *
3010+
(duprev[secondidxs] +
3011+
dt * Θ *
3012+
(b1Θ * k1[secondidxs] +
3013+
b3Θ * k3[secondidxs] +
3014+
b4Θ * k4[secondidxs] +
3015+
b5Θ * k5[secondidxs] +
3016+
b6Θ * k6[secondidxs]))
30163017
@views @.. broadcast=false out[isfirsthalf]=duprev[firstidxs] +
3017-
dt * Θ *
3018-
(bp1Θ * k1[firstidxs] + bp3Θ * k3[firstidxs] +
3019-
bp4Θ * k4[firstidxs] + bp5Θ * k5[firstidxs] +
3020-
bp6Θ * k6[firstidxs])
3018+
dt * Θ *
3019+
(bp1Θ * k1[firstidxs] +
3020+
bp3Θ * k3[firstidxs] +
3021+
bp4Θ * k4[firstidxs] +
3022+
bp5Θ * k5[firstidxs] +
3023+
bp6Θ * k6[firstidxs])
30213024
out
30223025
end

src/nlsolve/utils.jl

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -308,7 +308,8 @@ function build_nlsolver(
308308
end
309309
prob = NonlinearProblem(NonlinearFunction(nlf), copy(ztmp), nlp_params)
310310
cache = init(prob, nlalg.alg)
311-
nlcache = NonlinearSolveCache(nothing, tstep, nothing, nothing, invγdt, prob, cache)
311+
nlcache = NonlinearSolveCache(
312+
nothing, tstep, nothing, nothing, invγdt, prob, cache)
312313
else
313314
nlcache = NLNewtonConstantCache(tstep, J, W, true, true, true, tType(dt), uf,
314315
invγdt, tType(nlalg.new_W_dt_cutoff), t)

test/interface/interpolation_output_types.jl

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -63,7 +63,7 @@ sol = solve(prob, DPRKN6())
6363
@test sol(0.5) isa RecursiveArrayTools.ArrayPartition
6464
@test sol(0.5; idxs = 1) isa Number
6565
@test sol(0.5; idxs = [1]) isa Vector
66-
@test sol(0.5; idxs = [1,2]) isa Vector
67-
@test Vector(sol(0.5)) == sol(0.5; idxs = [1,2])
68-
@test reverse(Vector(sol(0.5))) == sol(0.5; idxs = [2,1])
66+
@test sol(0.5; idxs = [1, 2]) isa Vector
67+
@test Vector(sol(0.5)) == sol(0.5; idxs = [1, 2])
68+
@test reverse(Vector(sol(0.5))) == sol(0.5; idxs = [2, 1])
6969
@test Vector(sol(0.5)) == [sol(0.5; idxs = 1); sol(0.5; idxs = 2)]

0 commit comments

Comments
 (0)