jeilerts

50 Reputation

2 Badges

12 years, 162 days

MaplePrimes Activity


These are questions asked by jeilerts

Hi,

 

I was wondering, suppose I have an ordinary differential equation, y''(x)  + y(x) - y(x)^3, and that the RHS is equal to zero (Duffing type equation).. Is there any way to declare this as in Maple, such as,

y''(x):=y(x)^3-y(x);

so that any time Maple sees y''(x) + y(x)-y(x)^3 in an expression, it will replace it with zero? I have tried the above, but it receive an error which says, "error, illegal use of an object as a name." 

Hi,

I have a trigonometric series which contains 1D and 2D modes. It looks something like the following:

S:= Acos(mx)sin(nz) + Bcos(kz)sin(qx) + Csin(sz) for m,n,k,q,s=1,.....10.

I am iterested in obtaining the amplitudes of the 1D modes (i.e. C in the above expression). Is there a way to do this using the coeffs function? I would like to use this in such a way as to isolate the 1D modes from th series. Any suggestions?

 

Thanks for your help.

Hi,

I have an expression which contains terms like cos(3*x)*cos(x) + sin(3*x)*sin(x). In this expression, I replace the prevous terms by using applyrule as:

applyrule([cos(3*x)*cos(x)=1/2*(cos(2*x)+cos(4*x)), sin(3*x)*sin(x)=1/2(cos(2*x)-cos(4*x))],expr);

 

Is there a way to generalize this so that I may replace all forms of sin(n*x)*sin(m*x) = 1/2(cos((n-m)*x)-cos((n+m)*x))?

 

Thanks for your help.

To Whom it May Concern:

I have a 3D array, P, with dimension P:=array(1..6,1..6,1..5). I would like to extract each 2D array from the 3D array and declare them as matrices. Additionally, I would like to store the sequence of matrices is a 1D array. I tried the following, but it did not work:

 

P:=array(1..6,1..6,1..5):

L:= matrix(1..6,1..6):

V:=array(1..5):

for l to 5 do: for i to 6 do: for j to 6 do: L[i,j] := P[i,j,l]: od: od: V[l]:=L: od:

I have a question about the "applyrule" function. I have an expression that looks like:

 

exprsn1:=sin(z)(Acos(z) + Bcos(x)cos(2z) + Ccos(x));

 

I would like to express cos(2z)sin(z) in the form 1/2(sin(3z)-sin(z)). However, when I use the "applyrule" as:

exprsn2 := applyrule(sin(z)cos(2z)=1/2(sin(3z)-sin(z), exprsn1);

it returns the same expression. Is there something else I should be doing before I use applyrule?

1 2 3 Page 2 of 3