3728 Reputation

17 Badges

6 years, 26 days

MaplePrimes Activity

These are replies submitted by mmcdara


I had the same naive idea... whose main limitation is that the number of possibilities to examine is V!/C!/(V-C)! (V= number of vertices, C= connectivity number [28 for graph G2]).
Nonetheless I vote up.


Thank you acer. 

It hadn't occurred to me to remove the alias.


It's perfect.
If I understand correctly the key was to use the neutral Diff instead of diff in the definition of kin?

So I generalized what you said to a more complex problem which consists in buiding a single dof (degree of freedom) system equivalent, in a given sense, to a 2 dof system.

There still remain a little problem for more complex expressions of phi. as illustrated below

value(eval((Diff(Phi, t, t), Phi=psi))
                         / d  / d   \\
                       k |--- |--- X||
                         \ dt \ dt  //
value(eval(Diff(Phi, t, t), Phi=psi))
            /                              2    \
            |/ d  / d   \\          / d   \     |
            ||--- |--- X|| cos(X) - |--- X|  psi|
            \\ dt \ dt  //          \ dt  /     /

How can I get rid of psi and have sin(X) instead?

Thanks again.


Great !


I vote up!

Years ago, I coded the Winding Number method in Fortran. It was a nightmare because of the definition of the trigonometric functions and the precision of the calculations.
I'm stunned that it is (almost) that simple in Maple.

PS : I didn't tested your code but I imagine it could be caught off guard in some complex cases (possible examples: a crossed polygon, a polygonal domain whose boundary is traveled by turning alternately clockwise and counterclockwise, an edge aligned with the point whose position is checked)?

@Carl Love 

I always wondered why PolyhedralSets does not accept floating point coordinates?
Every time I use it, I have to convert the list of points to a list of rationals.
Is there an algorithmic reason for this? 

@Ronan answer and an a posteriori proof to @Carl Love claim

t1 := taylor(sin(x), x = 0, 10):
t2 := taylor(sin(x)*cos(x), x = 0, 10):

ratios := coeff~(t1, x, [seq(1..10, 2)]) /~ coeff~(t2, x, [seq(1..10, 2)])
                      [   1  1   1    1 ]
          ratios :=   [1, -, --, --, ---]
                      [   4  16  64  256]

# recurrence of the consecutive ratios:

genfunc:-rgf_findrecur(1, ratios, ratio, n);
                   ratio(n) = - ratio(n - 1)


@Carl Love 

Thanks, intersting remarks.

  • About the "continuity correction": you're right, I wrote my answer too quickly.
    I've planned to complete the test by a gaussian (or an exponential) approximation but it appeared that even for large values of n Probability seems to work correctly and that there is no need (?) to do something more.
  • Is "my" test "exact and simple"?
    In R the implementation of the binomial test is termed "exact", but the "exact" estimation of the confidence interval comes from a more complex formula binom.test.html.
    See also Binomial_proportion_confidence_interval (Clopper-Pearson interval, we can interpret from a bayesian point of view).
  • Finally "A lack of sufficient evidence for a hypothesis ..."
    I completely agree with what you say and I sacrificed to the "convention" to return only an accepted/rejected message. Wich is too simple a way to correctly describe what the test says.
    Far more convenient forms (And I suspect it's what you have in mind) are "the test doesn't provide enough evidence to reject the null hypothesis" and "the test provides strong evidence to reject the null hypothesis".
    Similarly, I had thought of returning a p-value, but there are actually so many misinterpretations about it that I decided not to do so.

PS: I wasn't aware of the name "binomial test" befor the OP asxed his question.
More generally, given a Binomial(n, p) random variable X and two probabilities alpha and beta such that 0 <= alpha < beta <= 1, it's just the problem of building the dispersion interval (not the confidence interval!) Quantile(X, alpha)..Quantile(X, beta) and look where some given value k is is situated with regard to this interval
Ignoring this could lead us to introduce as many test names as there are different distributions: geometric test, Pooisson test, unifotm test, ...


I suggest that you modify the procedure as follows

  lb   := floor(Quantile(B, beta)):
  ub   := ceil(Quantile(B, 1-beta));
  printf("Range of accepted values = %d..%d\n", lb, ub):

This reminds me of a problem I faced years ago. I believe the answer from the hotline was that plosetup (as some other commands) was not supported by the maple/cmaple online command

I am waiting for a more substantial answer from a more experienced member.

PS: Same error with Maple2015.2  on Mac OSX  (maple command)




I agree that the uniqueness of the linear combination makes the family free.
What is curious is that French Math Courses (FMC) generally present the things this way:

  1. definition of a free family f={v1, ...vN}
  2. definition of a generating family (every vector is a linear combination of elements if F [note there is no uniqueness here])
  3. definition of a basis : a free generating family.

But it's more seldom to read (FMC) that a basis is defined by "each vector is a unique combination ...).

If I'm not mistaken, I think I understood that you know a little French? I allow myself to give you this reference
Définition d'une base
A family of vectors of E is a basis of E if it is both a generating family of E and a free family. Equivalently a family is a basis of E when every vector of E is a unique linear combination of the vectors of this basis.

Are there "pathological" situations that could justify this 3 stage definition of a basis instead of the the one underlined above?


to avoid unnecessary computations:

point(P, 6, -3):
line(L, x+2*y-1, [x,y]):
parabola(Par, ['vertex' = P,'directrix' = L], [x,y]):
eq := Equation(Par)

              2            2                        
    eq :=  4 x  - 4 x y + y  - 56 x + 38 y + 225 = 0

@MapleMathMatt  @kiraMou

For informaton: the construction of X can be avoided this way

dt := evalf((b-a)/(n-1)):
T  := a +~ dt *~ < [$0..n] >:
dT := < [dt$n]>:                           # vector of times             
V  := map(v, T):
Vm := (V[2..-1] + V[1..-2]) *~ 0.5:        # velocities at mid points T[i]+dt/2
X  := Statistics:-CumulativeSum(dT *~ Vm): # integration scheme

dataplot( T, [V, X], style = line, legend = [velocity,displacement], color = [red,blue], title = "Discrete Velocity and Displacement" );



Ok, I understand the confusion my personal license is a 2015 (but a 2021 at work) and I thought the problem was my using a personal license and not an older version of MAPLE.

5 6 7 8 9 10 11 Last Page 7 of 86