## Exponents to floating point...

Maple 15

eq:=1/2*x^(1/2) + 1/13*x^(1/3) + 1/26*x^(45/37);
evalf(eq);

The exponents are still fractions.  I want to have floating point exponents.

0.5*x^0.500000 + 0.07692307692*x^0.333333 + 0.03846153846*x^1.216216216

How do I do this?

Tom Dean

## why evalf dosnt work????...

hi.please help me .why rule ''''evalf'''' dose not work properly?and I should copy the former answer in a another 'evalf' rule a gain??can I use only one rule 'evalf' instad twice useage??

this program attached blow.thanks alot

evalf.mw

## Evalf precision incorrect...

In the following code, the evalf prints -32.16...

restart; S := 8;

sigma := 8/sqrt(2*Pi);

iprec := 151;

evalf(log[2](-(sum(log(round(2^iprec*exp(-j^2/(2*sigma^2)))/2^iprec*exp(-j^2/(2*sigma^2))))*round(2^iprec*exp(-j^2/(2*sigma^2)))/2^iprec, j = 0 .. 7))));

Change the last line to evalf[20](log[2](....)), and re-run *just that line*. It now prints -66.67...

Change the last line to evalf[200](log[2](...)) and re-run *just that line* again. It now prints -151.24... (I have strong evidence to support that the true value is near -151, so I believe this answer.)

Now remove the precision indicator from the command completely and re-run just the last line. It *still* prints -151.24...!

My two questions are: why do I need evalf[200] to get the first three digits of the answer to be correct? and why does setting the evalf precision and then removing it cause the previous precision to persist?

## Broken Summation Notation...

Below is a Maple ws describing the problem. I have some fixed values pr0 and pr1, and a four variations of a function "pdf". The problem is that when I use the function in a sum (either the "sum" function or the sigma notation), the result is different than if I write out the sum explicitly. It's very puzzling as to why they woudl be different in the first place, but even more strange is that the different versions have *different* deltas. Even version 3, with a delta of 10^-100 is too much for my application (moreover the delta gets larger when I sum over more terms).

In the worksheet below, I compare "sum(f(x),x=3..3)" to "f(3)". I expect this should always be identically 0, but that is not true for any of the four versions of my function. (The same is true for "Sum(f(x),x=3..3)".) However, "sum(f(3),x=3..3)" *is* (blessedly) identically "f(3)". What gives?

 >
 >
 >
 >
 >
 >

Maple doesn't always like subscripted variables. Is that the problem?

 >

Maybe it's the binary expansion that's the issue

 >

No procedures, no arrays

 >
 >
 (1)
 >
 >
 (2)
 >
 (3)
 >
 (4)
 >
 >
 >
 >

## Why does Maple calculate so slowly?...

PS,
PiFast43 is freely available at,

http://numbers.computation.free.fr/Constants/PiProgram/pifast.html

## high precision problem...

I found this problem in a book about mathematica.
I want repeat it with maple.
But even Digits=1400, the exact value of s@x=70 is still different with the result(0.633319) on that book.
How to resolve this problem?
I want some help.

code:
restart;
Digits:=1400:
p:=convert(series(cos(x),x,201),polynom):
#plot(s,x=0..40,view=[0..40,-2..2],numpoints=6000,gridlines,style=point);
simplify(eval(s,x=70));
evalf(%);

## evalf abs encapsulated...

given the following:

param:= {mu[2] = (1600), mu[4] = (1500)}
R := unapply(1/(1+exp((1/50)*x)), x);

prior := evalf(expand(eval(eval(R(abs(mu[4]-mu[2])), `` = (x->x)), param)));

I need to keep the paramaters encapsulated. I would like this last step to output the answer 0.1192029.... but the abs function doesn't let me

## How do I convince Maple to evaluate this double in...

Hello everybody,

I am working on a somewhat complicated analytical problem, which includes the evaluation of the following (finite and singularity free) double integral (the stated numerical parameters may vary):

There are no unevaluated variables inside (all the e's are real exp()s). However, when putting it through evalf(), Maple returns it (after calculating for some time) unevaluated. I have no idea why, as a simple box sum should succeed.

Any input would be appreciated. Best regards,

K. Reuther

P.S.: Raw expression for further deliberations

Int(exp(18.1818*(Int((0.579160e-1*sqrt(x)*Ei(1., 0.500000e-4*x)+(1072.23*(.999950-1.*exp(-0.500000e-4*x)))/sqrt(x))/sqrt(x), x = 1. .. eta))-9.10000*eta)/eta, eta = 1. .. 100.)

## Rational Numbers...

x_1 = 1;

x_n = 1/2 (x_n-1 + 3/x_n-1 ) for n>=2

Is there a maple command to check if the above statement is rational, eventhough it is obvious enough?

I tried to evaluate x_2 using subs(n=2, x_n) but keep getting an expression in terms of x_1. Using evalf(x_2), the result was x_2.

## problem of numerical integration with method = _d0...

See AAAA.mw

The alpha and beta are 'randomly' chosen, both >0, to produce some values, hence a value for the target function to optimize.

I am having trouble to evaluate the expression in the middle of the calculation.

Sometimes, the 'chosen' alpha and beta works fine with 'method = _d01amc' for numerical integration. and such way is really "fast".

But sometimes, the the 'chosen' alpha and beta will fail. Even when both of them are perfectly defined. and the integral can be easily evaluated using Int() and then evalf().

So what's be best way to proceed?

Thanks,

casperyc

## How to evaluate an array(Matrix) involve numerical...

If I were to evaluate a single numerical integral, I can use evalf( Int(,method = _d01amc)).

But when the expression say is created by a built in function, Student[VectorCalculus][Hessian], from a complicated expression involve integrals. The resulting expression does not have the option "method = _d01amc". It then takes a long time to evaluate.

See this "HE" variable for example. HE.txt

value(HE); # takes a long time

evalf(HE); # takes a long time

Is there a way to evaluate "HE", using ",method = _d01amc" wherever necessary?

Thanks!

## how to export numerical evaluations immediately to...

for example i want to save the Square root of 2 to 1000000 decimal place to an ascii text file ...

i used the writeto command after evalf[100](sqrt(2)) for but it contains line breaks and \ character in output !

but i only need the pure continues 1000000 digits !

please guide me on this simple request ?

## Spacial Matrix Prodution...

Hi all

I have a mathematical problem and I asked it in various sites but the answers till yet are not correct.

Assume that we have:

T[m]:=t->t^m:
b[n,m]:=unapply(piecewise(t>=(n-1)*tj/N and t<n*tj/N, T[m](N*t-(n-1)*tj), 0), t):

where n,N,tj are known constants. furthermore assume that we want to comute the following integral:

for following approximations:

I have written the following code but it seems to be incorrect:

V1:=Vector([seq(seq(b[n,m](t),m=0..1),n=1..3)]);
V:=evalf(V1.Transpose(V1));

the original program is :

taaylor.mws

I will be so grateful if any one can help me to solve it by maple

Ph.D Candidate

Applied Mathematics Department

## 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--------------------

 1 2 3 4 Page 2 of 4
﻿