login  home  contents  what's new  discussion  bug reports     help  links  subscribe  changes  refresh  edit

Edit detail for SandBox revision 1 of 233

1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 112 113 114 115 116 117 118 119 120 121 122 123 124 125 126 127 128 129 130 131 132 133 134 135 136 137 138 139 140 141 142 143 144 145 146 147 148 149 150 151 152 153 154 155 156 157 158 159 160 161 162 163 164 165 166 167 168 169 170 171 172 173 174 175 176 177 178 179 180 181 182 183 184 185 186 187 188 189 190 191 192 193 194 195 196 197 198 199 200 201 202 203 204 205 206 207 208 209 210 211 212 213 214 215 216 217 218 219 220 221 222 223 224 225 226 227 228 229 230 231 232 233
Editor: page
Time: 2007/09/11 18:44:40 GMT-7
Note:

changed:
-
This is the front page of the SandBox. You can try anything you like
here but keep in mind that other people are also using these pages to
learn and experiment with Axiom and Reduce. Please be curteous to
others if you correct mistakes and try to explain what you are doing.

No Email Notices

  Normally, if you 'edit' any page on MathAction and click
'Save' or if you add a comment to a page, a notice of the
change is sent out to all subscribers on the axiom-developer
email list, see the [Axiom Community]. Separate notices are
also sent to those users who 'subscribe' directly to
MathAction.

Use Preview

  If you click 'Preview' instead of 'Save', you will get a chance
to see the result of your calculations and LaTeX commands but
**no** email notice is sent out and the result is not saved until
you decide to click 'Save' or not.

Use the !SandBox

  On this page or on any other page with a name beginning with
SandBox such as SandBoxJohn2, SandBoxSimple, SandBoxEtc, clicking
'Save' only sends email notices to users who 'subscribe'
directly to that specific SandBox page. Saving and adding
comments does *not* create an email to the email list. You
can safely use these pages for testing without disturbing
anyone who might not care to know about your experiments.

New !SandBox Pages

  You can also create new SandBox pages as needed just by
editing this page and adding a link to the list of new page
below. The link must include at least two uppercase letters
and no spaces or alternatively it can be any phrase written
inside ![ ] brackets as long as it begins with SandBox. When
you Save this page, the link to the new page will appear with
a blue question mark <font color="blue">?</font> beside it.
Clicking on the blue question mark <font color="blue">?</font>
will ask you if you wish to create a new page.

[SandBox Aldor Foreign] -- Using Aldor to call external C routines

[SandBox Aldor Generator] -- Aldor defines a 'generator' for type Vector

[SandBox Aldor Sieve] -- A prime number sieve in Aldor to count primes <= n.

[SandBox Aldor Testing] -- Using Aldor to write Axiom library routines

[SandBox Arrays] -- How fast is array access in Axiom?

[SandBox Axiom Syntax] -- Syntax of *if* *then* *else*

[SandboxBiblography]

[SandBox Boolean] -- evaluating Boolean expressions and conditions

[SandBox Cast] -- Meaning and use of 'pretend' vs. strong typing

[SandBox Categorical Relativity] -- Special relativity without the Lorentz group

[SandBox Category of Graphs] -- Graph theory in Axiom

[SandBox CL-WEB] -- Tangle operation for literate programming implemented in Common Lisp

[SandBox Combinat] -- A{ld,xi}o{r,m}Combinat

[SandBox Content MathML] -- Content vs. presentation MathML

[SandBox Direct Product] -- A x B

[SandBox DistributedExpression] -- expression in sum-of-products form

[SandBox Domains and Types] -- What is the difference?

[AxiomEmacsMode] -- Beginnings of an Emacs mode for Axiom based off of Jay's work and others

[SandBox Embeded PDF] -- pdf format documents can be displayed inline

[SandBox EndPaper] -- Algebra and Data Structure Hierarchy (lattice) diagrams

[SandBox Folding] -- experiments with DHTML, javascript, etc.

[SandBox Functional Addition] -- "adding" two functions

[SandBox Functions] -- How do they work?

[SandBox Functors] -- What are they? In Axiom functors are also called domain constructors.

[SandBox Gamma] -- Numerical evaluation of the incomplete Gamma function

[SandBox GuessingSequence] -- Guessing integer sequences

[SandBox Integration] -- Examples of integration in Axiom and Reduce

[SandBox Kernel] -- What is a "kernel"?

[SandBox kaveh]

[SandBox LaTeX] -- LaTeX commands allowed in MathAction

[SandBox Lisp] -- Using Lisp in Axiom

[SandBox Manip] -- expression manipulations

[SandBox Manipulating Domains] -- testing the domain of an expression

[SandBox Mapping] -- A->B is a type in Axiom

[MathMLFormat]

[SandBox Matrix] -- Examples of working with matrices in Axiom

[SandBox Maxima] -- Testing the Maxima interface

[SandBox Monoid] -- Rings and things

[SandBox Monoid Extend] -- Martin Rubey's beautiful idea about using 'extend'
to add a category to a previously defined domain.

[SandBox Noncommutative Polynomials] -- XPOLY and friends

[SandBox Numerical Integration] -- Simpson method

[SandBox NNI] -- NonNegative Integer without using SubDomain

[SandBox Pamphlet] -- [Literate Programming] support on MathAction

[SandBoxPartialFraction] -- Trigonometric expansion example

[SandBox Polymake] -- an interface between Axiom and PolyMake

[SandBox Polynomials] -- Axiom's polynomial domains are certainly
rich and complex!

[SandBox ProblemSolving] -- Test page for educational purposes

[SandBox Qubic] -- Solving cubic polynomials

[SandBox Reduce And MathML] -- Reduce can use MathML for both input and output

[SandBoxRelativeVelocity] -- Slides for IARD 2006: Addition of
Relative Velocites is Associative

[SandBox RenameTitle] -- trying to re-create a crash due to renaming pages

[SandBox Sage] -- This is a test of Sage in MathAction

[SandBox Shortcoming] -- Implementation of solve

[SandBox Solve] -- Solving equations

[SandBox Statistics] -- calculating statistics in Axiom

[SandBox SubDomain] -- What is a SubDomain?

[SandBox Tail Recursion] -- When does Axiom replace recursion with iteration?

[SandBox Text Files] -- How to access text files in Axiom

[SandBox Trace Analysed] -- Tracing can affect output of '1::EXPR INT' or '1::FRAC INT'

[SandBox Tuples Products and Records] -- Basic structured data types in Axiom

[SandBox Units and Dimensions] -- Scientific units and dimensions

[SandBox Spad] -- Domain construction

[SandBox Speed] -- Compilation speed

[SandBox Zero]

[SandBox Axiom Strengths]

SandBoxJohn2 -- Experiments with matrices and various other stuff

SandBox2 -- Experiments

SandBox3 -- Experiments

SandBox4 -- Experiments

SandBox5 -- Experiments with GraphViz and StructuredTables

SandBox6 -- Differential Equations etc.

[SandBox7] -- 

[SandBox8] -- Here you can create your own SandBox.

[SandBox9] -- Experiments with JET Bundles

[SandBox10]

[SandBox DoOps] -- used to run Axiom without actually have to have it installed!

[SandBoxKMG]

Click on the <font color="blue">?</font> to create a new page.
You should also edit this page to include a description and a new empty
link for the next person.

<hr />

Examples

  Here is a simple Axiom command::

    !\begin{axiom}
    integrate(1/(a+z^3), z=0..1,"noPole")
    \end{axiom}

\begin{axiom}
integrate(1/(a+z^3), z=0..1,"noPole")
\end{axiom}

And here is a REDUCE command::

  !\begin{reduce}
  load_package sfgamma;
  load_package defint;
  int(1/(a+z^3), z,0,1);
  \end{reduce}

\begin{reduce}
load_package sfgamma;
load_package defint;
int(1/(a+z^3), z,0,1);
\end{reduce}
<hr />

Common Mistakes

  Please review the list of [Common Mistakes] and the list
  of [MathAction Problems] if you are have never used
  MathAction before. If you are learning to use Axiom and think
  that someone must have solved some particular problem before
  you, check this list of Common [Axiom Problems].

From unknown Wed Dec 7 09:11:18 -0600 2005
From: unknown
Date: Wed, 07 Dec 2005 09:11:18 -0600
Subject: szsz
Message-ID: <20051207091118-0600@wiki.axiom-developer.org>

Works with ASCII text output formatting.
\begin{axiom}
)set output tex off
)set output algebra on
\end{axiom}
\begin{axiom}
    solve([x^2 + y^2 - 2*(ax*x + ay*y) = l1, x^2 + y^2 - 2*(cx*x + cy*y) = l2],[x,y])
\end{axiom}

But fails with LaTeX.
\begin{axiom}
)set output tex on
)set output algebra off
\end{axiom}


From kratt6 Tue Jan 3 05:22:52 -0600 2006
From: kratt6
Date: Tue, 03 Jan 2006 05:22:52 -0600
Subject: 0**0
Message-ID: <20060103052252-0600@wiki.axiom-developer.org>

The result of '0**0' depends on the type of '0':

\begin{axiom}
  (0::Float)**(0::Float)
\end{axiom}

The idea was, that defining $0^0$ as 1 is ok whenever there is no notion of limit. However, 

\begin{axiom}
  (0::EXPR INT)**(0::EXPR INT)
\end{axiom}

is not quite in line with this, I think.
There has been some discussion on this subject on axiom-developer.

It is easy to change this behaviour, if we know better...

From unknown Sun Jan 29 13:09:07 -0600 2006
From: unknown
Date: Sun, 29 Jan 2006 13:09:07 -0600
Subject: ruleset
Message-ID: <20060129130907-0600@wiki.axiom-developer.org>

Let's see if the same happens here:
\begin{axiom}
sinCosProducts := rule
  sin (x) * sin (y) == (cos(x-y) - cos(x+y))/2
  cos (x) * cos (y) == (cos(x-y) + cos(x+y))/2
  sin (x) * cos (y) == (sin(x-y) + sin(x+y))/2
\end{axiom}


From BillPage Mon Jan 30 09:00:02 -0600 2006
From: Bill Page
Date: Mon, 30 Jan 2006 09:00:02 -0600
Subject: when typing
Message-ID: <20060130090002-0600@wiki.axiom-developer.org>

When you are typing or when you cut-and-paste commands directly
into the Axiom interpreter you must use an underscore character at
the end of each incomplete line, and you must use the ( ) syntax
instead of identation, like this::

  sinCosProducts := rule (_
  sin (x) * sin (y) == (cos(x-y) - cos(x+y))/2; _
  cos (x) * cos (y) == (cos(x-y) + cos(x+y))/2; _
  sin (x) * cos (y) == (sin(x-y) + sin(x+y))/2)

Alternatively, using a text editor you can enter the commands into a
file called, for example 'sincos.input' exactly as in MathActon above
and the use the command::

  )read sincos.input


From unknown Sat Mar 11 13:19:44 -0600 2006
From: unknown
Date: Sat, 11 Mar 2006 13:19:44 -0600
Subject: 
Message-ID: <20060311131944-0600@wiki.axiom-developer.org>

\begin{axiom}
)lib RINTERPA RINTERP PCDEN GUESS GUESSINT GUESSP
guess(n, [1, 5, 14, 34, 69, 135, 240, 416, 686, 1106], n+->n, [guessRat], [guessSum, guessProduct, guessOne],2)$GuessInteger
\end{axiom}


From BillPage Thu Mar 23 22:21:41 -0600 2006
From: Bill Page
Date: Thu, 23 Mar 2006 22:21:41 -0600
Subject: conversion failed
Message-ID: <20060323222141-0600@wiki.axiom-developer.org>

Unknown wrote:

> z:=sum(myfn(x),x=1..10) -- This fails, why?

