axiom-developer
[Top][All Lists]

## [Axiom-developer] [Guessing formulas for sequences]

 From: anonyme Subject: [Axiom-developer] [Guessing formulas for sequences] Date: Mon, 21 Mar 2005 10:54:55 -0600

```Changes
http://page.axiom-developer.org/zope/mathaction/GuessingFormulasForSequences/diff
--

??changed:
-guess(n, [0, 1, 3, 9, 33], n+->n, 2, [guessRat],
-        [guessSum, guessProduct, guessOne])\$GuessInteger
guess(n, [0, 1, 3, 9, 33], n+->n, [guessRat],
[guessSum, guessProduct, guessOne], 2)\$GuessInteger

??changed:
-Thus, 'guess' takes five parameters. The first three parallel the parameters in
Thus, 'guess' takes six parameters. The first three parallel the parameters in

??changed:
-         [guessSum, guessProduct])\$GuessPolynomial
[guessSum, guessProduct], 2)\$GuessPolynomial

??changed:
-guessPRec(n,[1, 1, 1+q, 1+q+q^2, 1+q+q^2+q^3+q^4, 1+q+q^2+q^3+2*q^4+q^5+q^6,
1+q+q^2+q^3+2*q^4+2*q^5+2*q^6+q^7+q^8+q^9, 1+q+q^2+q^3+q^4+q^5+q^6,
(1+q^4)*(1+q+q^2+q^3+q^4+q^5+2*q^6+2*q^7+2*q^8+2*q^9+q^10+q^11+q^12)],
n+->q^n)\$GuessPolynomial
l1:=[1,1,1+q,1+q+q^2,1+q+q^2+q^3+q^4,1+q+q^2+q^3+2*q^4+q^5+q^6]
l2:=[1+q+q^2+q^3+2*q^4+2*q^5+2*q^6+q^7+q^8+q^9]
l3:=[(1+q^4+q^6)*(1+q+q^2+q^3+q^4+q^5+q^6)]
l4:=[(1+q^4)*(1+q+q^2+q^3+q^4+q^5+2*q^6+2*q^7+2*q^8+2*q^9+q^10+q^11+q^12)]
l:=append(append(append(l1,l2),l3),l4)
guessPRec(n, l1, n+->q^n)\$GuessPolynomial