## 559 Reputation

6 years, 308 days

## with sum and index notation...

 > restart:
 > B[t+1]:=B[t]+X[t,t+1]-D[t,t+1];
 (1)
 > T[t+1]:=(m+1)/(m*sum(X[t-i,t+1-i],i=1..m-1));
 (2)
 >

## i think u just want assign s members to ...

i think u just want assign s members to constants , u can do it like this :

for i to nops(s) do
C||i:=rhs(op(i,s));od;

 > restart:
 > Eq1 := diff(psi(y), y, y, y, y)-M*(diff(psi(y), y, y))-Gr*b*y = 0;
 >
 > bcs1:=psi(0)=0,(D@@2)(psi)(0)=0,psi(h)=-F/2,D(psi)(h)=A;
 >
 > res1:=(dsolve(Eq1));
 >
 >
 (1)
 > res2:=(dsolve({Eq1,bcs1},psi(y)));
 (2)
 >
 > match(rhs(res2)=rhs(res1),y,s);
 (3)
 > s;
 (4)
 > for i to nops(s) do C||i:=rhs(op(i,s));od;
 (5)
 >

## the picture is not seen...

it is almost correct, i just made i also local ,

 > restart;
 >
 > with(plots);
 >
 > g := proc (F, A, B, X0, g::evaln) local f, a, b, E, x0,i, erreur, N, n, x1, ps, pp, pic; f := F; a := A; b := B; x0 := X0; E :=evalf(abs(f(x0)));
 >
 > erreur := 0.1e-3;
 >
 > N := 100;
 >
 > n := 0;
 >
 > for i to N do x1 := evalf(x0-f(x0)/(D(f))(x0));
 >
 > E := abs(f(x1));
 >
 > n := n+1; ps[n] := plot([[x0, 0.], [x0, f(x0)], [x1, 0.]], color = green, thickness = 2);
 >
 > x0 := x1 end do; g := evalf(x1); pp := plot(f(x), x = a .. b, color = red); pic := seq(ps[i], i = 1 .. n); display(pp, pic) end proc;
 > f := proc (x) options operator, arrow; sin(x)-cos(2*x)+.2 end proc;
 > a := 0; b := 6;
 >
 (1)
 >

## maplesoft help page...

http://www.maplesoft.com/support/faqs/detail.aspx?sid=87675

Changing the default set of fonts Maple uses in the Standard interface is a two step process.

To change the default font for a type of input or output:

1. Select Format -> Styles

2. Select the style you wish to change and click the "Modify" button.

3. Change the font type, size, colour, etc. as desired and click "OK"

The default input/output modes for Maple are:

2D Math input: "C 2D Math"

1D Math input: "C Maple Input"

2D Math output: "C 2D Output"

The above steps will apply the change for the current worksheet only. If you were to restart Maple, the old default values will be restored. You must make a user defined style set if you want this change permanently. Here is how you can save the changes made above:

1. Select Format -> Manage Style Sets -> New Style Set

2. Select "Select All". Save the file.

3. Select the "User-defined Style Set" radio button. Browse to the style set file you created in the previous step and select it. Click "OK".

This makes Maple use the style set you've defined in future sessions.

(Note that you will need to keep that style set worksheet in its current location. If you move it, the font will go back to its default)

Format -> Manage Style Sets

and select “Default Maple Style Set”.

good luck!

## oh, you are so respective and cute...

one of many way is this :

 > restart:n:=5;# number of arguments#
 (1)
 > f:=Sum((a[i])*x^i,i=0..n);
 (2)
 >
 > # giving values to coefficients#
 > a[1]:=1.3:a[2]:=5.73:a[3]:=7:a[4]:=9:a[5]:=11:
 > value(eval(f));
 (3)
 > #or u can do like this
 > restart:
 > f:=a*x^2+b*x+c:
 > params:={a=1,b=2,c=3}:
 > eval(f,params);
 (4)
 >

for editing your post, in the down of your question,there is more,click on more and edit it . hope bests for you,since you decerve it . good luck

## use a program which adds virtual printer...

u can use a program which adds virtual printer so that u can print any thing u want to pdf files. for example adobe acrobat pro.
also u can use these pdfs.

M15QRC_win.pdf

maple-ref.pdf

maple_18.pdf

## use hint...

