## Strange behavior of evalf...

evalf(10.2^20, 50);

evalf((10+1/5)^20, 50);

Where are 50 digits of the first result?

## how to force the maple to outputs numeric value? e...

my codes list below.note the last line of the codes.evalf is not effective? the output is a long expression. how to force the maple to evaluate the long expression into a numeric value?

--------------------codes---------------------

restart:
with(Tolerances):
ALL := [`\$`(1 .. 3)]:
solution_k := simplify(solve(map(proc (i) options operator, arrow:
1/k[i] = (cos(Phi)*(x[i]-Tx)+sin(Phi)*(y[i]-Ty))/(-sin(Phi)*(x[i]-Tx)+cos(Phi)*(y[i]-Ty)) end proc, ALL), [Tx, Ty, Phi]), size):
assign(solution_k):
k := map(proc (i) options operator, arrow:
tan(phi[i]) end proc, ALL):
phi0[1] := Tolerances:-`*`(Pi, Tolerances:-`^`(3, Tolerances:-`-`(1))):
phi0[2] := Pi:
phi0[3] := Tolerances:-`-`(Tolerances:-`*`(Pi, Tolerances:-`^`(3, Tolerances:-`-`(1)))):
alpha := Tolerances:-`*`(Pi, Tolerances:-`^`(10, Tolerances:-`-`(1))):
L := 1:
phi := phi0:
x := map(proc (i) options operator, arrow:
cos(phi0[i]+alpha)*L end proc, ALL):
y := map(proc (i) options operator, arrow:
sin(phi0[i]+alpha)*L end proc, ALL):
angleError := Tolerances:-`&+-`(0, Tolerances:-`^`(10, -4)):
locError := Tolerances:-`&+-`(0, Tolerances:-`^`(10, -4)):
phi := map(proc (i) options operator, arrow:
phi[i]+angleError end proc, ALL):
x := map(proc (i) options operator, arrow:
x[i]+locError end proc, ALL):
y := map(proc (i) options operator, arrow:
y[i]+locError end proc, ALL):
evalf(Phi)

-----------------------------outputs--------------------

## How do I iterate this function using the @@ operat...

I can get the function to iterate as a recursive function by just reevaluating the x := evalf(x-(f1*j-i*g1)/(h*k-i*j), 25); y := evalf(y-(h*g1-f1*j)/(h*k-i*j), 25) portion of the function below but im trying beneath it to assign it as newt2d so that i can iterate it as newtons method in two variables like (newt2d@@10) and I can't seem to figure out what im doing wrong. Thanks for any help you can provide!

f := proc (x, y) options operator, arrow; x+y-cos(x)+sin(y-1) end proc; f1 := f(x, y)

(x, y) -> x + y - cos(x) + sin(y - 1)
x + y - cos(x) + sin(y - 1)

> g := proc (x, y) options operator, arrow; x^4+y^4-2*x*y end proc; g1 := g(x, y);

(x, y) -> x + y - 2 x y
x + y - 2 x y

> dh := D[1](f); h := dh(x, y);

(x, y) -> 1 + sin(x)
1 + sin(x)

> di := D[2](f); i := di(x, y);

(x, y) -> 1 + cos(y - 1)
1 + cos(y - 1)

> dj := D[1](g); j := dj(x, y);

(x, y) -> 4 x - 2 y
4 x - 2 y

> dk := D[2](g); k := dk(x, y);

(x, y) -> 4 y - 2 x
4 y - 2 x

x := .3; y := .8

0.3
0.8

> x := evalf(x-(f1*j-i*g1)/(h*k-i*j), 25); y := evalf(y-(h*g1-f1*j)/(h*k-i*j), 25);

0.2924403963319692595180140
0.8321243516906678979858730

> newt2d(.3, .8);

0.2577789764, 0.8333916830

> (newt2d@@5)(.3, .8);

Error, (in @@) invalid arguments

## Evaluate all numbers in maple expression using flo...

I would like to tell Maple to evaluate all numbers in an expression using floating point numbers (of a desired precision). Short example:

evalf[30](x^(1/12));

prints

x^(1/12)

while I want it to print

x^(0.0833333333333333333333333333333)

