MaplePrimes Questions

Maple 2015:

simplify(1-2*sin(x)^2);  gives 2*cos(x)^2-1

I looked at help trying to understand why Maple thinks 2*cos(x)^2-1 is simpler than 1-2*sin(x)^2 but did not see it. I was expecting to see cos(2*x) as a result.

Is there a place to understand more Maple's simplification rules other than the help page? http://www.maplesoft.com/support/help/maple/view.aspx?path=simplify%2fdetails

I need to show that the following expression,
a^3b-a^3c+a^3z+a^3x+a^3y-a^2bx+a^2by+a^2cx-a^2cy-a^2zx+a^2zy-a^2x^2+a^2y^2-abcz-abcx-aczx-acx^2+b^2c^2+2bc^2x+c^2x^2-b^2c-2bcx-cx^2,

is positive

given that:

1. a,b,c,x,y,z are positive real numbers

2. a>b+x

3. c<b+y

I know a priori that the expression is indeed positive, but I do not know how to show it, or how to use Maple to do it?

Specifically, how can I use Maple to **partially factorize** the expression in terms of the expressions a-b-x and c-b-y?

Thanks for any help.

Can anyone tell me what is going on in the following worksheet? 


restart:

 

The following type  matches any second-or-higher-order derivative specified in D form with independent variables. You don't need to understand how this type works---which is, admittedly, convoluted---in order to understand the rest of this post.


TypeTools:-AddType(
     HODD,
     {typefunc(
           name,
           typefunc(
                name,
                {'`@@`'(identical(D), posint),
                 And(specindex(posint, D), satisfies(D-> nops([op(D)]) > 1))
                }
           )
      )
     }
);

 

Here's an expression which is simply a sum of various types of derivatives. Note that the first and last terms only differ in the dependent variable name.


expr:=
     D[1,2](u)(x,t) + diff(u(x,t), x, t) + diff(f(x),x$2) +
     diff(f(t),t) + (D@@3)(f)(x) + D(g)(x) + D[1,2](v)(x,t)
;

(D[1, 2](u))(x, t)+diff(diff(u(x, t), t), x)+diff(diff(f(x), x), x)+diff(f(t), t)+((D@@3)(f))(x)+(D(g))(x)+(D[1, 2](v))(x, t)

I1:= indets(expr, HODD);

{(D[1, 2](u))(x, t), (D[1, 2](v))(x, t), ((D@@3)(f))(x)}

The above result is as expected: Ds of order greater than 1 are selected; diffs are not. Now I try to extract the diffs also.

 

indets(expr, HODD &under (convert, D));

{diff(diff(f(x), x), x), diff(diff(u(x, t), t), x), (D[1, 2](v))(x, t), ((D@@3)(f))(x)}

The above result is missing D[1,2](u)(x,t) even though it contains the syntactically identical term D[1,2](v)(x,t)! Running trace  on `type/&under` shows that it never gets called for that missing term! So, the problem is not in &under. A further test shows that if the missing term is put elsewhere in expr (after restart, of course) then the indets works okay.

 

The following result is even weirder. One would expect that for any types T1 and T2 and any expression expr, that indets(expr, {T1, T2}) would equal indets(expr, T1) union indets(expr, T2), right? One would expect that even if there were a bug with one of the individual indets calls, right? So, note that I1 above contains the first term of expr, yet ...

indets(expr, {HODD, HODD &under (convert, D)});

{diff(diff(f(x), x), x), diff(diff(u(x, t), t), x), (D[1, 2](v))(x, t), ((D@@3)(f))(x)}

I get the same results if put the type explicitly in the indets calls rather than using AddType. I get the same results in Maple 16 and 18. So, what's going on?

 


Download indets.mw

I have created and saved a MAPLE module in an .mla archive. The module contains three procedures A, B, C, where

A calls, B and C.  

Once the module library has been loaded, A acccepts inputs and generates outputs.

Is it possible to create a MAPLE player worksheet which calls the module and share it with a Maple Player (only) user, so that they can then supply the inputs and observe the outputs from A using the Maple Player programme components?

Can anyone help?

MRB

 

 

 

Hi everybody:

I'm going to learn programming with maple 18, are there any good and new pdf files for learn it?

with regards...

 

Consider the following situation: I have a function f, say

f:=x -> 1+x^2/n;

I want to compute the composition of f with itself; e.g.

g:=f@@n;
eval(g(x),n=3);

So it appears eval does evaluate the threefold composition but not at n=3. Obviously I can wrap this example in a subs() or another eval to get the replacement done; but it is a bit curious and I wonder whether this behaviour is as designed or an "undocumented feature."

I ran across this when investigating whether or how to do the composition for an arbitrary n (so I can e.g. find the limit for n=infinity) and really wanted to ask about that, but I see that such a question was dealt with before by Joe Riel using rsolve so I'll see first how far that approach gets me. In my case the function will be a polynomial vector function with vectorial arguments, providing for some additional challenge.

Mac Dude.

for example

There is a Matrix A:=Matrix([[1,2,3],[4,5,6]]), which function can help me find if 4 is an entry of  this Matrix?