use hint for sepration of varibales, you should also write Pi with capital P .

 > restart:
 > PDE:=diff(u(x,t),t)=diff(u(x,t),x\$2);
 (1)
 > BCs:={u(0,t)=0, u(Pi/4,t)=0 , u(x,0)=x*(Pi/4-x)};
 (2)
 >
 > ans:=pdsolve(PDE, HINT = h(x)*g(t));
 (3)
 > PDEtools:-build(ans);
 (4)
 >
 > pds:=pdsolve(PDE,BCs,numeric):
 > p1 := pds:-plot(t = 0):p2 := pds:-plot(t = 1/10):p3 := pds:-plot(t = 1/2):p4 := pds:-plot(t = 1):p5 := pds:-plot(t = 2):plots[display]({p1, p2, p3, p4, p5});
 >
 > PDEtools:-Laplace(PDE,u(x,t));
 >

actually i do not know why Laplace does not solve this.

## two procedures...

 > restart:
 > Max:=proc() local m,i; m:=-infinity; for i in (args) do if i>m then m:=i end if;od;m; end proc:
 > triangle:=proc(a,b,c) local A,S; A:=evalf({(args)} minus {Max(args)}); S:=sqrt(op(1,A)^2+op(2,A)^2); if Max(args)
 > triangle(3,5,10);triangle(3,5,4);
 (1)
 >
 >
 >
 >

## the problem solved...

 > restart: with(Optimization): with(LinearAlgebra): L:=1:  r:=2:  tau:= 1: interface(rtablesize= 2*r+1): Z:= Matrix(      2*r+1, 2*r+1,      [tau,       seq(evalf((L/(2*(iz-1)*Pi))*sin(2*(iz-1)*Pi*tau/L)), iz= 2..r+1),       seq(evalf((L/(2*(iz-1-r)*Pi))*(1-cos(2*(iz-1-r)*Pi*tau/L))), iz= r+2..2*r+1)       ],      scan= columns,      datatype= float[8] );                          Dtau00:= < 1 >: Dtau01:= Vector[row](r): Dtau02:= Vector[row](r): Dtau10:= Vector(r): Dtau20:= Vector(r): Dtau1:= DiagonalMatrix([seq(evalf(cos(2*i*Pi*tau/L)), i= 1..r)]): Dtau2:= DiagonalMatrix([seq(evalf(sin(2*i*Pi*tau/L)), i= 1..r)]): Dtau3:= -Dtau2: Dtau4:= copy(Dtau1): Dtau:= < < Dtau00 | Dtau01 | Dtau02 >,          < Dtau10 | Dtau1  | Dtau2  >,          < Dtau20 | Dtau3  | Dtau4  > >;   P00:= < L/2 >: P01:= Vector[row](r): P02:= Vector[row](r, j-> evalf(-L/j/Pi), datatype= float[8]): P10:= Vector(r): P20:= Vector(r, i-> evalf(L/2/i/Pi)): P1:= Matrix(r,r): P2:= DiagonalMatrix(P20): P3:= DiagonalMatrix(-P20): P4:= Matrix(r,r): P:= < < P00 | P01 | P02 >,       < P10 | P1  | P2  >,       < P20 | P3  | P4  > >; interface(rtablesize=2*r+1):    # optionally J:=Vector([L, L/2 \$ 2*r]):      # Matrix([[...]]) would also work here E:=DiagonalMatrix(J); X:=  Vector[row](2*r+1,symbol=a); U:=Vector[row](2*r+1,symbol=b); X0:= Vector[row](2*r+1,[1]); G:=Vector[row](2*r+1,[1]); C:=simplify(X-X0-G.Z-X.Dtau.P+X.Dtau.Z-U.P);
 (1)
 > J:=X.E.Transpose(X)+U.E.Transpose(U);
 (2)
 >
 (3)
 > Minimize(J,{seq(C[i]=0,i=1..nops(C))});
 (4)
 > #XP:=-.015+X[1]+add(X[l+1]*f1(l)+X[r+l+1]*f2(l), l= 1..r): #plot([XP,T1], t= 0..1);#,legend= "Solution Of x(t) with r=50"):
 >
 >
 >
 >
 >

