sand15

842 Reputation

13 Badges

10 years, 250 days

MaplePrimes Activity


These are answers submitted by sand15

@maple2015 

 

Very optimistic of you to say it would take at least 10 minutes !
(it took more than 1.5 hour to me)

 

A hint (sorry I can't provide you the Maple code for a network to network transfert problem)

  1. Comment your last "Determinant(KFF)" line and deplace it by
    DetKFF := z -> Determinant(evalf(subs(P=z, KFF)));
  2. To have an idea of what DetKFF(z) looks like do
    plot('DetKFF(z)', z=0.01..5)
    Do not forget the quotes !
  3. It seems (zoom on the plot) that there is a first root around 0.15.
    Execute
    fsolve('DetKFF(z)', z=0.1)
    You should get the answer  0.16999...

 

It'is impossible to hope finding a root of Determinant(KFF).
Since the computation of it is extremely time consuming (I killed the command before it ended).

Other hints:

  1. do not try to start fsolve from z=0 (singularity for z=0)
  2. if you have a close look to the plot near z=0 you will find numerical oscillations: they can avoided by increasing the value of "Digits" (to the detriment to the efficiency of plot and fsolve).



BTW: I did a little mistake in the numerical values

node 1 = (0,0)

node 2 = (0,1)

node 3 = (5,6)

node 4 = (6,6)

I keep using Maplets (quite unusual by these days), and I suggest you to try TextBox.
The idea is to create your own "InputDialog" with a TextBox inside (you can use the Maplet assistant for this). 
Unfortunately I do not have MAPLE right now and I can't provide you a piece of code to whow how to proceed.
Let me know if still encounter problems and I will send you something later.
 

I keep opened this question for any other person who could face this same problem.

Here is the solution in the case MyNewList contains the list of elements to add to MyList

DO NOT USE   Maplets :-Tools :-Set(DDB(itemlist)=MyNewList)

BUT
for k in MyNewList do
   Maplets :-Tools :-Set(DDB(appenditem)=k)
end do;


The bold-written restriction above can generally be bypassed by a proper definition of MyList and of MyNewList

Hope this can help even if the Maplets seem old-fashioned

Hi,

I use maple 2016 on a Windows 7 PC.
I provide tou a screen capture of the Maple code (I can't upload a file by using the green arrow).
First thing : change search(...) text by StringTools:-Search(...)

PS : don't worry about the name of the file : the first test I made was saving x := [ evalf[10](Pi) ]

I may be mistaken, but it looks like you want to compute quantiles at regular intervals ???

If it is the case, the following may help you
(after loadings of the suitable packages)

q := i -> Quantile(GammaDistribution(4.5/100, 2.5), 1/(2*(N+1))+1/(N+1)*i, numeric) + 0.068

[Seq(q(i), i=1..(N-1))]

 

Note 1 : with Maple 2015 (Windows 7) your code returns me a "connection to server failed"

Note 2 : the sequence [seq(q(i), i=1..(N-1))]  runs very quickly : using Threads does not seem necessary

Note 3 : the CDF is a non decreasing function of its argument, and even here a strictly increasing one. As a consequence there should be only one solution to the "solve( (1/(2*(N+1))+1/(N+1)*i)=cdf(x),x)" command of yours.
In practice, for a reason I do not know, this command returns many solutions, some real and others complex (probably the reason for which you load the RealDomain package ?).
Using "Quantile" prevents these spurious solutions.

I cannot provide you the piece of code I have written for computer-related problems
But what I did is sufficiently simple for me to give you a sketch of it

Step 1 :

EasySys := {diff(v(t), t)=0, diff(h(t), t)=w(t), siff(w(t), t)=0}  # if I am not mistaken
EasySol := dsolve ( EasySys, {v(t), h(t), w(t)})                       # which can be done manually

Step 2:

HarderSys := {diff(x1(t), t)=v(t)*cos(h(t)), diff(x2(t), t)=v(t)*sin(h(t))}
HarderSys := subs(EasySol, HarderSys):
HarderSol := dsolve(HarderSys, {x1(t), x2(t)})                        # easily found too

FullSol := EasySol union HarderSol;

I am not certain it is the solution you were searching for (no numerics here)
Probably someone will provide you a clever solution

Hope I helped

try  printf("%g\n",p) to add a carriage return and printf("%g\n\n",p) to skip a line after the print

1 2 3 4 5 6 Page 6 of 6