## Can anyone explain me how 'infinity' is treated in...

Hi

I got, a bit by mistake, a weird result that seems to come from the way "Maple" manipulates infinity (please have a look at the results below)
I couldn't find a correct explanation to these results in the help pages dedicated to infinity or evaluation.

Could anyone explain me why, in some circumstances, 'infinity' seems to be a name (for instance infinity*Pi; does not return  infinity but infiniy/Pi).

 > restart:
 > with(Statistics):
 > f := PDF(Cauchy(0, 1), x)
 (1)
 > m := int(x*f, x=-infinity..+infinity);
 (2)
 > p := int(x*f, x);
 (3)
 > # Naive "proof" : eval(..., infinity) seems to consider infinity as a name (consistent with # the first line in help(infinity) without any particular property. # This seems to be confirmed by the value of p1 and p2 : I expected to get infinity instead # of infinity/Pi. p1 := eval(p, x=-infinity); p2 := eval(p, x=+infinity); p2 - p1;
 (4)
 > # Correct "proof" : a := limit(p, x=-infinity); b := limit(p, x=+infinity); b-a
 (5)
 > # Does Maple treat 'infinity' as a number ? infinity         - infinity; infinity*2       - infinity*2; infinity*(1/3)   - infinity*(1/3); infinity*0.333   - infinity*0.333; infinity*sqrt(2) - infinity*sqrt(2); infinity/Pi      - infinity/Pi;
 (6)
 > limit(sqrt(2)/x, x=0) - limit(sqrt(2)/y, y=0); limit(Pi/x, x=0)      - limit(Pi/y, y=0);
 (7)
 >

## Spliting of a matrix ...

Dear Users!

Hope you would be fine with everything. I have following code to generate marix A of order M by M

restart; with(LinearAlgebra); with(linalg); Digits := 30; M := 10; nu := 1;

for k1 while k1 <= M do

C[k1] := simplify(sum((-1)^(k1-1-i1)*GAMMA(k1-1+i1+2*nu)*GAMMA(nu+1/2)*x^i1/(GAMMA(i1+nu+1/2)*factorial(k1-1-i1)*factorial(i1)*GAMMA(2*nu)), i1 = 0 .. k1-1))

end do;

A := evalm(Matrix(M, M, proc (i, j) options operator, arrow; eval(C[j], x = (i-1)/(M-1)) end proc))

I want to split (or decompose) A into two parts Ad and Ab

where Ad is M by M matrix of all entries of A but first and last rows of Ad shoud be zero

and Ab is M by M matrix with zero entries expect first and last rows.

For exmaple for M = 5, A, Ab and Ad are given as,

Ab := Matrix(5, 5, {(1, 1) = 1, (1, 2) = -2, (1, 3) = 3, (1, 4) = -4, (1, 5) = 5, (2, 1) = 0, (2, 2) = 0, (2, 3) = 0, (2, 4) = 0, (2, 5) = 0, (3, 1) = 0, (3, 2) = 0, (3, 3) = 0, (3, 4) = 0, (3, 5) = 0, (4, 1) = 0, (4, 2) = 0, (4, 3) = 0, (4, 4) = 0, (4, 5) = 0, (5, 1) = 1, (5, 2) = 2, (5, 3) = 3, (5, 4) = 4, (5, 5) = 5});

Ad := Matrix(5, 5, {(1, 1) = 0, (1, 2) = 0, (1, 3) = 0, (1, 4) = 0, (1, 5) = 0, (2, 1) = 1, (2, 2) = -1, (2, 3) = 0, (2, 4) = 1, (2, 5) = -1, (3, 1) = 1, (3, 2) = 0, (3, 3) = -1, (3, 4) = 0, (3, 5) = 1, (4, 1) = 1, (4, 2) = 1, (4, 3) = 0, (4, 4) = -1, (4, 5) = -1, (5, 1) = 0, (5, 2) = 0, (5, 3) = 0, (5, 4) = 0, (5, 5) = 0});

Special request @acer @Carl Love @Kitonum @Preben Alsholm

## How can I have a pretty display of a piecewise exp...

Hi,

How can I force the command InsertContent(Worksheet(Group(Input( T )))) to display the variable eq as it appears in label (2) ?

(a screen capture of the output of InsertContent(Worksheet(Group(Input( T )))) is given after the Maple code)

 > restart:
 > interface(version)
 (1)
 > with(DocumentTools):
 > with(DocumentTools[Layout]):
 > eq := piecewise(t < 1, sin(t), cos(t)); C := Cell( Textfield(style=TwoDimOutput,Equation(eq)) ): T := Table(Column(), widthmode=percentage, width=40, Row(C)): InsertContent(Worksheet(Group(Input( T )))):
 (2)
 >

