krozy

0 Reputation

2 Badges

12 years, 313 days

MaplePrimes Activity


These are replies submitted by krozy

 

I have:

restart:

f:=x->(1-cos(x))/x;

eps:=1:

for N from -10 while abs(evalf(1/N)) < eps do 'f'(1/N) = evalf(1/N) end do;

 
                      /-1\                
f|--| = -0.1000000000
\10/
/-1\
f|--| = -0.1111111111
\9 /
/-1\
f|--| = -0.1250000000
\8 /
/-1\
f|--| = -0.1428571429
\7 /
/-1\
f|--| = -0.1666666667
\6 /
/-1\
f|--| = -0.2000000000
\5 /
/-1\
f|--| = -0.2500000000
\4 /
/-1\
f|--| = -0.3333333333
\3 /
/-1\
f|--| = -0.5000000000
\2 /
 
I am playing around with numbers a bit but I don't think I'm on the right track.. 

 

I have:

restart:

f:=x->(1-cos(x))/x;

eps:=1:

for N from -10 while abs(evalf(1/N)) < eps do 'f'(1/N) = evalf(1/N) end do;

 
                      /-1\                
f|--| = -0.1000000000
\10/
/-1\
f|--| = -0.1111111111
\9 /
/-1\
f|--| = -0.1250000000
\8 /
/-1\
f|--| = -0.1428571429
\7 /
/-1\
f|--| = -0.1666666667
\6 /
/-1\
f|--| = -0.2000000000
\5 /
/-1\
f|--| = -0.2500000000
\4 /
/-1\
f|--| = -0.3333333333
\3 /
/-1\
f|--| = -0.5000000000
\2 /
 
I am playing around with numbers a bit but I don't think I'm on the right track.. 

@Markiyan Hirnyk3578

minima := []: maxima := []:
for j to nops(CP) do if evalf(df(CP[j]-0.1e-3)) > 0 and evalf(df(CP[j]+0.1e-3)) < 0
 then maxima := [op(maxima), CP[j]] 
else if evalf(df(CP[j]-0.1e-3)) < 0 and  evalf(df(CP[j]+0.1e-3)) > 0
 then minima := [op(minima), CP[j]] 
end if:
 end if:

^^ I keep getting a logic error with this - I even took directly from your maple file and still. 
@Markiyan Hirnyk3578

minima := []: maxima := []:
for j to nops(CP) do if evalf(df(CP[j]-0.1e-3)) > 0 and evalf(df(CP[j]+0.1e-3)) < 0
 then maxima := [op(maxima), CP[j]] 
else if evalf(df(CP[j]-0.1e-3)) < 0 and  evalf(df(CP[j]+0.1e-3)) > 0
 then minima := [op(minima), CP[j]] 
end if:
 end if:

^^ I keep getting a logic error with this - I even took directly from your maple file and still. 
Page 1 of 1