emendes

440 Reputation

6 Badges

8 years, 19 days

MaplePrimes Activity


These are replies submitted by emendes

@acer Many thanks.   I could not find the slider in the first option.  I can see the controls but not the slider. 

The second option, there is no slider (as you said).  

The third option has everything I need.  Many thanks.  

 

 

 

@acer Many thanks. Great alternatives that I can easliy follow. 

 As I said that was the first time I tried to use plots in Maple.   Although, after the alternatives, a plot is created I could not see a slider (or something like that) that I can use to change the values of a.  Am I missing something here?   

 

@Carl Love Many thanks. 

@Carl Love Many thanks.    

  • The way to delay the evaluation is to use single quotes, right?
  • I agree, it is definitely awkward.  The use of a function is way more elegant.
  • I could not figure out how to change a (that is, there is no animation).

 

My wish has to do with Grid and Threads packages:

1) Efficient usage of memory -   Once a grid command finishes the memory allocated should return to Maple (I am not sure whether this is possible or not). There is a post in the list showing that, in some calculations using Grid, Maple hangs for no apparent reason.

2) A clear explanation in the help files (examples) on which variables should be Grid:-Set and which don't.  (Although I have received help from tops users on the list and from maple support, the answers are not the same in some cases).

3) CodeTools:-ThreadSafetyCheck - Some of the functions that are threadsafe checked by this command causes Maple to hang.  Is the list of threadsafe functions updated?  

@Kitonum Many thanks.   I can't believe I have missed allsolutions.   

@nm Many thanks.   The problem I am experiencing is definitely very similar to what you have described but there is a twist.  In my case, even though I left the job running overnight, maple did not move to the next iteration.  Perhaps I will have to wait longer to see if Maple goes to the next iteration, but I don't have the patience.  I wrote the code having in mind this issue, so it is very easy for me to kill the job and restart it from where it stopped.    

Another issue that bothers me is Grid memory demand.  From one iteration to the next, Grid does not seem to release the memory used in the previous iteration and demands probably the same amount of memory on top of the used one. That forces me to again kill the job and restart it from where it stopped. 

 

@nm and @Carl Love I have a similar problem when I use Grid with timelimit to be sure that Maple won't get stuck in any of the calculations.   Somehow Maple hangs in one of the loop iterations without any warning (all 36 cpus go from 100% to 0% and the allocated memory sits there until I kill the job - I am using the command line instead of the usual interface).   If the job starts from scratch there is a good chance that Maple will hang at the same point (the job takes two or three days to finish so I cannot be 100% sure).  Fortunately, the job can be started from the previous iteration and, when it does  Maple won't hang at the same point. 

Maple 2020.1 on Linux (with plenty of memory left).   

@Carl Love Many many thanks.  Thanks to you and @acer the part of try-catch in my code is working as intended (and much faster).   However, I am still struggling with Grid demands for memory.  

@acer Many thanks.  I think I have now a better understanding of how to use try-catch

@Carl Love Many many thanks.  I wasn't sure of when finally should be used.  Now I know that I didn't need it at all.   Thanks.   

Would catch: #any other error be the answer for the errors I mentioned in my answer to @acer?  

Just to be sure, if I have the following sequence of commands

try
  .... #line 1
  .... #line2
  .... #line3 

  ... #line4
  catch:
     .....
     return:
end try:

1) If there is an error, catch will caught it, right?  

2) If there is an error in line 2 for instance, all commands in line3 to line 4 will not be evaluated, right? 

If the answer is yes to both questions, I am making things more complicated than they are. 

 

@acer Thank you for the clear explanation.   I am trying to follow all suggestions given in your reply.  

Please bear with me a little longer.  Could you send some examples of what you meant by "one or more flags, ...,  etc.", please? 

Although I have added more catchStrings to catch

catch "time expired", "does not exist", "invalid input":

some errors were not caught: 

Error, (in PolynomialSystemSolvers:-PseudoResultant) at offset 3101 in `RootOf.m`, time expired


Error, (in SolveTools:-MakeSolutions) at offset 3 in `:-40706.m`, time expired

 

I guess that answers your question, that is,  the error message upon time-out does not always begin with "time expired".  How to deal with it?  

 


 

@Carl Love You are right.  Thanks.   Last question: infolevel[Grid:Seq]:=3:  shows quite a few messages but infolevel[Threads-Seq]:=3 does not.  What am I missing?  

@Carl Love Many thanks for the clear explanation.  

Unfortunately, Threads does not work after Grid in the examples I am running (I will try the option of saving the results to a file and call the procedure in a separate mpl-file).  As for Grid I need some help. If I change seq to Grid:-Seq in both cases, Maple issues an error msg.  If I change the internal seq, memory goes up to the roof.  

 

 

@Carl Love Many many thanks. I wonder if you could spare some time to explain the procedures.  

  1. Why do I need [seq]?  (The brackets ?)
  2. local _?  
  3. ^+?  

Can Threads or Grid be used here?   As you know I have problems using Threads after Grid (Maple keeps evaluating forever).   I had to use Grid before using the procedures given above (PolynomialSystem is part of the previous calculation).  

 

5 6 7 8 9 10 11 Last Page 7 of 20