## GKLS - Optimization test functions generator...

Hi!

There is a (relatively) known software code (written in C), called ." GKLS-generator" or "GKLS" to generate, according to certain user paramenters, optimization test functions. The code is available for free at the web

http://wwwinfo.deis.unical.it/%7Eyaro/GKLS.html

I would like to write this code in Maple. In the attached zip there is a PDF explaining how to build these functions. For now, I tried the follwoing Maple code GKLS_v4.mw

I think I'm doing something wrong, since the drawing generated by the attached Maple does not look much like the PDF in the attached zip (Fig. 1 of page 8).

Please, Can you help me with this?

## Collocating a vector...

Hi User!

Hope you would be fine with everything. I have a vector "POL" of M dimension obatined for the following expression

restart; with(LinearAlgebra); nu := 1; M := 3;
for k while k <= M do
Poly[k] := simplify(sum(x^i*GAMMA(nu+1)/(factorial(i)*GAMMA(2*nu)), i = 0 .. k-1))
end do;
POL := `<,>`(seq(Poly[k], k = 1 .. M))

and I want to construct a matrix of M by M by collocating it on the points x=i/(M-1) for i=0,1,2,...,M-1 like the following way,

For M=3 I need

Matrix(3, 3, {(1, 1) = Poly[1](0), (1, 2) = Poly[1](1/2), (1, 3) = Poly[1](1), (2, 1) = Poly[2](0), (2, 2) = Poly[2](1/2), (2, 3) = Poly[2](1), (3, 1) = Poly[3](0), (3, 2) = Poly[3](1/2), (3, 3) = Poly[3](1)});

For M=4 I need

Matrix(4, 4, {(1, 1) = Poly[1](0), (1, 2) = Poly[1](1/3), (1, 3) = Poly[1](2/3), (1, 4) = Poly[1](1), (2, 1) = Poly[2](0), (2, 2) = Poly[2](1/3), (2, 3) = Poly[2](2/3), (2, 4) = Poly[2](1), (3, 1) = Poly[3](0), (3, 2) = Poly[3](1/3), (3, 3) = Poly[3](2/3), (3, 4) = Poly[3](1), (4, 1) = Poly[4](0), (4, 2) = Poly[4](1/3), (4, 3) = Poly[4](2/3), (4, 4) = Poly[4](1)})

and general form is like this

[[[Poly[1](0/(M-1)),Poly[1](1/(M-1)),Poly[1]((2)/(M-2)),...,Poly[1]((M-1)/(M-1))],[Poly[2](0/(M-1)),Poly[2]((1)/(M-1)),Poly[2]((2)/(M-1)),...,Poly[2]((M-1)/(M-1))],[Poly[3]((0)/(M-1)),Poly[3]((1)/(M-1)),Poly[3]((2)/(M-1)),...,Poly[3]((M-1)/(M-1))],[...,...,...,...,...],[Poly[M]((0)/(M-1)),Poly[M]((1)/(M-1)),Poly[M]((2)/(M-1)),...,Poly[M]((M-1)/(M-1))]]];

Another problem is I want to define a vector of M dimension using a function f(x)=sin(x) and two points a=1, b=2 like the following way,

Vec:=[[[a],[f((1)/(M-1))],[f((2)/(M-1))],[f((3)/(M-1))],[...],[f((M-1)/(M-1))],[b]]]
Special request @acer @acer @Carl Love @Kitonum @Preben Alsholm

## Simplification of an expression...

Dear Users!

Hope you would be fine with everything. I want the simpliest for of the following expression in two step:

