acer

32490 Reputation

29 Badges

20 years, 7 days
Ontario, Canada

Social Networks and Content at Maplesoft.com

MaplePrimes Activity


These are replies submitted by acer

If you are using the green up-arrow and the Upload button in the popup dialog then you also need to use either the Insert Link or Insert Contents button within that same popup dialog.

What point is being made by this posting that would not be more appropriate as further discussion of this previous thread started by the same person?

@C_R This is somewhat misleading because you are using 2-argument eval which does a substitution. That is significantly different from the OP's approach of using actual assignment of the parameters, and 1-argument eval merely as an attempt to force re-evaluation.

There are lots of ways to get the desired result, and you've shown one. That is fine. But what you've stated is not an explanation of the OP's issues.

And your statement, "If you want to use eval you have to load the Standard package." is false. The substitution approach that you showed for Units:-Standard also works for Units:-Simple.

restart; interface(version)

`Standard Worksheet Interface, Maple 2023.0, Linux, March 6 2023 Build ID 1689885`

(1)

`α__1` = arctan(l__1*sin(alpha)/(l__1*cos(alpha)+l__2))

alpha__1 = arctan(l__1*sin(alpha)/(l__1*cos(alpha)+l__2))

(2)

l__1 = 50*Unit('mm'), l__2 = 40*Unit('mm'), alpha = 120*Unit('arcdeg')

l__1 = 50*Units:-Unit(mm), l__2 = 40*Units:-Unit(mm), alpha = 120*Units:-Unit(arcdeg)

(3)

with(Units)

Automatically loading the Units[Simple] subpackage
 

 

eval(alpha__1 = arctan(l__1*sin(alpha)/(l__1*cos(alpha)+l__2)), [l__1 = 50*Units[Unit](mm), l__2 = 40*Units[Unit](mm), alpha = 120*Units[Unit](arcdeg)])

alpha__1 = arctan((5/3)*3^(1/2))

(4)

NULL

Download Units_simple_not_simplified_ac.mw

Please stop posting completely separate new Question threads on this example.

Instead, add your close followup and related queries on this example to one of your earlier Question threads on it.

Try to fully characterize precisiely what you're trying to accomplish, and what would be acceptable to you as a solution.

Please stop posting completely separate new Question threads on this issue.

@minoush82 Please stop posting completely separate new Question threads on this topic.

You wrote, "specific width", and you also wrote, "10 characters".

But ten characters does not have a specific width in general, if you're not using a fixed-width font.

Please don't spawn a completely separate new Question thread for this.

You could add your followup details here.

If you have followup queries or additional details about this example then please add them here instead of spawning wholly separate new Question threads.

@zenterix 

As I wrote, it is tricky to do programmatically in general.

The act of trying grid=[1000,1000] strikes me as a bad idea, since it'd place a large burden on the GUI's 3D plot renderer which also allows things like manual rotation, etc.

@Carl Love I also turned off "Check for Updates" and anything else in the Network tab. Since I did that (last week) I didn't see a hang.

However, it's also possible that someone might have fixed a misbehaving backend server.

@Carl Love Thanks.

This is slightly simpler syntax,

plots:-display(
 plot3d(f, x=-1..-y^2, y=-1..0),
 plot3d(f, x=-y^2..0,  y=-1..0),
 plot3d(f, x=0..y^2,   y=-1..0),
 plot3d(f, x=y^2..1,   y=-1..0),
 plot3d(f, x=-1..-y^2, y=0..1),
 plot3d(f, x=-y^2..0,  y=0..1),
 plot3d(f, x=0..y^2,   y=0..1),
 plot3d(f, x=y^2..1,   y=0..1));

You could try this if..then inside an init file.

restart;

kernelopts(version);

`Maple 2023.0, X86 64 LINUX, Mar 06 2023, Build ID 1689885`

if convert(kernelopts(version),string)[7..12]="2023.0" then
  __foo := ToInert(eval(IntegrationTools:-Indefinite:-Stage2)):
  unprotect(IntegrationTools:-Indefinite:-Stage2):
  IntegrationTools:-Indefinite:-Stage2:=FromInert(subsop([5,11,2,2,1,2]=_Inert_EXPSEQ(_Inert_INTPOS(5), _Inert_STRING("Stage2"), _Inert_FUNCTION(_Inert_ASSIGNEDNAME("sprintf", "PROC", _Inert_ATTRIBUTE(_Inert_EXPSEQ(_Inert_NAME("protected", _Inert_ATTRIBUTE(_Inert_NAME("protected"))), _Inert_NAME("_syslib")))), _Inert_EXPSEQ(_Inert_STRING("computed an answer with an unevaluated evalat or intat %a"), _Inert_LOCAL(3)))),__foo)):
  __foo:='__foo':
  protect(IntegrationTools:-Indefinite:-Stage2):
end if:

int((b*g*x+a*g)^2/(A+B*ln(e*(b*x+a)/(d*x+c))),x);

int((b*g*x+a*g)^2/(A+B*ln(e*(b*x+a)/(d*x+c))), x)

showstat(IntegrationTools:-Indefinite:-Stage2,25);


IntegrationTools:-Indefinite:-Stage2 := proc(f, x, $)
local fnames, a0, ans, p, num, den, other, exparg, ff, nonstdfnames, handler, func;
       ...
  25       IntegrationTools:-Utils:-Userinfo:-PrintInfo(5,"Stage2",sprintf(
             "computed an answer with an unevaluated evalat or intat %a",ans))
       ...
end proc
 

Download Stage2_subsop.mw

@nm It might not appear on subsequent calls due to remembered results.

I can try and construct at ToInert, subsop, FromInert fix that could be put in an init file.

For what it's worth, you could also use method=risch or method=elliptic in Maple 2023.0.

(Using method=_RETURNVERBOSE shows the undefined arising from method=default, although it's not obvious what programmatic flow that takes here.)

Have you submitted a bug report?

First 82 83 84 85 86 87 88 Last Page 84 of 594