gulliet

256 Reputation

7 Badges

17 years, 308 days

Social Networks and Content at Maplesoft.com

MaplePrimes Activity


These are replies submitted by gulliet

Congratulations to Jacques and Robert. They deserve it and I am convinced that both of them will be on the short list for the annual prize (well, we have to wait a little before that, but the bets are open :-) Best regards, -- Jean-Marc
Hi, Reading your post, I have just released that inputs and outputs were not clearly delineated in my previous. Sorry about that. Indeed, the inputs are the first two lines only. The rest of the lines is the output, though it is a stylized version for whatever reason that come from the copy and past process. If you evalute the first two lines in a worksheet, you will see the "real" output in the form of meaningful Maple expessions. About the second point you mentioned, keep in mind that a Mathematica notebook is not necessarily a program. Say, we write some stuff about integration. The notebook is likely to mixed textual information, or explanations, in the form of text cells, and input and output cells that contains different types of integrals and their corresponding results after evaluation. In this case, converting a notebook is just a matter of looking for each input cell in turn and translating them in the corresponding Maple integration command. On the other hand, one or more user defined functions may occur in a given notebook or the notebook may be just a collection of such definitions (in this case we speak of package). I hope this clears up the confusion. Regards, -- Jean-Marc
Hi, Reading your post, I have just released that inputs and outputs were not clearly delineated in my previous. Sorry about that. Indeed, the inputs are the first two lines only. The rest of the lines is the output, though it is a stylized version for whatever reason that come from the copy and past process. If you evalute the first two lines in a worksheet, you will see the "real" output in the form of meaningful Maple expessions. About the second point you mentioned, keep in mind that a Mathematica notebook is not necessarily a program. Say, we write some stuff about integration. The notebook is likely to mixed textual information, or explanations, in the form of text cells, and input and output cells that contains different types of integrals and their corresponding results after evaluation. In this case, converting a notebook is just a matter of looking for each input cell in turn and translating them in the corresponding Maple integration command. On the other hand, one or more user defined functions may occur in a given notebook or the notebook may be just a collection of such definitions (in this case we speak of package). I hope this clears up the confusion. Regards, -- Jean-Marc
As far as I understand Maple, symbolic determinants are computed in a fully expanded form without simplification. In other words, asking for the determinant of a symbolic matrix will result in a non simplified polynomial (that is, assumptions such as a >= 0 are not taken in account during the computation of the determinant). For a dense matrix, the number of terms is n!. As an example, say we want to compute the determinant of the following 2x2 matrix with symbolic entries. It is easy to spot that the determinant is one for all x. However, the Maple command Determinant returns a fully expanded polynomial that we can simplify further by asking so (using the command simplify).
> with(LinearAlgebra);
> m := Matrix([[cos(x), sin(x)], [-sin(x), cos(x)]]);
                           Matrix(%id = 162941476)
> Determinant(m);
                                    2         2
                              cos(x)  + sin(x) 
> simplify(%);
                                      1
So, the polynomial generated during the computation of a dense symbolic 13x13 matrix is going to consume a lot of memory (proportional to 13! = 6,227,020,800). Moreover, keep in mind that the computational time is also asymptotic to n!. Therefore, increase the size of the matrix not only required a huge increase in memory but also in a huge increase in the number of arithmetic operations, dramatically increasing the time needed to get an answer. HTH, -- Jean-Marc
I would say 'no' (there is enough spams on comp.soft-sys.math.maple). To me, the main advantage of having a slightly moderated forum is precisely because spams and junks can avoided (or at least discarded in a reasonable time). Regards, -- Jean-Marc
Answering your question accurately is completely dependent of the structure and type of the matrix you have in mind. Is your matrix dense (few entries are equal to zero) or sparse (many entries are equal to zero)? A sparse matrix can be stored in a more efficient way with less memory consumption than a dense one. Is your matrix numeric or symbolic? (A numeric matrix contains only numbers.) If your matrix is numeric, is machine- or software-precision use? What is the size of the matrix? (In terms of determinants, going from a 11x11 matrix to a 12x12 matrix makes a huge difference.) Regards, -- Jean-Marc
It is not clear from your post what exactly the structure of the matrix is. The worst case scenario is a dense symbolic 13 by 13 matrix, that is a matrix with none (or nearly none) of its entries equals to zero and which entries are not numbers but symbols (such as a, b, or c) or, worst, symbolic expressions (such as sin(alpha) or cos(theta)). So why this is bad? Because, the determinant of such a matrix is a polynomial made of 13! terms, that is this polynomial has more than six billions of terms (6,227,020,800 exactly). Moreover, each individual term is a product of 13 variables. Combinning both numbers (and assuming the unrealistic assumption that any symbol does occupy only one byte in memory), you would need about 80 GB (~80 billions of bytes) of memory to hold the determinant. Therefore, it seems perfectly reasonable that Maple complains about the lack of enough available memory. If you can reduce the size of the matrix, say just for experimental purpose, you should be able to compute a 10x10 or even a 11x11 determinant. What you can do with the output is another story. The examples below are just to illustrate the patterns when computing a 2x2, 3x3, and 4x4 determinants.
> with(LinearAlgebra);

> Determinant(Matrix(2, 2, {(1, 1) = n[1, 1], (1, 2) = n[1, 2], (2, 1) = n[2, 1], (2, 2) = n[2, 2]}));

                      n[1, 1] n[2, 2] - n[1, 2] n[2, 1]