The reason this fails is because Axiom tries to evaluate
'myfn(x)' **first**. But 'x' is not yet an 'Integer' so Axiom
cannot compute 'myfn(x)'. I guess you were expecting Axiom
to "wait" and not evaluate 'myfn(x)' until after 'x' has
been assigned the value 1, right? But Axiom does not work
this way.

The solution is to write 'myfn(x)' so that is can be applied
to something symbolic like 'x'. For example something this:

\begin{axiom}
myfn(i : Expression Integer) : Expression Integer == i
myfn(x)
z:=sum(myfn(x),x=1..10)
\end{axiom}

From Bill(Nameomitted) Fri Mar 24 21:45:25 -0600 2006
From: Bill (Name omitted)
Date: Fri, 24 Mar 2006 21:45:25 -0600
Subject: Any hints for multivariate functions?
Message-ID: <20060324214525-0600@wiki.axiom-developer.org>
In-Reply-To: <20060323222141-0600@wiki.axiom-developer.org>

Hi Bill:

Thanks for your quick response.  I tried to respond to this earlier, but didn't see it in the sand box, please forgive me if you get multiple copies.

I tried to simplify the code from my original program, and generated a univariate function, however my actual code has a multivariate function,
and your excellent hint on the use of the Expression qualifier on the parameter and return type which works great for the univariate function case appears to fail for multivarite functions.
Please consider the following example.
\begin{axiom}
a(n : Expression Integer, k : Expression Integer, p : Expression Float) : Expression Float == binomial(n,k) * p**(k) * (1.0-p)**(n-k)
output(a(4,3,0.25)) -- see that the function actually evaluates for sensible values
z := sum(a(4,i,0.25), i=1..3) --- this fails
output(z)
\end{axiom}

I did notice in the Axiom online book, chapter 6.6, around page 241, the recommendation to use untyped functions, which appears to allow Axiom to do
inference on parameter and result type.
\begin{axiom}
b(n, k, p) == binomial(n,k) * p**(k) * (1.0-p)**(n-k)
output(b(4,3,0.25)) -- see that the function actually evaluates for sensible values
z := sum(b(4,i,0.25), i=1..3) --- this fails
output(z)
\end{axiom}
For univariate functions the approach
\begin{axiom}
c(k) == binomial(4,k) * 0.25**k * (1.0 - 0.25)**(4-k) -- This approach is only a test, but is not suitable for my program
output(c(3)) -- test to see if function can be evaluated for sensible arguments
z := sum(c(i), i=1..3) -- still doesn't work
output(z)
\end{axiom}
But interestingly something like
\begin{axiom}
d(k) == 1.5 * k -- coerce uotput to be a Float
z := sum(d(i), i=1..3) -- This works!
output(z)
\end{axiom}
Bill, thanks again for your quick help, unforutnatly I lack a local Axiom expert, any ideas would really be welcome here.

From billpage Sat Mar 25 16:01:07 -0600 2006
From: billpage
Date: Sat, 25 Mar 2006 16:01:07 -0600
Subject: reduce(+,[...]) = sum(...)
Message-ID: <20060325160107-0600@wiki.axiom-developer.org>

Try this
\begin{axiom}
z := reduce(+,[b(4,i,0.25) for  i in 1..3])
\end{axiom}


From Bill(Nameomitted) Mon Mar 27 08:10:26 -0600 2006
From: Bill (Name omitted)
Date: Mon, 27 Mar 2006 08:10:26 -0600
Subject: Handling the result from functions returning a matrix
Message-ID: <20060327081026-0600@wiki.axiom-developer.org>
In-Reply-To: <20060325160107-0600@wiki.axiom-developer.org>

Hi all:

Thanks Bill Page for your help, it is much appreciated (although I used a for loop and not reduce :-)).

I'm having a bit of difficulty getting a Function returning a matrix to work as expected,
perhaps it is just cockpit error, but I don't see the error of my ways.
\begin{axiom}
CFM(Q : Matrix(Float)): Matrix(Float) ==
   x := nrows(Q)
   MyIdentityMatrix : Matrix(Float) := new(x, x, 0)
   for i in 1..nrows(MyIdentityMatrix) repeat
      MyIdnetityMatrix(i,i) := 1.0
   Ninv := MyIdnetityMatrix - Q
   N := inverse(Ninv)
   N

--test ComputeFundamentalMatrix
X := matrix[[0, 0.5, 0],[0.5, 0, 0.5],[0, 0.5, 0]]
output(X)
N := CFM(X)
output(N)
\end{axiom}
Any ideas where I'm blowing it here?  I tried explicitly setting N to be a Matrix type but that failed too.
\begin{axiom}
CFM(Q : Matrix(Float)): Matrix(Float) ==
   x := nrows(Q)
   MyIdentityMatrix : Matrix(Float) := new(x, x, 0)
   for i in 1..nrows(MyIdentityMatrix) repeat
      MyIdnetityMatrix(i,i) := 1.0
   Ninv := MyIdnetityMatrix - Q
   N := inverse(Ninv)
   N

--test ComputeFundamentalMatrix
X := matrix[[0, 0.5, 0],[0.5, 0, 0.5],[0, 0.5, 0]]
output(X)
N : Matrix(Float) := CFM(X)
output(N)
\end{axiom}

Thanks again for all your help.

Regards:

Bill M. (Sorry, my unique last name attracts too much spam).

From billpage Mon Mar 27 09:34:35 -0600 2006
From: billpage
Date: Mon, 27 Mar 2006 09:34:35 -0600
Subject: typo and identity
Message-ID: <20060327093435-0600@wiki.axiom-developer.org>

> although I used a for loop and not reduce :-)

Good thinking. ;)

You have a simple typographical error. You have written both::

  MyIdentityMatrix

and ::

  MyIdnetityMatrix

BTW, instead of the complicated construction of the identify matrix
you should just write::

  Ninv := 1 - Q

For matrices '1' denotes the identity.


From unknown Sat Apr 8 10:45:29 -0500 2006
From: unknown
Date: Sat, 08 Apr 2006 10:45:29 -0500
Subject: 
Message-ID: <20060408104529-0500@wiki.axiom-developer.org>

\begin{axiom}
)set output tex off
)set output algebra on
FunFun := x**4 - 6* x**3 + 11* x*x + 2* x + 1
radicalSolve(FunFun)
)set output tex on
)set output algebra off

\end{axiom}

Matthias

\begin{axiom}
t:=matrix ([[0,1,1],[1,-2,2],[1,2,-1]])
\end{axiom}

We cat diagonalise t by finding it's eigenvalues.
\begin{axiom}
)set output tex off
)set output algebra on
e:=radicalEigenvectors(t)
d:=diagonalMatrix([e.1.radval,e.2.radval,e.3.radval])
\end{axiom}

Now prove it by constructing the simularity transformation
from the eigenvectors:
\begin{axiom}
p:=horizConcat(horizConcat(e.1.radvect.1,e.2.radvect.1),e.3.radvect.1)
p*d*inverse(p)
)set output tex on
)set output algebra off
\end{axiom}
\end{axiom}


From unknown Fri Apr 28 14:03:28 -0500 2006
From: unknown
Date: Fri, 28 Apr 2006 14:03:28 -0500
Subject: Axiom can't integrame exp(x^4) ;(
Message-ID: <20060428140328-0500@wiki.axiom-developer.org>

Axiom can't integrame exp(x^4) ;(

\begin{axiom}
integrate(exp(x**4),x)
\end{axiom}

But Maple can...

\begin{axiom}
f(x) == (1/4)*x*(-Gamma(1/4,-x**4)*Gamma(3/4)+%pi*sqrt(2))/((-x**4)**(1/4)*Gamma(3/4))
D(f(x),x)
\end{axiom}

From kratt6 Fri Apr 28 16:34:16 -0500 2006
From: kratt6
Date: Fri, 28 Apr 2006 16:34:16 -0500
Subject: Axiom cannot integrate 'e^(4*x)'
Message-ID: <20060428163416-0500@wiki.axiom-developer.org>

This is not a big surprise: note that 'Gamma(x,y)' is not an elementary function.

Martin


From unknown Thu May 18 11:30:21 -0500 2006
From: unknown
Date: Thu, 18 May 2006 11:30:21 -0500
Subject: 
Message-ID: <20060518113021-0500@wiki.axiom-developer.org>

This is both obviously wrong since the integrand is a positive function:
\begin{axiom}
integrate(1/(1+x^4),x=%minusInfinity..%plusInfinity)
numeric(integrate(1/(1+x^4),x=0..1))
\end{axiom}


From unknown Wed May 24 04:31:40 -0500 2006
From: unknown
Date: Wed, 24 May 2006 04:31:40 -0500
Subject: 
Message-ID: <20060524043140-0500@wiki.axiom-developer.org>

\begin{axiom}
)clear co
n := 32

y : FARRAY INT := new(n,1)

n0 := n
n1 := sum(x^1, x=0..n-1)
n2 := sum(x^2, x=0..n-1)
n3 := sum(x^3, x=0..n-1)
n4 := sum(x^4, x=0..n-1)

A := matrix([[n4, n3, n2],_
            [n3, n2, n1],_
            [n2, n1, n0]])

X := vector([x1, x2, x3])
B := vector([sum(x^2* u, x=0..n-1),_
       sum(x*   v, x=0..n-1),_
       sum(     w, x=0..n-1)])

solve([A * X = B], [x1, x2, x3])
\end{axiom}


From unknown Tue May 30 23:51:26 -0500 2006
From: unknown
Date: Tue, 30 May 2006 23:51:26 -0500
Subject: can this be correct?
Message-ID: <20060530235126-0500@wiki.axiom-developer.org>

\begin{axiom}
integrate(1/((x+t)*sqrt(1+(x*t)**2)),t=0..%plusInfinity,"noPole")
subst(%,x=1)
integrate(1/((1+t)*sqrt(1+(1*t)**2)),t=0..%plusInfinity,"noPole")
simplify(%-subst((asinh(x^2)+asinh(1/x^2))/sqrt(1+x^4),x=1))
%::Expression Float
\end{axiom}


From unknown Mon Jul 3 02:07:02 -0500 2006
From: unknown
Date: Mon, 03 Jul 2006 02:07:02 -0500
Subject: 
Message-ID: <20060703020702-0500@wiki.axiom-developer.org>

\begin{axiom}
a := matrix([ [-1,0,0,0,1,0], [0,1,0,0,0,0], [0,0,2,0,0,-2], [0,0,0,4,0,0], [0,0,0,0,3,0], [0,0,-3,0,0,3]]) 
determinant(a)
inverse(a)
\end{axiom}


From unknown Fri Jul 7 11:54:52 -0500 2006
From: unknown
Date: Fri, 07 Jul 2006 11:54:52 -0500
Subject: 
Message-ID: <20060707115452-0500@wiki.axiom-developer.org>

a := matrix([ [-3,1,1,1], [1,1,1,1], [1,1,1,1], [1,1,1,1]])


From unknown Fri Jul 7 13:24:57 -0500 2006
From: unknown
Date: Fri, 07 Jul 2006 13:24:57 -0500
Subject: 
Message-ID: <20060707132457-0500@wiki.axiom-developer.org>
In-Reply-To: <20060707115452-0500@wiki.axiom-developer.org>

