Maple的内部常数

合集下载
  1. 1、下载文档前请自行甄别文档内容的完整性,平台不提供额外的编辑、内容补充、找答案等附加服务。
  2. 2、"仅部分预览"的文档,不可在线预览部分如存在完整性等问题,可反馈申请退款(可完整预览的文档不适用该条件!)。
  3. 3、如文档侵犯您的权益,请联系客服反馈,我们会尽快为您处理(人工客服工作时间:9:00-18:30)。

Maple的内部常数
Maple的常用内部数学函数
)
Maple中的数学运算符
Maple的关系运算符
函数的连续性
四大数学软件(mathcad,mathematica,maple,matlab)中,只有Maple才有判断函数连续性的命令,其命令如下:
如何用Maple求极限
(1)极限:
(2)单侧极限:
左极限:
右极限:
如何用Maple求导数
如何用Maple求高阶导数
如何在Maple中求隐函数的导数
在Maple中,没有直接求参数方程确定的函数的导数的命令,只能根据参数方程确定的函数的求导公式
一步一步地进行推导;或者,干脆自己编一个小程序,应用起来会更加方便。

如何用Maple求不定积分
求定积分、广义积分
如何用Maple
先加载student函数库,加载方法为:with(student);
如何用Maple进行分部积分的计算
先加载student函数库,加载方法为:with(student);
在Maple中,如何用矩形法、梯形法和辛普森法求近似积分在计算之前,首先要加载student函数库,加载方法为:with(student);
矩形法
梯形法
辛普森法
如何用Maple对数列和级数进行求和
如何用Maple进行连乘
如何用Maple展开级数
如何在Maple中进行积分变换
在进行拉普拉斯变换及其逆变换、傅立叶变换及其逆变换、傅立叶正弦变换和傅立叶余弦变换时,必须要先加载积分变换函数库,加载方法为:with(inttrans),但在进行Z变换及其逆变
换时,不用加载任何函数库。

如何用Maple解微分方程
如何用Maple解微分方程组
如何用maple求多变量函数的极限
以两个变量为例说明,多于两个变量的函数极限可以依次类推。

计算极限
如何用maple 求多元函数的偏导数
求偏导数
如何用maple 求多变量函数的泰勒展开式
首先要加载mtaylor 链接库,加载方法为:readlib (mtaylor )(在maple7、maple8、maple9中不用加载)
如何用maple 求重积分
可以利用数个int ()指令的组合来完成。

对于二重积分和三重积分,也可利用student 链接库里的
Doubleint
()和Tripleint ()指令来完成。

格式如下:
首先要加载student 链接库,加载方法为:with(student)
注意:Doubleint ()和Tripleint ()指令只保留原积分式,并没有求值,如果要求值,必须用value ()指令来完成。

