Find Docs

Astronomical Applications Department, U.S. Naval Observatory - Linear Least Squares (Page 9)

Wodocs >> Science : Astronomy >> Astronomical Applications Department, U.S. Naval Observatory Linear Least Squares Page 9
Astronomical Applications Department, U.S. Naval Observatory - Linear Least Squares
leastsqrs[0]: Forming the normal equations...
leastsqrs[0]: partials
=
=
i 1
N
(
)
-
+
+
2 y
i
2 A 2 B t
i
0
=
=
i 1
N
(
)
-
2 (
)
- -
y
i
A B t
i
t
i
0
leastsqrs[0]: summation terms


,
,
,
=
i 1
N
y
i
=
i 1
N
t
i
y
i
=
i 1
N
t
i
=
i 1
N
t
i
2
leastsqrs[0]: normal equations
=
-
+
+
2 S
0
2 A N 2 B T
1
0
=
-
+
+
2 S
1
2 A T
1
2 B T
2
0
leastsqrs[0]: Solving the normal equations...
leastsqrs[0]: raw solution(s)


,
=
A
-
S
0
T
2
T
1
S
1
-
+
T
1
2
T
2
N
=
B
-
-
+
S
1
N T
1
S
0
-
+
T
1
2
T
2
N
leastsqrs[0]: substitution list


,
,
,
,
=
-
+


=
i 1
N
t
i
2


=
i 1
N
t
i
2
N
=
S
0
=
i 1
N
y
i
=
S
1
=
i 1
N
t
i
y
i
=
T
1
=
i 1
N
t
i
=
T
2
=
i 1
N
t
i
2
leastsqrs[0]: Verifying the solution...


,
=
A
-
S
0
T
2
T
1
S
1
=
B
-
S
1
N T
1
S
0
The substitutions are stored in the global variable _subslist. Hence, the full solution is
(
)
eval
,
% _subslist


,
=
A
-


=
i 1
N
y
i


=
i 1
N
t
i
2


=
i 1
N
t
i


=
i 1
N
t
i
y
i
-
+


=
i 1
N
t
i
2


=
i 1
N
t
i
2
N
=
B
-


=
i 1
N
t
i
y
i
N


=
i 1
N
t
i


=
i 1
N
y
i
-
+


=
i 1
N
t
i
2


=
i 1
N
t
i
2
N
We can convert the solution into an optimized Maple procedure. This procedure can then be used to
evaluate the model with a set of data. It is easily saved to disk for conversion into a C or fortran
procedure -- also quite easy.
:=
tmp
(
)
array
(
)
map
,
x
( )
rhs x %
Page 9

<< Previous       1 .. 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16       Next >>



Other Documents:
Sensitivity Integral, 3 D plot fits, lyap2, NAO 150, Rotate Vector, lyapcalc, wedges, Scifull, Precession Memo, Precession Maple, Curves 3 D, NOVAS 2004 Overview, NOVAS 2006 Overview, thesis, Ranson,


WODocs | |
All rights reserved. wodocs.comę 2009
WODocs


New Docs

Documents Category:
Arts (Design, Movies, Music, Radio, Television)
Automotive (Cars, Marine, Motorcycle, ATV, Snowmobiles)
Business (Biotechnology and Pharmaceuticals, Chemicals, Construction and Maintenance, Materials, Real Estate, Services)
Electronics (Computers, Motion Control, Power Supply)
Games (Board, Family, Party, Card, Construction, RC Toys)
Health (Animalm, Beauty, Healthcare, Medicine, Pharmacy, Surgery, Weight Loss)
Home (Accessories, Cooking, Decor and Design, Electrical, Family, Pets)
News (Newspapers, Sports, Television)
Recreation (Collecting, Hiking, Scouting, Survival, Travel)
Reference (Education, Libraries and Archives, Museums)
Science (Agriculture, Astronomy, Biology, Chemistry)
Shopping (Antiques and Collectibles, Clothing, Flowers, Food, Home and Garden)
Sports (Bicycle, Snowboard, Skiing, Other)