diff(U(X, Y, Z, tau), tau)+U(X, Y, Z, tau)*(diff(U(X, Y, Z, tau), X))+V(X, Y, Z, tau)*(diff(U(X, Y, Z, tau), Y))+W(X, Y, Z, tau)*(diff(U(X, Y, Z, tau), Z))+u[delta]*lambda[1]*(diff(U(X, Y, Z, tau), tau, tau))/L[delta]+u[delta]*lambda[1]*(diff(U(X, Y, Z, tau), tau))*(diff(U(X, Y, Z, tau), X))/L[delta]+u[delta]*lambda[1]*U(X, Y, Z, tau)*(diff(U(X, Y, Z, tau), tau, X))/L[delta]+u[delta]*lambda[1]*(diff(V(X, Y, Z, tau), tau))*(diff(U(X, Y, Z, tau), Y))/L[delta]+u[delta]*lambda[1]*V(X, Y, Z, tau)*(diff(U(X, Y, Z, tau), tau, Y))/L[delta]+u[delta]*lambda[1]*(diff(W(X, Y, Z, tau), tau))*(diff(U(X, Y, Z, tau), Z))/L[delta]+u[delta]*lambda[1]*W(X, Y, Z, tau)*(diff(U(X, Y, Z, tau), tau, Z))/L[delta];
Step 1:
diff(U(X, Y, Z, tau), tau)+U(X, Y, Z, tau)*(diff(U(X, Y, Z, tau), X))+V(X, Y, Z, tau)*(diff(U(X, Y, Z, tau), Y))+W(X, Y, Z, tau)*(diff(U(X, Y, Z, tau), Z))+u[delta]*lambda[1]*(diff(diff(U(X, Y, Z, tau), tau)+U(X, Y, Z, tau)*(diff(U(X, Y, Z, tau), X))+V(X, Y, Z, tau)*(diff(U(X, Y, Z, tau), Y))+W(X, Y, Z, tau)*(diff(U(X, Y, Z, tau), Z)), tau))/L[delta];
Step 2: (final form I need)
(1+(u[delta] lambda[1])/(L[delta]) (&PartialD;)/(&PartialD;tau)) ((&PartialD;)/(&PartialD;tau) U(X,Y,Z,tau)+U(X,Y,Z,tau) ((&PartialD;)/(&PartialD;X) U(X,Y,Z,tau))+V(X,Y,Z,tau) ((&PartialD;)/(&PartialD;Y) U(X,Y,Z,tau))+W(X,Y,Z,tau) ((&PartialD;)/(&PartialD;Z) U(X,Y,Z,tau)));
Special request:
@acer @Carl Love @Kitonum @Preben Alsholm

## How to use the Liebniz notation in a complex expre...

Hi

I would like to use  the Liebniz notation that someone from the technical support posted here
Writing Derivatives at a Point Using Leibniz Notation
to display a formula that is not just a partial derivative but a more complex expression invoking partial derivatives.
Typically an expression like this one:

2*(Diff(f(mu__1, mu__2), mu__1))^2*lambda__1^2-(Diff(f(mu__1, mu__2), mu__1))^2*mu__1^2+2*(Diff(f(mu__1, mu__2), mu__2))^2*lambda__2^2-(Diff(f(mu__1, mu__2), mu__2))^2*mu__2^2+2*(Diff(f(mu__1, mu__2), mu__1))*(Diff(f(mu__1, mu__2), mu__2))*lambda__1*lambda__2-2*(Diff(f(mu__1, mu__2), mu__1))*mu__1*(Diff(f(mu__1, mu__2), mu__2))*mu__2

Could anyone help me to do this?