> Determinant(Matrix(3, 3, {(1, 1) = n[1, 1], (1, 2) = n[1, 2], (1, 3) = n[1, 3], (2, 1) = n[2, 1], (2, 2) = n[2, 2], (2, 3) = n[2, 3], (3, 1) = n[3, 1], (3, 2) = n[3, 2], (3, 3) = n[3, 3]}));

 n[1, 1] n[2, 2] n[3, 3] - n[1, 1] n[2, 3] n[3, 2] + n[2, 1] n[3, 2] n[1, 3]

    - n[2, 1] n[1, 2] n[3, 3] + n[3, 1] n[1, 2] n[2, 3]

    - n[3, 1] n[2, 2] n[1, 3]

> Determinant(Matrix(4, 4, {(1, 1) = n[1, 1], (1, 2) = n[1, 2], (1, 3) = n[1, 3], (1, 4) = n[1, 4], (2, 1) = n[2, 1], (2, 2) = n[2, 2], (2, 3) = n[2, 3], (2, 4) = n[2, 4], (3, 1) = n[3, 1], (3, 2) = n[3, 2], (3, 3) = n[3, 3], (3, 4) = n[3, 4], (4, 1) = n[4, 1], (4, 2) = n[4, 2], (4, 3) = n[4, 3], (4, 4) = n[4, 4]}));

   n[1, 1] n[2, 2] n[3, 3] n[4, 4] - n[1, 1] n[2, 2] n[3, 4] n[4, 3]

      + n[1, 1] n[3, 2] n[4, 3] n[2, 4] - n[1, 1] n[3, 2] n[2, 3] n[4, 4]

      + n[1, 1] n[4, 2] n[2, 3] n[3, 4] - n[1, 1] n[4, 2] n[3, 3] n[2, 4]

      - n[2, 1] n[1, 2] n[3, 3] n[4, 4] + n[2, 1] n[1, 2] n[3, 4] n[4, 3]

      - n[2, 1] n[3, 2] n[4, 3] n[1, 4] + n[2, 1] n[3, 2] n[1, 3] n[4, 4]

      - n[2, 1] n[4, 2] n[1, 3] n[3, 4] + n[2, 1] n[4, 2] n[3, 3] n[1, 4]

      + n[3, 1] n[1, 2] n[2, 3] n[4, 4] - n[3, 1] n[1, 2] n[4, 3] n[2, 4]

      + n[3, 1] n[2, 2] n[4, 3] n[1, 4] - n[3, 1] n[2, 2] n[1, 3] n[4, 4]

      + n[3, 1] n[4, 2] n[1, 3] n[2, 4] - n[3, 1] n[4, 2] n[2, 3] n[1, 4]

      - n[4, 1] n[1, 2] n[2, 3] n[3, 4] + n[4, 1] n[1, 2] n[3, 3] n[2, 4]

      - n[4, 1] n[2, 2] n[3, 3] n[1, 4] + n[4, 1] n[2, 2] n[1, 3] n[3, 4]

      - n[4, 1] n[3, 2] n[1, 3] n[2, 4] + n[4, 1] n[3, 2] n[2, 3] n[1, 4]
Regards, -- Jean-Marc
Hi Dan, I see what you mean. Unfortunately, at the moment I am working on a machine without Maple installed, so I cannot do any test. Nevertheless, I believe that if you set the number of tick marks to 40 rather than 20 in the given example, you should get all the tick marks displayed but not all the associated labels (because as you have noticed, they are sometimes too close to each other). I will test it when I am back to my machine later in the day. Regards, -- Jean-Marc
Hi Dan, I see what you mean. Unfortunately, at the moment I am working on a machine without Maple installed, so I cannot do any test. Nevertheless, I believe that if you set the number of tick marks to 40 rather than 20 in the given example, you should get all the tick marks displayed but not all the associated labels (because as you have noticed, they are sometimes too close to each other). I will test it when I am back to my machine later in the day. Regards, -- Jean-Marc
with(plots): logplot(10^n, n = 1..4); Regards, -- Jean-Marc
with(plots): logplot(10^n, n = 1..4); Regards, -- Jean-Marc
Right click on the plot; in the contextual menu select "Axes" -> "Properties" -> "Vertical Axis", then _uncheck_ the option "Let render choose tickmarks" and click on the radio button to select either "Number of tickmarks" or "Custom spacing". In the example below, the second plot is drawn with "Number of tickmarks" set to 20.

> Maple Equation

> Maple Equation

Maple Plot

> Maple Equation

Maple Plot

> Maple Equation

This post was generated using the MaplePrimes File Manager

View 97_logplot_tick_marks.mw on MapleNet or Download 97_logplot_tick_marks.mw
View file details

Right click on the plot; in the contextual menu select "Axes" -> "Properties" -> "Vertical Axis", then _uncheck_ the option "Let render choose tickmarks" and click on the radio button to select either "Number of tickmarks" or "Custom spacing". In the example below, the second plot is drawn with "Number of tickmarks" set to 20.

> Maple Equation

> Maple Equation

Maple Plot

> Maple Equation

Maple Plot

> Maple Equation

This post was generated using the MaplePrimes File Manager

View 97_logplot_tick_marks.mw on MapleNet or Download 97_logplot_tick_marks.mw
View file details

Good news: the "About" and "Help" pages are both now accessible again, regardless whether one is logged in or not. Regards, -- Jean-Marc
Yes, I finally did find what I was looking for, especially the
 tags that allow to keep the formating of some Maple outputs since the white spaces are not removed. For instance,

> solve({y = 10*x, y = 5*x-4}, {x, y});

                              /    -4        \ 
                             { x = --, y = -8 }
                              \    5         / 


Many thanks, -- Jean-Marc
First 12 13 14 15 Page 14 of 15