Actual timed Mathomatic output from the poly script
Mathomatic version 15.8.4
Copyright © 1987-2012 George Gesslein II.
200 equation spaces available in memory,
1920 kilobytes per equation space.
HTML color mode enabled; manage by typing "help color".
1−>
1−> ; Combine 3 quadratic polynomial equations with 3 unknown coefficients (a, b, c).
1−> ; Solve for variables (a), (b), and (c).
1−>
1−> clear all ; restart Mathomatic
1−> ; enter all 3 equations:
1−> y1=a+b*x1+c*x1^2
#1: y1 = a + (b·x1) + (c·x1^2)
1−> y2=a+b*x2+c*x2^2
#2: y2 = a + (b·x2) + (c·x2^2)
2−> y3=a+b*x3+c*x3^2
#3: y3 = a + (b·x3) + (c·x3^2)
3−> 2 ; select equation number 2 as the current equation
#2: y2 = a + (b·x2) + (c·x2^2)
2−> eliminate a ; eliminate variable (a) from the current equation
Solving equation #1 for a and substituting into the current equation...
#2: y2 = (b·x2) − (x1·(b + (c·x1))) + y1 + (c·x2^2)
2−> 3 ; select equation number 3
#3: y3 = a + (b·x3) + (c·x3^2)
3−> eliminate a b ; eliminate variables (a) and then (b) from the current equation
Eliminating variable a using equation #1...
Solving equation #2 for b and substituting into the current equation...
(y1 − y2 + (c·(x2^2 − x1^2)))·x3 (y1 − y2 + (c·(x2^2 − x1^2)))
#3: y3 = –––––––––––––––––––––––––––––––– − (x1·(––––––––––––––––––––––––––––– + (c·x1))) + y1 + (c·x3^2)
(x1 − x2) (x1 − x2)
3−> solve verify c
Solving equation #3 for c with verification...
((y2·(x1 − x3)) + (y1·(x3 − x2)) − (y3·(x1 − x2)))
#3: c = –––––––––––––––––––––––––––––––––––––––––––––––––––––––––––––
((x1·(x2^2 + (x1·(x3 − x2)))) − (x3·(x2^2 + (x3·(x1 − x2)))))
Solution verified.
3−> simplify
(y1 − y2) (y3 − y2)
(––––––––– + –––––––––)
(x2 − x1) (x3 − x2)
#3: c = –––––––––––––––––––––––
(x3 − x1)
3−> 2 ; select equation number 2 again
(y1 − y2 + (c·(x2^2 − x1^2)))
#2: b = –––––––––––––––––––––––––––––
(x1 − x2)
2−> eliminate c using 3 ; find (b) by combining equation numbers 2 and 3
Eliminating variable c using equation #3...
(y1 − y2) (y3 − y2)
(––––––––– + –––––––––)·(x2^2 − x1^2)
(x2 − x1) (x3 − x2)
(y1 − y2 + –––––––––––––––––––––––––––––––––––––)
(x3 − x1)
#2: b = –––––––––––––––––––––––––––––––––––––––––––––––––
(x1 − x2)
2−> simplify
((x1^2·(y2 − y3)) + (x3^2·(y1 − y2)) + (x2^2·(y3 − y1)))
#2: b = ––––––––––––––––––––––––––––––––––––––––––––––––––––––––
((x2 − x1)·(x3 − x1)·(x2 − x3))
2−> 1 ; select equation number 1
#1: a = -((x1·(b + (c·x1))) − y1)
1−> eliminate c using 3 b using 2 ; find (a)
Eliminating variable c using equation #3...
Eliminating variable b using equation #2...
(y1 − y2) (y3 − y2)
(––––––––– + –––––––––)·x1
((x1^2·(y2 − y3)) + (x3^2·(y1 − y2)) + (x2^2·(y3 − y1))) (x2 − x1) (x3 − x2)
#1: a = -((x1·(–––––––––––––––––––––––––––––––––––––––––––––––––––––––– + ––––––––––––––––––––––––––)) − y1)
((x2 − x1)·(x3 − x1)·(x2 − x3)) (x3 − x1)
1−>
1−> simplify fraction all ; display all solutions, converting to simple fractions first
((x1^2·((y2·x3) − (y3·x2))) + (x1·((x2^2·y3) − (x3^2·y2))) + (y1·((x3^2·x2) − (x3·x2^2))))
#1: a = ––––––––––––––––––––––––––––––––––––––––––––––––––––––––––––––––––––––––––––––––––––––––––
((x2 − x1)·(x3 − x1)·(x3 − x2))
((x1^2·(y2 − y3)) + (x3^2·(y1 − y2)) + (x2^2·(y3 − y1)))
#2: b = ––––––––––––––––––––––––––––––––––––––––––––––––––––––––
((x2 − x1)·(x3 − x1)·(x2 − x3))
((x3·(y1 − y2)) + (x2·(y3 − y1)) + (x1·(y2 − y3)))
#3: c = ––––––––––––––––––––––––––––––––––––––––––––––––––
((x2 − x1)·(x3 − x1)·(x3 − x2))
Successfully finished reading file "poly.in".
1−>
End of input.
real 0.07 user 0.07 sys 0.00 seconds total execution time.
www.mathomatic.org