Alejandro Jakubi

MaplePrimes Activity


These are replies submitted by Alejandro Jakubi

@nm 

Macsyma (now Maxima), the ancestor of Maple, does have a construct named block. It looks like Maple's procedure derives from it.

@Carl Love 

Certainly, the use statement is resolved at automatic simplification time, what makes it both a lighter and more limited alternative. I wonder what the Ada feature looks like.

@nm 

Yes, that help page could improve about examples. But you could see such example in the Programming Guide, Chapter 6 Procedures, 6.6 How Procedures Are Executed > Statement Sequence Interpretation > Variable Evaluation Rules within Procedures. This particular chapter is worth reading.

@nm 
Keyword parameters were introduced in Maple 10 (2005), see ?updates,Maple10,programming .

@PatrickT 

Actually this move was part of the 2010 plan: item Change style of forums to a question/answer format in Bryon's post linked earlier. In my opinion, it was one of the worst errors of that plan, literally killing the discusion spirit that characterized this site along its early years, and marking the start of its decadence. Remarkably, Bryon admired and copied the worst side of stack sites, like the competition for anonymous votes, but did not copied their best side, like MathJax typesetting.

 

@Christopher2222 

This is another example of the GUI rigidity problem. Maple has a vast user base with most diverse requirements and preferences. And a monolithic, unconfigurable design cannot address properly their needs.  These are just two recent examples of requests for alternative key bindings:

key bindings and acceptance of automatic key presses

Is there a way to recall/repeat previous commands using a shortcut?

Note that several comments are missing in the first linked thread (I have a complete version archived).

@Axel Vogt 

By the change of variables x= -exp(-w)+Pi, the branch point is not avoided, but just shifted to infinity. Certainly, with this change, the divergence shows simpler. Yet, the option continuous has to be added to get a result (by the method improper):

> J:=Int(sin(x)^cos(x),x= 0 .. Pi):
> IntegrationTools:-Change(J,x= -exp(-w)+Pi);
                  infinity
                 /
                |                      (-cos(exp(-w)))
                |          sin(exp(-w))                exp(-w) dw
                |
               /
                 -ln(Pi)
> int(op(%),continuous);
                                    infinity

@Axel Vogt 

Indeed, the log term shows it:

> MultiSeries:-series(sin(x)^cos(x), x= Pi,3);
            -1   /                 Pi                \                      2
  - (x - Pi)   + |- 1/6 + 1/2 ln(------) - 1/2 ln(Pi)| (x - Pi) + O((x - Pi) )
                 \               Pi - x              /

@Markiyan Hirnyk 

Certainly, the algorithms implemented in MultiSeries:-series typically handle better than series cases with multiple asymptotic scales, as needed here. Is this what you mean?

@Markiyan Hirnyk 

It holds csgn(x)=+/-1, see ?csgn. So, (-1)^csgn(...)=-1. Nevertheless MultiSeries:-series gives it more clear:

> MultiSeries:-series(sin(x)^cos(x), x= Pi,2);
                               -1           1
                     - (x - Pi)   + O(ln(--------)) (x - Pi)
                                              x
                                         1 - ----
                                              Pi

@Carl Love 

Just a link so that all people here could see the difference...

There was an earlier thread on this issue.

Today I have had a surprise about the case of missing comments. This thread contained several comments of mine and racoon at October 8 2013 (I have a text version in my archive). But nowadays, as you can see, there is no comment of mine any longer. Nevertheless my subscription to this thread remained as I have received an email notification of the comments of today by ilke.

@Axel Vogt 

A matrix is an array of objects. It 'may' represent a linear map. But also it may represent a vector, as in this case.

@Markiyan Hirnyk 

This is another issue that occurs earlier in the computation. Discontinuities in the summand are checked before going into solving for its roots. In the OP's case, it is found that the summand is "continuous" for the interval 3..infinity:

> trace(solve):
> trace(iscont):
> P := Product(cos(Pi/k), k = 3 .. infinity):
> value(P);
memory used=1.1MB, alloc=30.3MB, time=0.07
{--> enter iscont, args = cos(Pi/n), n = 3 .. infinity, closed
                                 Open := false
                                    x := n~
                                     a := 3
                                 b := infinity
                                    sba := 1
                                   ds := {0}
                                  disc := {0}
                                   r := true
                                     d := 0
                                   inds := {}
                                    sb := 1
                                    sa := -1
<-- exit iscont (now in product) = true}
{--> enter solve, args = cos(Pi/n), n, AllSolutions
...

While, for the symbolic lower limit case n..infinity, the code has no clue about the order relation between 0 and n:

> trace(solve):
> trace(iscont):
> product(cos(Pi/k), k = n .. infinity);   
{--> enter iscont, args = cos(Pi/n), n = n .. infinity, closed
                                 Open := false
                                     x := n
                                     a := n
                                 b := infinity
                         sba := -signum(-infinity + n)
                                   ds := {0}
                                  disc := {0}
                                   r := true
                                     d := 0
                                   inds := {}
                                    sb := 1
                                sa := -signum(n)
                                   r := FAIL
<-- exit iscont (now in product) = FAIL}
product:   "Cannot show that cos(Pi/k) is continuous on [n,infinity]"
First 25 26 27 28 29 30 31 Last Page 27 of 109