Skip to content

Commit 2bc1ff3

Browse files
authored
use _reshape
1 parent cbfdf88 commit 2bc1ff3

File tree

1 file changed

+8
-8
lines changed

1 file changed

+8
-8
lines changed

lib/OrdinaryDiffEqFIRK/src/firk_perform_step.jl

Lines changed: 8 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -169,7 +169,7 @@ end
169169

170170
rhs1 = @. fw1 - αdt * Mw1 + βdt * Mw2
171171
rhs2 = @. fw2 - βdt * Mw1 - αdt * Mw2
172-
dw12 = reshape(LU1 \ _vec(@. rhs1 + rhs2 * im), size(u))
172+
dw12 = _reshape(LU1 \ _vec(@. rhs1 + rhs2 * im), axes(u))
173173
integrator.stats.nsolve += 1
174174
dw1 = real(dw12)
175175
dw2 = imag(dw12)
@@ -450,8 +450,8 @@ end
450450
rhs1 = @.. broadcast=false fw1-γdt * Mw1
451451
rhs2 = @.. broadcast=false fw2 - αdt * Mw2+βdt * Mw3
452452
rhs3 = @.. broadcast=false fw3 - βdt * Mw2-αdt * Mw3
453-
dw1 = reshape(LU1 \ _vec(rhs1), size(u))
454-
dw23 = reshape(LU2 \ _vec(@.. broadcast=false rhs2+rhs3 * im), size(u))
453+
dw1 = _reshape(LU1 \ _vec(rhs1), axes(u))
454+
dw23 = _reshape(LU2 \ _vec(@.. broadcast=false rhs2+rhs3 * im), axes(u))
455455
integrator.stats.nsolve += 2
456456
dw2 = real(dw23)
457457
dw3 = imag(dw23)
@@ -508,7 +508,7 @@ end
508508
mass_matrix != I && (tmp = mass_matrix * tmp)
509509
utilde = @.. broadcast=false integrator.fsalfirst+tmp
510510
if alg.smooth_est
511-
utilde = reshape(LU1 \ _vec(utilde), size(u))
511+
utilde = _reshape(LU1 \ _vec(utilde), axes(u))
512512
integrator.stats.nsolve += 1
513513
end
514514
# RadauIIA5 needs a transformed rtol and atol see
@@ -902,9 +902,9 @@ end
902902
rhs3 = @.. broadcast=false fw3 - β1dt * Mw2-α1dt * Mw3
903903
rhs4 = @.. broadcast=false fw4 - α2dt * Mw4+β2dt * Mw5
904904
rhs5 = @.. broadcast=false fw5 - β2dt * Mw4-α2dt * Mw5
905-
dw1 = reshape(LU1 \ _vec(rhs1), size(u))
906-
dw23 = reshape(LU2 \ _vec(@.. broadcast=false rhs2+rhs3 * im), size(u))
907-
dw45 = reshape(LU3 \ _vec(@.. broadcast=false rhs4+rhs5 * im), size(u))
905+
dw1 = _reshape(LU1 \ _vec(rhs1), axes(u))
906+
dw23 = _reshape(LU2 \ _vec(@.. broadcast=false rhs2+rhs3 * im), axes(u))
907+
dw45 = _reshape(LU3 \ _vec(@.. broadcast=false rhs4+rhs5 * im), axes(u))
908908
integrator.stats.nsolve += 3
909909
dw2 = real(dw23)
910910
dw3 = imag(dw23)
@@ -973,7 +973,7 @@ end
973973
mass_matrix != I && (tmp = mass_matrix * tmp)
974974
utilde = @.. broadcast=false integrator.fsalfirst+tmp
975975
if alg.smooth_est
976-
utilde = reshape(LU1 \ _vec(utilde), size(u))
976+
utilde = _reshape(LU1 \ _vec(utilde), axes(u))
977977
integrator.stats.nsolve += 1
978978
end
979979
atmp = calculate_residuals(utilde, uprev, u, atol, rtol, internalnorm, t)

0 commit comments

Comments
 (0)