feat: correct greedy/lazy and inplace/functional, split into multiple inputs
This commit is contained in:
parent
b037dacccf
commit
5bce9e5b01
12 changed files with 117 additions and 65 deletions
|
|
@ -40,10 +40,10 @@ sig (* {{{ *)
|
|||
size(b) = ns x ns
|
||||
(but only the lower strictly triangular entries)
|
||||
size(e) = ns
|
||||
size(bi) = ns x po
|
||||
size(bi) = ns x po
|
||||
(where po is the order of the interpolating polynomial)
|
||||
*)
|
||||
|
||||
|
||||
|
||||
end (* }}} *)
|
||||
|
||||
|
|
@ -322,7 +322,7 @@ struct (* {{{1 *)
|
|||
s.time <- nextt;
|
||||
s.h <- nexth;
|
||||
s.time
|
||||
|
||||
|
||||
let get_dky { last_time = t; time = t'; h = h; yold = y; k = k } yi ti kd =
|
||||
|
||||
if kd > 0 then
|
||||
|
|
@ -334,7 +334,7 @@ struct (* {{{1 *)
|
|||
failwith
|
||||
(Printf.sprintf
|
||||
"get_dky: requested time %.24e is out of range\n\ [%.24e,...,%.24e]"
|
||||
ti t t');
|
||||
ti t t');
|
||||
|
||||
let h = t' -. t in
|
||||
let th = (ti -. t) /. h in
|
||||
|
|
@ -358,9 +358,9 @@ struct (* {{{1 *)
|
|||
let copy ({ last_time; time; h; yold; k } as s) =
|
||||
{ s with last_time; time; h; yold = Zls.copy yold; k = Zls.copy_matrix k }
|
||||
|
||||
let blit { last_time = l1; time = t1; h = h1; yold = yhold1; k = k1 }
|
||||
let blit { last_time = l1; time = t1; h = h1; yold = yhold1; k = k1 }
|
||||
({ last_time; time; h; yold; k } as s2) =
|
||||
s2.last_time <- l1; s2.time <- t1;
|
||||
s2.last_time <- l1; s2.time <- t1;
|
||||
Zls.blit yhold1 yold; Zls.blit_matrix k1 k
|
||||
|
||||
end (* }}} *)
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue