Maple 12 Questions and Posts

These are Posts and Questions associated with the product, Maple 12

I rename text file as mws when I click it , it show a few button and then need to extra click maple input and then need to click enter in order to run.

 

how to run directly when I open it with maple?

I find eval(Diff(x,x)) still is Diff(x,x)

how to make become 1

or how to evaluate Capital Diff ?

 

and I find sum(diff(x^k,x)/k! , k=1..n)

return exp(x) *gamma(n,x)/gamma(n)

why not exp(x)?

 

and diff( m(x+ diff(...) ...) / diff without m(x) , why return 0

i still have not define m(x)

 

if there is a equation subs(...)

how to make a similar symbol like Diff(f(t),t) and diff(f(t),t) use for a new solver procedure use?

restart;
Digits:=4:
n:=11:
M := 2:
Le := 5:
Lb := 2:
L:= 1:
l := 0.5:
Pr := 1:
Pe := 2:
Nt := 0.5:
Nb := 0.8:
F[0]:=0:
F[1]:=l*F[2]:
F[2]:=a:
T[0]:=1:
T[1]:=b:
d:=k->piecewise(k<>0,0,k=0,1):
for k from 0 to n do F[k+3]:=-1/(d(k)+(k+1)*(k+2)*F(k+2))*((sum(F[k-m]*(m+1)*(m+2)*F[m+2],m=0..k))-(sum((k-m+1)*(m+1)*F[k-m+1]*F[m+1],m=0..k))-M*(k+1)*F[k+1])*(factorial(k)/factorial(k+3));
T[k+2]:=-1*(Pr/(k+1)*(k+2))*((sum(F[k-m]*(m+1)*T[m+1],m=0..k))+Nt*(sum((k-m+1)*(m+1)*T[k-m+1]*T[m+1],m=0..k))+Nb*(sum((k-m+1)*(m+1)*T[k+1]*F[k-m+1],m=0..k))) end do: 
f:=sum(F[k]*y^k,k=0..n); 
t:=sum(T[k]*y^k,k=0..n); 
with(numapprox):
pade(diff(f,y),y,[4,4]):
pade(t,y,[4,4]):
solve({limit(pade(diff(f,y),y,[4,4]),y=infinity)=0.,limit(pade(t,y,[4,4]),y=infinity)=0.,[a,b]);

   1 1 1 2 2 3 3  

(  1 3 3 2 2 1 2 )

how to input this permutation into permgroup ?

 

with(DiscreteTransforms);
Digits := 600;
ss := 1:
windowlength := 50:
ma := []:
me := []:
counter1 := 1:
Z := Vector(windowlength, datatype = complex[8]);
Z5 := []:
for i from windowlength+ss to 1+ss by -1 do
eq2 := x:
eq2a := x*2:
god := solve(eq2a=y, t);
ma := [op(ma), evalf(subs(t=100, eq2a))]:
me := [op(me), 100]:
Z[counter1] := [Complex(evalf(subs(t=100, eq2a)),0)];
counter1 := counter1 + 1:
od:
Z2 := FourierTransform(Z);
Z5 := []:
for i from 1 to counter1 do
Z5 := [op(Z5),Re(Z2[i])]:
od:
p := dualaxisplot(listplot(Z, color = red), listplot(me, color = blue), style = line, gridlines = false):
p3 := dualaxisplot(listplot(ma, color = red), listplot(me, color = blue), style = line, gridlines = false):
> Z[counter1] := [Complex(evalf(subs(t = 100, eq2a)), 0)];
Error, unable to evaluate expression to hardware floats: [0.1395407376854069872222364799062994087470140319577366200576294159849633469734297167456440703192248821030980068084453175485138428545865904609881858312543669285411895851509107873579430804484462212873775830538595858575740816705029437533106045686220745333574567547827085763824574616984653193169818770743931611305635956093618789559193701301264280264321394773730076308141252308187470580964653518965117431518571850910086488220847415724949651796448259541027929735646487459091205173804995401770417274097230705447077344465381061736283732438996738107330437055827420813951050981604075837450139995544638...
> Complex(evalf(subs(t=100, eq2a));
Error, unable to match delimiters
Typesetting:-mambiguous(Complexlparevalf(subs(tequals100comma eq2a)),
  Typesetting:-merror("unable to match delimiters"))
> Complex(evalf(subs(t = 100, eq2a)), 0);
1.395407376854069872222364799062994087470140319577366200576294159849633469734\
  297167456440703192248821030980068084453175485138428545865904609881858312543\
  669285411895851509107873579430804484462212873775830538595858575740816705029\
  437533106045686220745333574567547827085763824574616984653193169818770743931\
  611305635956093618789559193701301264280264321394773730076308141252308187470\
  580964653518965117431518571850910086488220847415724949651796448259541027929\
  735646487459091205173804995401770417274097230705447077344465381061736283732\
                                                                               -571
  43899673810733043705582742081395105098160407583745013999554463814123790354 10   
   + 0. I

If maple can auto discover derived equations, 

then most variable are unknown name which may or may not be physics variable.

so, how to guess which physics data suitable for these look like meaningless variable?

or these tools only visualize the relationship of existing known equations?

How to use Fourier transform to extract the part of data which higher than near flat data no matter of scale such as very small decimal value?

would like to extract part when very small decimal small start to increasing or a noise start to appear in time series data.

and then highlight with rectangle in plot for that part of data.

if Fourier transform can not detect this noise or an increasing data or spike then return 0, if detected then return 1

can anyone help me to calculate the exact  value of the eigenvalues of this matrix:
 

Download mat.mw

 

2.22 *10^(-87)

2.55 *10^(-90)

would like to get 2.22 and 2.55 only by ignoring any power

how to do this?

with(RegularChains);
R := PolynomialRing([x, y, z]);
p1 := x^2+5-2*x*z;
p2 := z^3*y+x*y^2;
p3 := -8*z^3+3*y^2;
F := [p1, p2, p3];
MainVariable(p1, PolynomialRing([x, y, z]));
MainVariable(p1, PolynomialRing([z, y, x]));
prem(p1, p2, x);
prem(p2, p1, z);
prem(p3, p2, y);
premcustom := proc(Fparam,Gparam, xparam)
local R, G, F, lcg, lcr, dr, dg:
R := Fparam:
G := Gparam:
F := Fparam:
if degree(G,xparam) = 0 then
 print("return 0"):
 return 0:
elif degree(F, xparam) < degree(G, xparam) then
 print("return R"):
 return R:
else
 lcg := coeff(G, xparam, degree(G, xparam)):
 dg := degree(G, xparam):
 while degree(R, xparam) > degree(G, xparam) do
  lcr := coeff(R, xparam, degree(R, xparam)):
  dr := degree(R, xparam):
  R := lcg * R - lcr * G * (x^(dr - dg)):
 od:
end if:
return R:
end proc:
coeff(p1, x, degree(p1, x));
coeff(p2, x, degree(p2, x));
prem(p1,p2,x);
prem(p2,p1,z);

premcustom(p1,p2,x);
premcustom(p2,p1,z);
 
why premcustom looping?
 
is this coeff(p1, x, degree(p1, x)); wrong ?
 
should this to get real coefficient in number instead of variable and how?
 
is there equivalent function as dprem?
 
with(diffalg):with(diffalg):
FlessThanG := proc(Fparam, Gparam, PRing)
F := Fparam:
G := Gparam:
if leader(F,PRing) < leader(G,PRing) or (leader(F,PRing) = leader(G,PRing) and degree(F, leader(F,PRing)) < degree(G, leader(G,PRing))) then
 return True:
else
 return False:
end if:
end proc:
dprem := proc(Fparam, Gparam, x, PRing)
local R, theta, thetax, thetaG, F, G;
F := Fparam:
G := Gparam:
R := F:
thetax := leader(G, PRing);
while FlessThanG(R, G, PRing) or FlessThanG(G, R, PRing) do
theta := leader(R, PRing);
R := prem(R, thetaG, theta)
od:
return R:
end proc:
R := differential_ring(ranking = [[x,y,r]], derivations = [t], field_of_constants=[m,l], notation = diff):
p1 := m*x[2] + r*x;
p2 := m*y[2] + r*y - g;
p3 := x^2 + y^2 - l^2;
dprem(p1, p3, x, R);
 
 
is x[2] = diff(x,t$2) in diffalg ?
 
if not how to write in this way?
 
i had defined constant
but got error
 
Error, (in DifferentialAlgebra:-Tools:-LeadingDerivative) unknown symbol (approx. error location: [m*x[2 --> ] <-- +r*x])
 
 

Assume 

matrix([[1,0],[0,1]]) * matrix[[y],[y']]
= a system 

 

how to get back matrix([[1,0],[0,1]]) from this system in general method if the system is very large?

Is there a function to convert recurrence equation to a system of equations?

https://math.stackexchange.com/questions/301068/how-do-you-find-a-corresponding-recurrence-relation-for-some-random-algorithm/301709

according to this link, how to parse or walk through the algorithm in maple to generate recurrence relation formula?

How to remove all punctuation marks in a string read from a text file 

and then store in a list of words according to the ordering of the original text?

1 2 3 4 5 6 7 Last Page 1 of 29