\begin{axiom}
As := matrix([ [-3,1,1,1], [1,1,1,1], [1,1,1,1], [1,1,1,1]])
A := subMatrix(As, 2,4,2,4)
ob := orthonormalBasis(A)
P : Matrix(Expression Integer) := new(3,3,0)
setsubMatrix!(P,1,1,ob.3) 
setsubMatrix!(P,1,2,ob.1) 
setsubMatrix!(P,1,3,ob.2)
Pt := transpose(P)
Ps : Matrix(Expression Integer) := new(4,4,0)
Ps(1,1) := 1
setsubMatrix!(Ps,2,2,P)
PsT := transpose(Ps)
PsTAsPs := PsT * As * Ps
b1 := PsTAsPs(2,1)
l1 := PsTAsPs(2,2)
Us : Matrix(Expression Integer) := new(4,4,0)
Us(1,1) := 1
Us(2,2) := 1
Us(3,3) := 1
Us(4,4) := 1
Us(2,1) := -b1 / l1
PsUs := Ps * Us
PsUsT := transpose(PsUs)
PsUsTAsPsUs := PsUsT * As * PsUs
C := inverse(PsUs) 
c := PsUsTAsPsUs(1,1)
gQ := PsUsTAsPsUs / c 
x1 := transpose(matrix([[1,2,3,4]]))
v1 := transpose(x1) * As * x1
x2 := C * x1
v2 := transpose(x2) * PsUsTAsPsUs * x2
\end{axiom}


From unknown Tue Aug 1 02:17:12 -0500 2006
From: unknown
Date: Tue, 01 Aug 2006 02:17:12 -0500
Subject: graphics
Message-ID: <20060801021712-0500@wiki.axiom-developer.org>

\begin{axiom}
draw(y**2/2+(x**2-1)**2/4-1=0, x,y, range ==[-2..2, -1..1])
\end{axiom}


From greg Sat Feb 3 09:35:50 -0600 2007
From: greg
Date: Sat, 03 Feb 2007 09:35:50 -0600
Subject: series test 
Message-ID: <20070203093550-0600@wiki.axiom-developer.org>

\begin{axiom}
f1 := taylor(1 - x**2,x = 0)
asin f1
sin %
\end{axiom}

SandboxMSkuce
\begin{axiom}
1+1
\end{axiom}


SandBoxCS224

From jhnbk Fri Jun 8 03:50:35 -0500 2007
From: jhnbk
Date: Fri, 08 Jun 2007 03:50:35 -0500
Subject: integration
Message-ID: <20070608035035-0500@wiki.axiom-developer.org>

\begin{axiom}
integrate((x-1)/log(x), x)
integrate(x*exp(x)*sin(x),x)
\end{axiom} 

From daneshpajouh Sat Jun 16 07:00:00 -0500 2007
From: daneshpajouh
Date: Sat, 16 Jun 2007 07:00:00 -0500
Subject: Working With Lists
Message-ID: <20070616070000-0500@wiki.axiom-developer.org>

\begin{axiom}
[p for p in primes(2,1000)|(p rem 16)=1]
[p**2+1 for p in primes(2,100)]
\end{axiom}

\begin {axiom}
integrate (2x^2 + 2x, x)
\end {axiom} 
\end {axiom}


From vv Sat Jul 28 14:00:27 -0500 2007
From: vv
Date: Sat, 28 Jul 2007 14:00:27 -0500
Subject: is it error?
Message-ID: <20070728140027-0500@wiki.axiom-developer.org>
In-Reply-To: <20070616070000-0500@wiki.axiom-developer.org>

\begin{axiom}
radix(36,37)
\end{axiom}

Is it error?

From pbwagner Mon Sep 10 13:00:06 -0500 2007
From: pbwagner
Date: Mon, 10 Sep 2007 13:00:06 -0500
Subject: example from my daughter's college calc
Message-ID: <20070910130006-0500@wiki.axiom-developer.org>

integrate(log(log(x)),x)

From pbwagner Mon Sep 10 13:01:48 -0500 2007
From: pbwagner
Date: Mon, 10 Sep 2007 13:01:48 -0500
Subject: (better) example (with axiom markers this time) ;-)
Message-ID: <20070910130148-0500@wiki.axiom-developer.org>

\begin{axiom}
integrate(log(log(x)),x)
\end{axiom}

This is the front page of the SandBox. You can try anything you like
here but keep in mind that other people are also using these pages to
learn and experiment with Axiom and Reduce. Please be curteous to
others if you correct mistakes and try to explain what you are doing.

No Email Notices

Normally, if you edit any page on MathAction and click Save or if you add a comment to a page, a notice of the change is sent out to all subscribers on the axiom-developer email list, see the [Axiom Community]. Separate notices are also sent to those users who subscribe directly to MathAction.

Use Preview

If you click Preview instead of Save, you will get a chance to see the result of your calculations and LaTeX commands but no email notice is sent out and the result is not saved until you decide to click Save or not.

Use the SandBox

On this page or on any other page with a name beginning with SandBox such as SandBoxJohn2, SandBoxSimple, SandBoxEtc, clicking Save only sends email notices to users who subscribe directly to that specific SandBox page. Saving and adding comments does not create an email to the email list. You can safely use these pages for testing without disturbing anyone who might not care to know about your experiments.

New SandBox Pages

You can also create new SandBox pages as needed just by editing this page and adding a link to the list of new page below. The link must include at least two uppercase letters and no spaces or alternatively it can be any phrase written inside [ ] brackets as long as it begins with SandBox. When you Save this page, the link to the new page will appear with a blue question mark ? beside it. Clicking on the blue question mark ? will ask you if you wish to create a new page.

[SandBox Aldor Foreign]
Using Aldor to call external C routines
[SandBox Aldor Generator]
Aldor defines a generator for type Vector
[SandBox Aldor Sieve]
A prime number sieve in Aldor to count primes <= n.
[SandBox Aldor Testing]
Using Aldor to write Axiom library routines
[SandBox Arrays]
How fast is array access in Axiom?
[SandBox Axiom Syntax]
Syntax of if then else

[SandboxBiblography]

[SandBox Boolean]
evaluating Boolean expressions and conditions
[SandBox Cast]
Meaning and use of pretend vs. strong typing
[SandBox Categorical Relativity]
Special relativity without the Lorentz group
[SandBox Category of Graphs]
Graph theory in Axiom
[SandBox CL-WEB]
Tangle operation for literate programming implemented in Common Lisp
[SandBox Combinat]
A{ld,xi}o{r,m}Combinat
[SandBox Content MathML]
Content vs. presentation MathML
[SandBox Direct Product]
A x B
[SandBox DistributedExpression]
expression in sum-of-products form
[SandBox Domains and Types]
What is the difference?
[AxiomEmacsMode]
Beginnings of an Emacs mode for Axiom based off of Jay's work and others
[SandBox Embeded PDF]
pdf format documents can be displayed inline
[SandBox EndPaper]
Algebra and Data Structure Hierarchy (lattice) diagrams
[SandBox Folding]
experiments with DHTML, javascript, etc.
[SandBox Functional Addition]
"adding" two functions
[SandBox Functions]
How do they work?
[SandBox Functors]
What are they? In Axiom functors are also called domain constructors.
[SandBox Gamma]
Numerical evaluation of the incomplete Gamma function
[SandBox GuessingSequence]
Guessing integer sequences
[SandBox Integration]
Examples of integration in Axiom and Reduce
[SandBox Kernel]
What is a "kernel"?

[SandBox kaveh]

[SandBox LaTeX]
LaTeX commands allowed in MathAction
[SandBox Lisp]
Using Lisp in Axiom
[SandBox Manip]
expression manipulations
[SandBox Manipulating Domains]
testing the domain of an expression
[SandBox Mapping]
A->B is a type in Axiom

[MathMLFormat]

[SandBox Matrix]
Examples of working with matrices in Axiom
[SandBox Maxima]
Testing the Maxima interface
[SandBox Monoid]
Rings and things
[SandBox Monoid Extend]
Martin Rubey's beautiful idea about using extend to add a category to a previously defined domain.
[SandBox Noncommutative Polynomials]
XPOLY and friends
[SandBox Numerical Integration]
Simpson method
[SandBox NNI]
NonNegative Integer without using SubDomain
[SandBox Pamphlet]
[Literate Programming] support on MathAction
[SandBoxPartialFraction]
Trigonometric expansion example
[SandBox Polymake]
an interface between Axiom and PolyMake
[SandBox Polynomials]
Axiom's polynomial domains are certainly rich and complex!
[SandBox ProblemSolving]
Test page for educational purposes
[SandBox Qubic]
Solving cubic polynomials
[SandBox Reduce And MathML]
Reduce can use MathML for both input and output
[SandBoxRelativeVelocity]
Slides for IARD 2006: Addition of Relative Velocites is Associative
[SandBox RenameTitle]
trying to re-create a crash due to renaming pages
[SandBox Sage]
This is a test of Sage in MathAction
[SandBox Shortcoming]
Implementation of solve
[SandBox Solve]
Solving equations
[SandBox Statistics]
calculating statistics in Axiom
[SandBox SubDomain]
What is a SubDomain?
[SandBox Tail Recursion]
When does Axiom replace recursion with iteration?
[SandBox Text Files]
How to access text files in Axiom
[SandBox Trace Analysed]
Tracing can affect output of 1::EXPR INT or 1::FRAC INT
[SandBox Tuples Products and Records]
Basic structured data types in Axiom
[SandBox Units and Dimensions]
Scientific units and dimensions
[SandBox Spad]
Domain construction
[SandBox Speed]
Compilation speed

[SandBox Zero]

[SandBox Axiom Strengths]

SandBoxJohn2
Experiments with matrices and various other stuff
SandBox2
Experiments
SandBox3
Experiments
SandBox4
Experiments
SandBox5
Experiments with GraphViz and StructuredTables
SandBox6
Differential Equations etc.
[SandBox7]
[SandBox8]
Here you can create your own SandBox.
[SandBox9]
Experiments with JET Bundles

[SandBox10]

[SandBox DoOps]
used to run Axiom without actually have to have it installed!

[SandBoxKMG]

Click on the ? to create a new page. You should also edit this page to include a description and a new empty link for the next person.


Examples

Here is a simple Axiom command:

    \begin{axiom}
    integrate(1/(a+z^3), z=0..1,"noPole")
    \end{axiom}

axiom
integrate(1/(a+z^3), z=0..1,"noPole")
\begin{equation} \label{eq1}{-{{\sqrt {3}} \ {\log \left( {{{3 \ {a \sp 2} \ {{\root {3} \of {{a \sp 2}}} \sp 2}}+{{\left( -{2 \ {a \sp 3}}+{a \sp 2} \right)} \ {\root {3} \of {{a \sp 2}}}}+{a \sp 4} -{2 \ {a \sp 3}}}} \right)}}+{2 \ {\sqrt {3}} \ {\log \left( {{{{\root {3} \of {{a \sp 2}}} \sp 2}+{2 \ a \ {\root {3} \of {{a \sp 2}}}}+{a \sp 2}}} \right)}}+{{12} \ {\arctan \left( {{{{2 \ {\sqrt {3}} \ {\root {3} \of {{a \sp 2}}}} -{a \ {\sqrt {3}}}} \over {3 \ a}}} \right)}}+{2 \ \pi}} \over {{12} \ {\sqrt {3}} \ {\root {3} \of {{a \sp 2}}}} \end{equation}
Type: Union(f1: OrderedCompletion? Expression Integer,...)

And here is a REDUCE command:

  \begin{reduce}
  load_package sfgamma;
  load_package defint;
  int(1/(a+z^3), z,0,1);
  \end{reduce}

\begin{reduce} load_package sfgamma; load_package defint; int(1/(a+z^3), z,0,1); \end{reduce}


Common Mistakes

Please review the list of [Common Mistakes]? and the list of [MathAction Problems]? if you are have never used MathAction? before. If you are learning to use Axiom and think that someone must have solved some particular problem before you, check this list of Common [Axiom Problems]?.

Works with ASCII text output formatting.
axiom
)set output tex off )set output algebra on

