acer

32348 Reputation

29 Badges

19 years, 330 days
Ontario, Canada

Social Networks and Content at Maplesoft.com

MaplePrimes Activity


These are replies submitted by acer

@Vrighty If you are typing in the expression in x from scratch then you can do this to obtain a procedure:

  f := x -> 5 + x;
  f(5);

If the expression comes as the result of another calculation (say, the result of calling procedure blah, or solve, etc) then you can use unapply to obtain a procedure. You cannot use the arrow notation directly in this case and have it all work properly.

   f := unapply(blah(x),x);
   f(5);

You cannot use the syntax f(x):=... and get it all to work properly, regardless of whether you start entering all the expressions by hand or if they arise as the results of computations.

Or you could use an expression and 2-argument eval (as I alluded to earlier):

  f := 5+x;
  eval(f, x=5);

You just wrote, "In the past, I have... Everything works just fine. I expected, if I do the same, I will get the same result...".  The problem is that the worksheet makes syntax mistake after another. It is almost all done completely wrong. There are even parts which work because two later mistakes just happen to accomodate a prior one. But eventually it all tumbles down and becomes unworkable. It is riddled with statements like this, which are having effects,
   F(x) := F(x);
...
   F(k) := F[k];
...
   F(x) := subs(x=y+c,F(x));

Procedures are created but then only ever used by calling them with their named parameter, which makes many more steps or much more complicated syntax than needed.

The best solution is to rip it all out and start again using only expressions. A smaller amount of corrections that will allow you to proceed along your path without it all becoming unworkable is as I suggested in my posted edits. (You could get rid of the initial unapply calls where expressions are first defined, yes. But you have to either use unapply or expressions and eval throughout, for the many instances of the other cases, and you cannot work it practically with the mis-used remember table assignments and indexed references.)

The posted document is one of the most muddled I've ever seen. That's OK, we all had to learn somewhere. But I find your resistance to suggestion alarming, given the severity of the muddle.

I cannot for the life of me understand why at least two people up-voted the question.

I changed a recent submission by you from Post to Question. Please don't submit usage queries as Posts. (But that one wasn't a draft -- it had already been submitted, albeit incorrectly.)

You should be able to see tabs/links that point to all your Questions/Posts/Replies.

@dingtianlidi Hmm. Perhaps it is a bug. You could ask support@maplesoft.com

You have not told us explicitly which version of Maple nor which Operating System you are using.

On my Maple 2019 for Linux the user-defined Tasks get put in a Help Database file like
    ~/.maple/2019/tasks.help
Perhaps on your OS there is a similar file. Eg, on MS-Windows it might be under either C:/Users/yourID or wherever kernelopts(homedir) reports.

Have you tried using the command DocumentTools:-RemovePaletteEntry ?

 

@Carl Love This site is running an old and outdated version of MapleNet as on its back-end server.

I have requested -- several times over many years -- that this site's back-end server be updated, in particular for this gridlines problem (which was purportedly fixed in more modern MapleNet, in consequence of one of my reports long ago).

I've also asked that the inlining of .mw worksheets use a better graphic export for plots than JPEG, which is why inlined plots look so poor. Any update should utilize PNG export (though even GIF would look much better than present).

Over the years I've sometimes asked nicely and I've sometimes asked brusquely -- that doesn't seem to make a practical difference.

@kfli You said that you run that code a "bazillion times".

But presumably you don't run all that code many times, since you've included the call to Compiler:-Compile. So, I suppose you call cProduct_3DC many times. I asked earlier how that has to be done, and I suspect that still matters. Is there a reason that you cannot supply complete code to reproduce, or at least code that calls Product_3DC several times?

Could you supply a summation formula and description for what Product_3DC does?

@djc That's what I suspected. Thanks. I know someone else using Windows 10 who can reproduce that. A bug report has been submitted.

@kfli You haven't provided any details at all about your example, so it's very difficult to make constructive comments.

Is it a very quick/short command which you call a great many times? If so, do you have to call it sequentially, or can you suppy a float[8] Vector of input values and do many at once?

Is it (possibly) many different procedures and all must be compiled and run?

Are you using the in-memory LLVM or the gcc? (This might not be germane to your issue, but I am hunting for information.)

It sounds like you are seeing the overhead of the external-call process, which for a very small procedure may be significant compared to the overhead of direct execution.

Arguments passed from Maple must go through some degree of conversion, even scalar HFloats and float[8] rtables. If you could combine many together (in a single call with Vectors/Matrices of arguments) then that overhead could be mitigated.

I cannot say more, because you haven't given us anything to work with.

You haven't indicated how complicated the boundary might be, in the worst case. Is it partially self-obscuring? If so then you might be able to accomplish some kind of (crude) volume rendering with transparency. Perhaps see this old post.

@djc Does the following return true for you?

e := (a or b) and (not a or not b) and (a or not b);
SMTLIB:-Satisfiable(e);

Upload and attach your full code (eg. in a .mw worksheet).

@Stretto I see, you just need an animation inside Maple.

I thought you wanted to export to a movie file, because I read this -- literally -- in your Question's title, "create movi".

You might Explore a call to IterativeMaps:-Bifurcation, or any procedure which returns images. And you can use an option to have that "play" the images in succession. (There's an example of that in the
  ?examples,Explore
page, using Mandelbrot.)

But the play-rate is determined by how quickly the images are generated. So if Bifurcation computes them slowly then you may need to compute them up front, store in a table, and then Explore calls to a short procedure which simple picks them off that table using argument i::posint.

I would have to poke around, to discover inefficiency in Bifurcation, and unfortunately I don't have time for that this week, sorry,

I converted your query from a Post to a Question.

Why do you submit every single query as a Post, instead of a Question? It is inconsiderate and impolite, since you've been politely asked about this several times.

I changed the Product from "Maple 16" to "Maple 2016", since that's the version in which your attachment was last saved.

I recall doing something like that for myself, a long time ago. I'd have to dig out the details.

In the meantime, perhaps you could supply the basic information of your Maple version and Operating System? If you do then I shall adjust the headings of this Question accordingly.

I get results true and false, respectively, for your two examples. I'm using 64bit Linux.

First 186 187 188 189 190 191 192 Last Page 188 of 592