43
Appendix 1 MuPAD Libraries and Procedures In this appendix I have included all the libraries available in MuPAD, and almost all the procedures that are available in the most current version of MuPAD at the time of writing. I have tried to make this list as complete as it was possible. However, I could have missed a few things. There are many procedures that are either undocumented or considered to be internal. However, the border between internal procedures and those that are designated to be used by MuPAD users can be a bit dim. So, some of the procedures described here might also be internal and some other can become internal in the future. In fact, from the user's point of view there is little difference between internal and official procedures. You can use them, as long as you know their syntax and where to find them. For many procedures, I have provided a short syntax and description that may help the readers to identify the role of the procedure or find a procedure for a specific goal. You need to keep in mind that most of these procedures can be used in a wide variety of ways with a number of parameters. It is therefore not possible to describe in a small chapter all the forms of syntax and parameters that can be applied to them. My intention while developing this appendix was to provide you with the most basic information about what you can find in MuP AD's libraries and in the whole MuPAD system. There is huge number of procedures that I have grouped under the title "MuP AD Standard Collection". In fact, these procedures are not always included in any particular library; they are placed in various parts of the MuPAD system. However, you can access them directly without using the slot operator regardless of where they really are. Thus, if you can use a procedure like this, f1oat(1+exp(J)) but not like this, comb; nat: : bell (I5), then I will consider this procedure as a part of the so-called standard collection. Many of the procedures listed here were not even mentioned in my book. You can find information about them through MuPAD's help. My intention was to use this appendix instead of an index. Thus,

Appendix 1 MuPAD Libraries and Procedures

  • Upload
    others

  • View
    7

  • Download
    1

Embed Size (px)

Citation preview

Page 1: Appendix 1 MuPAD Libraries and Procedures

Appendix 1

MuPAD Libraries and Procedures

In this appendix I have included all the libraries available in MuPAD, and almost all the procedures that are available in the most current version of MuP AD at the time of writing. I have tried to make this list as complete as it was possible. However, I could have missed a few things. There are many procedures that are either undocumented or considered to be internal. However, the border between internal procedures and those that are designated to be used by MuPAD users can be a bit dim. So, some of the procedures described here might also be internal and some other can become internal in the future. In fact, from the user's point of view there is little difference between internal and official procedures. You can use them, as long as you know their syntax and where to find them.

For many procedures, I have provided a short syntax and description that may help the readers to identify the role of the procedure or find a procedure for a specific goal. You need to keep in mind that most of these procedures can be used in a wide variety of ways with a number of parameters. It is therefore not possible to describe in a small chapter all the forms of syntax and parameters that can be applied to them. My intention while developing this appendix was to provide you with the most basic information about what you can find in MuP AD's libraries and in the whole MuPAD system.

There is huge number of procedures that I have grouped under the title "MuP AD Standard Collection". In fact, these procedures are not always included in any particular library; they are placed in various parts of the MuPAD system. However, you can access them directly without using the slot operator regardless of where they really are. Thus, if you can use a procedure like this, f1oat(1+exp(J)) but not like this, comb; nat: : bell (I5), then I will consider this procedure as a part of the so-called standard collection.

Many of the procedures listed here were not even mentioned in my book. You can find information about them through MuP AD's help. My intention was to use this appendix instead of an index. Thus,

Page 2: Appendix 1 MuPAD Libraries and Procedures

14 MuPAO Pro Computing Essentials

MuP AD objects that I have described in this book shall have a page number attached, where you can find more information about them.

The order of libraries and procedures is alphabetic.

A 1.1 MuPAD Libraries (ver. 2.5, 18/01/2002)

adt - basic collection of abstract data types

Ax - basic axiom call tmctors

Cat - basic calegOlY constructors

(:ombinat -func/iolls for combinatories

detools - tools for differential equations

Dom - domain call truc/ors

fp - utilities forJunetional programming

generate - utilities to generate foreign Jormats Jrom expressions

groebner - calculatioll of Groebner-bases/or polYllomial ideals

import - utilitiesfor reading data in different formats

intlib - utilities for symbolic integration

linalg - the linear algebra package

linopt - package Jar linear optimizatioll

listlib - utilitiesJor list operations

matchlib -toolsJorpallem matching

odule - IItilities Jar modllle management

Network - package for handling directed graphs

numeric -fllnctionsJorllumerical mathematics

umlib - the package for elemen/my number theOlY

orthpoly - tools for orthogonal polynomials

output - utilities lor the output of data

plot - graphical primitives andfimclion for two- and three-dimensional plot·

polylib - utilities for polY/lomials

prog - programming utilities

property - properties ofidentifier.

RGB - color definitions

Series - tools and data structures for working with eries

solvelib - methods for solving equations. :.)'stem a/equations and ineqllalities

specfunc - element{//J' and special functions

Page 3: Appendix 1 MuPAD Libraries and Procedures

Appendix 1: MuPAD Libraries and Procedures

stats - stalisticalfimctions

tringlib - utilities for workillg with strillgs

tudent - the student package

transform - librUlJI for illtegral transformatiollS

A 1.2 Operators Represented by Symbols : = -as ign a value to a variable (p. 26)

+, -, /, *,11_ aritmetica{ operatioll (p. 9, 266)

I -factorial operation (p. 9)

, - derivative of a filllction (p. 432)

, <, <=, >=, > - equality and illequality relation (p. 266)

-> - declaratioll of a filllction (p. 28)

415

~> , <=> Booleall operators representillg implicatioll and equivalence (p. 31 J)

. - dot operator to COllcatenate two fist or strillg (p. 96)

.. - the range operator, 2 .. 5

... - range operator, Pl...5.1, returns afloatillg point interval illculdillg it · end', camp. {1II1f

@ - composition offimclions

@@ - iterate Clfunction givenllllfnber of times

S - create a sequence (p. 93)

?word - display he{pfor the given word (p. 19, 110)

:: - the 1010 erator, acces to object /ot

A1.3 MuPAD Standard Collection

This section lists only procedures that can be applied to objects different than numbers. All arithmetic functions are listed in section Al.32.1.

implies - illtemal repre entation of implication

alias{x=object) - deJines x CIS all alias of the givell object

anames{All) - returns identifier that have values or properties ill currellt session of MuPAD (p. 28)

and, or, not, xor - Booleall operators (p. 311)

args x - fill/clion accessill rocedure arometer . 102)

Page 4: Appendix 1 MuPAD Libraries and Procedures

416 MuPAD Pro Com uting Essentials

array{kl .. nl. k2 .. n2, ... ) - creates an array

assert{cond) - declares the condition to be true at the moment when statement is evaluated

assign{List) - as igns values given in the form of list of equation(s)

assignElements{L, i=v, .. ) - assigns values to entries ofa list. array

assume{x. property) - assign a mathematical property to a MuPAD object (p.34)

asymptlf, x) - computes asymptotic series expansion

bool{expr) - produces Boolean vallie of the given e..rpression (p. 317)

break - procedure terminating execution of a loop or case structure (p. 57)

byte!iO - returns the cun'ent memory use

cardtpet) - produces cardinality of a given set

coeff(p) - returns sequence of non-zero coefficients of a polynomial

coerce{object, U) - tries to convert object into an object of a domain U

collect(p. x) - collects coefficients of a given polynomial

combfne{expr) - combines terms of a given expression into a single power (p. 299)

complexlnffnity - constant representing infinity in complex numbers

conjugate{z) - produces conjugate ofa complex number (p. 273)

contafns{A. object) - checks if a given element A is contained inside of a container object

content(p) - computes the content of the polynomial. i.e. gcd of its coefficients

context{object) - evaluates object in the given context of the calling procedure

contfrac{x) - produces continued fraction of a given number

copyClosure - copies the lexical closure of a procedure

O(/) - differential operator. equivalent to f' debugO, debug{statement) - starts MuPAD debugger for a given statement

degree(p. x) - returns degree of the polynomial p with respect to x (p. 285)

degreevec(p) - returns a list of exponents of the leading term ofa polynomial

delete{xi, x2 ... ) - deletes values of the given identifiers (p. 37)

denom{expr) - produces denominator of a given rational expression

dffflf, x) - produces derivative ofafunction in respect to a given variable (p.432)

dfscontlf, x) - produces all discontinuities of afunctionj{x)

dfv - produces results of integer division (p. 254)

domtype{object) - returns domain type of the given object (p. 88)

error{"message") - breaks nmningprocedure and produces error message

Page 5: Appendix 1 MuPAD Libraries and Procedures

~ndfx 1: MuPAD libraries and Procedures 417

eval(object) • evaluates the given object

evalassign(x, value, depth) . el'Oluates x with the given depths and assigns value to the result

evalp{p, x=xO) • evaluates po(vnomial p for x=xO (p. 285)

expand(erprenion) - erpands an arithmetical expression (p. 284)

export(library, procedures) • erports procedures from a given library (p. l OS)

expose (procedure) - displays the source code of a given procedure or domain

expr(object) • com"erts object into an element of a basic domain

expr2text(object) • converts object into a string of characters

extemal(, . ) -returns the function environment

extnops(object) • returns the number of operands of the given object in intemal representation

extop(object) • returns 0/1 operands of a domain element

extsubop(d, i=nC"K"e/) • produces a copy of the domo.in element with replaced j-th operand

factor{p) -factors polynomial into i"educible polynomials (p. 254, 284)

Factored(/) - domain of objects infactored form (po 354)

fclose(n). closes thefile with descriptor n

ffnput(filename) -reads MuPAD objects from the given binary or ASCII file

fname(n) - returns the name of the file with specified descriptor

fopen(fiJename) • opens the file with the gi\"en name

fprlnt(filename, objects). writes MuPAD objects into aft/e

fract(x) -fractional part of the number x

frandom() -floating point number random function

fread(tllename) - reads and erecutes the specified MuPAD file

freeze(/) • creates an inactive copy of the functionf (p. 354)

ftextlnput(filename, x) • procedure reads /ine from a text file and assigns it to the identifier x

funcenv(/). procl!dure crates afunction environment

gcd{p,q, .. ) - produces the greatest common divisor ofpolynomiau (p. 285)

gcdex(p, q, xl • the erlended Eue/idean algorithm for polynomials

genldent() - create a new identifier thaI was not wed be/ore in current session

genpoty(n, b, x ) - creates apo/ynomial p with variable x such thotp(b) =- n

~etpldO - returns ID of the running MuPAD process In UNIX operating system

getprop(~ r). returns mathe . I ro 01 /yerz,exprusfo 6 9

Page 6: Appendix 1 MuPAD Libraries and Procedures

~18 MuPAD Pro Com~uttnl Essential,

ground(p) - returns the constanl coefficient of p(O,O, .. O}

haS(objectJ. objectl ) - procedure checks syntax of objects to determine if object I is part of the object2

f'Stype(ohject, type ) - checks If a gi\'en object has Q specified type

helprworo) -procedure to display help about a given word (p. /9)

history(n), hlstory() - retunu the index ofn-th entry (or last one) in the history table

old(object) - prevenu evaluation of the given object (p. J54)

huU(object) - produces a floating point inten'fll enclosing object

fcontentfp) - computes the conlent of the polynomial wi,h integer or rational coefficients

td(x) -I!\'fliuates x Qnd returns result of eWl/ualion

Ifactor(n) - produces prime factorization ofn (p. 154)

IIICd(n!. n2 •.. . nk) - produces the greatest common divisor a/integers (p. 254)

Igcdex(x. y) - produces the ged of integers using Euclidean algorithm (p.254)

lIcm(nl. n2, ... nk) - produces the least common mullip/e of integers (p. 254)

Im(z) -imaginary part ofa complex number (p. 273)

In - checks ifan object is a an element ofa given set. syntax: x in set

