|
|
|
last edited 15 years ago by Bill Page |
| 1 2 3 4 5 6 7 8 9 10 11 | ||
|
Editor: Bill Page
Time: 2008/06/12 10:32:31 GMT-7 |
||
| Note: mathaction proxy error work-a-round | ||
added:
\begin{axiom}
coefficient(cs, 0)
coefficient(cs, 1)
coefficient(cs, 2)
coefficient(cs, 3)
coefficient(cs, 4)
coefficient(cs, 5)
\end{axiom}
The output of the next command apparently causes a "Proxy Error" on the mathaction server. This can be avoided by changing the output from LaTeX to ASCII mode:
\begin{axiom}
)set output tex off
)set output algebra on
coeffs4: ACList P := [coefficient(cs, i) for i in 0..5]
)set output tex on
)set output algebra off
\end{axiom}
Let's do some more advanced stuff. See
the "functorial composition testpage":http://www.risc.uni-linz.ac.at/people/hemmecke/AldorCombinat/combinatsu78.html#x117-16400029.2
for more details.
\begin{axiom}
e: S := cycleIndexSeries() $ SetSpecies(Z);
e2: S := term(coefficient(e, 2), 2);
h: S := functorialCompose(e * e, e2 * e);
coefficient(h, 0)
coefficient(h, 1)
coefficient(h, 2)
coefficient(h, 3)
coefficient(h, 4)
coefficient(h, 5)
\end{axiom}
Test species in axiom/FriCAS?.
The species project is written in Aldor. Thus we need to load the libraries explicitly:
Want loading of libraries with no output.
(1) -> )cd ~/combinat/src
The current FriCAS default directory is /var/aw/var/LatexWiki
)re ../lib/combinat.input
The file ../lib/combinat.input is needed but does not exist.
Let's define a binary tree.
#includeDir "/var/lib/zope/combinat/include" #libraryDir "/var/lib/zope/combinat/lib" #include "combinat"
macro { E == EmptySetSpecies; X == SingletonSpecies; + == Plus; * == Times; }
A(L: LabelType): CombinatorialSpecies L == (E + X*A*A)(L) add;
Compiling FriCAS source code from file
/var/lib/zope2.10/instance/axiom-wiki/var/LatexWiki/5200085684951427974-25px002.as
using Aldor compiler and options
-O -Fasy -Fao -Flsp -lfricas -Mno-ALDOR_W_WillObsolete -DFriCAS -Y $FRICAS/algebra -I $FRICAS/algebra
Use the system command )set compiler args to change these
options.
"/var/lib/zope2.10/instance/axiom-wiki/var/LatexWiki/5200085684951427974-25px002.as", line 3:
#include "combinat"
^
[L3 C1] #1 (Error) Could not open file `combinat'.
The )library system command was not called after compilation.X := A(ACInteger)
There are no library operations named A Use HyperDoc Browse or issue )what op A to learn if there is any operation containing " A " in its name.
Cannot find a definition or applicable library operation named A with argument type(s) Variable(ACInteger)
Perhaps you should use "@" to indicate the required return type,or "$" to specify which version of the function you need.
Ooops, it seems that elements of P cannot be printed in Axiom. :-(
So let's find the problem. P is the polynomial domain in infinitely many variables with rational coefficients.
p: P := 1$P
P is not a valid type.
Hmm, prints fine...
coefficient(cs,0)
There are 4 exposed and 6 unexposed library operations named coefficient having 2 argument(s) but none was determined to be applicable. Use HyperDoc Browse,or issue )display op coefficient 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 coefficient with argument type(s) Variable(cs) NonNegativeInteger
Perhaps you should use "@" to indicate the required return type,or "$" to specify which version of the function you need.
The output of the next command apparently causes a "Proxy Error" on the mathaction server. This can be avoided by changing the output from LaTeX? to ASCII mode:
)set output tex off
)set output algebra on
coeffs4: ACList P := [coefficient(cs,i) for i in 0..5]
There are no library operations named ACList Use HyperDoc Browse or issue )what op ACList to learn if there is any operation containing " ACList " in its name.
Cannot find a definition or applicable library operation named ACList with argument type(s) Variable(P)
Perhaps you should use "@" to indicate the required return type,or "$" to specify which version of the function you need.
Let's do some more advanced stuff. See the functorial composition testpage for more details.
e: S := cycleIndexSeries() $ SetSpecies(Z);
S is not a valid type.