axiom
solve([x^2 + y^2 - 2*(ax*x + ay*y) = l1, x^2 + y^2 - 2*(cx*x + cy*y) = l2],[x,y]) (2) [ (- 2cy + 2ay)y - l2 + l1 [x= ------------------------, 2cx - 2ax 2 2 2 2 2 (4cy - 8ay cy + 4cx - 8ax cx + 4ay + 4ax )y + 2 2 (4cy - 4ay)l2 + (- 4cy + 4ay)l1 + (8ax cx - 8ax )cy - 8ay cx + 8ax ay cx * y + 2 2 2 2 l2 + (- 2l1 + 4ax cx - 4ax )l2 + l1 + (- 4cx + 4ax cx)l1 = 0 ] ]
Type: List List Equation Fraction Polynomial Integer

But fails with LaTeX?.

axiom
)set output tex on )set output algebra off

The result of 0**0 depends on the type of '0':

axiom
(0::Float)**(0::Float) >> Error detected within library code: 0**0 is undefined

The idea was, that defining $0^0$ as 1 is ok whenever there is no notion of limit. However,

axiom
(0::EXPR INT)**(0::EXPR INT)
\begin{equation} \label{eq2}1 \end{equation}
Type: Expression Integer

is not quite in line with this, I think. There has been some discussion on this subject on axiom-developer.

It is easy to change this behaviour, if we know better...

Let's see if the same happens here:
axiom
sinCosProducts := rule sin (x) * sin (y) == (cos(x-y) - cos(x+y))/2 cos (x) * cos (y) == (cos(x-y) + cos(x+y))/2 sin (x) * cos (y) == (sin(x-y) + sin(x+y))/2
\begin{equation} \label{eq3}\left\{ {{ \%H \ {\sin \left( {x} \right)} \ {\sin \left( {y} \right)}} \mbox{\rm == } {{-{ \%H \ {\cos \left( {{y+x}} \right)}}+{ \%H \ {\cos \left( {{y -x}} \right)}}} \over 2}}, \: {{ \%I \ {\cos \left( {x} \right)} \ {\cos \left( {y} \right)}} \mbox{\rm == } {{{ \%I \ {\cos \left( {{y+x}} \right)}}+{ \%I \ {\cos \left( {{y -x}} \right)}}} \over 2}}, \: {{ \%J \ {\cos \left( {y} \right)} \ {\sin \left( {x} \right)}} \mbox{\rm == } {{{ \%J \ {\sin \left( {{y+x}} \right)}} -{ \%J \ {\sin \left( {{y -x}} \right)}}} \over 2}} \right\} \end{equation}
Type: Ruleset(Integer,Integer,Expression Integer)

when typing --Bill Page, Mon, 30 Jan 2006 09:00:02 -0600 reply
When you are typing or when you cut-and-paste commands directly into the Axiom interpreter you must use an underscore character at the end of each incomplete line, and you must use the ( ) syntax instead of identation, like this:
  sinCosProducts := rule (_
  sin (x) * sin (y) == (cos(x-y) - cos(x+y))/2; _
  cos (x) * cos (y) == (cos(x-y) + cos(x+y))/2; _
  sin (x) * cos (y) == (sin(x-y) + sin(x+y))/2)

Alternatively, using a text editor you can enter the commands into a file called, for example sincos.input exactly as in MathActon? above and the use the command:

  )read sincos.input

axiom
)lib RINTERPA RINTERP PCDEN GUESS GUESSINT GUESSP )library cannot find the file RINTERPA. )library cannot find the file RINTERP. )library cannot find the file PCDEN. )library cannot find the file GUESS. )library cannot find the file GUESSINT. )library cannot find the file GUESSP. guess(n, [1, 5, 14, 34, 69, 135, 240, 416, 686, 1106], n+->n, [guessRat], [guessSum, guessProduct, guessOne],2)$GuessInteger GuessInteger is not a valid type.

conversion failed --Bill Page, Thu, 23 Mar 2006 22:21:41 -0600 reply
Unknown wrote:
z:=sum(myfn(x),x=1..10) -- This fails, why?

The reason this fails is because Axiom tries to evaluate myfn(x) first. But x is not yet an Integer so Axiom cannot compute myfn(x). I guess you were expecting Axiom to "wait" and not evaluate myfn(x) until after x has been assigned the value 1, right? But Axiom does not work this way.

The solution is to write myfn(x) so that is can be applied to something symbolic like x. For example something this:

axiom
myfn(i : Expression Integer) : Expression Integer == i Function declaration myfn : Expression Integer -> Expression Integer has been added to workspace.
Type: Void
axiom
myfn(x)
axiom
Compiling function myfn with type Expression Integer -> Expression 
      Integer
\begin{equation} \label{eq4}x \end{equation}
Type: Expression Integer
axiom
z:=sum(myfn(x),x=1..10)
\begin{equation} \label{eq5}55 \end{equation}
Type: Expression Integer

Any hints for multivariate functions? --Bill (Name omitted), Fri, 24 Mar 2006 21:45:25 -0600 reply
Hi Bill:

Thanks for your quick response. I tried to respond to this earlier, but didn't see it in the sand box, please forgive me if you get multiple copies.

I tried to simplify the code from my original program, and generated a univariate function, however my actual code has a multivariate function, and your excellent hint on the use of the Expression qualifier on the parameter and return type which works great for the univariate function case appears to fail for multivarite functions. Please consider the following example.

axiom
a(n : Expression Integer, k : Expression Integer, p : Expression Float) : Expression Float == binomial(n,k) * p**(k) * (1.0-p)**(n-k) Function declaration a : (Expression Integer,Expression Integer, Expression Float) -> Expression Float has been added to workspace.
Type: Void
axiom
output(a(4,3,0.25)) -- see that the function actually evaluates for sensible values
axiom
Compiling function a with type (Expression Integer,Expression 
      Integer,Expression Float) -> Expression Float 
   0.046875
Type: Void
axiom
z := sum(a(4,i,0.25), i=1..3) --- this fails There are 6 exposed and 2 unexposed library operations named sum having 2 argument(s) but none was determined to be applicable. Use HyperDoc Browse, or issue )display op sum to learn more about the available operations. Perhaps package-calling the operation or using coercions on the arguments will allow you to apply the operation. Cannot find a definition or applicable library operation named sum with argument type(s) Expression Float SegmentBinding PositiveInteger Perhaps you should use "@" to indicate the required return type, or "$" to specify which version of the function you need. output(z) 55
Type: Void

I did notice in the Axiom online book, chapter 6.6, around page 241, the recommendation to use untyped functions, which appears to allow Axiom to do inference on parameter and result type.

axiom
b(n, k, p) == binomial(n,k) * p**(k) * (1.0-p)**(n-k)
Type: Void
axiom
output(b(4,3,0.25)) -- see that the function actually evaluates for sensible values
axiom
Compiling function b with type (PositiveInteger,PositiveInteger,
      Float) -> Float 
   0.046875
Type: Void
axiom
z := sum(b(4,i,0.25), i=1..3) --- this fails
axiom
Compiling function b with type (PositiveInteger,Variable i,Float)
       -> Expression Float 
   There are 6 exposed and 2 unexposed library operations named sum 
      having 2 argument(s) but none was determined to be applicable. 
      Use HyperDoc Browse, or issue
                               )display op sum
      to learn more about the available operations. Perhaps 
      package-calling the operation or using coercions on the arguments
      will allow you to apply the operation.
   Cannot find a definition or applicable library operation named sum 
      with argument type(s) 
                              Expression Float
                       SegmentBinding PositiveInteger
      Perhaps you should use "@" to indicate the required return type, 
      or "$" to specify which version of the function you need.
output(z)
   55
Type: Void

For univariate functions the approach

axiom
c(k) == binomial(4,k) * 0.25**k * (1.0 - 0.25)**(4-k) -- This approach is only a test, but is not suitable for my program
Type: Void
axiom
output(c(3)) -- test to see if function can be evaluated for sensible arguments
axiom
Compiling function c with type PositiveInteger -> Float 
   0.046875
Type: Void
axiom
z := sum(c(i), i=1..3) -- still doesn't work
axiom
Compiling function c with type Variable i -> Expression Float 
   There are 6 exposed and 2 unexposed library operations named sum 
      having 2 argument(s) but none was determined to be applicable. 
      Use HyperDoc Browse, or issue
                               )display op sum
      to learn more about the available operations. Perhaps 
      package-calling the operation or using coercions on the arguments
      will allow you to apply the operation.
   Cannot find a definition or applicable library operation named sum 
      with argument type(s) 
                              Expression Float
                       SegmentBinding PositiveInteger
      Perhaps you should use "@" to indicate the required return type, 
      or "$" to specify which version of the function you need.
output(z)
   55
Type: Void

But interestingly something like

axiom
d(k) == 1.5 * k -- coerce uotput to be a Float
Type: Void
axiom
z := sum(d(i), i=1..3) -- This works!
axiom
Compiling function d with type Variable i -> Polynomial Float
\begin{equation} \label{eq6}9.0 \end{equation}
Type: Fraction Polynomial Float
axiom
output(z) 9.0
Type: Void

Bill, thanks again for your quick help, unforutnatly I lack a local Axiom expert, any ideas would really be welcome here.

reduce(+,[...]?) = sum(...) --billpage, Sat, 25 Mar 2006 16:01:07 -0600 reply
Try this
axiom
z := reduce(+,[b(4,i,0.25) for i in 1..3])
\begin{equation} \label{eq7}0.6796875 \end{equation}
Type: Float

Handling the result from functions returning a matrix --Bill (Name omitted), Mon, 27 Mar 2006 08:10:26 -0600 reply
Hi all:

Thanks Bill Page for your help, it is much appreciated (although I used a for loop and not reduce :-)).

I'm having a bit of difficulty getting a Function returning a matrix to work as expected, perhaps it is just cockpit error, but I don't see the error of my ways.

axiom
CFM(Q : Matrix(Float)): Matrix(Float) == x := nrows(Q) MyIdentityMatrix : Matrix(Float) := new(x, x, 0) for i in 1..nrows(MyIdentityMatrix) repeat MyIdnetityMatrix(i,i) := 1.0 Ninv := MyIdnetityMatrix - Q N := inverse(Ninv) N Function declaration CFM : Matrix Float -> Matrix Float has been added to workspace.
Type: Void
axiom
--test ComputeFundamentalMatrix X := matrix[[0, 0.5, 0],[0.5, 0, 0.5],[0, 0.5, 0]]
\begin{equation*} \label{eq8}\left[ \begin{array}{ccc} {0.0} & {0.5} & {0.0} \ {0.5} & {0.0} & {0.5} \ {0.0} & {0.5} & {0.0} \end{array} \right] \end{equation*}
Type: Matrix Float
axiom
output(X) +0.0 0.5 0.0+ | | |0.5 0.0 0.5| | | +0.0 0.5 0.0+
Type: Void
axiom
N := CFM(X) The form on the left hand side of an assignment must be a single variable, a Tuple of variables or a reference to an entry in an object supporting the setelt operation. output(N) N
Type: Void

Any ideas where I'm blowing it here? I tried explicitly setting N to be a Matrix type but that failed too.

axiom
CFM(Q : Matrix(Float)): Matrix(Float) == x := nrows(Q) MyIdentityMatrix : Matrix(Float) := new(x, x, 0) for i in 1..nrows(MyIdentityMatrix) repeat MyIdnetityMatrix(i,i) := 1.0 Ninv := MyIdnetityMatrix - Q N := inverse(Ninv) N Function declaration CFM : Matrix Float -> Matrix Float has been added to workspace. Compiled code for CFM has been cleared. 1 old definition(s) deleted for function or rule CFM
Type: Void
axiom
--test ComputeFundamentalMatrix X := matrix[[0, 0.5, 0],[0.5, 0, 0.5],[0, 0.5, 0]]
\begin{equation*} \label{eq9}\left[ \begin{array}{ccc} {0.0} & {0.5} & {0.0} \ {0.5} & {0.0} & {0.5} \ {0.0} & {0.5} & {0.0} \end{array} \right] \end{equation*}
Type: Matrix Float
axiom
output(X) +0.0 0.5 0.0+ | | |0.5 0.0 0.5| | | +0.0 0.5 0.0+
Type: Void
axiom
N : Matrix(Float) := CFM(X) The form on the left hand side of an assignment must be a single variable, a Tuple of variables or a reference to an entry in an object supporting the setelt operation. output(N) N is declared as being in Matrix Float but has not been given a value.

