Rouben Rostamian

MaplePrimes Activity


These are replies submitted by Rouben Rostamian

Thank you all for your replies and interesting discussion.  It appears that Kitonum's solution, that is,

collect(algsubs(1/(T[1]*V[2])=U, B), U);

is the most effective in this case.  Carl Love's sentiment regarding algsubs()'s quirks is duly noted.

@Alejandro Jakubi Doh! (slapping my forehead).  Why didn't I think of that?

I gues I was not thinking.  But please also have a look at the amended question above.

@nm That's an excellent solution, but please see the amended question above.

Amended problem

Having seen the replies from nm and Alejandro Jakubi, I realize that I have been careless in posing my question.  The actual expression which I wish to simplify is somewhat more complex than "A" shown above.  I made up the reduced expression "A" assuming that the solution of one will also be the solution of the other, but I was wrong.  Here is what I should have asked:

B := (V[1]*T[2]*(alpha-1)*(exp(-t/T[2])*T[2]-exp(-t/T[1])*T[1])*c[1,`in`]/((T[1]-T[2])*T[1]*V[2])-(T[1]*V[2]-T[2]*V[1])*exp(-t/T[2])*(beta-1)*c[2,`in`]/(T[1]*V[2]))/(c[1,`in`]*alpha*T[2]*V[1]/(T[1]*V[2])+beta*(T[1]*V[2]-T[2]*V[1])*c[2,`in`]/(T[1]*V[2]));

(V[1]*T[2]*(alpha-1)*(exp(-t/T[2])*T[2]-exp(-t/T[1])*T[1])*c[1, `in`]/((T[1]-T[2])*T[1]*V[2])-(T[1]*V[2]-T[2]*V[1])*exp(-t/T[2])*(beta-1)*c[2, `in`]/(T[1]*V[2]))/(c[1, `in`]*alpha*T[2]*V[1]/(T[1]*V[2])+beta*(T[1]*V[2]-T[2]*V[1])*c[2, `in`]/(T[1]*V[2]))

(1)

What was "u" in "A" is now "T[1]*V[2]" in "B", so collect() no longer works.  Since T[1]*V[2] also appears elswhere in "B", the subs() trick does not work either.  Here is my hand-crafted simplification:

(V[1]*T[2]*(-alpha+1)*(exp(-t/T[1])*T[1]-exp(-t/T[2])*T[2])*c[1,`in`]/(T[1]-T[2])+(T[1]*V[2]-T[2]*V[1])*exp(-t/T[2])*(-beta+1)*c[2,`in`])/(beta*(T[1]*V[2]-T[2]*V[1])*c[2,`in`]+c[1,`in`]*alpha*T[2]*V[1]);

(V[1]*T[2]*(-alpha+1)*(exp(-t/T[1])*T[1]-exp(-t/T[2])*T[2])*c[1, `in`]/(T[1]-T[2])+(T[1]*V[2]-T[2]*V[1])*exp(-t/T[2])*(-beta+1)*c[2, `in`])/(beta*(T[1]*V[2]-T[2]*V[1])*c[2, `in`]+c[1, `in`]*alpha*T[2]*V[1])

(1)

 

@Carl Love  Yes, as a rule I do pay attention to the ongoing discussion.  In this case, however, I failed to notice your answer, possibly because it was so terse, but that's not a good excuse.  I am sorry for having repeated your answer.  I attempted to remove my post but apparently there is no mechanism provided for that.

@Konstantin@ You get the second derivative from the differential equation itself:

de := diff(y(x), x$2)-1.0325*diff(y(x), x)+1.36*y(x)=sin(2*x);
solve(de, diff(y(x), x$2));

This expresses the second derivative in terms of y(x) and the derivative of y(x) which you already have from dsolve.

 

Your worksheet contains quite a few syntax errors.  After fixing those, problems still remain.  For instance, σ is

Leter we want to integrate σ A with respect to z, where A depends on z as well.  Now, forget about the A for a moment.  How would you integrate σ by itself?  There is no antiderivtative in terms of elementary functions, so you wil need to do a numerical integration at best.  But then you will need numerical values for all the symbols.  But that's not possible either, since k and εα are the unknowns in your problem which need to be solved for.

A possible approach would be to define numeric values for all constants other than k and εα, then set up a Newton's iteration to solve the resulting system of two equations in two unknowns.  Such reformulation will take you far away from where you are now, so I don't think it's useful to speculate how that will work out.

 

@Met28 Your integral cannot be computed since it is divergent, as Alsholm has explained.

To appreciate the issue, see what you can do with the following simpler problem by hand, not by Maple:

int(1/(x-1), x=0..3);

You will find the exercise quite instructive.

This is not an answer to your question but a side note which you may want to take into consideration.

In your worksheet you have

    q := {q1(t), q2(t), q3(t), q4(t)};
    xm1 := q[1];
    xm2 := q[1] + l1 * cos(q[2]);

You have specified q as a set.  The order of the elements of the set is not necessarily predetermined, so there is no quarantee that q[1] will produce q1(t).  To fix the order of elements in q, give it as list rather than a set, as in

    q := [q1(t), q2(t), q3(t), q4(t)];

 

@acer What you are suggesting certainly makes sense.  Putting the orientation information in the PlotComponent should be no more demanding than putting it in Maple's toolbar, as it's done currently for some of 3D plots.  I hope to see that in a Maple in the near future.

Hello Acer, thanks for your very helpful response.  It solves my immediate problem.

I attempted to extend your examples by querying indets(G,'specfunc(:-ORIENTATION)') in order to get the plot's current orientation but it just returned the empty set.  I did "lprint(G)" to see G's contents but apparently there is no orientation information in it.  Is there some other trick to extract a 3D plot's orientation information?

I know that normally one can read the orientation angles theta, phi, and psi in Maple's toolbar.  Unfortunately that toolbar is not available when Maple displays an animation.

Rouben

First 93 94 95 Page 95 of 95