tndets(expr) - produces indeterminates of the given expre.Jsion

Indexval(x, i) - accesses to entries of arrays and tables without evaluation

Infinity - the constant representing infinity

InfoO. Info(name) - display short information about gil'en object (p. 19. 110)

input( .• ) -interactil'e input data to a MuPAD program

Int(f). Intlf, r=a .. b) - produces definite/indefinite integral of a funclion (p. 35 I )

Intltext(n) - conl'erts integer n inlo a string of characters

Interpolate(xList. yLi.ftl - computes an interpolating polynomial

quo(m. n) - results ofinlegerdMsion m by n

lrem(m. n)- reminder of integer division m by n

irreducibteCp) - tests if the gil'f!n polynomial is irreducible

is(x. property) - checles if the object has the given mathematical property (p. 89)

sprtme(n) - checles if the given number is aprime number (p. 254)

lsqrt(n) - produces integer approximation of the square root of integer n

szero(object) - checking if the g iven object is zero element in its domain

Ithprtme(i) - roduces the i-Ih prime numbet:.iJ!.,," 2,,5,,4<--_

Page 7: Appendix 1 MuPAD Libraries and Procedures

~pendlx 1: MuPAD Libraries and Procedures

last(n) - accesing the previously computed object. equivalent to %n

lasterrorO - reproduces the last error in the current session

Icm(p. q) - produces Ihe least common multiple of polynomials (p. 285)

Icoeff(P) - returns the leading coefficients of the polynomial

~19

tdegree(p.x) • lowest degree of the terms of the polynomial p in respect to l'Qriable

ength(object) . returns an integer number representing the complexity of an object

level(object. n) . e~'Qluates object until/lewd of subslitution n

Ihs(equality) - returns left side of Q given equality

Itmlt(f, .\-'xO) • computes the limit ofa gil'en expression (p. 333)

Itnsolve([equations],[variables]) - solves a system of linear equal ions (p. 378)

IIItnt(A) . procedure using LLL algorithm 10 the columns of a matrix

trnonomlalCp) • returns Ihe leading term of a polynomial

loadllb(/ibrary)· loads library paclcage

loadmocWname-) -loads specified dynamic module

loadproc(object, path. file) • loads MuPAD objectfrom a specifiedfile

lterm(p) • returns the leading term of a given polynomial

map(object,/) - applies afunction to 01/ operands of a given object (p. J91)

mapcoeffs(p.f, a/,a2 ... ) - procedure applies function Jto the polynomial p replacin coefficients by j{c,al,a2, .. )

aprat(object, /) - applies afunction to the rationalized object

matrix(m. n. [elements]) - procedure produces matrix with specified dimensions and elements (p. 97, J8/)

ax(xl. x2 ... ) - produces maximum of given numbers (p. 254)

mtn(x/. x2 ... ) . produces minimum of given numbers (p. 254)

mod - modulofunclion. x mod m (p. 254)

modp(x. m) • division ofx modulo m (p. 254)

mods(x, m) -least absolute value r such that x-r is divisible by m

multcoeffs(p. c) -mUltiplies all coefficients of the polynomial p by c

newer, object I, object2, .. ) - creates a new elements of the domain T with a given internal representation

newOomaln(k) . creates a new domain with the key k

extprime(n) - produces Ihe smallest prime p such thaI n<=p

tL • the nil object

l)OPS(object) • number of operands o[the given objef11p. J2v.,

Page 8: Appendix 1 MuPAD Libraries and Procedures

uPAD Pro Com~utll1l Essentials

norm(M) - norm of the matrix M

normal(x) - returns the normal form of the rational expression

nterms(p) - number a/terms 0/ a polynomial

nthcoeff(P) - returns the n-th non zero coefficient 0/ a polynomial

nthmonomialfp, n) - return' the n-th non-trivial monomial a/the polynomial

nthterm(p, n) - returns the n-,h non-zero term 0/ the polynomial

ull() - returns empty sequence 0/ MuPAD expressions

numer(expression) - returns numerator 0/ a given rational expression

o -domain 0/ Landau symbols

o -the number zero

ode(equ, y(x» - declares equ as a differential equation

op(object) - operands a/the given object

operator(s),mb,! type, priority) - declare a new operator defined by the given

l JunctionJ

ackage(directory) - loads a new library package

adelf, x) - computes a Pade approximation o/the given expression f

partfrac(expr, x) - produces partial/ractions of given ralional expression

patchlevelO - returns the number of patch of the current MuPAD library

pathname(directory) - produces path name valid in the curren, o.s.

pdfvide(p, q) - pseudo..JMsion of univariate poynomials p and q

iecewise([ cond, j). [cond I, j7] ••• ) -returns the piecewise function

plot(obJects) - procedure to plot graphical objects (p. /25, /13)

ploUd(object) - generates 2D plot of a graphical object on the plane (p. 125)

lotld(object) - generates lD plot 0/ a graphical object (p. 125)

lotfunc2dlf, x=a .. b) - plots a graph offunction of one Wlriable (p. 125)

plotfunc3dlf, x=a .. b. y=c .. d) - plots a graph off unction a/two variables (p. 125)

Iy(p, [x}) - declares polynomial p (p. 286)

point(x. y) - creates a 2D point (note - this is different than point In plot library)

Int(x. y, z) - creates 3D point (note - this is different than point in plot library)

poly2I1st(P) - convet1s polynomial p into a list of coefficients and exponents (p. 287)

