C_R

3412 Reputation

21 Badges

5 years, 315 days

MaplePrimes Activity


These are questions asked by C_R

When executing the attached work sheet, the output

changes to

Why is that (local seetings maybe?) and how to reproduce the former, more compact output?

Copy-pasted from the wonderful:

Advanced Engineering Mathematics

Dr. Robert J. Lopez

Emeritus Professor of Mathematics

Maple Fellow

© Maplesoft, a division of Waterloo Maple Inc., 2023

This is obtained in Maple by writing the differential equation

 

q := diff(x(t),t) = k*(40 - 16/18*x(t))*(8 - 2/18*x(t));

diff(x(t), t) = k*(40-(8/9)*x(t))*(8-(1/9)*x(t))

(1)

 

and solving via the syntax

 

X := simplify(rhs(dsolve({q,x(0)=0},x(t))));

(-360+360*exp((8/3)*t*k))/(8*exp((8/3)*t*k)-5)

(2)

 

The differential equation is actually separable, and can be solved with the techniques of elementary calculus discussed in Section 3.1.

 

If an observation provides the data that at time t = 1 there were 6 grams of water, then the constant of proportionality k can be computed.  In Maple, the data point gives the equation

 

eq := eval(X, t=1) = 6;

(-360+360*exp((8/3)*k))/(8*exp((8/3)*k)-5) = 6

(3)

 

whose solution is

 

K := solve(eq,k);

(3/8)*ln(55/52)

(4)
 

 

Download Output_formated_with_rational_factor_.mw

On the corresponding Modelica page I find

Since MapleSim 2024 now has been upgraded to Modelica 4.0 (which I appreciate very much by the way - Thank you), I was wondering if I could give this libraray a try?

I am looking for simple ways to set up digital controllers in the context of developement of code for micro-controllers. From the github page:

Furthermore, in sublibrary Controller about 20 input/output blocks of linear systems are provided that are based on the different representation forms, e.g., PID, StateSpace, Filter blocks. A unique feature of these blocks is that it is very convenient to quickly switch between a continuous and a discrete block representation. Also, templates are provide to quickly built-up standard controller structures. 

I was about to convert -1 to exp(I*Pi).

First try by intuition

convert(-1, exp);
                               -1

False intuition. Next try by right click on -1 and consulting the context pannel: -> nothing that rings a bell

Entering a complex number 0.5000000001 + 0.8660254037*I to see if that changes something

-> something but no exponential form
                          

Next: AI assitant

->   OK, I know this. -> refine query

Polar, of course!

convert(-1, polar);
                          polar(1, Pi)

Not what I want. Maybe

convert(convert(-1, polar), exp);
                               -1

Next -> Ask for help in MaplePrimes whether there is a command

I have tried to understand why ODESteps cannot find a solution for cases where an ODE can separated into a polynomial expression and an ODE.

or example, when I trace like this

restart;
trace(Student:-ODEs:-ODESteps:-ModuleApply);
printlevel:=10;
Student:-ODEs:-ODESteps:-ModuleApply(x*(diff(y(x), x)) = 0);
printlevel:=1

trace is tracing an unknown procedure

and not showing any further details of this procedure.
What unknow function/procedure is traced?

Can, in this particular case, the message "Cannot compute integral"   be traced (it’s not an error message, which are traceable).

I have tried to increase printlevel which reveals some unkown procedures but did not get down to this one. Hence my questions.

In the example below, the second call to simplify is ineffective

eq := (a*x + b)/(c*x + d) = 1;

`simplify/nodenom`:= x -> (numer@(lhs - rhs) = 0)(x);                       
                      
`simplify/nodenom`(eq);
simplify(eq, nodenom);

Why is that?
Convert, for example, works

`convert/nodenom`:= x -> (numer@(lhs - rhs) = 0)(x);

`convert/nodenom`(eq);
               
convert(eq, nodenom);

 

First 15 16 17 18 19 20 21 Last Page 17 of 44