Note that the real expression may be arbitrarily complicated. I know that it is possible easily because I have already seen this somewhere, but I don't remember it.

## How can I solve this equation?...

How to solve this equation

cos(x)^2+2*x*cos(x)-2*sin(x)+4=0

with

solve(%,x) and evalf(%) ?

I get no solution. Is there any option to force Maple to solve this equation by solve and evalf?

Student[Calculus1]:-NewtonsMetnod(%,x=2) solves the problem.
If I use Series for sin(x) and cos(x) Maple can solve it too.

Thank you

## Parallel Add cause kernel connection lost...

If i use expression with function add() it runs normaly, but if I use expression with Threads:-Add (parallel implementation) it causes error "Error, continuation task already created for the current task" or "Kernel connection has been lost"

Expression:

Array(1 .. N,1 .. 1/2*N-NR-1,(i, m) -> evalf(Add(cosArr2[modp(k*i,N)]/kl[k],k = 1 .. NR+m-1)+Add(cosArr2[modp(k*i,N)]*alpha[k],k = NR+m .. 1/2*N)))

What am I doing wrong? Can I use two Add in one evalf?

## limit of sequence at infinity bugs

by: Maple

The following limit does not return a value. Then the evalf gives a wrong answer.

The answer should be "undefined" or -infinity .. infinity.

limit(exp(n)/(-1)^n, n = infinity) assuming n::posint; evalf(%);

/exp(n)              \
limit|------, n = infinity|
|    n               |
\(-1)                /

0.

The same happens if you delete the assumption.

A similar problem occurs with

limit(sin(Pi/2+2*Pi*n), n = infinity) assuming n::posint;
-1 .. 1
without the assumption this would be appropriate.

## What is the reason for this difference in int() vs...

I was looking at a question on another forum, and tried in Maple also, and Maple also have a problem with this integral. Here is a simple version. The problem is that int() gives different numerical answer from evalf(Int). Maple can't solve this analytically, so values have to be used for the integrand before calling int()

restart;
eq2:=(a/(a + c*z))^L*exp(-z)/sqrt(z);

L:=2:
a:=10^(0.1):
b:=10^(0.1):
c:=0.01*a:
int(eq2,z=0..infinity);   # 177.245
evalf(Int(eq2,z=0..infinity));   # 1.7551

I think the 1.7551 is the correct value. My question is: Why did maple give wrong answer from int()? Is it analytical reason, or purely numerical?

Maple 17.02, windows 7.

## Very, very slow numerical calculation?...

Hi everyone. Long time reader, first time poster.

I have a rather nasty function that I need to use in various calculations (namely, one of them is a numerical integration). But, even evaluating this function at a given point takes exceedingly long (several seconds to tens, maybe even hundreds of seconds!). Is there any way I can make maple do all of the calculations numerically instead of doing all but the last evalf symbolically? I think that may be the problem. Anyway, here is my defined function:

## How to put you answer in decimal form in Maple...

I'm given this equation:

f := proc (x) options operator, arrow; x^5-51*x^4+939*x^3-7685*x^2+28800*x-40500 end proc

and I have to find the decimall value of

f(ln(3*Pi)+8*e^4+sqrt(8+sin(4)))

How do you program this in Maple?

## Evaluation inputs with a single number...

How do I do to get a single number (decimal) when I evaluate an input.

For example, I write this:

evalf((546, 1/1000000000)*(7, 0)*sqrt(36+1/(7, 0)^2));

but I still get the same thing as I inputed as a response, how do I do to get an actual number?

## brackets and evalf...

Can somebody explain me this:

## evalf fails to deliver RootOf numerical value...

Dear All,

evalf(RoofOf(Z^6-3*Z^4+3*Z^2+Z-1,index=real[2]) fails to deliver a numerical value.

1. I can use fsolve to compute the real roots but I need to replace all the occurences of RootOf by its numerical value in lengthy expressions.
2. Also simplify(RoofOf(Z^6-3*Z^4+3*Z^2+Z-1,index=real[2],RootOf) does not work.
3. I read the other posts related but could not find any answer.

Thanks for any help,

S.

## complex trigonometric function roots...

I want to calculate successive roots of the following complex eq.

how can I set interval (?) for fsolve in the following code: