acer

32717 Reputation

29 Badges

20 years, 85 days
Ontario, Canada

Social Networks and Content at Maplesoft.com

MaplePrimes Activity


These are replies submitted by acer

@das1404 All Comments, Questions, and Posts on this site are public. You don't have to log in to view them.

Putting in a token link such as @das1404  into a response merely lets the reader know which previous Comment/Question you're addressing, and which member wrote it. Doing that doesn't cause the system to send a private message or email. (This site has a separate mechanism for sending a private message. And members get email notifications when threads in which they are active get additional content, but only if they set a Preference on their account.)

I'll try and check out your latest attachment, if nobody else fixes it up for you. But likely not before the weekend, sorry, I'm just too busy right now.

@Adam Ledger It's not too hard to produce that kind of infix display as output.

But the tricky bit is if you want the customised notation for typeset 2D math input.

Do you need input as well as output?

I believe that Maple 7 will produce a plot structure in which the first operand is a CURVES substructure.

But the operands of the CURVES substructure will not be an Array or a Matrix or even a listlist. Rather it may be a sequence of lists. Each of those lists will contain two lists, each representing a point by having two floats designating x and y values.

In other words, the line segments are represented separately within the CURVES substructure.

I'm not sure whether either (end) point of any outer list will necessarily agree with a point in a neighboring outer list (of the sequence) even though several of them may visually render like a continuous curve when they are all displayed.

This is my recollection, anyway.

If the OP uploads a worksheet with the implicitplot displayed then I could extract the data for examination (even without re-executing).

I could also mention that it's always been an issue that the fsolve command uses its complex option in two ways: 1) to specify that nonreal results can be obtained, and 2) to allow searching over nonreal values. So it doesn't provide a nice way to allow searching for purely real results while computing with complex domain values.

But for your particular example this will also work,

ee:=-2*sqrt(-K[1]^2+1)*K[1]+4*K[1]^2-Pi-2*arctan(sqrt(-K[1]^2+1)/K[1]):

fsolve(ee, K[1]=0.5-I..20+I, complex);

                          0.9832314847

And this would work too,

RootFinding:-Analytic(ee, K[1]=0.5-I..20+I);

                          0.9832314850

@Adam Ledger If you want to get a string then you could use a TextArea Component.

MAPLE_PLEASE_HELP_1.mw

@das1404 please keep followup questions that are so closely related as this to the same thread. 

@Jameel123 
 

NULL

restart

u := proc (x, t) options operator, arrow; 1/2+I*sqrt(2)/(exp(-t+x)+2*exp(t-x))+(1/2)*(exp(-t+x)-2*exp(t-x))/(exp(-t+x)+2*exp(t-x)) end proc

proc (x, t) options operator, arrow; 1/2+I*sqrt(2)/(exp(-t+x)+2*exp(t-x))+(1/2)*(exp(-t+x)-2*exp(t-x))/(exp(-t+x)+2*exp(t-x)) end proc

plots:-complexplot3d([Re(u(x, t)), Im(u(x, t))], x = -3 .. 3, t = -3 .. 3)

Download plot33_b.mw

Could you upload an actual worksheet using the green up-arrow in the Mapleprimes editor, rather than just showing us inlined images?

@vv I agree. I was thinking about the given example, rather than in general.

Perhaps better would have been to take the result from `solve` without fancy options, apply `simplify`, and then put that into a piecewise manually constructed to return NULL except for x in the stated domain.

The `real` option is related to the `parametric` option of `solve`. See ?solve,parametric for a help page. It's weird that sometimes it has an effect for input other than polynomial systems, and that no error message is emitted in cases where it will have no effect. (bugs that I've reported previously...)

Having said all that, the following is produced (in Maple 14, since the Question is marked for that) even without the `real` option.

restart;

kernelopts(version);

`Maple 14.01, X86 64 LINUX, Oct 15 2010, Build ID 535952`

simplify(solve({y>1,y<2,3^665/2^x=y}, {x}));

piecewise(y <= 1, [], y < 2, [{x = (665*ln(3)-ln(y))/ln(2)}], 2 <= y, [])

 

Download solve_res.mw

@ganelon Use the command evalf to approximate to floating-point.

@Jameel123 Yes, there are lots of ways.

Please tell us what you want.

Do you want a 2D or a 3D plot? Do you want a single shape which changes color? Or which changes with time as an animation?

Do you want a density plot whose color or hue or intensity vary with complex argument or magnitude?

Or a single surface where the height represents the real component and the shading represents imaginary component?

Or a 2D curve with horizontal and vertical values taking the real and imaginary values parameterized by the "x" in u(x,t), and the whole thing animated by the "t".

Or something else?

@tomleslie Is the link now fixed? [I corrected it.]

@Muhammad Usman It works for me using Maple 2015.2 on either 64bit Linux or 64bit Windows 7 Pro.

On Windows 7 I saved the file to my Desktop, so that the call to ExcelTools:-Import would look the same (except for our user names).

You might want to re-check the filename extension, so ensure that it is really "Employees.xlsx". The following ought to return true, if it's really there and named as you say.

FileTools:-Exists("C:/Users/Usman/Desktop/Employees.xlsx");

Perhaps someone else could try it.

Perhaps you could consider the point-release upgrade from Maple 2015.0 to Maple 2015.2.

What happens if you instead reference the file by its location explicitly when calling Import? Or if you change currentdir() to that file's location before calling Import?

I mean, where is it? Is it something like, umm, "C:/Users/Usman/Desktop/Employees.xlsx" or similar?

@Kitonum I wrote a procedure which searches for more compact representations and optionally informs me of the command which obtained the smallest result, under a supplied time limit. Trying various combinations of collect (with various simplifications on the coefficients) is one part of it.

It can be told to try other things too, such combination of actions like simplify, rationalize, radnormal, expand, etc., as well as combine restricted to various subsets of the trig terms and to a limited depth, and even applying a proc generated by codegen[optimize](...,tryhard) following unapply. It can use several metrics, such as length and `simplify/size/size` and LeafCount

I am hoping to find time to clean it up and add it to a modest package of utilities in the maplecloud.

First 264 265 266 267 268 269 270 Last Page 266 of 599