Carl Love

Carl Love

28015 Reputation

25 Badges

12 years, 294 days
Himself
Wayland, Massachusetts, United States
My name was formerly Carl Devore.

MaplePrimes Activity


These are replies submitted by Carl Love

Your example clearly shows to me that you're strictly interested in the number of characters per line without regard to any typographical niceties such as not beginning lines with commas or the physical width of the output (in, say, milimeters). This of course makes your request quite easy to fulfill for any specific output, but I don't know of any Maple technique to post-process all worksheet output. I've often wanted something like that. I think that it'd be quite easy for Maplesoft to provide such a mechanism; it'd be as simple as allowing a `print/...procedure to apply to all output. It should then be up to the user to program in exclusions for, say, plot output, which'd be trivial to do if the particular post-processing isn't wanted for plots.

Regarding the specific example that you showed, did you explicitly intend to remove the spaces that ordinarily come after commas?

@vs140580 I think that the following idea can help for your reformulated Question, although I haven't yet figured out all the steps for a proper algorithm.

My idea is based on the powers of the adjacency matrix, say A. For any nonnegative integer k, the [i,j] entry of A^k is the number of walks of length exactly from vertex i to vertex j. So self-returning walks always appear as nonzero diagonal entries of A^k for some k. (For this problem, we don't care about that actual value on the diagonal, only that it's not 0.) The main thing that I haven't figured out yet is how to know that all vertices are included in the walk.

As I've said to you before, Maple's type processing (which is used by indets), is purely syntactic and doesn't consider semantics such as mathematical definitions; and this is the way it has always been and must be. Incorporating mathematical semantics is of course possible, but it must be built on top of the syntactic type system. I don't see how it could possibly be otherwise.

@mmcdara Thanks for your correction and especially for your pedagogically excellent and well-presented counterexample. Unfortunately, I've never seen a proper formal definition of cycle basis, so my Answer was based on guessing. If "basis" means what it usually means in math, then I'd expect that all cycles could be generated from the cycle basis via some relatively easy computation (such as unions and intersections). Since your example only has one member containing 5, I don't see how that works. Do you know how to get the cycle [3, 4, 5, 6, 8] from your basis?

I see now that under the OP's reformulation of the Question, cycle bases won't be useful for its Answer. However, I'd still appreciate any teaching that you can give regarding the issues that I mentioned in the first paragraph.

@Carl Love Perhaps the symbolic solution that you actually want is a singular solution that can't be expressed as any instantiation of a generic symbolic solution. By instantiation I mean an assigment of numeric values to some parameters. Here's an example:

#2x2 matrix and 2x1 vector. 5 parameters (a, b, d, x, y). The 2 decision variables are
#unseen and unnamed in this pure matrix-vector form. Their values are the two entries 
#in the solution vectors S0 and S1.

A:= <a, b; 0, d>;  B:= <x, y>;

#Get a generic solution:
S0:= LinearAlgebra:-LinearSolve(A, B);

#Instantiate 3 parameters (a, d, y) to 0 and solve again:
S1:= LinearAlgebra:-LinearSolve(eval([A, B], [a, d, y]=~ 0)[]);

#Note that no possible instantiation of S0 can produce S1.

 

@Carl Love Let's suppose that there theorethically exists a symbolic solution S such as you seek regardless of our ability to find that solution. So, I mean "exists" in the idealized Platonic sense. Then S could easily be used to generate any numeric solution N. But, of course, there are numeric methods that could be used to find an approximation to N (without knowing S) that use much less computation. If you can't find any suitable numeric solutions, then IMO it's a waste of effort to search for S. So, look for approximate numeric solutions first.

@MaPal93 I just reread this entire thread, and I noticed that you never really answered my first question: Why do you think that there's a solutionAnd what makes you think that the computation is "stuck" rather than proceeding in a correct manner with a very lengthy process?

I haven't yet looked at your most-recent attachments.

@sursumCorda It's not strange at all. There is no bug in `simplify/sqrt/function`. An error message tells you what procedure was executing when the presence of a bug (from any location) was detected. It doesn't tell you where in the code the bug is.

@C_R The OP's title suggests (to a small degree) that they believe this to be a Maple 2023 new bug.

There's no need to use $ in any form; F~(list1, list2) works fine.

@zenterix Maple's 2D plot command has some fairly sophisticated options (discontfdiscont) for handling discontinuities. These can use both symbolic and numeric techniques, and I think better results are usually achieved symbolically. As far as I know, there's nothing like that currently available for 3D plots.

Larger grids generally provide "diminishing marginal returns". In other words, one quickly gets to a point where the plot's improvement isn't worth the additional computation. Using a 1000x1000 grid for this plot means 24-million numeric values computed, which is likely above your display's resolution. Maple's kernel can easily handle the initial computation of these, but the GUI has trouble moving and positioning them.

@acer As is usual with Maplesoft, the absence of any official response is quite disturbing. Even an official response just saying "We are aware of the existence of the problem. We are investigating. We will keep you updated." would be comforting. 

@acer FWIW, I did your suggested Options setting, and it seems that the problem has disappeared. So, I 🗳  👍 

@acer I vote up for this Answer also, and I'm surprised at how "tight" and unragged you managed to get it with the default grid values.

@Rouben Rostamian  It's an impressive work, Rouben. I wish that I could give this Answer a 2nd Vote Up.

First 57 58 59 60 61 62 63 Last Page 59 of 708