Thanks again for all your help.

Regards:

Bill M. (Sorry, my unique last name attracts too much spam).

typo and identity --billpage, Mon, 27 Mar 2006 09:34:35 -0600 reply
although I used a for loop and not reduce :-)

Good thinking. ;)

You have a simple typographical error. You have written both:

  MyIdentityMatrix

and :

  MyIdnetityMatrix

BTW, instead of the complicated construction of the identify matrix you should just write:

  Ninv := 1 - Q

For matrices 1 denotes the identity.

axiom
)set output tex off )set output algebra on FunFun := x**4 - 6* x**3 + 11* x*x + 2* x + 1 4 3 2 (28) x - 6x + 11x + 2x + 1
Type: Polynomial Integer
axiom
radicalSolve(FunFun) (29) [ x = - ROOT +---------------------+2 | +-+ +----+ |2069\|3 + 144\|- 79 - 9 |--------------------- 3| +-+ \| 27\|3 + +---------------------+ | +-+ +----+ |2069\|3 + 144\|- 79 30 |--------------------- - 169 3| +-+ \| 27\|3 * ROOT +---------------------+2 | +-+ +----+ |2069\|3 + 144\|- 79 9 |--------------------- 3| +-+ \| 27\|3 + +---------------------+ | +-+ +----+ |2069\|3 + 144\|- 79 15 |--------------------- + 169 3| +-+ \| 27\|3 / +---------------------+ | +-+ +----+ |2069\|3 + 144\|- 79 9 |--------------------- 3| +-+ \| 27\|3 + +---------------------+ | +-+ +----+ |2069\|3 + 144\|- 79 - 144 |--------------------- 3| +-+ \| 27\|3 / +---------------------+ | +-+ +----+ |2069\|3 + 144\|- 79 9 |--------------------- 3| +-+ \| 27\|3 * ROOT +---------------------+2 | +-+ +----+ |2069\|3 + 144\|- 79 9 |--------------------- 3| +-+ \| 27\|3 + +---------------------+ | +-+ +----+ |2069\|3 + 144\|- 79 15 |--------------------- + 169 3| +-+ \| 27\|3 / +---------------------+ | +-+ +----+ |2069\|3 + 144\|- 79 9 |--------------------- 3| +-+ \| 27\|3 + +-------------------------------------------------------------+ | +---------------------+2 +---------------------+ | | +-+ +----+ | +-+ +----+ | |2069\|3 + 144\|- 79 |2069\|3 + 144\|- 79 |9 |--------------------- + 15 |--------------------- + 169 | 3| +-+ 3| +-+ | \| 27\|3 \| 27\|3 |------------------------------------------------------------- + 3 | +---------------------+ | | +-+ +----+ | |2069\|3 + 144\|- 79 | 9 |--------------------- | 3| +-+ \| \| 27\|3 / 2 , x = ROOT +---------------------+2 +---------------------+ | +-+ +----+ | +-+ +----+ |2069\|3 + 144\|- 79 |2069\|3 + 144\|- 79 - 9 |--------------------- + 30 |--------------------- 3| +-+ 3| +-+ \| 27\|3 \| 27\|3 + - 169 * ROOT +---------------------+2 | +-+ +----+ |2069\|3 + 144\|- 79 9 |--------------------- 3| +-+ \| 27\|3 + +---------------------+ | +-+ +----+ |2069\|3 + 144\|- 79 15 |--------------------- + 169 3| +-+ \| 27\|3 / +---------------------+ | +-+ +----+ |2069\|3 + 144\|- 79 9 |--------------------- 3| +-+ \| 27\|3 + +---------------------+ | +-+ +----+ |2069\|3 + 144\|- 79 - 144 |--------------------- 3| +-+ \| 27\|3 / +---------------------+ | +-+ +----+ |2069\|3 + 144\|- 79 9 |--------------------- 3| +-+ \| 27\|3 * +-------------------------------------------------------------+ | +---------------------+2 +---------------------+ | | +-+ +----+ | +-+ +----+ | |2069\|3 + 144\|- 79 |2069\|3 + 144\|- 79 |9 |--------------------- + 15 |--------------------- + 169 | 3| +-+ 3| +-+ | \| 27\|3 \| 27\|3 |------------------------------------------------------------- | +---------------------+ | | +-+ +----+ | |2069\|3 + 144\|- 79 | 9 |--------------------- | 3| +-+ \| \| 27\|3 + +-------------------------------------------------------------+ | +---------------------+2 +---------------------+ | | +-+ +----+ | +-+ +----+ | |2069\|3 + 144\|- 79 |2069\|3 + 144\|- 79 |9 |--------------------- + 15 |--------------------- + 169 | 3| +-+ 3| +-+ | \| 27\|3 \| 27\|3 |------------------------------------------------------------- + 3 | +---------------------+ | | +-+ +----+ | |2069\|3 + 144\|- 79 | 9 |--------------------- | 3| +-+ \| \| 27\|3 / 2 , x = - ROOT +---------------------+2 | +-+ +----+ |2069\|3 + 144\|- 79 - 9 |--------------------- 3| +-+ \| 27\|3 + +---------------------+ | +-+ +----+ |2069\|3 + 144\|- 79 30 |--------------------- - 169 3| +-+ \| 27\|3 * ROOT +---------------------+2 | +-+ +----+ |2069\|3 + 144\|- 79 9 |--------------------- 3| +-+ \| 27\|3 + +---------------------+ | +-+ +----+ |2069\|3 + 144\|- 79 15 |--------------------- + 169 3| +-+ \| 27\|3 / +---------------------+ | +-+ +----+ |2069\|3 + 144\|- 79 9 |--------------------- 3| +-+ \| 27\|3 + +---------------------+ | +-+ +----+ |2069\|3 + 144\|- 79 144 |--------------------- 3| +-+ \| 27\|3 / +---------------------+ | +-+ +----+ |2069\|3 + 144\|- 79 9 |--------------------- 3| +-+ \| 27\|3 * ROOT +---------------------+2 | +-+ +----+ |2069\|3 + 144\|- 79 9 |--------------------- 3| +-+ \| 27\|3 + +---------------------+ | +-+ +----+ |2069\|3 + 144\|- 79 15 |--------------------- + 169 3| +-+ \| 27\|3 / +---------------------+ | +-+ +----+ |2069\|3 + 144\|- 79 9 |--------------------- 3| +-+ \| 27\|3 + +-------------------------------------------------------------+ | +---------------------+2 +---------------------+ | | +-+ +----+ | +-+ +----+ | |2069\|3 + 144\|- 79 |2069\|3 + 144\|- 79 |9 |--------------------- + 15 |--------------------- + 169 | 3| +-+ 3| +-+ | \| 27\|3 \| 27\|3 - |------------------------------------------------------------- + 3 | +---------------------+ | | +-+ +----+ | |2069\|3 + 144\|- 79 | 9 |--------------------- | 3| +-+ \| \| 27\|3 / 2 , x = ROOT +---------------------+2 +---------------------+ | +-+ +----+ | +-+ +----+ |2069\|3 + 144\|- 79 |2069\|3 + 144\|- 79 - 9 |--------------------- + 30 |--------------------- 3| +-+ 3| +-+ \| 27\|3 \| 27\|3 + - 169 * ROOT +---------------------+2 | +-+ +----+ |2069\|3 + 144\|- 79 9 |--------------------- 3| +-+ \| 27\|3 + +---------------------+ | +-+ +----+ |2069\|3 + 144\|- 79 15 |--------------------- + 169 3| +-+ \| 27\|3 / +---------------------+ | +-+ +----+ |2069\|3 + 144\|- 79 9 |--------------------- 3| +-+ \| 27\|3 + +---------------------+ | +-+ +----+ |2069\|3 + 144\|- 79 144 |--------------------- 3| +-+ \| 27\|3 / +---------------------+ | +-+ +----+ |2069\|3 + 144\|- 79 9 |--------------------- 3| +-+ \| 27\|3 * +-------------------------------------------------------------+ | +---------------------+2 +---------------------+ | | +-+ +----+ | +-+ +----+ | |2069\|3 + 144\|- 79 |2069\|3 + 144\|- 79 |9 |--------------------- + 15 |--------------------- + 169 | 3| +-+ 3| +-+ | \| 27\|3 \| 27\|3 |------------------------------------------------------------- | +---------------------+ | | +-+ +----+ | |2069\|3 + 144\|- 79 | 9 |--------------------- | 3| +-+ \| \| 27\|3 + +-------------------------------------------------------------+ | +---------------------+2 +---------------------+ | | +-+ +----+ | +-+ +----+ | |2069\|3 + 144\|- 79 |2069\|3 + 144\|- 79 |9 |--------------------- + 15 |--------------------- + 169 | 3| +-+ 3| +-+ | \| 27\|3 \| 27\|3 - |------------------------------------------------------------- + 3 | +---------------------+ | | +-+ +----+ | |2069\|3 + 144\|- 79 | 9 |--------------------- | 3| +-+ \| \| 27\|3 / 2 ]
Type: List Equation Expression Integer
axiom
)set output tex on )set output algebra off

Matthias

axiom
t:=matrix ([[0,1,1],[1,-2,2],[1,2,-1]])
\begin{equation*} \label{eq10}\left[ \begin{array}{ccc} 0 & 1 & 1 \ 1 & -2 & 2 \ 1 & 2 & -1 \end{array} \right] \end{equation*}
Type: Matrix Integer

We cat diagonalise t by finding it's eigenvalues.