polyg:on(pl. p2, .. pn) - defines polygon with gil'en l'ertices (different than plot::Po/ygonj

rwermod(p, a, m) - produces a modular power ofa polynomial p"modm

pnnt(gpj t - r·n S object on the screen (Ph66) _

Page 9: Appendix 1 MuPAD Libraries and Procedures

~pendlx 1: MuPAD Libraries and Procedures

product(l{i), i=a .. b) - produces definile and indefinite products (p. 360)

protect(identijier) - protects the g iven identijier (p. 27)

protocol(filename) -creates protocol of MuPAD session

quitO· terminates current session of MuPAD

adslmp(expr) . simplify radicals in all arithmetical expression

andomo. random(II/ .. n2) . random number generator (p. 254)

ratlonatlze(object) - transforms an expression illlo a rational expression

Re(:;;) -real part ofa complex number (p. 273)

read(fllename ) - reads, searches and executes a file (p. 113)

rec(equalion, y(n) - represents a reccurence equation for the sequence yen)

rectform(z) -produces rectangular form of a complex expression (p. 273)

esetO - reinitia/izes the current MuPAD session (p. 37)

eturn(X) • terminates execution of the procedure alld returns object X (p. 71)

evert(list) . reverses the order of elements in a gJven list, string or series

rewrite(expr, newfon) - transforms expression Jnto an equivalent form using specijied components (p. 297)

s(equa/ity) • right side of an equality

ootOf(p, x , - roots ofa polynomial

ImeO· returns the total real time of the current session, or executing a command(s)

save(X) • saves the slate of the identijier X

select(object, j) . selects operand of a given object

serieslf, xl - produces a series expansion of a gil'en expression (p. 362)

setuserinfolf, n' . sets the information lel'eJ

lmpllfy(expr' - simplifies a given expression (p. 78, 291)

lot(d, "name") - returns the value of the named slot of the object d

421

slot(d. "name", vI - creates the value of the named slot of the object d

solve([eqllations], [var]). solves an equation or system of equations (p. 10, 299)

sort (list' - sorts a given /ist

parsematrtx(m, n, [,,]) • creates a sparse matrix

spllt(object. j) - splits object into a lisl of three objects

strmatch(text, paltern) • checlcs if the given patterns occurs in the s tring

subslf, prel'=m:'w, · substitutes a new value intof(p. 30, 391)

5ubsextt: 1;(' - • extended substitution

Page 10: Appendix 1 MuPAD Libraries and Procedures

~22 MuPAD Pro Computtnl'-"' ........... '""~

subsop(object. i-new) - substitutes the ;-th operand

substring(s,r, ;) - retums a substring of a given string

sum((. n) - produces definite or indefinite sum (p . .360)

systemrcommand") - executes Q command a/lhe operating system

tablet), table(ind=ob} .... ) - creales a new empry table or foble with specified elements

taylorV; x-xO) - produces Taylor series of a/unclion around Q given point (p. 363)

tbI2text(strings) - concatenates strings in Q table

tcoeff(p) - produces the trailing coefficient a/lhe polynomial

testtype(ohjecl. n -checks if the given object has a syntactical type T

text2expr(text) - converts Q gil'en string into a MuPAD object

text2int(texl) - com'erts string of characters inlo integer number

text2list(texl, separators) - splits text into a list of substrings

text2tbl(text, separators ) - splits lext into a table of substrings

textlnput(x) - procedure aI/owing interactive input of text

tlmeO - returns the total execution time of the cun-ent session

traperror(object) - lraps errors produced while e\'QluQting gi\>en object

TRUE, FALSE, UNKNOWN - Boolean constants (p. 3//)

type(object )· returns Ihe type of the given object (p. 89)

unallas(x) - deletes the alias x

unassume(x) · remOl-oes properties of a given variable (p. 37)

undefined · constant representing an undefined object

unexport(library) • undoes export of a library

unfreeze(objec/) . creates an active copy of the object withfrozenfimction (see freeze)

universe - constant representing the uni\>erse set

nloadrmoduleM

) . unload the dynamic module

unprotect(x). removes protection of x (p. 28)

~al(object) - rep/aces every identifier in the ghoen object by irs l-'o/ue

ersIOn() • returns the \>erslon number of the MuPAD library

wamlng("messageM

) _ prints the specified warning message

wrlte(l1le, values) - writes given values to the specified file (p. 112)

,xor - xor boolean operator

Z'lp(/J, 12 . .. ) - combine lists or matrices (p. 39/)

Page 11: Appendix 1 MuPAD Libraries and Procedures

A endix 1: MuPAD Libraries and Procedures

A 1.4 Library' adt' - Abstract Data Types

adt::Queue(qllelle elements) - abstract data type queue

adt: :Stack(stllck element) - ab~tract data type stack

adt: :Tree(tree) - abstract data type tree

A 1.5 Library 'Ax' - Basic Axiom Constructors

Ax: :canonicalOrder - the axiom oj callonically ordered et

Ax: :canonicalRep - the axiom oj callonically representation

Ax: :canonicalUnitNormal - the axiom oj canonicalZv unit normals

Ax::closedUnitNormals -the axiom oJclosed IInit normals

Ax: :efficientOperation - the axiom of efficient operations

Ax: :indetElements - the axiom saying that indeferminetes may be elements

Ax: :noZeroDivisors - fhe axiom oJril/g -with no zero divi ors

Ax::normalRep -the axiom oJnormal represelltation

Ax::systemRep -the axiom oJJacade domaills

A 1.6 Library 'Cat' - Category Constructors

Cat: :AbelianGroup - the categOlY oj abelial/ groups

Cat: : AbelianMonoid - the categOlY oj abelian mOlloid.~

Cat::AbelianSemiGroup - the category oJabelian semi-groups

Cat: :Algebra - tile category oj associative algebras

Cat:: BaseCategory - the base category

Cat: :CancellationAbelianMonoid - the category of abelian mOl/aiel- with callcellation

Cat::CommutativeRing - the categOlY of commutative rings

Cat:: DifferentialFunction - the cathegory of differential funetioll .

Cat:: DifferentialRing - the categolY of ordil/ary differential ring

Cat:: DifferentialVariable - the cathegOlY of d~fferenlial variables

Cat:: EntireRing - the category oj entire rings

Cat::EuclideanDomain - the category oJeuclidean domaillS

Cat: : FactorialDomain - the categOlY offactorial domains

Cat::Field -the categOlY offield

Cat::FiniteCollection - the category offinite collection

423

Page 12: Appendix 1 MuPAD Libraries and Procedures

424 MuPAD Pro Computing Essentials

Cat::GcdDomain - the category oJintegral domains with gcd

Cat: :Group - the category oj group

Cat:: HomogeneousFiniteCollection - the category oj homogelleous finite collection

Cat:: HomogeneousFiniteProduct - the categOlY oj homogeneous finite products

Cat:: IntegralDomain - the category oj integral domain '

Cat:: LeftModule - tire category oj left R -module

Cat: :Matrix - the category oj matrices

Cat: :Module - the categOlY oj R-modules

Cat: :Monoid - the categOlY of monoids

Cat: :OrderedSet - the category oj ordered ets

Cat:: PartialDifferentialRing - the category oJpartial dijJeren/ial rillgs

Cat:: Polynomial - the category oj multivariate pO~Vllomials

Cat: :PrincipalldealDomain -the categOlY oJprincipal ideal domains

Cat: :QuotientField - the category oj quotielltfields

Cat: :RightModule - the category oJright R-modllles

Cat: :Ring - the category oJrillgs

Cat:: Rng - the category oj rings without Ullit

Cat: :SemiGroup - the categolY oj em i-groups

Cat: : Set - the category oj sets oj complex IIlImbers

Cat: :SkewField - the categOlY oj skew fields

Cat: :SquareMatrix - the categOlY o/square matrice

Cat:: UnivariatePolynomial - the category o.{univariate polynomials

Cat: :VectorSpace - the categolY o/vector spaces

A 1. 7 Library' combinat' - Combinatorial Functions

combinat: :bell(n) - computes the n-th Bell IlIll1/ber

combinat: :cartesian( elf, .. setN) - produce Cartesiall product of sets (p. 327)

combinat: :catalan(n) - produces Catalan /lumbers

combinat: :choose(set, k) - compute all k- ubsef 0/ a givell set

combinat: :composition(II, k) - computes k-compositioll 0/ all integer n

combinat::compositions(n) - computes all compositions of an integer

combinat::dyckWords(lI) - words of zeros alld ones

combinat: :generators - source oj infinite streams of objects

Page 13: Appendix 1 MuPAD Libraries and Procedures

Appendix 1: MuPAD Libraries and Procedures 425

combinat::integerVectors(n, m) - inleger vectors of length m buildfrom elements O, .. n

combinat::integerVectorsWeighted(n, Ii t) - weighted integer vectors

combinat::modStirling(q, n. k) - computes modified Stirling numbers

combinat:: partitions(n) - computes number of partition of a given integer

combinat:: permutations(list) - produces all permutations of a list

combinat: : permute (list) - produces all permutations of a Ii t (command obsolete)

combinat:: powerset(set) - produces powerset of a given set or a list. command obsolete (p. 329)

combinat: :stirling1 (n, k) - comp"tes Stirling numbers ofthejirst kind

combinat: :stirling2{n, k) - computes Stirling numbers of the second kind

combinat: :subsets(set) - produces all subsets of a given set (p. 329)

combinat: :subwords(list) - produces all sub words oj a given set or list (p. 329)

combinat: :tableaux(set) - YOllllg tableaux operator

combinat: :warnDeprecated( TRUE or FALSE) - determines whether use syntax from version 2.0

combinat: :words(lI. kJ -lists ofk elements usill O, .. n integers

A 1. 8 Library , detools' - Methods for Differential Equations

detools: :arbFuns(q. alpha) - lIumber of arbitrary functiolls in the general solulion oj an involutive partial differential equation

detools: :autoreduce(sys, illdvar, depvar) - autoredllcation oj a ystem of differential eqllations

detools::cartan{n, m, q. beta) - Cartan character. oJa differential equation

detools: :charODESystem(ldJ, s) - characteristic system of partial differential eqllation

detools: :charSolve(ldJ, in it. pars) - solves partial differential equatioll with the method oj characteristics

detools: :characteristics(ldJ, $) - characteristics o.(partial differential equation

detools: :derList2Tree{derlist) - minimal tree with a given list of derivatives as leaves

detools: :detSys(deq, indvar, depvar) - determining ystem Jor Lie pOint symmetries

detools: :euler{L, t, z) - ElIler operator o/variational calcuills

detools:: hasHamiltonian{ vecifield. q, p) - check Jar /Iamiltonian vector field

Page 14: Appendix 1 MuPAD Libraries and Procedures

426 MuPAD Pro Computing Essentials

detools:: hasPotential( vec{field, x) - check Jor gradient vector/ield

detools: :hilbert(alpha. 1') - llilbert polynomial oj a differential equation

detools: :modode(psi, depvar, indvm', step, order) - modified equatioll

detools: :ncDetSys(difeq. indvar, depvar) - determining system Jor nOli-classical Lie symmetries

detools::pdesolve(pdifeq, indvar, depvar) - solver/or partial differential eqllation!'

detools::transform(difeq, indvar, depvar, mode) - change o/variablesJor differenlial equations

A 1. 9 Library 'Dom' - Domain Constructors

om: :AlgebraicExtension - domaill oj algebraic field extensions

Dom: :ArithmeticalExpression - domaill oj arilhmetical exlellsions

Dom: : BaseDomain - the base doma;1I (i COlltained ill all other domains)

Dom: :Complex - the field of complex: numbers (p. 89)

Dom: : DifferentialExpression - domain oj differential expressions

Dom:: DifferentialFunction - domain oj differential/unctions

Dom: :DifferentiaIPolynomial- domain oj differential polynomials

Dom: :DihedralGroup - domain oj dihedral group

Dom:: DistributedPolynomial - domain oj dystribllied polynomials

Dom::Expression - domain oJall MIIPAD objecls o/basic type

Dom::ExpressionField - domaill oJall expressions/ormillg afield

Dom:: Float - domaill oj all real.floatillg poil/illumber'

Dom:: Fraction - the field oj all Jractions with integer compollellf

Dom: :GaloisField - domain offinitefields

Dom: : Ideal - domain oj sets oj ideals

Dom: :lmageSet - domaill oJimages oJsets

Dom: : Integer - the ring 0/ integer nllll/hers

Dom: :lntegerMod - rings oj integers modulo

Dom:: Interval- domain oj all il/tervals oJrealmlll/bers

Dom:: LinearDifferentialFunction - domain of iiI/ear differential JUI/ctions

Dom:: LinearDifferentialOperator - domain o/Iillear differential operators

Dom:: LinearOrdinaryDifferentialOperator - dOll/ain oj linear differential opera/aI's

Dom: :Matrix - domain 0 all matrice

Page 15: Appendix 1 MuPAD Libraries and Procedures

Appendix 1: MuPAD Libraries and Procedures

Dom: :MatrixGroup - Abelian group o/mxn matrices

Dom: :MonoidAlgebra - domain of monoid algebra

Dom: :MonoidOperatorAlgebra - domain ofmonoid operator algebras

Dom: :MonomOrdering - domain o.fmonomial orderings

Dom: :Multiset - domain of mllilisets

427

Dom: :MultivariatePolynomial- domain of multivariate polYllomials (I'. 88. 286)

Dom: :MultivariateSeries - domain of mllitivariate serie

Dom:: Numerical - field of number'

Dom::PermutationGroup - domain o/permutatioll groups

Dom::Polynomial- domains ofpolYllomials (I'. 286)

Dom::Product - domaill of homogenous products (p. 88)

Dom: : Quaternion - domain of quaterniolls (I'. 88)

Dom::Rational- domaill ofratiollal nUlI/ber. (p.88)

Dom: : Real - the field of real numbers (p. 88)

Dom:: RestrictedDifferentialVariable

Dom: : SparseMatrix - domain a/sparse matrices over the compollellt ring R

Dom: :SparseMatrixF2 - the domain of sparse matrices oller thefield with two elements

Dom: :SquareMatrix - (he rings of square matrices

Dom::TensorAlgebra - domain often or algebras

Dom:: TensorProduct - domain of tensor products

Dom::UnivariatePolynomial- the domains of univariate polYllomials (p. 286)

Dom: :UnivariateSkewPolynomial- domaill ofllllil'Oria(e skew polynomials

Dom::VectorField - domaill of vector fields

A 1. 1 0 Library 'fp' - Utilities for Functional Programming

fp: : apply if, arg ) - apply fUllctioll 10 argumellts

fp: :bottomO - the/unction that never returns

fp: :curry(f) - retm'lI . the higher order fllllction x~ (y ..... j(x,y)

fp: :expr _unapply(expr. x) - create a functiollal expre sioll from all expressioll

fp: :fixargsif, II) - createfimction by fuing all bllt n-tll argument

fp: :fixedpt(f) - returns fixed point of afimction

fp:: fold if, e:pr) - create function which iterates over sequellce of argwnen ts

Page 16: Appendix 1 MuPAD Libraries and Procedures

428 MuPAD Pro Computing Essentials

fp::nest{f. II) - repeated compo ilion offimction

fp::nestvals{f. II) - repeated composition returning illtermediate values

fp::unapply(expr. x) - create aprocedurefrolll a given expres iOIl

A 1.11 Library 'generate' - Generate Foreign Formats

generate::C(expr) - generate Cformatted string

generate: : fortran (expr) - generate FORTRAN formatted string

generate::Macrofort - FORTRAN code generator

generate::optimize(expr) - generate optimized code

generate::TeX(expr) - generate TEXformaued stringfrom expressions

A 1.12 Library 'groebner' - Utilities for Groebner Bases

groebner: :dimension(poLynomials) - the dimension of the affine variety generated by polynomials

groebner: :gbasis(polynomial ) - computation of a reduced Grabner basis

~roebner:: normalf(p. polynomial) - complete redllction modulo a polynomial ideaL

groebner: :spoly(pJ. p2) - the S-polynomial of two polynomials

groebner: :stronglylndependentSets( G) - stronly independellt set variables of a Groebner basis

A 1.13 Library 'import' - Utilities for Reading Data

Import: :readdata(,Jile") - reads ASCll dataflles

import: : readlisp(slring) -parse Lisp-formatted string

A 1.14 Library 'intlib' - Definite and Indefinite Integration

Intlib: :bypartS(integral, du) - tramforms integral using by pari formula (p. 352)

intlib: :changevar(inlegral. e /I) - transforms integral by changing variable. (p.352)

A 1. 15 Library' linalg' - the Linear Algebra Package

linalg: :addCol(A, cl, c2. s) - produces copy of matrix A with c2-c2+s*cl (p. 396)

linalg: :addRow(A, ,.1, 1'2, s) -produce copy of //latrix A with 1'2=1'2+$*1'1 (p. 396)

Page 17: Appendix 1 MuPAD Libraries and Procedures

A endtx 1: MuPAD Libraries and Procedures

linalg::adjoint(A) - adjoint oJa matrix

linalg::angle(A, B) - calculates the angle between two vectors (p. 395)

linalg::basis(S) - basisJora vector space

linalg::charmat(A, x) - produces characteristic matrix (p. 395)

429

linalg: :charpoly(A, x) - produces characteristic polynomial oj the matrix A (p. 395)

linalg: :col(A, c) - extracts column c Jrom matrix A (p. 396)

linalg: :companion(p) - companion matrix oj a univariate polynomial p

linalg: :concatMatrix(A, B ... , C) -joins matrices horizontally (p. 395)

linalg::crossProduct(A, B) - produces cross product oJtwo 3D vectors (p. 395)

linalg::curl(v. x) - curloJa vector field

linalg::delCol(A. cJ, c2) - deletes in matrix A columns c1...c2 (p. 396)

linalg::delRow(A. rl. r2) - deletes in matrix A rows r1...r2 (p. 396)

linalg::det(A) - produces determinant oJthe matrix A (p. 387, 401)

linalg::divergence(v, x) - divergel/ce oJa vector field

llnalg::eigenvalues(A) - produces eigenvalues oJthe matrix A (p. 395)

linalg::eigenvectors(A) - produces eigenvectors oJthe matrix A (p. 395)

linalg::expr2Matrix(equations, [x,y.z]) - transJorms system o/lil/ear equatiol/s into a matrix (p. 393)

linalg: :factorCholesky(A) - the Cholesky decomposition oj a matrix

linalg: :factorLU(A) - LV-decomposition oj a matrix

linalg::factorQR(A) - QR-decomposition oj a matrix

linalg: :frobeniusForm(A) - Frobenius Jom, oj a matrix

linalg::gaussEllm(A) - per/orms Gaussian elimination oJa matrix (p. 395. 397)

linalg: :gaussJordan(A) - per/om,s Gauss-Jordan eliminatiol/ oj a matrix (p. 395)

linalg: :grad(f. x) - vector gradiel/t

llnalg::hermiteForm(A) - Hermite normalJorm o/a matrix

linalg:: hessenberg(A) - Hessenberg matrix

linalg::hessian(f.x) - Hessian matrix o/a scalar fimction

llnalg::hilbert(n) - produces nxn Hilbert matrix generated by theJunction h(i.j) = (i + j - 1)- 1, (p. 385)

linalg::intBasis(SI,S2 ... ) - basisJor the intersection oJvectorspaces

linalg:: inverseLU(A) - computing the iI/verse oj a matrix usil/g LVdecompositiol/

linalg::invhilbert(n) - produces inverse oJthe nxn Hilbert matrix generated by h(i,j) = (i + j - 1)- 1, (p.385)

Page 18: Appendix 1 MuPAD Libraries and Procedures

430 MuPAD Pro Com uttn, Essentials

linala: :isHermttean(A) • checks whether a matrix is Hermitean

Unalg::lsPosDef(A) • test a matrix/or positive definiteness

Unalg::lsUnltary(A) - test whether a malri:c is unitary

Iinalg::jacoblan(v, xl - Jacobian matrix ofa vector function

IInalg::JordanForm(A) -Jordan nOrllla//orm ofa matrix

Iinals: :laptac1an(f, [x I, xl ... ) - produces Loplacian ofthefunction

Unalg: :matdtm(A) - returns dimensions aJthe maw A. (p. 395)

Iinall: :matltnsolve(A) - solve system of equations in matrix form (po 393)

IInal8: :matltnsolveLU(A) - solve system of equations in malrix form

tlnalg: :minpoly(A, xl - minimal polynomial ofa matrix

IInalg::multCol(A. c, $) - multiples in matrix If column c by numher s (p. 396)

lInalg::multRow(A, T, $) - multiples in matrix If row r by numbers (p. 396)

lInalg: :ncols(A) - return.s number of columns in the IIfl1trix A (p. J95)

Ilnalg::nonZerOS(A) - relUrn.s numbero/non-zero elements in the matrix (p.J95)

IInalg: :normallze(A) - normalizes a vector A (p.J95)

IInalg::nrows(A) - returns numbero/rows in the mt1trix A (p.J95)

linalg::nullspace(A) - basil for the null space 0/ a matrix

Iinalg: :ogCoordTab [ogNamel (u I, u2, uJ) - table of orthogonal coordinate transformations

IInalg::orthog(S) - orthogonalization a/vectors in S IInalg::permanent(A) -permanent a/a matrix

Ilnalg::pseudolnverse(A) - Moore-Penrose inverse ofa matrix

IInalg::randomMatrlx(n, m, domain, bound, options) - creates a new matrix with random elements (p.J85)

Iinalg: :rank(A) - rank 0/ a matrix

IInalg: :rOW(A, r) - extracts row r from the matrix A (p.J96)

IInalg: :scalarProduct(A, B) - produces scalar product aftwo vectors (p.J96)

Ilnalg::setCol(A, c, c/ ) - replaces in A column c by new column vector el (p.J96)

IInalg: :setRow(A, r, r/) - replaces in A row r by new row vee/or rl (p.J96)

Unalg: :smlthForm(A) - Smilh canonical form of a matrix

Iinalg::stackMatrlx(A, B, .. , C) -joins matrices vertically (p.J95)

Unalg::submatnX(A, rl .. r2, cl .. e2) - produces subma/rlx defined b,v the given ranges (p.J96)

IInalg: :substitute B. m n - substitutes matrix B inside olmatrix If .J96

Page 19: Appendix 1 MuPAD Libraries and Procedures

Appendix 1: MuPAD Libraries and Procedures

linalg: :sumBasis(Sl, S2 ... ) - basis for the sLIm of vector spaces

linalg: :swapCol(A. cl, c2) - swaps colUIllt1S' cJ and c2 ill matrix A (p.396)

linalg: :swapRow(A, 1'1, 1'2) - 'Waps rolVs 1'1 Qlld 1'2 ill matrix A (p.396)

linalg: :sylvester(p, q) - Sylve tel' matrix of two polYllolllial p al/d q

linalg: :tr(A) - trace of a matrix

linalg: :transpose(A) -produces trallspositioll of A, i.e. A I (p.395)

linalg: :vandermondeSolve(",y) - solve a linear VandermOl/de system

linalg: :vecdim( V) - returns number of elements of a given vector (p.395)

431

linalg: :vectorPotential(j, [xl , x2, x3)) - "ector potelltial of a three-dim en iOllal vectorfield

linalg: :wiedemann(A, b) - solving linear ystem by Wiedemanll's algorithm

A 1.15.1 Related functions in MuPAD Standard Collection

conjugate(=) - produces conjugate of a complex number

exp(A) - the exponentialfunctioll

norm(A) - returns I/oI'm of a vector or a matrix

normal(expr) - returns the normal form of the rational expression

A 1.16 Library 'linopt' - Tools for Linear Opti mization

linopt: :corners([cOl/str, obi]) - returns the feasible corners of a lillear prograll/

linopt: :maximize([col/str, obi]) - maximaize a !illear or mixed-integer program

linopt: :minimize([coll tr, obi)) - minimize a iiI/ear or mixed-integer prograll/

linopt: :ploCdata([con tr, ob)) - plots the feasible regiol/ of a linear program

linopt: :Transparent([col/str, ollj)) - returns the oridil/ary simplex of a linear program

A 1.17 Library 'listlib' - Operations on Lists

listlib: :insert(list, element) - in ert an element into a list

listlib: :insertAt(/ist, elemellt, place) - insert all elemellt illto a list

listlib: :merge(li tl, list2) - merge two ordered lists

listlib::removeDupSorted(/ist) - removes duplicate elllriesji-oll/ an ordered list

listlib: :removeDuplicates(list) - removes duplicate el/tries

Page 20: Appendix 1 MuPAD Libraries and Procedures

432 MuPAD Pro Computing Essentials

listlib: :singleMerge(fis/l, Ii 12) - merge' fwo ordered lisls wilhollt duplicates

listlib: :sublist(li tl, list2) - searchJor lIblists

A 1.17.1 Related Functions in MuPAD Standard Collection

_concat(fist 1,Ii8t2) - kemelfllllction to COl/catenate two lists, sirillgs

append (list, object) - add an object at the elld oJlhe lis/

revert(lisf) - revel'/ an order oj elemellts in the givell list

A 1.18 Library 'matchlib' - Pattern Matching Tools

atchlib: : analyze (expr) - analyse fhe structure oj any expressioll.

A 1.18.1 Related Functions in MuPAD Standard Collection

match (expr,pattern) - march a pat/ern ill a given expression

A 1.19 Library 'module' - Module Management Tools

module("modname") - loads a given module

module: :ageO - module age ill computer memOlY

module: :displace(modname) - unloads module

module: :func(modname) - creates a module /tlnctioll envirOllment

module: :help(modname) - display information abollt specified module

module: : load (modf/mne) -loads module

module: :max(nr) - se/~l the max nUII/ber oj imultalleously loadable modules

module: :statO - statu' oJthe lIIodule manager

module: :which(modllame) - retul'lls illstallalioll path oj a dynamic module

A 1.20 Library 'Network' - Tools for Directed Graphs

Network: :addEdge(/lel, [edges]) - adds edges to a network

Network: :addVertex(net, expr) - adds vertices to (/ /let work

Network: :admissibleFlow(llet,j/ow) - check~ oj/ow Jor admissibility in a network

Network: : allShortPath (net) - prodllce shortest paths Jor all pairs oj nodes

Network: :changeEdge(net. [edges]) - change weight oJnetwork edges

Network::changeVertex(lIel, [/lode']) - challges weight oJnetwork vertices

Page 21: Appendix 1 MuPAD Libraries and Procedures

Appendix 1: MuPAD Libraries and Procedures

Network: :convertSSQ(net. q. s) - convert· lIetwork inlo a ingle source ink network

Network: : cycle ([expressiolls]) - generales a cyclic network

Network::deIEdge(net, [edges]) - delele edges from a network

Network: :deIVertex(lIel, [vertices]) - deletes vertices from a nelt~'ork

Network: : eCapacity(nef) - return the lable of capacities

Network: :eWeight(net) - returns the table of edge weights

Network: :edge(ne/) - returns a list of all edges

Network:: epost(lIel) - return direct ucces '01' of each vertex

Network: :epre(nel) - returns direct predcessors 0/ each vertex

433

Network: :inDegree(net. node) - returns the number of edges commillg inlo a given node

Network: :isEdge(net. edge) - checks if a given object is an edge of the network

Network: :isVertex(nel, vertex) - checks if a given object i a vertex: oflhe network

Network: :longPath(net. v) - finds the longe I path in a network tartingfrom a givell vertex

Network: :maxFlow(nel, v1. 1'2) - produces the maxflow through rhe lIetwork

Network:: minCost(net) - compules a millimal cosl Jlow

Network: :minCut(nel. vI. v2) - computes a millimal cut eparating node vI from v2

Network: :outDegree(net) - relurn the alit-degrees/or nodes

Network:: printGraph(lIet) - prints all informatioll about a network

Network:: random([Il,m]. d. [k.l]) - generates a ralldom network

Network:: residuaINetwork(net .. flow) - produces the re idua/lletwork

Network:: shortPath (llet. v) - produce the shortest paths from a givell node v

Network: :shortPathTo(net. v) - produce the shortest path to a givell node

Network::showGraph(net) - plots graph ofa lIetwork

Network::topSort(lIet) - compules a topological orting ofa network

Network::vWeight(net) - returns the lable of vertex weights

Network: : vertex (net) - relurns a list of a II vertices

A1.21 Library 'numeric' - Tools for Numerical Methods

numeric: :butcher(method) - returns Butcher paramelers of the RUI/ge-Kulla cheme method

numeric::complexRound(z) - rounds a cOllplex Ilumber (awards the real or

Page 22: Appendix 1 MuPAD Libraries and Procedures

M PA P Hal.

'maginary axu numertc::cublcSpllne([xO.yOJ, .. ) - relunrs the cubic spline function interpolating

sequence of points

urneric::cubicSpltne2d([xO.xl ... l,rvo,yl ... lz, -ntums the hi-cubic splinefunclio interpolating sequence of data

numertc::det(A) - produces determinant alllle matrix (p. 401)

umerlc: :etgenvalues(A) • produces numerical eigenvalues of a matrix

umertc::eiaenYeCtors(A) -produces numerical eigenvectors of a matrix

nurnerlc::expMatrtX(A) - rehtnu exponentlalllUllrlx exp(A)

urneric::factorCholesky(A) - retumr thefae/or L o/Ihe ChoJuky factorization of A

numeric::factorlU(A) - retunu LV factorization of a matrix

umerlc: :factorQ.R(A) • retflnu QR !acrorizaion of a matrix umerlc::fft(dalo) - relllms discrete Fourier tratuformation a/the given data

numeric: :fsolve(equation.r) - returns a numerical approximation of a solul;on a/the system of equaljolU

umeric: :gldata(n. digits' - returns IIw weights ami the abscl3sae of the Gaws-Legendre quadrahlre rule

numeric: :atdata(n) - ntl1lll3 the weights and the abscissae of the Gaws-Tschebyscheff quadrature rule

numer1c: :tndets(object) - returns a set 0/ indelermlnantes contained in a given object

umertc: :Int(l) - computes numerical approximation 0/ an definite integral (p. 35 I)

mertc: : Inverse(A) -produces the inverse of a motrtx

umertc: :Invfft (data) - returns the inverse discrete Fourier transfoT1lUJtion

numertc: :leastSquares(A. b) - compUles leasl-squares solution a/linear system

umertc: :lInsolve(equatiollJ) -solves system o/linear equations

numeric: :matllnsolve(A. 8) - solve ~stem o/I/near equations

umertc: :ncdata(n, -produces weights and abscissae a/the Newton-Cotes quadrature

umertc::odesolvelf, to .. II. YO) - numerical solution 0/ an oridinary differentiaJ equation

umertc: :odesolve2lf, 10. YO) - numerical solution of an oridinary differentiaJ equation

numeric: :odesolveGeometric({. to .. t I. YO) - numerical solution 0/ an oridillary differential equalion on a homogenous manifold

Page 23: Appendix 1 MuPAD Libraries and Procedures

Appendix 1: MuPAD Libraries and Procedures 435

numeric: :ode2vectorfield( ) -cOllverl a system oj oridillary differential eql/ations

10 vectorfleLd represelltation

numeric: :polyroots(p) - produces Illimerical roots of a I/I/ivariate pO~Vllolllial

numeric: :polysysroots(equatiolls. var) - numerical roots of a :.yslem oj polynomial equations

numeric: :quadrature(j{x), x=a .. b •.. ) - nl/merical illlegral (p. 351)

numeric:: rationalize(object) - approximate floatillg poillt I/umber by a ratiollaL

numeric:: realroot(j{x). x=a .. b) - nUlllericaL search Jor a reaL rool oj a real Junction

f numeric::realroots(j{x), x=a .. b) - isolate illlerval contail/illg real roots of the

filllction J (p. 306)

numeric: :singularvalues(A) - lIumerical singular values oj a matrix

numeric: :singularvectors(A) - numericaL singular decompositiol/ oj a matrix

numeric: :solve(eql/ation ) - nl/merical ollitiof! oj equations (p. 306)

numeric: :sort(list) - sorts the list

numeric::spectralradius(A. xO. n) - produce ' the eigenvalue oflhe matrix A that has the larges absolute value

numeric: :sum(f[i], i=a .. b) - compl/tes numerical approximalioll oj the slIm:E~ f{i

A 1.22 Library 'numlib' - Elementary Number Theory

numlib: :contfrac(x) - cretes a cOlltbmedjracfioll approximatioll for reallll/mber x

numlib: :decimal(x) - prodllce decimal expan ion of the ratiol/allll/mher x

numlib: :divisors(lI) - prodl/ces the oJpo itive divisors oJn

numlib: :ecm(lI) -Jactorises all integer using ellipilc cl/rve method

numlib: :fibonacci(II) - produce ' II-th Fillonacci lIumber

numlib: :fromAscii(/isl) - cOllver" a list oj ASCII code to string

numlib: :~adic(l/) - g-adic represel/tation ofa nOlll/egative inleger

numlib: :ichrem(a. m) - prodllces the lea 'lllonllegative illieger representing Chillese remainder theorem

numlib: :igcdmult(nl. 112 .... nk) - produces gcd oj givell illteger using extended Euclideal/ algorithm

numlib: :invphi(n) - produces the inver e oj the Eulerfilllction for a given il/teger II

numlib: :ispower(n) - checks ifll ha aform 11/* Jor some positive inleger ' In and k

numlib::isquadres(lI, m) - test is a given number is a quadratiC residl~e 1Il0duio m

Page 24: Appendix 1 MuPAD Libraries and Procedures

436 MuPAD Pro Computing Essentials

numlib: :issqr(n) - test ifn i a quare of WI inleger

numlib: :jacobi (n, m) - produces value oj the Jacobi symbol (n I m)

numlib:: Lambda(n) - returns the value 0/ the Mangofdts 'Junctioll

numlib::lambda(n) - produces the value oJCarmichaelfunctioll ofn

numlib: :legendre(lI, p) - produces the Legendre symbol (II I p)

numlib:: lincongruence(a,b,m) - produces lisl of all solutions of the linear congruence a·xs b (modm)

numlib:: mersenneO - produces the fist of all Mer el1lle primes

numlib::moebius(lI) - produce the value ofMoebillsjiJllctioll ofn

numlib: :mpqs(n) - aplies multi-polynomial quadratic sieve to inleger II

numlib: : mroots (p, m) - produces list of all integers x such Ihat p(x}=. 0 (modm)

numlib: :msqrts(lI, m) - produce list of all illtegers uch that 112 =. n (modm)

numlib:: numdivisors(n) - prodllces number oj positive divisors of II

numlib: :numprimedivisors(n) - produces /lilli/bel' ofprime divisors ofn

numlib: :Omega(n) - returns number of prime divisors and their mllilipilcily for a

give/l /lumber n

numlib: :omega(n) - retllrn number ofprime divisors ofll and their mllltiplicity

numlib: :order(/I, m) - returns order of the re idue class modulo m

numlib::phi(n) - produces the Eulerfunctioll ofll

numlib: :pollard(n, m) - trie ' 10 filld afactor ofn using Pollard's rho algorithm

numlib:: prevprime(lI) - produces the large t prime number p5 n

numlib:: primedivisors(lI) - prodllces fist of prime divisors oj an integer /I

numlib: :primroot(n) - produce the last po ilive roof modulo /I

numlib: :proveprime(n) - te ts ifn is a prime lIumber usi/lg elliptic curves

numlib: :sigma(n) - produces Ihe sum of all positive divisors 0/11

numlib::sqrt2cfrac(n) - produce continuedfraction expansion of quare rools

numlib: :sumdivisors(lI) - produces SlillI of all divisor. of all illleger n

numlib: :tau(n) - returns nllmbers of positive divisors ofll

numlib: : toAscii (sIring) - converts a given strillg to ASCll

A 1.23 Library 'orthpoly' - Orthogonal Polynomials

orthpoly: :chebyshev1 (n, x) - produces II-th degree hebyshev polynomial oJllle fir. t kind

orthpoly: :chebyshev2(1I, x) - produce n-th degree Chebyshev polynomial oflhe second killd

Page 25: Appendix 1 MuPAD Libraries and Procedures

Appendix 1: MuPAD Libraries and Procedures 437

orthpoly: :curtz(n, x) - produces n-Ih degree CllrtZ polynomial

orthpoly::gegenbauer(n, a, x) - produces n-111 degree GegellbauerpoiYllomial

orthpoly:: hermite(n, x) - produces ,,-111 degree Hermite polynomial

orthpoly: :jacobi(n, a, b, x) - produces II-th degree Jacobi polynomial

orthpoly: :laguerre(n, a, x) - prodllces n-Ill degree generalized Laguerre polYllomial

orthpoly: :legendre(n, x) - produces II-III degree Legelldre polynomial

A 1.24 Library 'output' - Tools for the Output of Data

output: :ordinal(n) - converts an inleger to the Engli "ordjllalllllmber

output::tableForm(object) - prill Is objeci in file tableJorlll

output: : tree (Iree) -Jormat internally repre ellied Irees to display in graphicsJorm

A 1.25 Library 'plot' - 20 and 3D Graphical Objects

plot:: bars(datalist) - gellerales graphical objecl repre 'enting dolo as bars (p.224)

plot: :contour([x(u, v),y(u, V),Z(LI, v»), lI= a .. b, v=c .. d) - generales graphical objeci representillg contour curves (p, 208)

plot: :copy(object) - make a copy oj an existing graphical object (p. 155)

plot: :cylindrical([r(ll, v),phi(ll, V),Z(II, v»), u=a .. b, v=c .. d) - generates graphical object repre enting a givenfilllclion in cylidrical coordinate' (p. 196)

plot: :Curve2d([x(t),y(t»), I=a .. b) - generates graphical object represellting 2D

cllrve (p. 173)

plot::Curve3d([x(t),y(t),z(t»), I- (/ .. b) - generales graphical objeci representillg 3D cllrve (p. 198)

plot: :density([x(lI, v),y(u, v),z(u, v)). LI=a .. b, v=c .. d) - generales graphical objecl representing dellsity plol (p. 211)

plot: : Ellipse2d(poillt, a, b) - gellerales graphical objecl representillg ellipse (p.235)

plot:: Function2d(j(x), x=a .. b) - gellerates grapllical object representingfilllclion 0

aile variable (p. 133, J 70)

plot: : Function3d(j(x,y), x=a .. b, -c .. d) - generates graphical object representillg filllClioll oJtwo variables (p. 184)

plot: :Group(objects) - groups elecled objects illto a single graphical objeci (p. 157

plot:: HOrbital(n, k, /) - visualize hydrogen electron orbital (k < n, I = -1,0,1)

plot::implicit(f(x,y) = 0, x=a .. b, y=c .. d) - gellerales graphical objeci representing implicit pial in 2D (p. 178, 181)

Page 26: Appendix 1 MuPAD Libraries and Procedures

38 MuPAD Pro Comput1nl Essentials

plot::inequallty{t{x,y) < g(x,y). X=lI .. b. y=c .. d) • generates graphical object representing ineqUl1lity re/alion (p. 2/5)

lot: :Une(p/, pl) • generales graphical object repre.fenting sq:ment joining two points (p. 228)

lot: :Lsys(angle. initrule. rules) - produces graphical representation of L-system (p.242)

plot: :modlfy(object, Oplion.s ) - generates a modifJied copy of graphical object (p.156)

ptot::ode({. [to.tl ... ], YO. (0]) - generales graphical object representing solution of Q differential equation

plot::piechart2d(datalist) - generates graphical object representing discrete data as piecharl (p. 224)

plot::piechart3d(dalalist) - generales graphical object representing discrete dala as 3D piechart (p. 224)

plot::Point«(a,b.c)) - produces graphical representation afpoint in 2D or 3D (p.225)

plot::Pointlist(pl, p2 ... pn) - produces graphical represention of list of points (p.227)

plot::polar(Vlj2]. phi~ .. b) - generates graphical object representing afunction in polar coordinates (p. J 76)

plot::Polygonfpl. p2, .. pn) - generates graphical object representing polygol! (p.211)

plot::Rectangle2dfp. a, b) - generales graphical object representing reelangle (p.235)

plot::Scene(objects) - generales graphical object representing collection of objects (p.l33)

lot::sphe rfcal([r(u, v), phi(u, v), theta(u , v) ], 1I"'fl .• b. v=;c .. d) - generates graphical object representingfimction in spherical coordinates (p./92)

plot: :Surlace3d([x(u, v),Y(II, v),::(u , 1')]. u:a .. b, v>=c .. d) - generates graphical objeci

representing parametric fimction (p. 190)

plot: :surlace([data]) - creates 3D slIrface plot of data represented in matrix!orm

plot: :Turtle() - generates graphical object re/Jre,senting lurtle path (p. 237)

plot::vectorfpl. p2) - generales graphical object representing I'eclor (p. 235)

plot: :vectorlfeld([ v/(x,)'), v2(x,),)], :r-a .. b, y=c .. l/) - generates graphical object represellling vector field (p. 2/3)

plot::xrotate(ltx). x=a .. b) - generates graphical object represeming surJace oj resolution (fJ. 217. 2 I?;,

Page 27: Appendix 1 MuPAD Libraries and Procedures

Appendix 1: MuPAD Libraries and Procedures 439

plot: :yrotate(f(x). x-Cl .. b) - generate graphical object represelllillg swface 0/ resolutiol/ (p. 217. 219)

A 1.25.1 Related Functions in MuPAD Standard Collection

plot(objects) - plots all the givell graphical objects

plot2d(objecls) - plots 2D graphical objects (ob olete)

plot3d(objects) - plot 3D graphical objects (obsolete)

plotfunc2d(fl.j2 •.. ) - quick plot 0/2D /ullcliolls

A 1.26 Library 'polylib' - Tools for Polynomials

polylib: :cyclotomic(n. x) - produces cye/otomic polyl/omials

polylib::decompose(p. x) - produces/ul/c/iol/al decomposition o/polYllomials

polylib: :discrim(p. x) - produces discriminal/I o/the pO~Vl/omiallVilh respect to variable x

polylib:: divisors(p) - produces divisors 0/ a polynomial

polylib: :Opoly(f) - differential operator/or polynomial

polylib: :elemSym([xl .... xn]. k) - produces k-th elementary )'II/metric polynomial

polylib:: makerat(expr) - cOllverls expression iflto a ratiollal fill/ction

polylib:: minpoly(a. fl. x) - produces Ihe minill/al polynomial

polylib: :Poly([xl ..... xn]. R) - domain o/po(Vl1omia/ over the ring R

polylib::primitiveElement((. g) - produces primitive elemenl

polylib:: primpart(p) - produces primitive parI o/Ihe given polYllomial

polylib: :randpolyO - produces random polYllomial

polylib::realroots(p. epsiloll) - produces intervals containing real rools o/p

polylib: :representByElemSym(p. [x1 •..• xlI]) - represents ymmetr;c polYllomial hy elemelltary symmelric po~vllolI/ials

polylib: :resultant(p. q) - prodllce the re IIllant 0/ p and q with respect 10 their first variable

polylib: :sortMonomials(p) - sarIs monomial with re peclto the order o.(term

polylib: :splitfield(p) - produces the splillingjield 0/ a polYflomial

polylib: :sqrfree(p) - produce quare-Fee factorizations of a polYllomial

A 1.26.1 Related Functions in MuPAD Standard Collection

coeff(p) - relums sequellce o/lIon-zero coefficiellts 0/ a pO~Vllomial

Page 28: Appendix 1 MuPAD Libraries and Procedures

440 MuPAD Pro Computing Essentials

content(p) - computes the cOlltellt of the polYllomial, i.e. gcd of its coefficients

degreevec(p) - returns a list of exponents of the leading term of a poly

divide(p, q) - divides hvo polynomials

expr(object) - converts object into an element of a basic domain

factor(p) -factors po(vllolllial into irreducible polynomials

ground(p) - returns the constant coejficient p(O. 0, .. 0)

lcoeff(p) - returns the leading coe,ff/cient of the polYllomial

lmonomial(p) - return the leading term of a polYllomial

lterm(p) - retllrns the leadillg term of a given polynomial

nthcoeff (p, II) - returns the n-th 11011 :ero coe,ff/cient of a polynomial

poly{/) - COli verts a polynomial expression into a polynomial

tcoeff(p) - trailing coefficiellt of a polynomial

A 1.27 Library 'prog' - Programming Utilities

prog: :allFunctionsO - command examines alld prillts allfunctioll alld libraries

prog: :calltree( laternent) - vi uali;;e the call strllcture ofnestedfunctioll calls

prog: :changes(object) - print information aboL4t changes of the object

prog: :check(object) - checks Mu? AD objects, lise to find errors ill lIser defined object

prog: :error(number) - COllverls all illtemal error IIlImber into all error message

prog: :exprtree(expres iOIl) - visualize expre ·sioll as a tree

prog: :find(expression, operand) - produces all paths to the operalld ill an expressioll

prog::getname(object) - produces the /lallle of the given Mu?AD object

prog: :init(object) - illitializes the given object

prog: :isGlobal(identijler) - checks ijthe given identifier is used ill the ystem

prog:: memuse(statement) - shows the memory usage for executing the gillen statement

prog:: profile(statemen/) - display timing data of nested jilllction calls

prog: :tcov(staternen/) - executes latemenl alldfor ech program line COlllltS the lIumber 0/ e..Tecutions

prog: :test(statemellt, res) - compare Ihe calculatioll result ·

prog::testexitO - closes automatic lests/rom testjiles

prog:: testfunc (/ill/clioll) - initialize tests for the given MuPAD jimctioll

prog: :testinit(protocolfile) - initialize tests

Page 29: Appendix 1 MuPAD Libraries and Procedures

Appendix 1: MuPAD Libraries and Procedures

prog::trace(object) - prints result ofob ervalioll ofa given MuPAD object

prog::tracedO - Lists all traced/unction

prog:: untrace(object) - terminates ob ervatioll of a given object

441

A 1.28 Library 'property' - Properties of Identifiers

property: :hasprop(objecl) - check i the givell object ha properties

property: :implies(propJ. prop2) - tries 10 check ifproperly J implies property 2

property:: Null- the emply property

property: :simpex(expr) - simplifie (he Boolean ex re sioll

A 1.28.1 Related Functions in MuPAD Standard Collection

assume(properly) - assign a properly (0 a MuPAD object

getpropO, getprop(J) - returns mathematical properly of a given expres ion

is(x. property) - check' if the given object has the given mathematical property

unassume( var) - removes propertie . of a given variable

A 1.29 Library 'RGB' - Color Names

RCB: :AliceBlue

RCB: :Antique RCB: :AquamarineMedium

RCB: :Azure RCB: : Bei ge RCB: :Black RCB: :Blue RCB: :BlueMedium RCB: :Brick RCB: : BrownOadder

RCB: : Bu rl ywood RCB: : Bu rntUmbe r RCB: : CadmiumLemon

RCB: : CadmiumRedDeep RCB::CadmiumYellow RCB: :Carrot RCB: :Chartreuse

RCB::AlizarinCrimson RCB: : Aquamari ne RCB::AureolineYellow

RCB::Banana RCB::Bisque

RCB::BlanchedAlmond RCB: :BlueLight RCB: :BlueViolet RCB: : Brown RCB::BrownOchre RCB::BurntSienna

RCB: : Cadet RCB: :CadmiumOrange

RCB: :CadmiumRedLight RCB: :CadmiumYellowLight RCB: :Cerulean RCB: :Chocolate

Page 30: Appendix 1 MuPAD Libraries and Procedures

~42 MuPAD Pro Computing Essentials

RGB::ChromeDxideGreen RGB::CinnabarGreen GB: : Cobalt RGB: :CobaltGreen

GB: :CobaltVioletDeep RCB: :ColdGray

RCB: :ColdGrey RCB: :ColorNames

RCB: :Coral RCB: :Corallight

RGB: :Cornflower81ue RCB: :Cornsilk

GB: :Cyan RCB: :CyanWhite

GB: :DarkOrange RCB: :DeepOchre GB: :DeepPink RCB: :DimGray

RCB: :OimGrey RCB: :OodgerBlue

GB: :Eggshel1 RCB: :EmeraldGreen

RGB: :EnglishRed RCB: :Firebrick RCS: : Flesh RCB: :FleshOchre

RCB: :Floral RCB: : ForestGreen ,

GB: :Gainsboro RCB: :GeraniumLake RCB: :Ghost RCB: :Gold

GB::GoldOchre RCB: :Goldenrod RGB::GoldenrodDark RGB::Goldenrodlight

GB: :GoldenrodPal e RCB: :Gray

RCB: :Green RCB: :GreenDark

RGB::GreenPale RGB::GreenYellow RGB: :GreenishUmber RGB: :Grey RGB::Honeydew RGB::HotPink RGB::IndianRed RGB: :Indigo RGB: : Ivory RGB: : IvoryBl ack G8: :Khaki RGB: :KhakiDark GB::LampBlack RGB::Lavender

RGB::LavenderBlush RGB::LawnGreen GB::LemonChiffon RGB::LightBeige GB::LightGoldenrod RGB::LightGray GB::LightGrey RGB::LightSalmon

RGB: :LimeGreen RGB: :Linen RGB: :MadderLakeDeep RGB: :Magenta ,RGB: : Mang",an,,!e~s~e~Bl'l u~el-____ RGB: :Maroon

Page 31: Appendix 1 MuPAD Libraries and Procedures

~~ndlx 1: MuPAD Libraries and Procedures

RGB: : MarsOrange .RGB: :Me1on

GB: :Mint RGB: :MistyRose RGB::Nap1esYe11owOeep

GB: : Navy RGB: :Oldlace

GB: :OliveDrab RGB: :Orange GB::Orchid GB::OrchidMedium

RGB: : Peach RGB: :Peacock GB::PermanentRedViolet

RGB: :Pink GB: : Plum

RGB::PrussianBlue RGB::PurpleMedium RGB::RawSienna RGB: :Red RGB: :RosyBrown GB::SaddleBrown

RGB::SandyBrown RGB ::SeaGreen RGB::SeaGreenlight RGB: : Seashell RGB: :Sienna GB::SkyBlueOeep GB: :SlateB1ue

RGB::SlateBluelight RGB::SlateGray RGB: :SlateGraylight RGB: :SlateGreyDark

GB: : Smoke

RGB: :MarsYellow RG8::MidnightBlue RGB: :MintCream RGB: :Moccasin RGB: : Navajo RGB: : NavyBl ue RGB: :Olive RGB::OliveGreenDark RGB::OrangeRed RGB::OrchidOark RGB::PapayaWhip RGB: : PeachPuff RGB::PermanentGreen RGB: : Peru RGB: : Pi nkl i ght RGB: :PowderBlue RGB: : Purple RGB: : Raspberry RGB: : RawUmbe r RGB::RoseMadder RGB: : RoyalB1ue RGB: : Salmon RGB: :SapGreen RGB::SeaGreenDark RGB: :SeaGreenMedium RGB: :Sepia RGB::SkyBlue RGB: :SkyBluelight RGB:: S1ateBlueOark RGB::S1ateBlueMedium RGB: :SlateGrayOark RGB ::SlateGrey RGB::S1ateGreylight RGB: : Snow

Page 32: Appendix 1 MuPAD Libraries and Procedures

RCB::SpringCreen

~CB::SteelBlue

~CB: :TerreVerte RCB: : Ti tani um

~CB: : Tu rquoi se RCB::TurquoiseDark RCB::TurquoisePale

RCB::UltramarineViolet

RCB::VenetianRed RCB: :VioletDark

RCB::VioletRedMedium ~GB::ViridianLight

~GB: :WarmGrey RGB: :White RCB::YellowBrown RCB::YellowLight

RCB: :Zinc

RCB: :SpringCreenMedium

RCB: :SteelBlueLight RCB: :Thistle

RCB: : Tomato RCB: :TurquoiseBlue

RCB::TurquoiseMedium RCB: :Ultramarine

RCB: :VanDykeBrown RCB: :Violet

RCB: :VioletRed RGB::VioletRedPale RGB: :WarmGray

RCB: :Wheat RCB: :Yellow

RCB::YellowGreen RGB::YellowOchre

Essentials

A 1.30 Library 'Series' - Tools for Series Expansions

~eries::gseries(ftx). x) - produces generalized series expallsions

Series::Puiseux(t!x). x) - produces initial segment of the trullcated Puiseux seri!:.\'

A 1.30.1 Related Functions in MuPAD Standard Collection

asympt(ftx), x) - computes asymptotic series expansion

series(ftx), x) - produces a series expansion ofa given expression

A1.31 Library 'solvelib' - Tools for Solving Equations

olvelib:: BasicSet - represents the four infinite sets - integers. rationals. complex and real numbers

lvelib: :conditionalSort(list) - sorts the list depending on param!:ters

Ivelib::getElement(set) - returns all element of tire given set

Ivelib::isFinite(set) - checks if the given set isjinite

olvelib::

Page 33: Appendix 1 MuPAD Libraries and Procedures

Appendix 1: MuPAD Libraries and Procedures 445

solvetib: :prelmage(f{x), x, sell - produce preimage 0/ a 'et under mapping

solvetib: :Union(set, t, pal:~et) - produces the ul/ion o/sets/or all vailles 0/ tfrom parset

A 1.32 Library 'specfunc' - Elementary and Special Functions

A 1.32.1 Related Functions in MuPAD Standard Collection

abs(x) - the absolute valuefimction

arccos(x) - the inverse o/the cosinefilllction

arccosh(x) - the inverse o/the hyperbolic cosh(x)fimctiol/

arccot (x) - the inverse tlygonometric cotangent fimction

arccoth{x) - the iI/vel' 'e hyperbolic cotangentfunclion

arccsc(x) - the inverse o/the cosecolltfilllction

arccsch(x) - the ill verse of the hyperbolic cosecantfimction

arccsc(x) - the inverse of the cosecantfunction

arcsec(x) - the inverse of the secantfimction

arcsech(x) - the inverse of the hyperbolic secantfimction

arcsin(x) -the invel~~e of the sin(.r) fill/Clioll

arcsinh(x) - the ill verse of the hyperbolic ine/imction

arctan{x) - the inverse of the tan (x) fimction

arctanh(x) - the inverse of the hyperbolic lal/gent/unction

arg(x) - the argument of the complex number

bernoulli(n) - produces n-th Bernoulli I/umber

bernoulli(n, x) - produces II-III Bernoulli polynomial ofx

bessell(v, z) - the modified Besselfimctioll

besselJ(l', z) - the Besselful/clion o/Iheftr t kind

besselK(v, z) - the modified Bessel/unction

besselY(v ,z) - the Besselfimction of the second killd

beta(x, y) - betafimclion

binomial(n, k) - billomialfilllclioll fI over k

ceil (x) - return the 'mal/est integer II stich that x<n

Ci(x) - co. ine il/tegral/unctioll

cos(x), sin(x), tan(x), cot(x), sec(x), csc(x) - trigonometricfimctions

Page 34: Appendix 1 MuPAD Libraries and Procedures

446 MuPAD Pro Computing Essentials

sinh(x), cosh(x), tanh(x), coth(x), csch(x) - hyperbolicJitnclions

dilog(x) -the dilogarithm/unctioll

dirac(x) - the Dirac delta distibutioll

dirac(x, II) -the 11-lh derivative o/the delta distribution

Ei(x) - exponelltial integral/unction

erf(x) - the error/unction

erfc(x) - the complementary errorfitnctiof/

exp(x) -the expollentialfimctioll rr fact(lI) - /actorial o/given illteger, same as 11!

floor(x) - returns the largest integer II such 1I<.x

float(x) - return jloatingpoint version a/the givenllumber x

frac(x) - theji-actional part o/the nUll/bel' x

gamma(x) - gamlllafimctioll

heaviside(x) - the Heavi ide step /ullction

hypergeom ([a 1. __ , all ], [b 1, __ , bk], z) - hypergeometric jill/ction

igamma(a, x) - the incomplete Gamllla/unction

lambertV(x) -lower real branch a/the Lambertfill/ctioll

lambertW(x) - upper real branch a/the Lambert/unction

In(x), log(n, x) -logarithms InCx) alld logn(x)

meijerG(lisls o/IIL11l1ebers) - Meijer G (unction

polylog(lI. x) - polylogarit/llnfilllction o/index /I

psi (x) - the digamlllafimction

round(x) - rOllnds x to the closest integer nllmber

Si(x) - sine integral fill/clion

sign(x) - the sigll Junction

signlm(z) - the sign a/the imagif/(lfJ' part 0/:

sqrt(x) -Junctioll rx trunc(x) - returns the integer part oJx

~eta(:) - the Riemann :e{afill/ctioll

A 1.33 Library 'stats' - Statistical Functions

stats: :betaCDF(a. b) - the cumulative distribution filllction oj the beta distribution

stats:: betaPDF(a. b) - the probability densil)' jlll/ction o/the beta distriblltion

stats:: betaQuantile(a. b) - the quantile filllctioll of the beta distribution

Page 35: Appendix 1 MuPAD Libraries and Procedures

~~ndtx 1: MuPAD Libraries and Procedures 447

stats: :betaRandom(a. b) - produces a procedure that returns beta deviates with shape parameters a > 0 and b > 0

stats: :blnomialCDF - distribution function

stats: :binomiaIPF(n, p ) - prodfiCes a procedure representing the probability function

stats::binomiaIQuantUe(n. p) - the binomial quantile function

stats: :blnomiaIRandom(n, p ) - the binomial deviates

stats::calc(sample. [c/ . c2 •.. }.[I,fl . ... ) - appliesfunctions to the sample

stats::cauchyCDF(n. p) - the cumulative distributionfonction of the Cauchy distribution

stats ::cauchyPDF(a. b) - the probability density fUnction afthe Cauchy distribution

stats ::cauchyQuantile(a. b) -the quantilefunction of the Cauchy distribution

stats ::cauchyRandom(a, b) - the random number generator function for Cauchy deviates

stats: :chlsquareCDF(mean) - the cumulat;\'e distribution function of the chi-square Jistribution

stats::chisquarePDF(mean) - the probability density f unction of the chi-square distribution

stats: :chlsquareQuantUe(mean) - the qualllilefunction of the chisquare distribution

stats: :chlsquareRa ndom(mean ) - random "umber generator function for chi-sqllare del'iates

stats: :col(sample, c/, c2, .. ) - creates a new sample from selected columns of the gil'ell sample

stats: :concatCol(s I. s2 . .. ) - creates a new sample containing columns of the given sample.f

stats: :concatRow(rl, r2 . .. ) - creates a lIew sample cOIl/aining rows of the g i l'ClI

samples

stats: :correlatlon([x I, x2 ... }, lvl, y2 . .. }) - the linear Bravais-Pear.fOIl corre/atiOIl

coeDiciellt

stats::covariance([xl. x2 ... },lY/, y2, .. }) -the coW/riance of data samples

5tat5::C5GOFT(data, cells. CDF=-j) - the classical chi-square goodness-of-fit test for the mill hypothesis

5tat5: :empiricaICDF(x J, x2 . .. ) - the empirical cllmlilatil'l! (/ist,.ibwionfunction of a jinite data sample

stat5: :empiricaIQuantile(x I. x2 . .. ) - the quantile fUllction oftlte empirical distribution

Page 36: Appendix 1 MuPAD Libraries and Procedures

«8 MuPAD Pro Computlnt Essentials

stats::equlprobabteCeUs(k. q) . procedure to divide the rea/line into equiprobabl intervals

stats::erlangCDF(a. b)· the cumulative dislribuliolljunclion a/the Er/ang distribution

stats::erlangPDF(a, b) - the probability density function a/the Er/ang distribulion

stats::ertangQuantne(a. b)· the quantile/unclion of the Erlang distribution

stats: :erlangRandom(a. b) - random number generator junction for Erlang deviale

stats::exponentlaICDF(u, b) - the cumulative dislribution/unction a/the exponential distribution

stats: :exponentiaIPDF(a. b) - the probability density function a/the f!Xponential distribution

tats::exponentiaIQuantUe(a, b) - the qualltilejunction a/the exponential distribution

stats::exponentiaIRandom(a, b) - random number generator function for exponential deviates

stats::fCDF(a, b) - the cumulalive distribution function of the Fisher'sf-dislribulion

stats::fPDF(a, bl -Iheprobability density jUnction of the Fisher'sfdistribution

stats:: fQuantlle(a, b) - the quantilefunction of/he Fisher'sfdistribution

stats: :fRandom(a, bl - random number generator function for Fisher 'sfdeviates

stats::gammaCDF(a, bl - the cumulalh oe distributionfonction of the gamma distribution

stats::gammaPDF(a, bl - the probability densityfunction of the gamma distribution

stats::gammaQuantile(a. b ) - the quantilefunclion of the gamma distribution

stats: :gammaRandom(a, bl - random number generator funclion for gamma d(.'Viates

stats::geometrtcCDF(PI - the cumuiatiloe distribution function of the geometric distribution

stats: :geometrtcMean(x I, x2, .. ) • the geometric mean of a data samples

stats::geometrtcPF(p) - the probability fimction of the geometric dil'tributioll

stats: :geometrtcQuantile(p) - tile quantile funclioll of the geometric distribution

stats::geometrtcRandom(p) - random number gellerator procedure for geometric del'iates

stats: :harmonlcMean(x I, x2, ... I - harmollic mean of a data sample

stats: :hypergeometncCDF(N, X n) - the cumulative probability funclioll of the hYlJergeometric distribution

stats: :hypergeometricPF(N, X n) - the probabililyflJllctioll of the h)!P£.r8!!!!.lIIetric

Page 37: Appendix 1 MuPAD Libraries and Procedures

~pendlx 1: MuPAD Libraries and Procedures

distribution

stats::hypergeometrtcQuantlle(N. X. n) - the quantile jUnction of the hypergeometric distribution

449

stats::hypergeometrtcRandom(N. X. n) - the random number generator for the hypergeometric distribution

stats::ksGOFT([xl. x2 . ... J. CDF=/J - the Kolmogorov-Smimov goodness.affil test

stats: :kurtosls{x/. x2, ... ) - the kunosis ofa data sample

stats::llnReg([x I. x2, ... J, [.vI . y2 • ... J) - linear regression

stats::loglstlcCDF(m, s ) -the cumulative distribulionjUnction of the logistic distribution

stats::logistlcPDF(m, s ) - Ihe probability density fUnction of the logistic distribution

stats: :logisticQuantile(m. s ) - the quantile function of the logistic distribution

stats: :logisticRandom(m. s ) - the random number generator for logistic deviatel'

stats::mean(xl. x2 • ... ) - the arithmetic mean ofa data sample

stats: :meandev(xl. x2, ... J -Ihe mean deviation ofa data sample

stats::medlan(xl, x2, ... ) -the median value of a data sample

stats::modal(x/, x2, ... ) - the mostfrequent value of a data sample

stats::moment(k. X. [x l , x2 • ... J) -the k-th moment ofa data sample

stats: :normaICDF(m. v) - the cumulative distribution fUnction of the normal distribution

stats::normaIPDF(m. v) -the probability density fonction of the normal distribution

stats: :normaIQuantile(m. v) - the quantile function of the normal distribution

stats: :normaIRandom(m, v) - the random number generator for normal deviales

stats: :obliqulty{x I. x2 . ... ) - the obliquity of a data sample

stats::poissonCDF(m) - the cllmulUlive distriblltionfunction of the Poisson distribution

stats::poissonPF(m) - the probability function of the Poisson distribution

stats::polssonQuantile(m) - the quantile function of the Poisson distribution

stats: :polssonRandom(m) - the ralldom IIumber generator for the Poisson distribution

stats: :quadraticMean(x I. x2 • ... ) - the quadratiC mean of a data sample

stats: :reg(data samples ) - genera/linear and nonlinear last squares fi t

stats :: row(sample. rl. r2, .. ) - select and rearrange roK'S ofa gi ~'en sample

stats::sampte([(al I, .. ,aln] , .. [aml ... ,amnJ)) - produces sample with m roK'S and n columns

Page 38: Appendix 1 MuPAD Libraries and Procedures

450 MuPAD Pro Com utfn Essentfals

stats: :sample2list( ample) - COli verts a 'ample into a Ii ·t ofli Is

stats: :selectRow(s. c. x) - procedure to select rows of a sample

stats: :sortSample(sample. cJ. c2 . .. ) - procedure 10 sort rows of a given sample

stats: :stdev(xi. x2 • .. ) - standard deviation of a data sample

stats:: swGOFT([xi. x2 • .. ]) - the Shapiro-Wilk goodlless-of-fit for normality

stats: :tCDF(a) - Ihe cumulative distribution of the Stlldellt's I-distribution

stats: : tPDF (a) - the probability density fUllction of the Student's t-distribution

stats:: tQuantile(a) - the quantile functiotl of the Sludent's t-distribution

stats: :tRandom(a) - the random generator for the Student's I-distribution

stats: :tTest([x 1. x2 • .. ]) - the t-test/or a mean

stats:: tabulate(sample) - statistic' oj duplicate rows in a sample

stats: :uniformCDF(a. b) -the cumlllative distriblltiolljilllctioll of the tllliform di ·tribution

stats:: uniformPDF(a. b) - the probability density junclion of the IIniform distriblltion

stats:: uniformQuantile(a. b) - the quantile jimction of the uniform distribution

stats:: uniformRandom(a. b) - the random nllmber generator for uniformly continllo deviates

stats:: unzipCol(li .[) - extracts eolumlls jrom a list of lists

stats: :variance(x I. x2 . .. ) - the variance of a data sample

stats: :weibullCDF(a. b) - the cllmulative distriblltion jimction of the Weibtlfl distribution

stats: :weibullPDF(a. b) - the probability density jill/clion of Ihe Weibull distribution

stats::weibullQuantile(a, b) -the quantilejunction of the Weibuff distribution

stats: :weibuIIRandom(a. b) - tile random number generalor of the Weibull deviates

stats: :zipCol(coli. col2 . .. ) - con veri a se uence of columns into a list of lists

A 1.34 Library 'stringlib' - Tools for String Manipulation

stringtib: :contains(stringl, tring2) - test if tring 1 contains string 2

stringlib::format( trl. width) - adjust the length of the string

stringlib::formatf(x, d) - convert ajloatingpointnllmberto a Siring

strlnglib:: lower( tring) - convert the given tring /0 lowerca e

stringlib: :match(slringl. string2) - checks if the string iI/wiehe ' Ihe string 2

stringlib:: pos(siring, sstI') - prodllces position of the substrillg sstr ill the given string

Page 39: Appendix 1 MuPAD Libraries and Procedures

A1?pendlx 1: MuPAD Libraries and Procedures 451

stringlib:: remove (slrillg. sstr) - removes the sub '(ring strfrom the given string

stringlib: :subs(string, 8str=lIsstr) - replaces a substring 8slr by IIsst,. in a given string

stringlib: :subsop( 'tring. n=newchar) - replaces character in posilioll II by the /lew characler

stringlib:: upper(string) - COli vert the givell string to IIppercase

A1.35 Library 'student' - the Student Package student: :equateMatrix(A. variable ) - prodllce a matrix equation

student: :isFree(/i t o.{vector ) - test of linear independence 0.( vectors

student: :Kn(n. F) - the vectors pace ofn-tuple over the field F

student:: plotRiemann(f, x=a .. b. n) - plot a lIumerical approximation of the integral Iising n rectangles (p. 357)

student::plotSimpson(f, x=Q .. b. n) - plot a nl/merical approximation o/the integral using the Simpson nile (p. 357)

student::plotTrapezoid(f, x=a .. b. n) - plot a numerical approximation of the illlegralusing trapezoids (p. 357)

student:: riemann(f, x-'a .. b. n) - produce a numerical approximation of the integral usillg n rectallgle (p. 357)

student: :simpson(f,. - a .. h, n) - produce a lIumerical approximation of the illlegral using the Simpson rule (p. 357)

student: :trapezoid(f, x=a .. b. n) - prodl/ce a lIumerical approximatioll 0.( the illtegralusillg trapezoids (p. 357)

A 1.36 Library 'transform' - Integral Transformations

transform: :fourier(f, I, s) - produce ' FOllrier trallsformation

transform: :invfourier(F. S, n -produces the inverse FOl/rier transformation

transform: :invlaplace - produces the inverse Laplace Irall~formation

transform: :laplace(f, t. s) - produces Laplace trail iformation

A 1.37 Library 'Type' - Predefined Types

Type: :AlgebraicConstant - type representing algebraic cOllstallls

Type::AnyType - Iype representing an arbitrQ/Y MuPAD object

Type: :Arithmetical - type represelltillg arithmetical objects

Page 40: Appendix 1 MuPAD Libraries and Procedures

452 MuPAD Pro Com~uttnl Essentials

Type::Complex . type representing complex numbers (p. 272)

irype: :Constant - type representing constant objects (p. 266)

il"ype: :Constantidents - type representing cons/ant identifiers in MuPAD

iType: :Equatton -Iype representing equations

Type: :Even - type representing even integer., (p. 254)

iType: :Functfon - type represenlingjunclions

iType::lmaginary - type representing romp/ex numbers with real parI equal 0 (p.272)

iType:: IndepOf - Iype representing object that donot contain given identifiers

iType:: Integer - type representing integer numbers (p. 154)

iType:: Interval - type representing intervals of real numbers (p. 35, 266)

iType: :ListOf - type representing lists of objects of the same type

iType: :ListProduct - type for testing lists

iType: :Neglnt - type representing negative inlegers (p. 254)

iType: :NegRat - type representing negative rational numbers (p. 262)

iType: :Negative -Iype representing nega/ive real numbers (p. 266)

iType::NonNeglnt -Iype representing non-negatj\'e integers (~)

irype: :NonNegRat - type representing non-negative rational numbers (~)

ype: :NonNegative - type representing non-negalil'e real numbers (~). (p.266)

irype::NonZero - type representing complex numbers withollt 0 (p. 266)

iType: :Numeric - type representing numerical objects

irype::Odd -type representing odd integers (p. 254)

Type::PolyExpr - Iype representing polynomial expressions (p. 286)

iType::PolyOf - type representing polynomials (p. 286)

Type::Poslnt -Iype representing positive integers (>0). (p. 254)

Type::PosRat -type representing poSitive rational numbers (>0). (p.262)

iType::Positlve - type representing positive real numbers (>0), (p.266)

Type::Prlme - type representing prime numbers. (p. 254)

iType::Product -Iype representing sequences

Type: :Property - Iype representing properties

Type: :RatExpr - Iype representing rational expresions

iType::Ratlonal- type representing ralional numbers (p. 267)

iType: :Real - type representing real numbers (p. 266)

[ype:: Relation - t);Pf! represellling relations

Page 41: Appendix 1 MuPAD Libraries and Procedures

Appendix 1: MuPAD Libraries and Procedures

Type:: Residue - type representing a residue class

Type::SequenceOf - type representing sequellces ofa given type

Type: :Series - type representing trllllcated Puiseux. Laurent alld Taylor series

Type: :Set - type representing set-theoretic e.\pressions

Type: :SetOf - type representing sets with elemellts of a given type

Type: :Singleton - type representillg exactly one object

Type: :TableOfEntry - type representing tables with entries of (l given type

Type: :TableOflndex - type representing tables wilh :,pecified indexes

453

Type: : Union - type representing objects having at least one of the specified types

Type:: Unknown - type repre entillg variables

Type:: Zero - type representillg a sillgle number 0 (p. 264)

A1.38 MuPAD Environmental Variables

DIGITS:=II - significallt nUlI/ber of digits ill floating point calclllations

FILEPATH - variable that contains the path to aJile

HISTORY, HISTORY:=II - determines the maximal number of en tries ill the history table

LEVEL, LEVEL:=n - determille the maximal substitutioll depth ofidentiJiers

MAXDEPTH, MAXDEPTH:=n -prevent inJinite recursion while callillg a procedllre

MAXLEVEL, MAXLEVEL:=II - determines the maximal substitution depth of identifiers

NOTEBOOKFILE - variable representing the /lotebookji/e /lame

NOTEBOOKPATH - variable representillg the lIotebook/ile path

ORDER, ORDER:=n -variable representing defauld I/llmber to be returned while producing serie expansion

LlBPATH - variable representing directOlY where are librmy Jiles

READPATH - variable representil/g direct01Y from which librmy Jiles will be loaded (p.1I3)

WRITEPATH - variable representing direct01Y to which library files will be saved (p.U2)

PRETTYPRINT, PRETTYPRINT:=value - variable contro/illg how the outpllt is jormal/ed

ESTPATH:=path - directolY wherejilllction prog::test will write/iles

TEXTWIDTH, TEXTWIDTH:=II - variable cOl/troling number of characters in the Ol/tpllt line 011 the screen

Page 42: Appendix 1 MuPAD Libraries and Procedures

Appendix 2 ___________ _

MuPAD Resources

The purpose of this appendix is to point out a few MuP AD-related resources. Most of the information about MuP AD can be found on the web site

• http://www.mupad.de/ This is the starting point to a number of web sites. Here are just some of them.

The Sci Face Web Site

SciFace Software GmbH & Co. KG, Germany, is the company that manages the MuP AD project, develops new graphical user interfaces and tools for visualization, and is responsible for production and distribution of MuP AD all over the world. Their web site has two alternative addresses:

• http://www.mupad.com/ or http://www.sciface.com/ This web site contains all the information related to the commercial aspects of MuP AD: how to buy it, how to get a free license, download evaluation versions, and links to SciFace partners all over the world.

The MuPAD Research Group

The MuP AD Research Group at the University of Paderborn is the scientific board of the SciFace Software Inc. This group develops ideas for new features of MuPAD, proposes new solutions and implements them. Their web site can be found at

• http://www.mupad.de/index_uni.shtml This is the best place to look for MuP AD documentation and a complete bibliography of books and articles about MuPAD.

MuPAD in Education

The Schule und Studium web site at

• http://www.mupad.de/schule+studium/

Page 43: Appendix 1 MuPAD Libraries and Procedures

1456 MuPAD Pro Computing Essentials

is devoted to the application of MuP AD in education. Most of the information provided here is in German. Thus, this web site can be an invaluable source of information for German and German speaking teachers. There are plans to develop a similar web site in English and Polish in the nearest future.

MacKichan Software Inc.

MuP AD is distributed and supported by a number of companies worldwide. A significant source of information about MuP AD can be the web site of MacKichan Software Inc. in USA. Their web site is at:

• http://www.mackichan.com/ MacKichan Software Inc., U.s.A. is widely known for their products Scientific Workplace (SWP), Scientific Word (SW) and Scientific Notebook (SN). Allow me to mention that SW is the best scientific word processor ever produced. It uses LaTeX as the format for its documents. SWP contains SW and a powerful computing engine. SN is a scaled down version of SWP - it does not include the TeX complier. Using these programs you can edit any scientific text including mathematical documents with a lot of formulae and perform all the calculations inside of your document. This book was in fact developed with the help of SNB. I had used SNB for typing the text, developing styles for printing, and for final typesetting.

Since the year 2000, MuP AD is being used as the computing engine for SWP and SN. Thus, SWP and SN can be considered as interactive, natural interfaces to MuPAD.

Book Resources

You can find some limited resources related to my book on the web site at

• http://www.mupad.com/majewski/ This is the place where you should look for the source code of the many examples that were used throughout the pages of this book. There are also solutions to some of the more complicated programming exercises, links to various MuP AD-related web sites, and certainly information about book updates and revisions.