Carl Love

Carl Love

28075 Reputation

25 Badges

13 years, 76 days
Himself
Wayland, Massachusetts, United States
My name was formerly Carl Devore.

MaplePrimes Activity


These are replies submitted by Carl Love

@brian bovril You haven't set up the distance matrix correctly. In the paper, read very carefully the first two sentences after the graph on page 43. Note how the main diagonal entries are defined differently. This means that in your Maple Matrix, the first superdiagonal is completely wrong. The main diagonal from the paper should become the first row of your Maple Matrix. This being a real-world problem, there can be no violations of the triangle inequality.

I'm convinced that both problems can be easily solved in Maple by exhaustive search. Use Iterator:-SetPartitionFixedSize to step through the partitions. For the first problem, use 7 blocks of size 2. There are only 135,135 such partitions. For the second problem, use 4 blocks of size 3 and 1 block of size 2. There are only 1,401,400 such partitions. For each block of size 3, there are 3 permutations to check (because reversing a permutation must give the same distance). But there are many repeats of the size-3 blocks! There are only 364 possible 3-blocks. For each of these, find the min of its 3 permutations and store this in a remember table.

So I expect the first problem to take about 10 lines of Maple code, and the second problem about 15. I'll be able to work on this after I sleep some.

@vv If the partitions are generated using Iterator:-SetPartitions and processed one at a time, then the memory usage will be trivial. I'd guess that once that memory issue is addressed, processing 28 million partitions wouldn't take an unreasonable amount of time. However, I haven't had a chance to try this yet.

Since the distance matrix violates the triangle inequality, yet the distances are so precisely specified (all to 3 significant digits), I wonder where this problem comes from.

Also, would you please state the problem in (mathematical) English rather than just showing Maple commands?

@shatha Yes, let's ignore the case of resonance for now. It's just as unlikely to happen as the coefficient matrix A being singular.

As you can see above, your pictures didn't come through. I'm going to send you a private email so that you can reply and send me the pictures directly.

@shatha Okay, now we're getting somewhere. You're trying to solve a system of differential equations by using the Poincare-Dulac Theorem (see this Encyclopedia of Mathematics article) to derive an iterative algorithm. I will change the title of this Question to reflect this, unless you object. Now please write your system of differential equations in standard mathematical notation and post them here.  DO NOT attempt to write them as Maple code. Then write an overview of the algorithm, in standard mathematical notation. Then write out the first several steps of the application of the algorithm to the particular system of differential equations at hand. Do not attempt to write any of this in Maple code!

You misspelled a word that I couldn't figure out. In the phrase "it is beuase deuation of dgree three", I can't figure out the word "deuation". What is it?

In your first line of code, the Matrix contains the symbol i. I can't figure out what you mean by that. Is it an integer iteration index?

Is your goal to solve a particular system of differential equations? Or is it to write a procedure to apply this Poincare-Dulac method in general?

@tomleslie You're absolutely right,Tom, about sequencing presenting a completely different situation with respect to the timings. Sorry that I forgot to include that case. Indeed, my first thought upon awakening this morning was that I had forgotten it.

This may seem counter-intuitive at first, but if you assign values to D__0 and R with assignment statements (using :=), then you guarantee that D__0 and R cannot appear in any subsequent results returned by Maple.

You are confusing moderators with administrators. You and I are both moderators. Moderators don't have the power to remove the material that you're referring to, but administrators do.

But, yes, I wholeheartedly agree that those accounts should be removed.

@vv I think that it's a (recent) bug that execution groups may have several prompts, and that it's been discussed here before. The extra prompts are very annoying when I've encountered them in others' code. I have never directly opened a .mpl file. I've always either read the file or copy-and-pasted it, so I've never experienced the problem directly.

@brian bovril I changed it to an Answer, and now you can upvote. You also have the power to change (others') Replies into Answers and do other editing.

By the way, there's also a very easy but crude way to remove the 5s: subs(5= NULL, P). Somehow this is distasteful to me, but I can't say exactly why. The (remove~)~ feels like removing the 5s with a micro-scapel controlled by a robotic arm; the subs feels like removing them with a leaf blower.

@Elisha The entire code for a for-do-od loop, including the od (or its equivalent: end do) must be in a single execution group. That means that you must use Shift-Enter rather than Enter to separate the lines of code. There should be no ">" prompt at the beginning of any line other than the first.

If you have a new algorithm (Adomian) for solving ODEs, you should compare it to the best algorithms currently in use. RK4 has been superceded (decades ago) by Runge-Kutta-Fehlberg fourth-fifth-order method (RKF45). This is what is used by default by dsolve(..., numeric) for an IVP.

@tomleslie I wouldn't call the computer-performed translation of a file from one only-readable-by-computer format to another an "update". Only the format is changed, not the content. Like, if a hardbook is released in paperback, you wouldn't call it an updated edition.

@gtbastos Why doubt? It's easily done. See help for the commands LinearAlgebra:-Modular:-RowReduce and LinearAlgebra:-Modular:-MatBasis.

@asa12 You can use sort for this purpose:

sort(Statistics:-Tally(["1","1","2","2","2","77"]), (a,b)-> lhs(a)<lhs(b));

That'll work in your Maple 12. In modern Maple, it can be simplified to

sort(Statistics:-Tally(["1","1","2","2","2","77"]), key= lhs);

Why do you want to use 4th-order Runge-Kutta (RK4) rather than any of the numerous other more-modern methods that Maple offers that have dynamic error control?

You can get RK4 via

dsolve(..., numeric, method= classical[rk4]);

First 361 362 363 364 365 366 367 Last Page 363 of 709