axiom
)set output tex off )set output algebra on e:=radicalEigenvectors(t) (31) [ +-----------------+2 +-----------------+ | +-+ +------+ | +-+ +------+ |3\|3 + \|- 1345 |3\|3 + \|- 1345 3 |----------------- - 3 |----------------- + 7 3| +-+ 3| +-+ \| 6\|3 \| 6\|3 [radval= --------------------------------------------------, radmult= 1, +-----------------+ | +-+ +------+ |3\|3 + \|- 1345 3 |----------------- 3| +-+ \| 6\|3 radvect = [ [ [ +-----------------+2 | +-+ +------+ +-+ |3\|3 + \|- 1345 - 12\|3 |----------------- 3| +-+ \| 6\|3 + +-----------------+ | +-+ +------+ +-+ +------+ |3\|3 + \|- 1345 +-+ +------+ (60\|3 + 6\|- 1345 ) |----------------- + 205\|3 + 3\|- 1345 3| +-+ \| 6\|3 / +-----------------+2 | +-+ +------+ +-+ |3\|3 + \|- 1345 126\|3 |----------------- 3| +-+ \| 6\|3 ] , [ +-----------------+2 | +-+ +------+ +-+ |3\|3 + \|- 1345 6\|3 |----------------- 3| +-+ \| 6\|3 + +-----------------+ | +-+ +------+ +-+ +------+ |3\|3 + \|- 1345 +-+ +------+ (117\|3 - 3\|- 1345 ) |----------------- - 71\|3 + 9\|- 1345 3| +-+ \| 6\|3 / +-----------------+2 | +-+ +------+ +-+ |3\|3 + \|- 1345 126\|3 |----------------- 3| +-+ \| 6\|3 ] , [1]] ] ] , [ radval = +-----------------+2 | +-+ +------+ +---+ |3\|3 + \|- 1345 (- 3\|- 3 - 3) |----------------- 3| +-+ \| 6\|3 + +-----------------+ | +-+ +------+ +---+ |3\|3 + \|- 1345 (- 3\|- 3 + 3) |----------------- + 14 3| +-+ \| 6\|3 / +-----------------+ | +-+ +------+ +---+ |3\|3 + \|- 1345 (3\|- 3 - 3) |----------------- 3| +-+ \| 6\|3 , radmult= 1, radvect = [ [ [ +-----------------+2 | +-+ +------+ +-+ |3\|3 + \|- 1345 - 24\|3 |----------------- 3| +-+ \| 6\|3 + +---+ +-+ +------+ +---+ +------+ ((- 60\|- 3 - 60)\|3 - 6\|- 1345 \|- 3 - 6\|- 1345 ) * +-----------------+ | +-+ +------+ |3\|3 + \|- 1345 |----------------- 3| +-+ \| 6\|3 + +---+ +-+ +------+ +---+ +------+ (205\|- 3 - 205)\|3 + 3\|- 1345 \|- 3 - 3\|- 1345 / +-----------------+2 | +-+ +------+ +-+ |3\|3 + \|- 1345 252\|3 |----------------- 3| +-+ \| 6\|3 ] , [ +-----------------+2 | +-+ +------+ +-+ |3\|3 + \|- 1345 12\|3 |----------------- 3| +-+ \| 6\|3 + +---+ +-+ +------+ +---+ +------+ ((- 117\|- 3 - 117)\|3 + 3\|- 1345 \|- 3 + 3\|- 1345 ) * +-----------------+ | +-+ +------+ |3\|3 + \|- 1345 |----------------- 3| +-+ \| 6\|3 + +---+ +-+ +------+ +---+ +------+ (- 71\|- 3 + 71)\|3 + 9\|- 1345 \|- 3 - 9\|- 1345 / +-----------------+2 | +-+ +------+ +-+ |3\|3 + \|- 1345 252\|3 |----------------- 3| +-+ \| 6\|3 ] , [1]] ] ] , [ radval = +-----------------+2 | +-+ +------+ +---+ |3\|3 + \|- 1345 (- 3\|- 3 + 3) |----------------- 3| +-+ \| 6\|3 + +-----------------+ | +-+ +------+ +---+ |3\|3 + \|- 1345 (- 3\|- 3 - 3) |----------------- - 14 3| +-+ \| 6\|3 / +-----------------+ | +-+ +------+ +---+ |3\|3 + \|- 1345 (3\|- 3 + 3) |----------------- 3| +-+ \| 6\|3 , radmult= 1, radvect = [ [ [ +-----------------+2 | +-+ +------+ +-+ |3\|3 + \|- 1345 - 24\|3 |----------------- 3| +-+ \| 6\|3 + +---+ +-+ +------+ +---+ +------+ ((60\|- 3 - 60)\|3 + 6\|- 1345 \|- 3 - 6\|- 1345 ) * +-----------------+ | +-+ +------+ |3\|3 + \|- 1345 |----------------- 3| +-+ \| 6\|3 + +---+ +-+ +------+ +---+ +------+ (- 205\|- 3 - 205)\|3 - 3\|- 1345 \|- 3 - 3\|- 1345 / +-----------------+2 | +-+ +------+ +-+ |3\|3 + \|- 1345 252\|3 |----------------- 3| +-+ \| 6\|3 ] , [ +-----------------+2 | +-+ +------+ +-+ |3\|3 + \|- 1345 12\|3 |----------------- 3| +-+ \| 6\|3 + +---+ +-+ +------+ +---+ +------+ ((117\|- 3 - 117)\|3 - 3\|- 1345 \|- 3 + 3\|- 1345 ) * +-----------------+ | +-+ +------+ |3\|3 + \|- 1345 |----------------- 3| +-+ \| 6\|3 + +---+ +-+ +------+ +---+ +------+ (71\|- 3 + 71)\|3 - 9\|- 1345 \|- 3 - 9\|- 1345 / +-----------------+2 | +-+ +------+ +-+ |3\|3 + \|- 1345 252\|3 |----------------- 3| +-+ \| 6\|3 ] , [1]] ] ] ]
Type: List Record(radval: Expression Integer,radmult: Integer,radvect: List Matrix Expression Integer)
axiom
d:=diagonalMatrix([e.1.radval,e.2.radval,e.3.radval]) Function definition for d is being overwritten. Compiled code for d has been cleared. (32) +-----------------+2 +-----------------+ | +-+ +------+ | +-+ +------+ |3\|3 + \|- 1345 |3\|3 + \|- 1345 3 |----------------- - 3 |----------------- + 7 3| +-+ 3| +-+ \| 6\|3 \| 6\|3 [[--------------------------------------------------,0,0], +-----------------+ | +-+ +------+ |3\|3 + \|- 1345 3 |----------------- 3| +-+ \| 6\|3 [0, +-----------------+2 | +-+ +------+ +---+ |3\|3 + \|- 1345 (- 3\|- 3 - 3) |----------------- 3| +-+ \| 6\|3 + +-----------------+ | +-+ +------+ +---+ |3\|3 + \|- 1345 (- 3\|- 3 + 3) |----------------- + 14 3| +-+ \| 6\|3 / +-----------------+ | +-+ +------+ +---+ |3\|3 + \|- 1345 (3\|- 3 - 3) |----------------- 3| +-+ \| 6\|3 , 0] , [0, 0, +-----------------+2 | +-+ +------+ +---+ |3\|3 + \|- 1345 (- 3\|- 3 + 3) |----------------- 3| +-+ \| 6\|3 + +-----------------+ | +-+ +------+ +---+ |3\|3 + \|- 1345 (- 3\|- 3 - 3) |----------------- - 14 3| +-+ \| 6\|3 / +-----------------+ | +-+ +------+ +---+ |3\|3 + \|- 1345 (3\|- 3 + 3) |----------------- 3| +-+ \| 6\|3 ] ]
Type: Matrix Expression Integer

Now prove it by constructing the simularity transformation from the eigenvectors:

axiom
p:=horizConcat(horizConcat(e.1.radvect.1,e.2.radvect.1),e.3.radvect.1) (33) [ [ +-----------------+2 | +-+ +------+ +-+ |3\|3 + \|- 1345 - 12\|3 |----------------- 3| +-+ \| 6\|3 + +-----------------+ | +-+ +------+ +-+ +------+ |3\|3 + \|- 1345 +-+ +------+ (60\|3 + 6\|- 1345 ) |----------------- + 205\|3 + 3\|- 1345 3| +-+ \| 6\|3 / +-----------------+2 | +-+ +------+ +-+ |3\|3 + \|- 1345 126\|3 |----------------- 3| +-+ \| 6\|3 , +-----------------+2 | +-+ +------+ +-+ |3\|3 + \|- 1345 - 24\|3 |----------------- 3| +-+ \| 6\|3 + +---+ +-+ +------+ +---+ +------+ ((- 60\|- 3 - 60)\|3 - 6\|- 1345 \|- 3 - 6\|- 1345 ) * +-----------------+ | +-+ +------+ |3\|3 + \|- 1345 |----------------- 3| +-+ \| 6\|3 + +---+ +-+ +------+ +---+ +------+ (205\|- 3 - 205)\|3 + 3\|- 1345 \|- 3 - 3\|- 1345 / +-----------------+2 | +-+ +------+ +-+ |3\|3 + \|- 1345 252\|3 |----------------- 3| +-+ \| 6\|3 , +-----------------+2 | +-+ +------+ +-+ |3\|3 + \|- 1345 - 24\|3 |----------------- 3| +-+ \| 6\|3 + +---+ +-+ +------+ +---+ +------+ ((60\|- 3 - 60)\|3 + 6\|- 1345 \|- 3 - 6\|- 1345 ) * +-----------------+ | +-+ +------+ |3\|3 + \|- 1345 |----------------- 3| +-+ \| 6\|3 + +---+ +-+ +------+ +---+ +------+ (- 205\|- 3 - 205)\|3 - 3\|- 1345 \|- 3 - 3\|- 1345 / +-----------------+2 | +-+ +------+ +-+ |3\|3 + \|- 1345 252\|3 |----------------- 3| +-+ \| 6\|3 ] , [ +-----------------+2 | +-+ +------+ +-+ |3\|3 + \|- 1345 6\|3 |----------------- 3| +-+ \| 6\|3 + +-----------------+ | +-+ +------+ +-+ +------+ |3\|3 + \|- 1345 +-+ +------+ (117\|3 - 3\|- 1345 ) |----------------- - 71\|3 + 9\|- 1345 3| +-+ \| 6\|3 / +-----------------+2 | +-+ +------+ +-+ |3\|3 + \|- 1345 126\|3 |----------------- 3| +-+ \| 6\|3 , +-----------------+2 | +-+ +------+ +-+ |3\|3 + \|- 1345 12\|3 |----------------- 3| +-+ \| 6\|3 + +---+ +-+ +------+ +---+ +------+ ((- 117\|- 3 - 117)\|3 + 3\|- 1345 \|- 3 + 3\|- 1345 ) * +-----------------+ | +-+ +------+ |3\|3 + \|- 1345 |----------------- 3| +-+ \| 6\|3 + +---+ +-+ +------+ +---+ +------+ (- 71\|- 3 + 71)\|3 + 9\|- 1345 \|- 3 - 9\|- 1345 / +-----------------+2 | +-+ +------+ +-+ |3\|3 + \|- 1345 252\|3 |----------------- 3| +-+ \| 6\|3 , +-----------------+2 | +-+ +------+ +-+ |3\|3 + \|- 1345 12\|3 |----------------- 3| +-+ \| 6\|3 + +---+ +-+ +------+ +---+ +------+ ((117\|- 3 - 117)\|3 - 3\|- 1345 \|- 3 + 3\|- 1345 ) * +-----------------+ | +-+ +------+ |3\|3 + \|- 1345 |----------------- 3| +-+ \| 6\|3 + +---+ +-+ +------+ +---+ +------+ (71\|- 3 + 71)\|3 - 9\|- 1345 \|- 3 - 9\|- 1345 / +-----------------+2 | +-+ +------+ +-+ |3\|3 + \|- 1345 252\|3 |----------------- 3| +-+ \| 6\|3 ] , [1,1,1]]
Type: Matrix Expression Integer
axiom
p*d*inverse(p) +0 1 1 + | | (34) |1 - 2 2 | | | +1 2 - 1+
Type: Matrix Expression Integer
axiom
)set output tex on )set output algebra off

\end{axiom}

Axiom can't integrame exp(x^4) ;( --unknown, Fri, 28 Apr 2006 14:03:28 -0500 reply
Axiom can't integrame exp(x^4) ;(

axiom
integrate(exp(x**4),x)
\begin{equation} \label{eq11}\int \sp{\displaystyle x} {{e \sp { \%Q \sp 4}} \ {d \%Q}} \end{equation}
Type: Union(Expression Integer,...)

But Maple can...

axiom
f(x) == (1/4)*x*(-Gamma(1/4,-x**4)*Gamma(3/4)+%pi*sqrt(2))/((-x**4)**(1/4)*Gamma(3/4))
Type: Void
axiom
D(f(x),x)
axiom
Compiling function f with type Variable x -> Expression DoubleFloat
\begin{equation} \label{eq12}e \sp {x \sp 4} \end{equation}
Type: Expression DoubleFloat?

Axiom cannot integrate e^(4*x) --kratt6, Fri, 28 Apr 2006 16:34:16 -0500 reply
This is not a big surprise: note that Gamma(x,y) is not an elementary function.

Martin

