dharr

Dr. David Harrington

5931 Reputation

21 Badges

19 years, 270 days
University of Victoria
Professor or university staff
Victoria, British Columbia, Canada

Social Networks and Content at Maplesoft.com

Maple Application Center
I am a professor of chemistry at the University of Victoria, BC, Canada, where my research areas are electrochemistry and surface science. I have been a user of Maple since about 1990.

MaplePrimes Activity


These are replies submitted by dharr

@Madhukesh J K You did not ask for a particular method before, and as my worksheet shows, Maple's default method works perfectly well. It found one of the second solutions, so it is up to the task of finding the "dual solutions". If you put in close enough approximate solutions, you will get what you want, but at this point your knowledge of the solutions and what they look like is key to moving forward.

@ogunmiloro The message is clear - there are only 13 eqns. You have missed ODE11.

@pik1432 FYI, rather than using j:=I to make j into sqrt(-1), use interface(imaginaryunit=j); This will also change the display from I to j.

solve has an option "useassumptions" which tells it to use the assumptions. Strange I know. In my version of Maple, then there is a warning that it may not respect the real assumptions, and the computation goes for a long time; longer than I was willing to wait.

@mmcdara You say "On the link  https://www.mapleprimes.com/help/moderation there is no mention of a moderator's right to edit another person's response," but that is not my reading of it - it says "please be *very* careful when editing someone’s message," and speaks about "being able to edit your own messages as well [my bold]". I agree it is open to abuse, but as I said that tends to be rare. You need a reputation of 500 to get to moderator, and although that really says nothing absolute about one's ethics, it probably does imply some dedication to the community. I am assuming that if some impoper editing happens, and Maple is made aware of that they can restore a message from a backup.

I'm not in favour of asking an OP if they want to allow a change, since this would allow them to leave copyrighted or offensive material up. I think in many cases where questions and followup answers have suddenly disappeared it is done by the original poster, who has got the answer to their assignment and now wants to remove the evidence of academic misconduct. Sometimes questioners complain, but mostly that is explained by duplicate or similar questions.

- and yes, I was not serious in my comment about your "transgression" since I knew you were being cautious.

@nm To make a bug report, just use the Mapleprimes "more" tab and choose "submit software change request"

@saher There is a PDE in your worksheet that you solve with pdsolve. So if that's not what you want you will need to be more specific about what exactly you want to do.

You used invElziki when it was defined as invEl, but I really don't understand what you want to plot. Your Elzikisol is a function of x that returns something with y in it. So you need to specify y before you can do a 2D plot. Not clear why you are plotting this twice. Perhaps you want a 3D plot?

pde_elziki.mw

@Amir Saman Mir Not sure what happened; I get the right answer.

restart

invEqs := [a[3]*cos(theta[1]+theta[2]+theta[3])+a[2]*cos(theta[1]+theta[2])+a[1]*cos(theta[1]) = px, a[3]*sin(theta[1]+theta[2]+theta[3])+a[2]*sin(theta[1]+theta[2])+a[1]*sin(theta[1]) = py, theta[1]+theta[2]+theta[3] = phi]

[a[3]*cos(theta[1]+theta[2]+theta[3])+a[2]*cos(theta[1]+theta[2])+a[1]*cos(theta[1]) = px, a[3]*sin(theta[1]+theta[2]+theta[3])+a[2]*sin(theta[1]+theta[2])+a[1]*sin(theta[1]) = py, theta[1]+theta[2]+theta[3] = phi]

q := [solve(invEqs, {theta[1], theta[2], theta[3]}, explicit)]

Two solutions - try each below - both give the same answer for cos(theta[2])

nops(q)

2

We want cos(theta[2])

c := simplify(eval(cos(theta[2]), q[1]))

(1/2)*(-2*cos(phi)*px*a[3]-2*py*sin(phi)*a[3]+px^2+py^2-a[1]^2-a[2]^2+a[3]^2)/(a[2]*a[1])

In terms of qx and qy

simplify(eval(c, {px = qx+a[3]*cos(phi), py = qy+a[3]*sin(phi)}))

(1/2)*(qx^2+qy^2-a[1]^2-a[2]^2)/(a[2]*a[1])

NULL

 

Download theta.mw

@tarik_mohamadi NullSpace(R1) leads to nonzero entries for only entry 5 and 7, showing that columns 5 and 7 are multiples of each other.

Determinant.mw

@lemelinm Sorry, I don't really understand what you are asking. You wanted Maple to do it automatically, and it does. You must have i<>j to fit a polynomial - if you had two y values for the same x value then it is not a function, and it cannot be a polynomial. If you try the i=j case, with two x values the same, then Maple correctly produces an error.

Interpolation of higher order polynomials will not be unique and they will tend to oscillate, so that is usually not useful.

You can construct your l_i(xi) by, for example

n:=4:i:=3:mul((xi-x[j])/(x[i]-x[j]), j in {$1..n} minus {i})

 

@ogunmiloro If you want values every 0.1 you can just set up a loop:

sim_plot.mw

@MPM2357 This is great - the bug has been fixed in 2021.0. I was using 2017. Note the general solution you got has sin(Pi*n*(r-1))=sin(Pi*n*r), but Maple 2017 got sin(2*Pi*n*r), I should have looked more carefully at your output before I ran the worksheet. So your general solution was the sum over n of sol4 (eq8), so you could start from that point directly. 

@Pepini Even without the IC there is no general solution. I think abs is a problem here. Perhaps there are some manipulations that could be done, like separating into magnitude and phase, but you probably need to know where you are headed.

The line assigning to pe is incomplete - it ends in ^

First 37 38 39 40 41 42 43 Last Page 39 of 61