acer

32303 Reputation

29 Badges

19 years, 305 days
Ontario, Canada

Social Networks and Content at Maplesoft.com

MaplePrimes Activity


These are replies submitted by acer

I see the same thing in my Maple 2024.2 for Linux.

It doesn't appear when I place focus on an output with units, and I instead get a long Java exception error to my launching console.

It seems to work ok in my Maple 2024.1.1 for Linux.

@scottwr In your original code you re-assigned to name y at the various stages. That seems to indicate that the original sampling (empirical distribution, [1..6]) isn't needed after it's used.

But in that case, could you not just generate a sample of the empirical distribution [-1,1] right off?

Is this whole operation to be repeated, possibly with different weights?

Do you actually need integer values, or will the floats -1.0,1.0 do? If floats would serve (and if the plot is the main thing) then a hardware double-precision float Matrix could be constructed to contains the numeric results. That might alleviate some overhead in the plot drivers.

What's your target size N? How fast do you need it all to be?

Optimizing the process may depend on such requirements. 

@mmcdara I'm still a bit hazy on the conditions, sorry. I'm not sure what kind of examples are supposed to return `false`.

When you write "powers" do you mean only posint exponents -- excluding fractional and negint exponents?

Does "function" mean function of an unassigned name, ie. not any standard math call? (See additional examples, and choices for K type.)

typefunc_ex_feedback_ac.mw

It is not necessary to hard-code all the module local names, for use in Grid:-Set.

One can do it programmatically, dynamically.

restart;

kernelopts(version);

`Maple 2024.2, X86 64 LINUX, Oct 29 2024, Build ID 1872373`

A := module()
  local DEBUG_MSG::truefalse:=false;
  local OTHER:=foo;
  export work_proc:=proc(n::integer)
     print("My flag is ", DEBUG_MSG, OTHER);
  end proc;
end module:

kernelopts(opaquemodules=false):

S := subsindets({op(3,eval(A))}, `::`, (L)->convert(lhs(L),`global`)):
S := map(u->parse(cat("A:-",u)), eval(S,1));

{OTHER, DEBUG_MSG}

Grid:-Set(0, A:-work_proc, op(eval(S,1)));
Grid:-Run(0, A:-work_proc,[ 0 ]);
Grid:-Wait();

"My flag is ", false, foo

A:-DEBUG_MSG := true:
A:-OTHER := blech:

Grid:-Set(0, A:-work_proc, op(eval(S,1)));
Grid:-Run(0, A:-work_proc,[ 0 ]);
Grid:-Wait();

"My flag is ", true, blech


Download grid_set_module_local_2.mw

This seems like quite a muddle, using the original condition with or without some extra assumptions on the names.

For fun, I throw in a crude, small utility that handles these two examples, but of course is not intended as general purpose; it's just a very short demonstration of concept.

(I'm more concerned about wrong results than FAILS.)

restart;

kernelopts(version);

`Maple 2024.2, X86 64 LINUX, Oct 29 2024, Build ID 1872373`

cnv := ee->Or(map(s->ifelse(nops(s)>1,And(s[]),s[]),
                remove~(evalb,[solve(ee)]))[]):

 

cond := x*z=0;

x*z = 0

is( x*y*z=0 ) assuming cond;

false

is( x*y*z=0 ) assuming cond, x::real, z::real;

false

is( x*y*z=0 ) assuming real, cond;

FAIL

cond2 := cnv( cond );
lprint(%);

Or(z = 0, x = 0)

Or(z = 0,x = 0)

is( x*y*z=0 ) assuming cond2;

true

 

cond := expand(x*(z-1)^2)-x=-x;

x*z^2-2*x*z = -x

is( x*y*(z-1)=0 ) assuming cond;

false

is( x*y*(z-1)=0 ) assuming cond, z::real, y::real;

FAIL

is( x*y*(z-1)=0 ) assuming cond, x::real;

false

is( x*y*(z-1)=0 ) assuming cond, x::real, y::real

true

is( x*y*(z-1)=0 ) assuming real, cond;

true

cond2 := cnv( cond );
lprint(%);

Or(x = 0, z = 1)

Or(x = 0,z = 1)

is( x*y*(z-1)=0 ) assuming cond2;

true


Download is_eq_solve.mw

In your very recent Update notes you wrote, "By passing in the name of the whole module A, now nodes are able to see all module A local vaiables."

But that does not seem to be true. You can do it by using Grid:-Set on the fully qualified module-local name. But your note about passing just the module name works for module exports, which are not declared as module locals.

Your original Question specifically mentioned module locals, and the original examples were about such. Later, (but not the first "Update") you changed to all module exports.

My Answer shows one way it can be done for your original module local example.

@FZ Your image still shows an instance of beta(t), when you assign to B.

Is the right-panel (context-panel) open in your Maple GUI? Is the behavior different, if you collapse it?

@svida Did you keep a copy of that file?

Maple will have created a new one for you, now, in that same location. But I'd be interested to see the old one, if you happened to have kept/renamed it...

@Ali Guzel  The worksheet "lesson 22" is a little outdated.

The author mentions that the ODE isn't solved in Maple 9.5, if both Initial Values are supplied, and then does a step-wise solution after supplying just one initial condition.

notes:
i) The full ODE (with both IVs) is solved in Maple 16.02, Maple 2018.2, Maple 2024.2,
    and more. It can be done as,
         dsolve({diff(y(x),x,x)=(1+diff(y(x),x)^2)^(1/2)*alpha,y(0)=a,D(y)(0)=0},y(x));
So the lengthy step-wise workaround approach is needed any more. See attachment.

ii) In the case of multiple results from dsolve it might be nice to mention
    (even if only briefly) which is chosen to go along with positive alpha, and why.

This attachment has a few (marked, and unmarked) edits.
lesson22_Suspended_Wire_acc.mw

@Ali Guzel  Thanks.

ps. Please don't (!) respond to spam postings. If they have no replies then as moderator I can remove-as-spam and deactivate the submitter.

@Ali Guzel  You're very welcome.

I'll try and look up the author Heck and send him my edits, in case they are of use to him.

This site does't allow .maple attachments to download properly. But if you can attach a .zip file of Doug Meades workbook then I can probably find time to look it over.

These two authors' Maple books are some of the best.

@zenterix Your first call like,

   simplify( expr, {...} )

is an example of so-called simplify with side-relations.

It might sometimes seem convenient if that action were also to do all other, more usual simplifications. But it would in fact be bad if that always happened; it would be too heavy-handed. There would be no good & easy way to prevent the followup simplifications, in cases where they were not wanted.

There are several targeted simplifications which need to be able to act quite individually. There are similar general needs for targeted/restricted manipulations for convert/combine/expand.

@Joe Riel This would also pick up any files having as extension any of the other 6 permutations allowed by that syntax.

So it doesn't select only the .pdf and .dvi files in general.

@Andiguys Make your new data lists all the same lengths.

First 13 14 15 16 17 18 19 Last Page 15 of 591