如何用maple 求梯度、散度、旋度
首先要加载软件包VectorCalculus ,加载方法为:
with (VectorCalculus )
Maple Examples
Below are some examples to help get you started using Maple. The best way to learn is to try things out on your computer. Table of Contents
∙Graphs
o Plotting a single function
o Plotting two functions at once
o Plotting a surface
∙Solving Equations
o One unknown
o Two unknowns
∙Computations
o Arithmetic
o Algebra
o Trigonometry
o Functions
o Calculus
o Matrices
∙Help
Back to Maple
Plotting a single function
To graph the function y = x^2 on the interval from -1 to 1, write this in Maple:
plot( x^2, x = -1..1 );
Table of contents
Plotting two functions at once
We can plot more than one function at a time:
plot( { sin(x), (1/3)*x }, x = -Pi..Pi );
By looking at the graph we can solve the equation sin(x) = x/3. The roots are determined by the places where the two curves cross.
Table of contents
Graphing surfaces
We can graph surfaces using the plot3d command. For example, to graph z = xy, where x and y run from -1 to 1, we do this:
plot3d( x*y, x=-1..1, y=-1..1, axes = BOXED, style = PATCH);
For more information use the ?plot3d command. No semicolon needed for this one. Table of contents
Equations in one unknown
To solve the equation x^3 + x = 27, do this:
solve(x^3 = 27);
1/2 1/2
3, - 3/2 + 3/2 I 3 , - 3/2 - 3/2 I 3
Note that there are three solutions, two of which are complex. Now let's try something more complicated:
solve(x^3 + 1.5*x = 27);
2.83, - 1.42 + 2.74 I, - 1.42 - 2.74 I
Note: There is a good reason why we wrote "1.5 " instead of "(3/2)" as the coefficient of x in the last equation. If one of the numbers in the equation is in decimal form, then Maple tries to find an approximate solution in decimal form. If none of the numbers are in decimal form, as in the first example, then Maple tries to find an exact solution. This may fail, since there is no algebraic formula for the roots polynomial equations of degree five or more ( Galois ).
Table of contents
Equations in two unknowns
We can also solve systems of equations:
solve( { 2*x + 3*y = 1, 3*x + 5*y = 1} );
{y = -1, x = 2}
These can contain literal as well as numerical coefficients:
solve( { a*x + 5*y = 1, 3*x + b*y = c}, { x, y } );
- 3 + a c - b + 5 c
{y = ----------, x = - ----------}
- 15 + a b - 15 + a b
In the second example we have to tell Maple that x and y are the variables to be solved for. Otherwise it wouldn't know.
You can solve systems of two equations in two unknowns of the form f(x) = 0, g(x) = 0 by graphing the functions f(x) and g(x) and seeing where the curves cross.
Table of contents
Arithmetic
Maple does arithmetic pretty much as you would expect it to:
3*(1.3 + 1.7)^2/2 - 0.1;
13.400000000
It has built-in commands which can do a lot of work quickly. For example, to add up the numbers 1, 1/2, 1/3, ... 1/10, we do this:
> sum(1/n, n= 1..10);
7381
----
2520
Note that Maple gave us the exact answer as a fraction in lowest terms. For an approximate answer in decimal form, do this:
> sum(1.0/n, n= 1..10);
2.928968254
The only difference was the 1.0 in place of 1 . Note the decimal point. We can also things like factor numbers:
> ifactor(123456789);
2
(3) (3803) (3607)
Table of contents
Algebra
Maple can do algebra:
> p := (a+b)^2; # define p to be the square of (a + b)
2
p := (a + b)
> expand(p); # expand it
2 2
a + 2 a
b + b
> factor(a^2 + 2*a*b + b^2);
2
(a + b)
> a := 1; # define a to be 1
a := 1
> p; # re-evaluate p
2
(1 + b)
> a := 'a'; # define a to be a again
a := a
> p; # check it out
2
(a + b)
Table of contents
Trigonometry
Maple does trigometry using radian measure:
> sin(Pi/2);
1
> arcsin(1);
1/2 Pi
We can set things up for conversions like this:
> deg := evalf(Pi/180); # use evalf to convert to decimal form deg := .01745329252
> rad := 1/deg;
rad := 57.29577951
> sin(90*deg);
1.
> arcsin(1)*rad;
28.64788976 Pi
> evalf("); # " stands for the result of the preceding computation
90.00000002
Note two things. Sometimes we need to use the evalf function to convert results from exact to floating point (decimal) form. Sometimes it is convenient to use the quote(") sign: it stands for the result of the preceding computation.
Table of contents
Functions
You can define your own functions in Maple:
> f := x -> sqrt( 1 + x^2 );
2
f := x -> sqrt(1 + x )
> f(1);
1/2
2
> f(a+3);
2 1/2
(10 + a + 6 a)
These can have more than one variable:
> g := (x,y) -> sqrt(x^2 + y^2);
2 2
g := (x,y) -> sqrt(x + y )
> g(3,4);
5
Table of contents
Calculus
Maple can differentiate an expression:
> diff( sin(cos(x)) + x^3 + 1, x );
2
- cos(cos(x)) sin(x) + 3 x
It can do both definite and indefinite integrals:
> int( x^2, x );
3
1/3 x
> int( x^2, x = 0..1);
1/3
> evalf( int( sqrt( 1 + x^3 ), x = 0..1 ) );
1.111447971
The last computation deserves comment. Suppose we just do the obvious thing (try it!).
> int( sqrt( 1 + x^3 ), x = 0..1 ):
Maple does not give us a numerical answer because the integral of this function cannot be expressed in terms of elementary functions. In particular it cannot be integrated by the usual techniques. However, note that we have surrounded our computation with
evalf( ... ). This forces Maple to evaluate the integral numerically: evalf stands for evaluate in floating point form
Table of contents
Matrices
Here are some examples of matrix calculations. Be sure to use with(linalg) before doing them. Also be sure to try these out to see how they work!
> with(linalg):
> a := matrix([
[1, 2],
[3, 4]
]);
matrix is displayed ........
> b := matrix([
[0, 1],
[1, 0]
]);
........
> multiply( a, b );
........
> multiply( b, a );
........
> evalm( b &* a ); # another way of computing ba
..........
> ?evalm # consult help on evalm
> aa := inverse( a );
........
> c := randmatrix(2,2); # 2x2 random matrix
> evalm( 1/c ); # invert it
> print( aa ); # redisplay aa
........
Did you notice the difference between the product ab and the product ba?
Table of contents
Help
For information and examples on a particular Maple " function", use the "?" command. For example,
> ?solve
gives information on the solve command. Often it is helpful to scroll to the end of the help window and look at the examples, bypassing the technical discussion that precedes it. You can also try the command with no keyword:
> ?
This gives additonal information on how to use the help system.
Maple Help
Try also Maple's help command, which is gotten by typing ? followed by what you want help on. Example:
> ?fsolve
> ?plot
> ?。

相关文档
最新文档