at first,i should request to upload the worksheet insetead of copying commands with this format, just copy and paste it in your worksheet to see it is not directly executable. when you load LinearAlgebra packgar,there is no need everytime to load part of package , if you need to load part of the package, just to it like this :

with(LinearAlgebra,DiagonalMatrix):

your matrix bounds are not correct so you can not multiply them correctly ! please change your matrix bounds,

 > restart:with(Optimization):with(LinearAlgebra,DiagonalMatrix):
 > L := 1: r := 2: tau := 1:
 > interface(rtablesize = 2*r+1):
 > Z:= Matrix(2*r+1, 2*r+1,[tau,seq(evalf((L/(2*(iz-1)*Pi))*sin(2*(iz-1)*Pi*tau/L)), iz= 2..r+1),seq(evalf((L/(2*(iz-1-r)*Pi))*(1-cos(2*(iz-1-r)*Pi*tau/L))), iz= r+2..2*r+1)],scan= columns,datatype = float[8]);
 (1)
 > Dtau00 := `<,>`(1); Dtau01 := Vector[row](r); Dtau02 := Vector[row](r); Dtau10 := Vector(r); Dtau20 := Vector(r);
 >
 (2)
 > Dtau1:= DiagonalMatrix([seq(evalf(cos(2*i*Pi*tau/L)), i= 1..r)]): Dtau2:= DiagonalMatrix([seq(evalf(sin(2*i*Pi*tau/L)), i= 1..r)]):  Dtau3:= -Dtau2: Dtau4:= copy(Dtau1): Dtau:= < < Dtau00 | Dtau01 | Dtau02 >>, < Dtau10 | Dtau1 | Dtau2 >, < Dtau20 | Dtau3 | Dtau4 > ;
 (3)
 > P00:= < L/2 >: P01:= Vector[row](r): P02:= Vector[row](r, j-> evalf(-L/j/Pi), datatype= float[8]):P10:= Vector(r): P20:= Vector(r, i-> evalf(L/2/i/Pi)): P1:= Matrix(r,r): P2:= DiagonalMatrix(P20): P3:= DiagonalMatrix(-P20): P4:= Matrix(r,r): P:= < < P00 | P01 | P02 >> ,< P10 | P1 | P2 >, < P20 | P3 | P4 > ;
 (4)
 > interface(rtablesize = 2*r+1); J := Vector([L, `\$`((1/2)*L, 2*r)]); E := DiagonalMatrix(J); X := Vector[row](2*r+1, symbol = a); U := Vector[row](2*r+1, symbol = b); X0 := Vector[row](2*r+1, [1]); G := Vector[row](2*r+1, [1]); C := simplify(X-X0-G.Z-X.Dtau.P+X.Dtau.Z-U.P);
 (5)
 > J := X.E.Transpose(X)+U.E.Transpose(U);
 > Minimize(J, {C = 0});
 >

## actually the only way is to go back from...

you can remove differentiation independent parameter by using declare and prime, like this :

with(PDEtools,declare):
declare(A(t), prime = t);

but actually it is not what you want, what you want is this :

 > restart:
 >
 >
 > d:=diff(A(t), t);
 >
 (1)
 > A(t)=((Int(d,t)));
 (2)
 >

maybe it is so obvious ,but this is the only direct way to relate a function to its differentiation !!! and u can not do it in any other way i think ! good luck !

## refer to these links, hops it helps you....

Hi sir,please refer to these links, hope it helps you . good luck Sir.

http://www.mapleprimes.com/questions/150659-How-To-Plot-With-The-Results-Of-Desolve-Command

good luck!

## use alias and factor...

what do u mean by finding relation between two expressions ?

 > restart:
 > alias(z=x^2+y);
 (1)
 > f(x^2+y)=factor(x^4+y^2+2*y*x^2);
 (2)
 >

## use unapply...

as maple help page :

unapply(expr, x, y, .., options);

The result of unapply(expr, x) is a functional operator. Applying this operator to x gives the original expression.
"unapply(expr,x)(x)->expr"

In particular, for a function
f(x)
,
"unapply(f(x),x)->f"

for example :
p := x^2+sin(x)+1;
f := unapply(p, x);
f(Pi);

good luck !

## in maple 18 everything is ok...

as u can seen in the picture, i write Pi in two ways in maple 18

 5 6 7 8 9 Page 7 of 9
﻿