Hello,

From a simulation software, I obtain in a matlab file my differential equations in the following way :

C_p_e = C_state/C_c;
C_p_f = I_state/I_i;
R_p_e = R_r*C_p_f;
I_p_e = (Se_p_e-R_p_e)-C_p_e;

For theses expressions, I would like to do two operations :
1) Transform it into equations
2) Conduct substitutions so as to change the names of the variables with nicer names.

For this objectives, I could do with the following code:

restart;
eq1:=C_p_e = C_state/C_c;
eq2:=C_p_f = I_state/I_i;
eq3:=R_p_e = R_r*C_p_f;
eq4:=I_p_e = (Se_p_e-R_p_e)-C_p_e
allsubs:= proc(XX )
subs(C_p_e=fs(t),C_p_f=v(t),R_p_e=fd(t),I_p_e=fm(t),C_c=1/k,I_i=m,R_r=c,Se_p_e=fe(t),I_state=int(fm(t),t),C_state=int(v(t),t),XX)
end proc:
eq1_a:=allsubs(eq1);
eq2_a:=allsubs(eq2);
eq3_a:=allsubs(eq3);
eq4_a:=allsubs(eq4);

Now, I would like to automatisation the creation of the equations eq1, eq2, eq3, eq4. For the moment, to create these equations, I have done copy/ paste from matlab.

But, I would like to create these equations eq1, eq2, eq3, eq4 with a automative process from my matlab equations. The reason comes from the fact that I would like to make the same work on bigger system which are composed with numerous equations.

How can I create equations labeled eq1, ...eqn from a list of expressions from matlab ?

Thank you for your help

Hello everybody,

I'm trying to solve two ODEs analytically but it returns this 'Warning, it is required that the numerator of the given ODE depends on the highest derivative. Returning NULL'. See the worksheet Parallel_flow.mw

Thanks.

I am not sure how/why, but here is the worksheet.

test.mw

 

The function evalutes fine and can be used for sequence. But it does not seem to be working with plot or Maximize.

V is assumed to between 0 and 1.

Need some help.

 

Thanks,

 

casper

Dear all,

I have to differential equations that I'd like to linearise, that is all higher order (>1) derivatives (like diff(uu[0],x$2)) and parameters (like beta^2) and the products of any derivatives with the parameters uu[0] and beta are zero (as they are assumed small).

The two equations considered are displayed below:

 

Up to now, I perform a very tedious substitution which is based on looking at the equations above and decide which terms I want to get rid of. Something like this, where K =1:KFBCLin:=simplify(eval(KFBC, [beta^3 = 0, beta^2 = 0,
seq(subs((diff(uu[n], x$3)) = 0),n=0..K),
seq(subs((diff(uu[n], x$2)) = 0),n=0..K),
seq(subs((diff(uu[n], t))*beta = 0),n=0..K),
seq(subs((diff(uu[n], x))^2 = 0),n=0..K),
seq(subs(g*diff(beta, x)*beta = 0),n=0..K),
seq(subs((d^2*diff(uu[n], x,t)*diff(beta,x)=0)),n=0..K),
seq(subs(-2*d*diff(uu[n], x,t)*beta*diff(beta,x)=0),n=0..K),
seq(subs((d^2*diff(uu[n], x$2,t)*beta=0)),n=0..K),
seq(subs((diff(uu[n], x)*uu[n])=0),n=0..K),
seq(subs((diff(uu[n], x)*uu[n]*beta)=0),n=0..K),
seq(subs((diff(uu[n], x)*uu[n]*d)=0),n=0..K),
seq(subs((diff(beta, x)*uu[n])=0),n=0..K),
seq(subs((diff(uu[n], x)*beta)=0),n=0..K)]));As there is a lack of automatisation, this procedure is not very helpful. Life would be easier if there was a command (or the like) that says "get rid of higher order derivatives".Any help is appreciated.Best regards,

I have purchased Maple 2015 Student Edition a few months ago.  Now, I was about to buy MapleSim Student Edition and I saw that MapleSim include a license of Maple. 

If I buy MapleSim and Maple,  I would pay 198$ even if I could have bought only MapleSim and still get both products? 

Can I get MapleSim Student without Maple at a lower price? 

Maybe the version of Maple included in MapleSim has less features and that's why the cost of MapleSim and Maple are the same? 

Thanks in advance!  

I did some search on Google and on this website, but I haven't found anything. 

Hello everyone!!

I am beggining to use Maple and i saw there are many Math Apps in the Library. I was wondering if I can see the source code of some of this Math Apps to learn how to do my own ones.

please demonstrate to me how to set up a maple document to solve a simple beam design from the scratch.

 

S. Hassan

I'm using commands evalDG and LieBrackets to calculate Lie Brackets of infinitisemal operators.

But how (using Maple) can i extract component from the result?

For example, I had a result:

T = (f'(x) - f(x)) D_x + D_y

I need to get its component for x - f'(x) - f(x) and y - 1.

Is there a command for this operation?

First 1249 1250 1251 1252 1253 1254 1255 Last Page 1251 of 2429