Data update
This commit is contained in:
parent
5150844a7d
commit
4bb20c9b71
7735 changed files with 38060 additions and 199180 deletions
|
|
@ -1,12 +0,0 @@
|
|||
with Ada.Numerics.Real_Arrays; use Ada.Numerics.Real_Arrays;
|
||||
|
||||
function Fit (X, Y : Real_Vector; N : Positive) return Real_Vector is
|
||||
A : Real_Matrix (0..N, X'Range); -- The plane
|
||||
begin
|
||||
for I in A'Range (2) loop
|
||||
for J in A'Range (1) loop
|
||||
A (J, I) := X (I)**J;
|
||||
end loop;
|
||||
end loop;
|
||||
return Solve (A * Transpose (A), A * Y);
|
||||
end Fit;
|
||||
|
|
@ -1,15 +0,0 @@
|
|||
with Fit;
|
||||
with Ada.Float_Text_IO; use Ada.Float_Text_IO;
|
||||
|
||||
procedure Fitting is
|
||||
C : constant Real_Vector :=
|
||||
Fit
|
||||
( (0.0, 1.0, 2.0, 3.0, 4.0, 5.0, 6.0, 7.0, 8.0, 9.0, 10.0),
|
||||
(1.0, 6.0, 17.0, 34.0, 57.0, 86.0, 121.0, 162.0, 209.0, 262.0, 321.0),
|
||||
2
|
||||
);
|
||||
begin
|
||||
Put (C (0), Aft => 3, Exp => 0);
|
||||
Put (C (1), Aft => 3, Exp => 0);
|
||||
Put (C (2), Aft => 3, Exp => 0);
|
||||
end Fitting;
|
||||
Loading…
Add table
Add a link
Reference in a new issue