(PS: I'm still using Maple 2015.2)

## Problem in making animation of multiple solutions...

Dear Users!

Hoped everything going fine with you. I want to make animation of ten solutions as given bellow but fail to do that. Please see it fix the problem. I shall be very thankful to u.
SOLNSuy[1, 1] := 2.5872902469406659197*10^(-20)-.65694549571241255901*y+1.9708364871372376767*y^2-1.3138909914248251176*y^3-1.6010739356637904911*10^(-19)*y^4;
SOLNSuy[2, 1] := -4.002204462000*10^(-20)-1.7879176897079605225*y+5.3637530691192141414*y^2-3.5758353794044226250*y^3-6.8309939211286845440*10^(-12)*y^4;
SOLNSuy[3, 1] := -1.1953264450000*10^(-19)-3.2481690589079594122*y+9.7445071767154794599*y^2-6.4963381177952273213*y^3-1.2292726248071398400*10^(-11)*y^4;
SOLNSuy[4, 1] := -2.6720465500000*10^(-19)-4.9239979672954025921*y+14.771993901873204315*y^2-9.8479959345587718955*y^3-1.9029826928878336000*10^(-11)*y^4;
SOLNSuy[5, 1] := 3.416928541000*10^(-20)-6.7268498492441931137*y+20.180549547714413714*y^2-13.453699698443639810*y^3-2.6580790570532587008*10^(-11)*y^4;
SOLNSuy[6, 1] := -2.554122292000*10^(-20)-8.5884528335125514887*y+25.765358500514014457*y^2-17.176905666966875698*y^3-3.4587270427710613504*10^(-11)*y^4;
SOLNSuy[7, 1] := -9.206107680000*10^(-20)-10.456823708331499352*y+31.370471124965259849*y^2-20.913647416590986491*y^3-4.2774005353527132160*10^(-11)*y^4;
SOLNSuy[8, 1] := 1.9644186790000*10^(-19)-12.293003938471349390*y+36.879011815379230436*y^2-24.586007876856948223*y^3-5.0932823222176363520*10^(-11)*y^4;
SOLNSuy[9, 1] := -3.775112769000*10^(-19)-14.068404975282556550*y+42.205214925807397100*y^2-28.136809950465931724*y^3-5.8908824448577377280*10^(-11)*y^4;
SOLNSuy[10, 1] := 1.146281780000*10^(-19)-15.762658869974768890*y+47.287976609878780960*y^2-31.525317739837422477*y^3-6.6589592851037286400*10^(-11)*y^4;
plots[animate](plot, [SOLNSuy[A, 1], y = 0 .. 1], A = 1 .. 10);

Special request:
@acer @Carl Love @Kitonum @Preben Alsholm

## Drawing fireworks with Maple

by: Maple 2015

Here is a little animation to wish all of you a Merry Christmas

FireWorks.mw

Hi,

In help page DocumentTools:-Layout:-Font, there is an example which shows how to inser a hyperlink in a Layout.

F := Font( "Some text", size=16, color=blue, style=:-Hyperlink ):
InsertContent(Worksheet(Group(Input(Textfield( F ))))):

When this id done, how can we activate this hyperlink ?
5I'm presently working with Maple 2015.2 under Mac OS Mojave)

## Why don't the sliders work?...

Hi,

Moving the sliders clean the plot.
Does any one can show me how to fix this (PS: this piece of code is a part of a procedure whose arguments are RV and SliderRanges and I need this unusual coding to make the procedure generic ... at least I guess so)

 > restart:
 > interface(version);
 (1)
 > with(Statistics):
 > RV   := RandomVariable(Normal(a, b)): law  := [attributes(RV)][3]: pars := law:-Parameters;
 (2)
 > SliderRanges := [-5.0..5.0, 1.0..3.0]: [seq(pars[k]=SliderRanges[k], k=1..numelems(pars))]
 (3)
 > f := PDF(RV, x); # Explore(plot(f, x=-3..3), parameters=[seq(pars[k]=SliderRanges[k], k=1..numelems(pars))]);
 (4)
 >

## Why doesn't dsolve[events] return the good result...

Hi,

Why extracting the features of the events doesn't return the good results when executed within a loop (see the pink test) ?

PS: please, spare me  replies of the type "you can solve this equation formally"

 > restart;
 > interface(version);
 (1)
 > sys := { diff(x(t), t) = 1, x(0) = 0 }: evs := [ [x(t)-0.1, none],  [x(t)-0.3, none], [x(t)-0.5, none] ]: sol := dsolve(sys, numeric, events=evs): plots:-odeplot(sol, [t, x(t)], t=0..0.5, gridlines=true);
 > # times that fired the events sol(1): # initialization sol(eventfired=[1]); sol(eventfired=[2]); sol(eventfired=[3]);
 (2)
 > # Same times computed  within a loop for i from 1 to 3 do   te := op(sol(eventfired=[i])); end do;
 (3)
 > # Values of x(t) computed  within a loop # # Why are calues for events 2 and 3 wrong ? for i from 1 to 3 do   te := op(sol(eventfired=[i])); # xe := sol(te);             # this doesn't return the correct result, # xe := subs(sol(te), x(t)); # this doesn't work neither   xe := eval(x(t), sol(te)); # this doesn't work neither end do;
 (4)
 >

## How do I plot a hyperbola in polar with no asympto...

I would like to plot a hyperbola using the polarplot command, such as the following:

polarplot(3/(1-1.5*sin(theta)), coordinateview = [0 .. 10, 0 .. 2*Pi])

But the graph includes the asymptotes, which I would not like to be included. I have tried the discont=true command, but it completely changes the shape of the graph and no longer looks like a hyperbola:

polarplot(3/(1-1.5*sin(theta)), coordinateview = [0 .. 10, 0 .. 2*Pi], discont = true)

How would I get the hyperbola above to display with no asymptotes?

Thanks

## is there any library or tools to design index of G...

is there any library or tools to design index of Grassmannian and its k and n for Schubert use?

is there any library to relate poset with index of Grassmannian and its k and n for Schubert use

hello everyone,
INGT.mw

 (1)

 (2)

 (3)

 (4)

 (5)

 (6)

 (7)

 (8)

 (9)

 (10)

 (11)

 (12)

 (13)

 (14)

 (15)

 (16)

 (1)

 (2)

 (3)

 (4)

 (5)

 (6)

 (7)

 (8)

 (9)

 (10)

 (11)

 (12)

 (13)

 (14)

 (15)

 (16)