Robert Israel

6577 Reputation

21 Badges

18 years, 217 days
University of British Columbia
Associate Professor Emeritus
North York, Ontario, Canada

MaplePrimes Activity


These are replies submitted by Robert Israel

showstat(`evalf/exp`) is not that enlightening.  For floats, at sufficiently low settings of Digits, Maple just passes the computation off to evalhf, which uses the floating-point hardware of the system.  To see how exp is implemented there, you'll have to ask Intel, not Maple.  If Digits is too high to use evalhf, you want to look at `evalf/exp/general`. 

 

Only for a top-level statement does ":" or ";" control whether or not printing occurs. 
For statements nested within a loop, they are equivalent.  This has nothing to do with printlevel.  Thus

for i from 1 to 2 do
  a: b;
end do;

will print both a's and b's, while

for i from 1 to 2 do
  a: b;
end do:

will print nothing.  If you want to print some things but not everything, it's best to use explicit "print" statements.

Only for a top-level statement does ":" or ";" control whether or not printing occurs. 
For statements nested within a loop, they are equivalent.  This has nothing to do with printlevel.  Thus

for i from 1 to 2 do
  a: b;
end do;

will print both a's and b's, while

for i from 1 to 2 do
  a: b;
end do:

will print nothing.  If you want to print some things but not everything, it's best to use explicit "print" statements.

I agree. But if there is some special structure, there may be better ways to discover such a structure than by grinding out the characteristic polynomial.

One thing you might try is substituting some fairly small more-or-less random integers for the symbolic parameters and looking at the characteristic polynomial for this special case, which should share any structure that the general case has.  If you find such a structure, there will probably be simpler ways to show that this occurs in general.  For example, if the characteristic polynomial is lambda^4 - a, the fourth power of your matrix will be a times the identity matrix.

 

I agree. But if there is some special structure, there may be better ways to discover such a structure than by grinding out the characteristic polynomial.

One thing you might try is substituting some fairly small more-or-less random integers for the symbolic parameters and looking at the characteristic polynomial for this special case, which should share any structure that the general case has.  If you find such a structure, there will probably be simpler ways to show that this occurs in general.  For example, if the characteristic polynomial is lambda^4 - a, the fourth power of your matrix will be a times the identity matrix.

 

If that's really what the equation is, it's trivial: the difference of the two sides of the equation factors as

y' (y''' - 1)

so there are two cases: y' = 0 and y''' = 1.

If that's really what the equation is, it's trivial: the difference of the two sides of the equation factors as

y' (y''' - 1)

so there are two cases: y' = 0 and y''' = 1.

The characteristic polynomial of a 4 x 4 matrix is a quartic.  In the absence of some special structure (e.g. it is reducible, or is a composition of two quadratics), the symbolic solution would require substituting the (already very complicated) formula for the coefficients of the quartic into the rather complicated general solution of the quartic.

> _EnvExplicit := true:
    solve(a*x^4 + b*x^3 + c*x^2 + d * x + e = 0, x);

The result would be a nightmare.  So you really don't want to use that explicit formula.  The characteristic polynomial will be bad enough. 

If a 4 x 4 matrix has entries which are each composed of 60 terms, then in the absence of simplification
the determinant (i.e. the constant term of the characteristic polynomial), written out in full, would have 4! * 60^4 = 311040000 terms.  You'd need an awful lot of memory to store such a monstrosity.  Perhaps you should re-think why you need a symbolic expression for the eigenvalues.

The characteristic polynomial of a 4 x 4 matrix is a quartic.  In the absence of some special structure (e.g. it is reducible, or is a composition of two quadratics), the symbolic solution would require substituting the (already very complicated) formula for the coefficients of the quartic into the rather complicated general solution of the quartic.

> _EnvExplicit := true:
    solve(a*x^4 + b*x^3 + c*x^2 + d * x + e = 0, x);

The result would be a nightmare.  So you really don't want to use that explicit formula.  The characteristic polynomial will be bad enough. 

If a 4 x 4 matrix has entries which are each composed of 60 terms, then in the absence of simplification
the determinant (i.e. the constant term of the characteristic polynomial), written out in full, would have 4! * 60^4 = 311040000 terms.  You'd need an awful lot of memory to store such a monstrosity.  Perhaps you should re-think why you need a symbolic expression for the eigenvalues.

Aargh... still some solutions missed, because in taking _C2 -> infinity you could have _C1 -> infinity as well.

Here's the latest file.

View 4541_runge.mw on MapleNet or Download 4541_runge.mw
View file details

A very alarming and bizarre notion, that it would alter the file.  Do you have any evidence that this was the case?
If it was, a cure should be simply to replace the altered license file with a backup copy (which is a good thing to have in any case).  But I recently upgraded XP to SP3, and had no problems with Maple 11 or 12.

A very alarming and bizarre notion, that it would alter the file.  Do you have any evidence that this was the case?
If it was, a cure should be simply to replace the altered license file with a backup copy (which is a good thing to have in any case).  But I recently upgraded XP to SP3, and had no problems with Maple 11 or 12.

Oops: some solutions seem to have been missed, namely

a(t) = a0/(1-a0*t), b(t)=b0/(1-a0*t)

This is the limit of the solution returned by dsolve as _C2 -> infinity.  I'll have to edit the file...

... and here it is:

View 4541_runge.mw on MapleNet or Download 4541_runge.mw
View file details

In that post I was looking for RK4 to give the exact solution with a particular step size.   I did not dream that there were nontrivial examples where it works for all step sizes, so I didn't look for them.

More and more interesting: I think I can characterize all first-order linear DE's that have this property.  I'll try to write it up in a blog page.

First 120 121 122 123 124 125 126 Last Page 122 of 187