This is both obviously wrong since the integrand is a positive function:
axiom
integrate(1/(1+x^4),x=%minusInfinity..%plusInfinity)
\begin{equation} \label{eq13}0 \end{equation}
Type: Union(f1: OrderedCompletion? Expression Integer,...)
axiom
numeric(integrate(1/(1+x^4),x=0..1))
\begin{equation} \label{eq14}-{0.2437477471 9968052418} \end{equation}
Type: Float

axiom
)clear co All user variables and function definitions have been cleared. All )browse facility databases have been cleared. Internally cached functions and constructors have been cleared. )clear completely is finished. n := 32
\begin{equation} \label{eq15}32 \end{equation}
Type: PositiveInteger?
axiom
y : FARRAY INT := new(n,1)
\begin{equation*} \label{eq16}\left[ 1, \: 1, \: 1, \: 1, \: 1, \: 1, \: 1, \: 1, \: 1, \: 1, \: 1, \: 1, \: 1, \: 1, \: 1, \: 1, \: 1, \: 1, \: 1, \: 1, \: 1, \: 1, \: 1, \: 1, \: 1, \: 1, \: 1, \: 1, \: 1, \: 1, \: 1, \: 1 \right] \end{equation*}
Type: FlexibleArray? Integer
axiom
n0 := n
\begin{equation} \label{eq17}32 \end{equation}
Type: PositiveInteger?
axiom
n1 := sum(x^1, x=0..n-1)
\begin{equation} \label{eq18}496 \end{equation}
Type: Fraction Polynomial Integer
axiom
n2 := sum(x^2, x=0..n-1)
\begin{equation} \label{eq19}10416 \end{equation}
Type: Fraction Polynomial Integer
axiom
n3 := sum(x^3, x=0..n-1)
\begin{equation} \label{eq20}246016 \end{equation}
Type: Fraction Polynomial Integer
axiom
n4 := sum(x^4, x=0..n-1)
\begin{equation} \label{eq21}6197520 \end{equation}
Type: Fraction Polynomial Integer
axiom
A := matrix([[n4, n3, n2],_ [n3, n2, n1],_ [n2, n1, n0]])
\begin{equation*} \label{eq22}\left[ \begin{array}{ccc} {6197520} & {246016} & {10416} \ {246016} & {10416} & {496} \ {10416} & {496} & {32} \end{array} \right] \end{equation*}
Type: Matrix Fraction Polynomial Integer
axiom
X := vector([x1, x2, x3])
\begin{equation*} \label{eq23}\left[ x1, \: x2, \: x3 \right] \end{equation*}
Type: Vector OrderedVariableList? [x1,x2,x3]?
axiom
B := vector([sum(x^2* u, x=0..n-1),_ sum(x* v, x=0..n-1),_ sum( w, x=0..n-1)])
\begin{equation*} \label{eq24}\left[ {{10416} \ u}, \: {{496} \ v}, \: {{32} \ w} \right] \end{equation*}
Type: Vector Fraction Polynomial Integer
axiom
solve([A * X = B], [x1, x2, x3]) There are 20 exposed and 3 unexposed library operations named solve having 2 argument(s) but none was determined to be applicable. Use HyperDoc Browse, or issue )display op solve to learn more about the available operations. Perhaps package-calling the operation or using coercions on the arguments will allow you to apply the operation. Cannot find a definition or applicable library operation named solve with argument type(s) List Equation Vector Fraction Polynomial Integer List OrderedVariableList [x1,x2,x3] Perhaps you should use "@" to indicate the required return type, or "$" to specify which version of the function you need.

can this be correct? --unknown, Tue, 30 May 2006 23:51:26 -0500 reply
axiom
integrate(1/((x+t)*sqrt(1+(x*t)**2)),t=0..%plusInfinity,"noPole")
\begin{equation} \label{eq25}{-{\log \left( {{{{{\left( {2 \ {x \sp {10}}} -{4 \ {x \sp 8}}+{6 \ {x \sp 6}} -{6 \ {x \sp 4}}+{4 \ {x \sp 2}} -2 \right)} \ {\sqrt {{{x \sp 4}+1}}}}+{2 \ {x \sp {12}}} -{4 \ {x \sp {10}}}+{7 \ {x \sp 8}} -{8 \ {x \sp 6}}+{7 \ {x \sp 4}} -{4 \ {x \sp 2}}+2} \over {x \sp 2}}} \right)}+{\log \left( {{{x \sp 6}+{x \sp 2}}} \right)}} \over {2 \ {\sqrt {{{x \sp 4}+1}}}} \end{equation}
Type: Union(f1: OrderedCompletion? Expression Integer,...)
axiom
subst(%,x=1)
\begin{equation} \label{eq26}0 \end{equation}
Type: Expression Integer
axiom
integrate(1/((1+t)*sqrt(1+(1*t)**2)),t=0..%plusInfinity,"noPole")
\begin{equation} \label{eq27}{{\sqrt {2}} \ {\log \left( {{{{12} \ {\sqrt {2}}}+{17}}} \right)}} \over 4 \end{equation}
Type: Union(f1: OrderedCompletion? Expression Integer,...)
axiom
simplify(%-subst((asinh(x^2)+asinh(1/x^2))/sqrt(1+x^4),x=1))
\begin{equation} \label{eq28}{{\log \left( {{{{12} \ {\sqrt {2}}}+{17}}} \right)} -{4 \ {asinh \left( {1} \right)}}} \over {2 \ {\sqrt {2}}} \end{equation}
Type: Expression Integer
axiom
%::Expression Float
\begin{equation} \label{eq29}0.0 \end{equation}
Type: Expression Float

axiom
a := matrix([ [-1,0,0,0,1,0], [0,1,0,0,0,0], [0,0,2,0,0,-2], [0,0,0,4,0,0], [0,0,0,0,3,0], [0,0,-3,0,0,3]])
\begin{equation*} \label{eq30}\left[ \begin{array}{cccccc} -1 & 0 & 0 & 0 & 1 & 0 \ 0 & 1 & 0 & 0 & 0 & 0 \ 0 & 0 & 2 & 0 & 0 & -2 \ 0 & 0 & 0 & 4 & 0 & 0 \ 0 & 0 & 0 & 0 & 3 & 0 \ 0 & 0 & -3 & 0 & 0 & 3 \end{array} \right] \end{equation*}
Type: Matrix Integer
axiom
determinant(a)
\begin{equation} \label{eq31}0 \end{equation}
Type: NonNegativeInteger?
axiom
inverse(a)
\begin{equation} \label{eq32}\mbox{\tt "failed"} \end{equation}
Type: Union("failed",...)

a := matrix([ [-3,1,1,1]?, [1,1,1,1]?, [1,1,1,1]?, [1,1,1,1]]?)

