Rouben Rostamian

MaplePrimes Activity


These are replies submitted by Rouben Rostamian

@nm Regarding the two differential equation
diff(y(x),x)^2 + y(x)^2 = 1
in my previous message, I must point out that of Maple's solutions y=1, y=−1y=sin(x+c) and y=−sin(x+c), the last two are actually the same sin(x+Pi)=−sin(x).

Furthermore, there are infinitely many other solutions that one may piece together from those. For instance, the colored part of the diagram below represents a solution of the differential equation:

Similarly, in the case of the second differential equation
y(x) = x*diff(y(x),x) + 1/2*diff(y(x),x)^2
whose solutions are y=x^2/2 and y=cx+c^2/2, we may produce infinitely many other solutions by piecing together the graphs of the regular and singular solutions, as shown here:

This latter example has an interesting implication — it allows solving a two-point boundary value problem such as
y(−2)=ay(+2)=b
for reasonable choices of a and b.  This is rather unusual since the equation is of the first order!

@nm Since you are curious about such issues, you may be interested in looking at Maple's solution of
diff(y(x),x)^2 + y(x)^2 = 1
and seeing how you would go about obtaining that by hand.

Once you are done with that, look at this more challenging one:
y(x) = x*diff(y(x),x) + 1/2*diff(y(x),x)^2

 

@Carl Love After dropping the eval:
 

plots:-animate(
   plots:-arrow,
   [p, ptan, width= 0.3, length= 4], s= 0..3,
   background= plots:-spacecurve(p, s= 0..16*Pi, color=red)
);

 

@Carl Love The purpose of the OP's example of the Determinant outside of the proc is to demonstrate that the definition of Determinant is confined to the proc, i.e.., it does not leak.

 

@ecterrab Regarding your suggestion for reorganizing the casesplit help page, I am afraid that's too far beyond my realm of knowledge for me to be of help there.  I don't even know what "differential elimination" means, and that appears to be central to what casesplit does.  Nevertheless, a few examples that I have seen of the uses of casesplit indicate that it's a valuable tool and deserves to be brought to the Maple users' attention.

@ecterrab Thanks for your responsiveness to this and all other issues that are brought to your attention.  You are an invaluable asset to Maplesoft.

 

As Christian Wolinski has already noted, changing sec to seq fixes the error.  But your observation about leakage from the Physics package is real.  This is demonstrated in this minimal example.

restart;

diff(x(t),t);

diff(x(t), t)

doit := proc()
  uses Physics;
end proc:

After executing the proc above, the typesetting form of the output changes.  It shouldn't.

diff(x(t),t);

diff(x(t), t)


 

Download mw.mw

@Carl Love Thanks for your detailed explanation.  In the last couple of days I had been working with C code where arrays are accessed as M[i][j]. When I wrote the equivalent code in Maple, I just copied the M[i][j] without thinking.

The following further illuminates what you have said:

 M := Matrix(3,3);                                                            
                                   [0    0    0]
                                   [           ]
                              M := [0    0    0]
                                   [           ]
                                   [0    0    0]

> M[1] := <a,b,c>;                                                             
                                          [a]
                                          [ ]
                                  M[1] := [b]
                                          [ ]
                                          [c]

> M;                                                                           
                                 [a    b    c]
                                 [           ]
                                 [0    0    0]
                                 [           ]
                                 [0    0    0]

 

@Christian Wolinski I've been staring at this for the last half hour and couldn't see it :-(

Thanks!

 

@nm You wrote:

y''= y-(y')^(1/2)
And if we try to square both sides, or raise to any power, there will remain a term y' with non integer power on the right side. Hence degree is not defined.
 

You may rearrange that equation into (y')^(/1/2)=y-y'' then square both sides to get rid of the fractional exponent.  The degree of the resulting equation may be 2 or may be undefined, depending precisely what is meant by the degree.

I remain unconvinced of the usefulness of the concept of the "degree of a differential equation" but that's a different story.

@Carl Love Thanks for your note regarding *.mpl versus *.maple.

The Maple code that you have shown does not make much sense, and it is difficult to guess from it what it is that you really want to do.

I suggest that instead of showing Maple code, just state your mathematical problem clearly in words or equations. Then someone should be able to show you how to translate that statement into code.

 

@Kitonum That's clever.  A thumb up!

@Kitonum I suspect that he wishes to get 

I don't know of a short way of getting there.

@dharr In a spearate thread here, the OP asked the same question and I provided a solution that agrees with his expected answer.  The main reason for discrepancy between your solution and his is that there is a typo in his PDE.

First 48 49 50 51 52 53 54 Last Page 50 of 101