C_R

3627 Reputation

21 Badges

6 years, 136 days

MaplePrimes Activity


These are replies submitted by C_R

@acer

Thank you for your detailed answer. I appreciate it very much.

Comparing the two elliptic integrals of the previous and this question reveals important differences. With delayed evaluation using ‘ ’ fsolve immediately evaluates numerically (which is the purpose of fsolve). What amazes me is the difference in computation time that changing the integration variable makes from the previous integral to the integral of this question. I did not realize this when you first demonstrated this.

Without delayed evaluation fsolve throws an error in one case and in the other it attempts to solve the integral symbolically, which is unsuccessful without key assumptions. This case “runs forever”, finally returning after 15 minutes the following unevaluated:

Concerning operator calling sequence in a call to plot:
In ranges_as_assumptions.mw f(x__0) in a plot call worked as well.  Plot seems to be smart enough not to evaluate x__0 as a name which is not the case for fsolve (without delayed evaluation).

Unapply vs assuming inside fsolve:
The approaches are equivalent in the sense that they both use successfully the method ftoc for symbolic integration to provide an expression that fsolve can process very efficiently. Therefore, I believe that these approaches are preferable to a delayed evaluation (at least for the cases we have discussed here).

However, I don’t know how exotic the cases are and if they would justify an enhancement of fsolve. That’s why my question was about whether fsolve could try to use ranges (or intervals) as assumptions for symbolic evaluation before applying numerical methods. This could be done implicitly (fsolve gets smarter as plot did in the past years) or explicitly with an option.

What I do not understand: Why does fsolve not treat f(x__0) as plot does (i.e. delay evaluation and avoid x__0 being evaluated to a name)? This could be an additional enhancement of fsolve.

@Scot Gould 
Yes, fsolve was updated according to fsolve,details and efficiency must have been one of them.

By the way, solve can solve the integral with an appropriate upper bound

((2*sqrt(alpha) = int(1/sqrt(sin(x__0) - sin(x)), x = 0 .. x__0)) assuming (0 < x__0 and x__0 < Pi/2))

 

@Scot Gould 
Thank you. This is inline with my "discovery" above. I have tried this unsuccessfully in the past.

Do you have any idea why delayed evaluation

g := alpha -> fsolve('f(x__0) = 2*sqrt(alpha)', x__0 = 0 .. Pi*1/2*0.9);
g(2);

does not work in the original problem inverse_function_with_fsolve.mw

@Preben Alsholm 
I am glad that I have asked. Your way of using unapply gave the hint what was missing in my function definitons.
Unapply seems to be better in the sense that an evaluation takes place.

@alexsid 

When the toolbar disappears, can you make the menu buttons reappear by moving the mouse over the toolbar?

I have been doing this for quite some time (since Maple 2021 at least). In my case, only the 7 or 8 left keys disappear, and this happens rarely and is not reproducible.

I use a AMD graphic card.

I pasted what you have send. Maybe there  are some hidden 2d characters in your Maple worksheet that cause the error.

@Carl Love 

In principle, you are right.

However, the contact elements I am discussing are massless which means that they only describe the geometry of the contact. In Maplesim other components with mass and innertia have to be added if this is relevant for the application.

@Carl Love @Preben Alsholm 

Q1: The menu offers radio buttons (a channel at the time) which either allow to select the SI system or chose a unit.

I checked with Wikipedia/SI: It could be that only derived units (as radian m/m) are offered.

Degrees are "permitted non-SI unit". I will make a software change request that arcdeg are offered becaue they are very common in daily live and its more likely that users want to convert from radians to arcdeg.

Q2: It's a use error. I found out the I have to enter the unit first before changing the channel ("enter unit"). Otherwise this happens

The flow from right to left (first  fill in the unit) is unusual. I will suggest to change this.

With right click on a tab one gets for example "updates,v2023" with can be inserted in a hyperlink or used in a command Help(updates,v2023)

@Olesen 

If I understand correctly. Where normaly

can be seen it's empty? This would be new to me. Did you try these buttons as well?

 

@Carl Love 

u and u(phi) corrected in Maple 2023

@Carl Love 

Maybe not the same root cause, because this question is still partly open.
I will therefore delete the tag doublicate-question.

@acer

An excellent way to learn typesetting details.

@nscheng 
This should help you get started with Maple MathML tags

@nscheng 

This site for example enables you to generate MathML code.

Unfortunately, the code can’t be used straight away, because Maples typesetting tags only roughly correspond to MathML tags (see here under exports and here for MathML).

If you execute

with(typesetting);

you get an overview of the MathML elements (all starting with an m like mi and mo) that can be used in Maple.

My idea of using a MathML editor was based on the fact that Maple can interpret MathML when copied from an editor. It can, but “only” in the way that MathML is converted to 2d-Math (which renders not as you wanted). There is no option “paste as Maple typesetting tags”. (This would be in combination with an external editor a way to avoid MathML typesetting via coding).

The only way I can think of that a MathML editor can help you is the following.

  • Edit an expression as you desire in an editor.

 

  • Investigate the MathML code for used elements (like mo, mi, msup, …) and html codes for characters (starting with &#). Pasting the code here helps structuring the elements in separate code lines.
  • Enter the used the elements as Maple tags the way mmcdara described it.

I hope this helps a bit.

First 56 57 58 59 60 61 62 Last Page 58 of 72