axiom
As := matrix([ [-3,1,1,1], [1,1,1,1], [1,1,1,1], [1,1,1,1]])
\begin{equation*} \label{eq33}\left[ \begin{array}{cccc} -3 & 1 & 1 & 1 \ 1 & 1 & 1 & 1 \ 1 & 1 & 1 & 1 \ 1 & 1 & 1 & 1 \end{array} \right] \end{equation*}
Type: Matrix Integer
axiom
A := subMatrix(As, 2,4,2,4)
\begin{equation*} \label{eq34}\left[ \begin{array}{ccc} 1 & 1 & 1 \ 1 & 1 & 1 \ 1 & 1 & 1 \end{array} \right] \end{equation*}
Type: Matrix Integer
axiom
ob := orthonormalBasis(A)
\begin{equation*} \label{eq35}\left[ {\left[ \begin{array}{c} -{{\sqrt {2}} \over {2 \ {\sqrt {3}}}} \ {{\sqrt {2}} \over {\sqrt {3}}} \ -{{\sqrt {2}} \over {2 \ {\sqrt {3}}}} \end{array} \right]}, \: {\left[ \begin{array}{c} -{1 \over {\sqrt {2}}} \ 0 \ {1 \over {\sqrt {2}}} \end{array} \right]}, \: {\left[ \begin{array}{c} {1 \over {\sqrt {3}}} \ {1 \over {\sqrt {3}}} \ {1 \over {\sqrt {3}}} \end{array} \right]} \right] \end{equation*}
Type: List Matrix Expression Integer
axiom
P : Matrix(Expression Integer) := new(3,3,0)
\begin{equation*} \label{eq36}\left[ \begin{array}{ccc} 0 & 0 & 0 \ 0 & 0 & 0 \ 0 & 0 & 0 \end{array} \right] \end{equation*}
Type: Matrix Expression Integer
axiom
setsubMatrix!(P,1,1,ob.3)
\begin{equation*} \label{eq37}\left[ \begin{array}{ccc} {1 \over {\sqrt {3}}} & 0 & 0 \ {1 \over {\sqrt {3}}} & 0 & 0 \ {1 \over {\sqrt {3}}} & 0 & 0 \end{array} \right] \end{equation*}
Type: Matrix Expression Integer
axiom
setsubMatrix!(P,1,2,ob.1)
\begin{equation*} \label{eq38}\left[ \begin{array}{ccc} {1 \over {\sqrt {3}}} & -{{\sqrt {2}} \over {2 \ {\sqrt {3}}}} & 0 \ {1 \over {\sqrt {3}}} & {{\sqrt {2}} \over {\sqrt {3}}} & 0 \ {1 \over {\sqrt {3}}} & -{{\sqrt {2}} \over {2 \ {\sqrt {3}}}} & 0 \end{array} \right] \end{equation*}
Type: Matrix Expression Integer
axiom
setsubMatrix!(P,1,3,ob.2)
\begin{equation*} \label{eq39}\left[ \begin{array}{ccc} {1 \over {\sqrt {3}}} & -{{\sqrt {2}} \over {2 \ {\sqrt {3}}}} & -{1 \over {\sqrt {2}}} \ {1 \over {\sqrt {3}}} & {{\sqrt {2}} \over {\sqrt {3}}} & 0 \ {1 \over {\sqrt {3}}} & -{{\sqrt {2}} \over {2 \ {\sqrt {3}}}} & {1 \over {\sqrt {2}}} \end{array} \right] \end{equation*}
Type: Matrix Expression Integer
axiom
Pt := transpose(P)
\begin{equation*} \label{eq40}\left[ \begin{array}{ccc} {1 \over {\sqrt {3}}} & {1 \over {\sqrt {3}}} & {1 \over {\sqrt {3}}} \ -{{\sqrt {2}} \over {2 \ {\sqrt {3}}}} & {{\sqrt {2}} \over {\sqrt {3}}} & -{{\sqrt {2}} \over {2 \ {\sqrt {3}}}} \ -{1 \over {\sqrt {2}}} & 0 & {1 \over {\sqrt {2}}} \end{array} \right] \end{equation*}
Type: Matrix Expression Integer
axiom
Ps : Matrix(Expression Integer) := new(4,4,0)
\begin{equation*} \label{eq41}\left[ \begin{array}{cccc} 0 & 0 & 0 & 0 \ 0 & 0 & 0 & 0 \ 0 & 0 & 0 & 0 \ 0 & 0 & 0 & 0 \end{array} \right] \end{equation*}
Type: Matrix Expression Integer
axiom
Ps(1,1) := 1
\begin{equation} \label{eq42}1 \end{equation}
Type: Expression Integer
axiom
setsubMatrix!(Ps,2,2,P)
\begin{equation*} \label{eq43}\left[ \begin{array}{cccc} 1 & 0 & 0 & 0 \ 0 & {1 \over {\sqrt {3}}} & -{{\sqrt {2}} \over {2 \ {\sqrt {3}}}} & -{1 \over {\sqrt {2}}} \ 0 & {1 \over {\sqrt {3}}} & {{\sqrt {2}} \over {\sqrt {3}}} & 0 \ 0 & {1 \over {\sqrt {3}}} & -{{\sqrt {2}} \over {2 \ {\sqrt {3}}}} & {1 \over {\sqrt {2}}} \end{array} \right] \end{equation*}
Type: Matrix Expression Integer
axiom
PsT := transpose(Ps)
\begin{equation*} \label{eq44}\left[ \begin{array}{cccc} 1 & 0 & 0 & 0 \ 0 & {1 \over {\sqrt {3}}} & {1 \over {\sqrt {3}}} & {1 \over {\sqrt {3}}} \ 0 & -{{\sqrt {2}} \over {2 \ {\sqrt {3}}}} & {{\sqrt {2}} \over {\sqrt {3}}} & -{{\sqrt {2}} \over {2 \ {\sqrt {3}}}} \ 0 & -{1 \over {\sqrt {2}}} & 0 & {1 \over {\sqrt {2}}} \end{array} \right] \end{equation*}
Type: Matrix Expression Integer
axiom
PsTAsPs := PsT * As * Ps
\begin{equation*} \label{eq45}\left[ \begin{array}{cccc} -3 & {3 \over {\sqrt {3}}} & 0 & 0 \ {3 \over {\sqrt {3}}} & 3 & 0 & 0 \ 0 & 0 & 0 & 0 \ 0 & 0 & 0 & 0 \end{array} \right] \end{equation*}
Type: Matrix Expression Integer
axiom
b1 := PsTAsPs(2,1)
\begin{equation} \label{eq46}3 \over {\sqrt {3}} \end{equation}
Type: Expression Integer
axiom
l1 := PsTAsPs(2,2)
\begin{equation} \label{eq47}3 \end{equation}
Type: Expression Integer
axiom
Us : Matrix(Expression Integer) := new(4,4,0)
\begin{equation*} \label{eq48}\left[ \begin{array}{cccc} 0 & 0 & 0 & 0 \ 0 & 0 & 0 & 0 \ 0 & 0 & 0 & 0 \ 0 & 0 & 0 & 0 \end{array} \right] \end{equation*}
Type: Matrix Expression Integer
axiom
Us(1,1) := 1
\begin{equation} \label{eq49}1 \end{equation}
Type: Expression Integer
axiom
Us(2,2) := 1
\begin{equation} \label{eq50}1 \end{equation}
Type: Expression Integer
axiom
Us(3,3) := 1
\begin{equation} \label{eq51}1 \end{equation}
Type: Expression Integer
axiom
Us(4,4) := 1
\begin{equation} \label{eq52}1 \end{equation}
Type: Expression Integer
axiom
Us(2,1) := -b1 / l1
\begin{equation} \label{eq53}-{1 \over {\sqrt {3}}} \end{equation}
Type: Expression Integer
axiom
PsUs := Ps * Us
\begin{equation*} \label{eq54}\left[ \begin{array}{cccc} 1 & 0 & 0 & 0 \ -{1 \over 3} & {1 \over {\sqrt {3}}} & -{{\sqrt {2}} \over {2 \ {\sqrt {3}}}} & -{1 \over {\sqrt {2}}} \ -{1 \over 3} & {1 \over {\sqrt {3}}} & {{\sqrt {2}} \over {\sqrt {3}}} & 0 \ -{1 \over 3} & {1 \over {\sqrt {3}}} & -{{\sqrt {2}} \over {2 \ {\sqrt {3}}}} & {1 \over {\sqrt {2}}} \end{array} \right] \end{equation*}
Type: Matrix Expression Integer
axiom
PsUsT := transpose(PsUs)
\begin{equation*} \label{eq55}\left[ \begin{array}{cccc} 1 & -{1 \over 3} & -{1 \over 3} & -{1 \over 3} \ 0 & {1 \over {\sqrt {3}}} & {1 \over {\sqrt {3}}} & {1 \over {\sqrt {3}}} \ 0 & -{{\sqrt {2}} \over {2 \ {\sqrt {3}}}} & {{\sqrt {2}} \over {\sqrt {3}}} & -{{\sqrt {2}} \over {2 \ {\sqrt {3}}}} \ 0 & -{1 \over {\sqrt {2}}} & 0 & {1 \over {\sqrt {2}}} \end{array} \right] \end{equation*}
Type: Matrix Expression Integer
axiom
PsUsTAsPsUs := PsUsT * As * PsUs
\begin{equation*} \label{eq56}\left[ \begin{array}{cccc} -4 & 0 & 0 & 0 \ 0 & 3 & 0 & 0 \ 0 & 0 & 0 & 0 \ 0 & 0 & 0 & 0 \end{array} \right] \end{equation*}
Type: Matrix Expression Integer
axiom
C := inverse(PsUs)
\begin{equation*} \label{eq57}\left[ \begin{array}{cccc} 1 & 0 & 0 & 0 \ {{\sqrt {3}} \over 3} & {{\sqrt {3}} \over 3} & {{\sqrt {3}} \over 3} & {{\sqrt {3}} \over 3} \ 0 & -{{\sqrt {3}} \over {3 \ {\sqrt {2}}}} & {{2 \ {\sqrt {3}}} \over {3 \ {\sqrt {2}}}} & -{{{\sqrt {2}} \ {\sqrt {3}}} \over 6} \ 0 & -{{\sqrt {2}} \over 2} & 0 & {{\sqrt {2}} \over 2} \end{array} \right] \end{equation*}
Type: Union(Matrix Expression Integer,...)
axiom
c := PsUsTAsPsUs(1,1)
\begin{equation} \label{eq58}-4 \end{equation}
Type: Expression Integer
axiom
gQ := PsUsTAsPsUs / c
\begin{equation*} \label{eq59}\left[ \begin{array}{cccc} 1 & 0 & 0 & 0 \ 0 & -{3 \over 4} & 0 & 0 \ 0 & 0 & 0 & 0 \ 0 & 0 & 0 & 0 \end{array} \right] \end{equation*}
Type: Matrix Expression Integer
axiom
x1 := transpose(matrix([[1,2,3,4]]))
\begin{equation*} \label{eq60}\left[ \begin{array}{c} 1 \ 2 \ 3 \ 4 \end{array} \right] \end{equation*}
Type: Matrix Integer
axiom
v1 := transpose(x1) * As * x1
\begin{equation*} \label{eq61}\left[ \begin{array}{c} {96} \end{array} \right] \end{equation*}
Type: Matrix Integer
axiom
x2 := C * x1
\begin{equation*} \label{eq62}\left[ \begin{array}{c} 1 \ {{{10} \ {\sqrt {3}}} \over 3} \ 0 \ {\sqrt {2}} \end{array} \right] \end{equation*}
Type: Matrix Expression Integer
axiom
v2 := transpose(x2) * PsUsTAsPsUs * x2
\begin{equation*} \label{eq63}\left[ \begin{array}{c} {96} \end{array} \right] \end{equation*}
Type: Matrix Expression Integer

axiom
draw(y**2/2+(x**2-1)**2/4-1=0, x,y, range ==[-2..2, -1..1]) There are 20 exposed and 18 unexposed library operations named ** having 2 argument(s) but none was determined to be applicable. Use HyperDoc Browse, or issue )display op ** to learn more about the available operations. Perhaps package-calling the operation or using coercions on the arguments will allow you to apply the operation. Cannot find a definition or applicable library operation named ** with argument type(s) FlexibleArray Integer PositiveInteger Perhaps you should use "@" to indicate the required return type, or "$" to specify which version of the function you need.

axiom
f1 := taylor(1 - x**2,x = 0)
\begin{equation} \label{eq64}1 -{x \sp 2} \end{equation}
Type: UnivariateTaylorSeries?(Expression Integer,x,0)
axiom
asin f1
\begin{equation} \label{eq65}{\pi \over 2} -{{1 \over {\sqrt {2}}} \ {x \sp 2}} -{{1 \over {8 \ {\sqrt {2}}}} \ {x \sp 4}} -{{1 \over {{32} \ {\sqrt {2}}}} \ {x \sp 6}} -{{5 \over {{512} \ {\sqrt {2}}}} \ {x \sp 8}} -{{7 \over {{2048} \ {\sqrt {2}}}} \ {x \sp {10}}}+{O \left( {{x \sp {11}}} \right)} \end{equation}
Type: UnivariateTaylorSeries?(Expression Integer,x,0)
axiom
sin %
\begin{equation} \label{eq66}1 -{{1 \over 4} \ {x \sp 4}} -{{1 \over {16}} \ {x \sp 6}} -{{7 \over {768}} \ {x \sp 8}} -{{5 \over {3072}} \ {x \sp {10}}}+{O \left( {{x \sp {11}}} \right)} \end{equation}
Type: UnivariateTaylorSeries?(Expression Integer,x,0)

SandboxMSkuce?

axiom
1+1
\begin{equation} \label{eq67}2 \end{equation}
Type: PositiveInteger?

SandBoxCS224?

axiom
integrate((x-1)/log(x), x)
\begin{equation} \label{eq68}\int \sp{\displaystyle x} {{{ \%R -1} \over {\log \left( { \%R} \right)}} \ {d \%R}} \end{equation}
Type: Union(Expression Integer,...)
axiom
integrate(x*exp(x)*sin(x),x)
\begin{equation} \label{eq69}{{x \ {e \sp x} \ {\sin \left( {x} \right)}}+{{\left( -x+1 \right)} \ {\cos \left( {x} \right)} \ {e \sp x}}} \over 2 \end{equation}
Type: Union(Expression Integer,...)

Working With Lists --daneshpajouh, Sat, 16 Jun 2007 07:00:00 -0500 reply
axiom
[p for p in primes(2,1000)|(p rem 16)=1]
\begin{equation*} \label{eq70}\left[ {977}, \: {929}, \: {881}, \: {769}, \: {673}, \: {641}, \: {593}, \: {577}, \: {449}, \: {433}, \: {401}, \: {353}, \: {337}, \: {257}, \: {241}, \: {193}, \: {113}, \: {97}, \: {17} \right] \end{equation*}
Type: List Integer
axiom
[p**2+1 for p in primes(2,100)]
\begin{equation*} \label{eq71}\left[ 5, \: {9410}, \: {7922}, \: {6890}, \: {6242}, \: {5330}, \: {5042}, \: {4490}, \: {3722}, \: {3482}, \: {2810}, \: {2210}, \: {1850}, \: {1682}, \: {1370}, \: {962}, \: {842}, \: {530}, \: {362}, \: {290}, \: {170}, \: {122}, \: {50}, \: {26}, \: {10} \right] \end{equation*}
Type: List Integer

axiom
integrate (2x^2 + 2x, x) Cannot find a definition or applicable library operation named 2 with argument type(s) Variable x Perhaps you should use "@" to indicate the required return type, or "$" to specify which version of the function you need.

\end {axiom}

axiom
radix(36,37) >> Error detected within library code: index out of range

Is it error?

example from my daughter's college calc --pbwagner, Mon, 10 Sep 2007 13:00:06 -0500 reply
integrate(log(log(x)),x)

(better) example (with axiom markers this time) ;-) --pbwagner, Mon, 10 Sep 2007 13:01:48 -0500 reply
axiom
integrate(log(log(x)),x)
\begin{equation} \label{eq72}{x \ {\log \left( {{\log \left( {x} \right)}} \right)}} -{li \left( {x} \right)} \end{equation}
Type: Union(Expression Integer,...)

Some or all expressions may not have rendered properly, because REDUCE returned the following error:
Error: export PATH=/usr/local/bin:$PATH;reduce < /var/zope/var/LatexWiki/6521556664208153236-25px.run


Some or all expressions may not have rendered properly, because Latex returned the following error:
! LaTeX Error: Environment reduce undefined.

See the LaTeX manual or LaTeX Companion for explanation. Type H <return> for immediate help. ...

l.505 \begin{reduce}

?