File tree Expand file tree Collapse file tree 1 file changed +4
-8
lines changed Expand file tree Collapse file tree 1 file changed +4
-8
lines changed Original file line number Diff line number Diff line change @@ -490,18 +490,14 @@ end
490
490
"""
491
491
move_blocking(Hp::Int, Hc::Int) -> nb, Hc
492
492
493
- Construct a move blocking vector `nb` to fit the provides `Hp` and `Hc` horizons.
493
+ Construct a move blocking vector `nb` that match the provided `Hp` and `Hc` horizons.
494
494
495
- The vector is filled with `1`s for the first `Hc` blocks. If `Hc < Hp`, the last block in
496
- `nb` is set to `Hp - Hc` to ensure the total sum is `Hp`.
495
+ The vector is filled with `1`s, except for the last element which is `Hp - Hc + 1`.
497
496
"""
498
497
function move_blocking (Hp_arg:: Int , Hc_arg:: Int )
499
498
Hp, Hc = Hp_arg, Hc_arg
500
- nb = fill (1 , Hc_arg)
501
- if Hc < Hp
502
- newblock = Hp - Hc
503
- nb = [nb; newblock]
504
- end
499
+ nb = fill (1 , Hc)
500
+ nb[end ] = Hp - Hc + 1
505
501
return nb, Hc
506
502
end
507
503
You can’t perform that action at this time.
0 commit comments