Maple 2022 Questions and Posts

These are Posts and Questions associated with the product, Maple 2022

restart

with(plottools)

with(plots)

with(CurveFitting)

Digits := 10

NULL

"f(t):=7.0*(e)^((-(t-13180)^(2))/(2000000))+4.7*(e)^((-(t-16000)^(2))/(3200000)):"

p1 := plot(f(t), t = 0 .. 20000, color = green); plots[display]({p1})

 

NULL

D1 := 15

epsilon := 200000

L := 6500

n := 200

t := 1000

1000

(1)

lambda := simplify(evalf(n*Pi*sqrt((1/2)*D1+sqrt((1/4)*D1^2+epsilon*(n*Pi/L)^2))/L))

.6928578233

(2)

b := 2*(int(f(t)*sin(m*Pi*x/L), x = 0 .. L))/L

-0.6366197724e-1*(0.1409730543e-28*cos(3.141592654*m)-0.1409730543e-28)/m

(3)

C(x, t) = sum(b*exp^(-lambda^2*t)*sin(m*Pi*x/L), m = 1 .. 2)

C(x, 1000) = 0.1794924675e-29*sin(0.4833219466e-3*x)/exp^(4800519633/10000000)

(4)

uu1000 := [seq(evalf(C(L-i, t)), i = 0 .. 6500, 100)]

[C(6500, 1000), C(6400, 1000), C(6300, 1000), C(6200, 1000), C(6100, 1000), C(6000, 1000), C(5900, 1000), C(5800, 1000), C(5700, 1000), C(5600, 1000), C(5500, 1000), C(5400, 1000), C(5300, 1000), C(5200, 1000), C(5100, 1000), C(5000, 1000), C(4900, 1000), C(4800, 1000), C(4700, 1000), C(4600, 1000), C(4500, 1000), C(4400, 1000), C(4300, 1000), C(4200, 1000), C(4100, 1000), C(4000, 1000), C(3900, 1000), C(3800, 1000), C(3700, 1000), C(3600, 1000), C(3500, 1000), C(3400, 1000), C(3300, 1000), C(3200, 1000), C(3100, 1000), C(3000, 1000), C(2900, 1000), C(2800, 1000), C(2700, 1000), C(2600, 1000), C(2500, 1000), C(2400, 1000), C(2300, 1000), C(2200, 1000), C(2100, 1000), C(2000, 1000), C(1900, 1000), C(1800, 1000), C(1700, 1000), C(1600, 1000), C(1500, 1000), C(1400, 1000), C(1300, 1000), C(1200, 1000), C(1100, 1000), C(1000, 1000), C(900, 1000), C(800, 1000), C(700, 1000), C(600, 1000), C(500, 1000), C(400, 1000), C(300, 1000), C(200, 1000), C(100, 1000), C(0, 1000)]

(5)

``

xx := [seq(k, k = 0 .. 6500, 100)]

NULL

p2 := plot(xx, uu1000, color = cyan)

Error, (in plot) two lists or Vectors of numerical values expected

 

plots[display]({p2})

Error, (in plots:-display) expecting plot structures but received: {p2}

 

NULL

Download easy_way.mw

Here are all non-isomorphic 3-regular vertex-transitive graphs with 62 vertices. I wanted to draw them all at once, but I found that tables cannot use the map function.

with(GraphTheory):
CubicVT[1] := Graph({{23,60}, {37,6}, {36,27}, {61,19}, {60,29}, {2,52},
{40,43}, {23,25}, {45,50}, {1,30}, {11,17}, {13,41}, {34,4}, {11,54}, {26,49}, 
{56,2}, {49,51}, {3,21}, {47,28}, {24,52}, {13,7}, {48,27}, {51,42}, {4,60}, 
{55,45}, {46,21}, {46,38}, {57,14}, {4,31}, {24,8}, {47,20}, {44,5}, {55,43}, 
{30,31}, {18,41}, {17,42}, {46,37}, {36,16}, {8,43}, {58,30}, {17,53}, {25,5}, 
{5,31}, {24,9}, {9,53}, {22,26}, {35,50}, {48,20}, {12,36}, {33,13}, {12,58}, 
{33,29}, {35,14}, {3,19}, {41,42}, {14,10}, {25,21}, {37,32}, {2,48}, {52,10}, 
{61,10}, {57,58}, {38,7}, {3,62}, {29,51}, {35,8}, {39,32}, {49,6}, {1,27}, 
{39,40}, {12,50}, {56,53}, {59,62}, {34,15}, {18,9}, {1,28}, {22,55}, {33,15}, 
{39,7}, {44,57}, {59,38}, {11,26}, {45,54}, {15,59}, {44,19}, {47,62}, {16,54}, {61,20}, {23,6}, {56,16}, {22,32}, {18,40}, {34,28}});

CubicVT[2] := Graph({{39,7}, {18,41}, {11,17}, {22,32}, {46,29}, {24,8},
{18,40}, {44,19}, {55,43}, {23,25}, {45,9}, {46,38}, {59,38}, {13,6}, {39,51}, 
{48,27}, {56,16}, {57,58}, {25,21}, {52,10}, {17,43}, {22,41}, {61,20}, {15,59},
{14,27}, {39,32}, {24,54}, {42,32}, {17,53}, {56,35}, {41,42}, {34,15}, {2,52}, 
{40,43}, {33,13}, {36,10}, {44,28}, {49,6}, {56,2}, {45,54}, {25,15}, {2,50}, 
{58,20}, {61,30}, {57,48}, {48,20}, {47,62}, {35,8}, {37,6}, {13,7}, {4,31}, 
{47,28}, {35,50}, {1,19}, {49,7}, {60,29}, {61,19}, {51,42}, {11,26}, {55,45}, 
{3,4}, {36,27}, {16,54}, {9,53}, {11,40}, {47,5}, {14,10}, {23,59}, {16,8}, 
{5,31}, {24,9}, {12,36}, {3,21}, {62,31}, {22,26}, {33,37}, {57,14}, {46,37}, 
{34,21}, {1,28}, {12,52}, {34,4}, {44,5}, {12,50}, {38,60}, {55,53}, {23,60}, 
{1,30}, {58,30}, {33,29}, {3,62}, {26,18}, {49,51}});

CubicVT[3] := Graph({{23,60}, {37,6}, {38,51}, {36,27}, {61,19}, 
{60,29}, {2,52}, {40,43}, {23,25}, {1,30}, {17,39}, {11,17}, {34,4}, {33,21}, 
{23,7}, {56,2}, {1,10}, {11,8}, {49,51}, {3,21}, {47,28}, {13,7}, {48,27}, 
{25,28}, {51,42}, {55,45}, {13,26}, {46,38}, {57,14}, {4,31}, {24,8}, {44,5}, 
{55,43}, {44,27}, {2,58}, {15,6}, {18,41}, {46,37}, {58,30}, {17,53}, {5,31}, 
{24,9}, {9,53}, {22,26}, {35,50}, {48,20}, {12,36}, {33,13}, {18,54}, {50,53}, 
{24,36}, {33,29}, {3,30}, {41,42}, {14,10}, {25,21}, {20,31}, {12,61}, {52,10}, 
{57,58}, {3,62}, {35,8}, {39,32}, {49,6}, {29,32}, {12,50}, {56,43}, {55,42}, 
{22,9}, {34,15}, {1,28}, {39,7}, {45,52}, {59,5}, {59,38}, {57,47}, {60,62}, 
{11,26}, {37,41}, {35,48}, {45,54}, {15,59}, {44,19}, {47,62}, {16,54}, {46,4}, 
{61,20}, {14,16}, {56,16}, {34,19}, {22,32}, {18,40}, {49,40}});

CubicVT[4] := Graph({{13,9}, {39,7}, {18,41}, {33,28}, {11,17}, {39,8}, 
{22,32}, {24,8}, {18,40}, {44,35}, {44,19}, {55,43}, {23,25}, {46,38}, {59,38}, 
{34,27}, {2,47}, {12,31}, {48,27}, {7,62}, {56,16}, {57,58}, {25,21}, {52,10}, 
{3,10}, {61,20}, {15,59}, {45,58}, {5,6}, {39,32}, {17,53}, {41,42}, {34,15}, 
{2,52}, {59,20}, {48,53}, {40,43}, {38,40}, {33,13}, {49,6}, {56,2}, {45,54}, 
{1,16}, {48,20}, {55,37}, {47,62}, {35,8}, {14,43}, {37,6}, {13,7}, {4,31}, 
{47,28}, {35,50}, {60,29}, {61,19}, {51,42}, {24,61}, {22,50}, {11,26}, {55,45},
{11,36}, {4,51}, {49,54}, {36,27}, {16,54}, {9,53}, {14,10}, {5,31}, {24,9}, 
{12,36}, {21,32}, {3,21}, {18,52}, {22,26}, {15,41}, {56,42}, {17,29}, {57,14}, 
{46,37}, {1,28}, {34,4}, {44,5}, {23,26}, {12,50}, {60,30}, {23,60}, {1,30}, 
{58,30}, {33,29}, {3,62}, {57,25}, {46,19}, {49,51}});

CubicVT[5] := Graph({{39,7}, {18,41}, {11,17}, {22,32}, {24,8}, {18,40},
{44,19}, {56,49}, {55,43}, {23,25}, {52,42}, {2,3}, {14,18}, {59,38}, {46,38}, 
{62,32}, {48,27}, {56,16}, {26,21}, {15,40}, {57,58}, {25,21}, {58,43}, {33,30},
{52,10}, {22,36}, {61,20}, {15,59}, {13,8}, {39,32}, {28,7}, {17,53}, {41,42}, 
{23,17}, {34,15}, {2,52}, {40,43}, {33,13}, {49,6}, {56,2}, {45,54}, {47,16}, 
{25,10}, {12,34}, {61,53}, {5,51}, {48,20}, {39,50}, {47,62}, {35,31}, {35,8}, 
{37,6}, {13,7}, {4,31}, {47,28}, {35,50}, {60,29}, {61,19}, {51,42}, {11,26}, 
{57,60}, {55,45}, {6,19}, {44,24}, {36,27}, {16,54}, {9,53}, {14,10}, {5,31}, 
{24,9}, {12,36}, {11,48}, {3,21}, {22,26}, {29,9}, {57,14}, {46,37}, {1,28}, 
{55,38}, {46,20}, {34,4}, {59,27}, {4,41}, {44,5}, {1,45}, {12,50}, {23,60}, 
{1,30}, {58,30}, {33,29}, {3,62}, {49,51}, {37,54}});

CubicVT[6] := Graph({{39,7}, {57,54}, {18,41}, {11,17}, {22,32}, {24,8},
{18,40}, {44,19}, {55,43}, {11,33}, {23,25}, {4,48}, {46,38}, {59,38}, {12,17}, 
{47,29}, {48,27}, {56,16}, {57,58}, {25,21}, {52,10}, {16,41}, {61,20}, {15,59},
{35,26}, {56,30}, {39,32}, {6,43}, {17,53}, {41,42}, {34,15}, {2,52}, {27,9}, 
{40,43}, {33,13}, {14,62}, {49,6}, {56,2}, {34,49}, {45,54}, {13,3}, {28,52}, 
{48,20}, {47,62}, {35,8}, {7,53}, {37,6}, {13,7}, {4,31}, {47,28}, {35,50}, 
{60,29}, {2,40}, {61,19}, {51,42}, {58,21}, {11,26}, {55,45}, {22,60}, {1,23}, 
{25,39}, {36,27}, {16,54}, {46,18}, {9,53}, {14,10}, {36,5}, {5,31}, {37,31}, 
{24,9}, {12,36}, {24,32}, {55,10}, {8,20}, {15,61}, {3,21}, {44,38}, {22,26}, 
{57,14}, {45,51}, {46,37}, {1,28}, {34,4}, {44,5}, {12,50}, {50,19}, {23,60}, 
{1,30}, {59,42}, {58,30}, {33,29}, {3,62}, {49,51}});

CubicVT[7] := Graph({{27,20}, {57,30}, {24,53}, {19,20}, {37,49}, 
{13,29}, {11,17}, {56,52}, {24,8}, {18,40}, {44,19}, {57,10}, {55,43}, {28,62}, 
{6,51}, {46,38}, {33,7}, {18,42}, {48,27}, {56,16}, {4,5}, {57,58}, {25,21}, 
{11,22}, {12,27}, {25,60}, {61,20}, {44,31}, {62,21}, {15,59}, {17,9}, {39,32}, 
{41,42}, {2,10}, {2,52}, {37,38}, {11,53}, {36,50}, {45,54}, {46,6}, {2,16}, 
{44,61}, {14,58}, {26,32}, {5,19}, {48,61}, {37,6}, {13,7}, {47,28}, {49,42}, 
{35,50}, {3,47}, {12,35}, {4,15}, {23,29}, {55,54}, {34,59}, {55,40}, {1,58}, 
{46,59}, {45,16}, {9,53}, {8,9}, {40,41}, {22,39}, {14,10}, {45,43}, {5,31}, 
{12,36}, {56,54}, {23,21}, {24,35}, {50,8}, {28,30}, {18,43}, {34,31}, {22,26}, 
{7,32}, {3,25}, {14,52}, {15,38}, {26,17}, {34,4}, {1,47}, {33,60}, {23,60}, 
{1,30}, {33,29}, {3,62}, {51,41}, {36,48}, {49,51}, {13,39}});

 

DrawGraph~(CubicVT)

Error, invalid input: GraphTheory:-DrawGraph expects its 1st argument, H, to be of type {GRAPHLN, list(GRAPHLN), set(GRAPHLN)}, but received Graph({{1, 30}, {1, 47}, {1, 58}, {2, 10}, {2, 16}, {2, 52}, {3, 25}, {3, 47}, {3, 62}, {4, 5}, {4, 15}, {4, 34}, {5, 19}, {5, 31}, {6, 37}, {6, 46}, {6, 51}, {7, 13}, {7, 32}, {7, 33}, {8, 9}, {8, 24}, {8, 50}, {9, 17}, {9, 53}, {10, 14}, {10, 57}, {11, 17}, {11, 22}, {11, 53}, {12, 27}, {12, 35}, {12, 36}, {13, 29}, {13, 39}, {14, 52}, {14, 58}, {15, 38}, {15, 59}, {16, 45}, {16, 56}, {17, 26}, {18, 40}, {18, 42}, {18, 43}, {19, 20}, {19, 44}, {20, 27}, {20, 61}, {21, 23}, {21, 25}, {21, 62}, {22, 26}...
Why can lists use the map function, but tables cannot?

DrawGraph~([seq(CubicVT[i],i=1..7)])

tablemap.mw

That is to say, a generalized map
E.g., here is a nested list: 

nl := [[[[s, t]], [u, [v, w]]], [[x, [y, z]]]]:

We can use map to apply the mapped function F to "each operand" (i.e., the first‐level parts) of : 

:-map(F, nl);
 = 
         [F([[[s, t]], [u, [v, w]]]), F([[x, [y, z]]])]

But in Mathematica, we can make further explorations: 

In[1]:= nl = {{{{s, t}}, {u, {v, w}}}, {{x, {y, z}}}}; 

In[2]:= Map[F, nl, {1}] (*Maple's result*)

Out[2]= {F[{{{s, t}}, {u, {v, w}}}], F[{{x, {y, z}}}]}

In[3]:= Map[F, nl, {2, -2}]

Out[3]= {{F[{F[{s, t}]}], F[{u, F[{v, w}]}]}, {F[{x, F[{y, z}]}]}}

In[4]:= Map[F, nl, {-3, 3}]

Out[4]= {{F[{F[{s, t}]}], F[{F[u], F[{v, w}]}]}, {F[{F[x], F[{y, z}]}]}}

In[5]:= Map[F, nl, {0, \[Infinity]}, Heads -> \[Not] True]

Out[5]= F[{F[{F[{F[{F[s], F[t]}]}], F[{F[u], F[{F[v], F[w]}]}]}], F[{F[{F[x], F[{F[y], F[z]}]}]}]}]

Note that the last case has been implemented in Maple as MmaTranslator[Mma][MapAll]:  

MmaTranslator:-Mma:-MapAll(F,nl);
 = 
   F([F([F([F([F(s), F(t)])]), F([F(u), F([F(v), F(w)])])]), 

     F([F([F(x), F([F(y), F(z)])])])])

Naturally, how to reproduce the other two results in Maple programmatically? (The output may not be easy to read or understand; I have added an addendum below.)

Addendum. It is also possible to display in "tree" structure (like dismantle) manually: 

`[]`
(
    `[]`
    (
        `[]`
        (
            `[]`
            (
                s
            ,
                t
            )
        )
    ,
        `[]`
        (
            u
        ,
            `[]`
            (
                v
            ,
                w
            )
        )
    )
,
    `[]`
    (
        `[]`
        (
            x
        ,
            `[]`
            (
                y
            ,
                z
            )
        )
    )
)

As you can see, the "depth" of  is five (0, 1, 2, 3, and 4), while the classical map just maps at the first "level". (Moreover, such descriptions may lead to a confusion.)

Supplement. Unfortunately, there remains a bug in the MmaTranslator[Mma][Level]. Compare: 

MmaTranslator:-Mma:-Level(nl, [4]); (*Maple*)
                             [v, w]

MmaTranslator:-Mma:-Level(nl, [-1]); (*Maple*)
          [s, t, u, v, w, x, y, z, -1, x, c, r, y, 2]

In[6]:= Level[nl, {4}] (*Mathematica*)

Out[6]= {s, t, v, w, y, z}

In[7]:= Level[nl, {-1}] (*Mathematica*)

Out[7]= {s, t, u, v, w, x, y, z}

Hey guys.

I want to replace _Z1, _Z2 and _B2 with n but it doesn't work. Can anyone help?

An example is attached.

Regards,

Oliveira

Example3.mw

I have noticed this before few times. I wonder if others have seen it.

When I have Maple open, (with may be few worksheets open) and not being used at all for anything and it is not running anything, after sometime (say 2-4 hrs or more), when I go back to using Maple, I find the GUI unresponsive. Nothing happens. Clicking on anything does nothing, It is frozen. Resizing the window, it become black and does not repaint.  

But If I wait about 5-10 minutes after doing this window resizing, it suddenly becomes responsive again and it become alive again.  This happened twice this week, where I was about to just kill Maple. Good thing I did not.

It feels like the Maple process/frontend went to sleep when not being used, and it takes few minutes to wake it up by shaking the window. I do not know what else could explain this.

This is windows 10. Latest updates and lots of RAM and nothing else is running on the PC at this time.

I go take a nap, come back and notice this. It does not happen all the time, but noticed it twice this week.

Any others seen this problem? Does Maple process go to sleep or hibernate when it detects it is not being used for sometime? Looking at task manager when this happens, I see no CPU activity at all and no memory changes at all in any of the servers.exe. So I think this might be a GUI issue, where Java go to sleep or something.   

Or it could be a windows 10 issue and not Maple. But I only noticed this with Maple where it seems to go to sleep when not used.

Hello there, 

Is there any chance to ask this one question?

The attached (following) worksheet shows the result of LieDerivative operation, which is not correct. 

The correct answer is given in the image in the middle of the worksheet. Is there any particular reason regarding Maple's way of conducting the operation in that way?

restart;

with(LinearAlgebra):

with(DifferentialGeometry):

with(LieAlgebras):

DGsetup([x1, x2], M, verbose);

`The following coordinates have been protected:`

 

[x1, x2]

 

`The following vector fields have been defined and protected:`

 

[_DG([["vector", M, []], [[[1], 1]]]), _DG([["vector", M, []], [[[2], 1]]])]

 

`The following differential 1-forms have been defined and protected:`

 

[_DG([["form", M, 1], [[[1], 1]]]), _DG([["form", M, 1], [[[2], 1]]])]

 

`frame name: M`

(1)

 

M > 

f := evalDG((x2)*D_x1 + (c1 * (1 - x1^2) * x2 - c2 * x1)*D_x2);

_DG([["vector", M, []], [[[1], x2], [[2], -c1*x1^2*x2+c1*x2-c2*x1]]])

(2)
M > 

h := evalDG((x1)*D_x1 + (0)*D_x2);

_DG([["vector", M, []], [[[1], x1]]])

(3)
M > 

###### answer

M > 

M > 

LieDerivative(f, h);

_DG([["vector", M, []], [[[1], x2], [[2], x1*(2*c1*x1*x2+c2)]]])

(4)
M > 

 

Download Q20230307.mw

I am trying to test types inside lists on the input to a procedure. Sometimes I can get this concept to work. 

This is a sample to show the problem. I need to know if the list has [ list[ $3] , Vector[column]($3) ] , or [ Vector[row]($3] , Vector [column]($3) ]

restart

 


        test:=proc(l1::[{[algebraic $ 3],'Vector[row](3, algebraic)'},'Vector[column](3, algebraic)'],l2::[{[algebraic $ 3],'Vector[row](3, algebraic)'},'Vector[column](3,algebraic)'])
        
        print("inputs recognised");

        end proc;

        

proc (l1::[{'Vector[row](3, algebraic)', [`$`(algebraic, 3)]}, 'Vector[column](3, algebraic)'], l2::[{'Vector[row](3, algebraic)', [`$`(algebraic, 3)]}, 'Vector[column](3, algebraic)']) print("inputs recognised") end proc

 

 

#  3d lines

l1:= [<1 | 5 | 7>, <3, 7, 9>]

[Vector[row](3, {(1) = 1, (2) = 5, (3) = 7}), Vector(3, {(1) = 3, (2) = 7, (3) = 9})]

l2:=[<-4 | 2 | 1>, <3, 8, -9>]

[Vector[row](3, {(1) = -4, (2) = 2, (3) = 1}), Vector(3, {(1) = 3, (2) = 8, (3) = -9})]

test(l1,l2)

Error, invalid input: test expects its 1st argument, l1, to be of type [{'Vector[row](3,algebraic)', [algebraic $ 3]}, 'Vector[column](3,algebraic)'], but received [Vector[row](3, [1,5,7]), Vector(3, [3,7,9])]

l3:= [[1 , 5 , 7], <3, 7, 9>]

[[1, 5, 7], Vector(3, {(1) = 3, (2) = 7, (3) = 9})]

l4:=[[-4 , 2 , 1], <3, 2, -9>]

[[-4, 2, 1], Vector(3, {(1) = 3, (2) = 2, (3) = -9})]

test(l3,l4)

Error, invalid input: test expects its 1st argument, l1, to be of type [{'Vector[row](3,algebraic)', [algebraic $ 3]}, 'Vector[column](3,algebraic)'], but received [[1, 5, 7], Vector(3, [3,7,9])]

type(l3[1],[algebraic $ 3])

true

type(l1[1],[algebraic $ 3])  

false

type(l1[1],'Vector[row](3, algebraic)')

true

type(l1[2],'Vector[column](3, algebraic)')

true

 

Download Q_2023-03-06_Proc_types_in_list_inputs.mw

This is second order ode solved using series method. This problem from textbook. The solution given by Maple does not match the book. I also solved this by hand and my hand solution agrees with the text book. I also solved this using Mathematica and its solution agrees with the book. 

Maple solution does not agree with the book for y2.  i.e. the general solution for this problem has the form 

    y= c_1 * y1 + c_2* (  y1 * ln(x)  +  y2 )

This is a Frobenius series method, since regular singular point and it falls into the hard case, where roots of indicial equation has difference of integer and where the second solution y2 can't be obtained using same method as y1 due to being undefined if using same method. So it require adjustment to the Frobenius series method.

This is ode

restart;
Order:=10;
ode:=x*diff(y(x),x$2)-3*diff(y(x),x)+x*y(x)=0;
dsolve(ode,y(x),'series')

Maple says that

   y2 = -144 - 36*x^2 + 1/2*x^6 - 25/1024*x^8 + ...)

First, it is missing x^4. And not able to make other coefficients match book. Book says y2 should be

   y2 = 1 + x^2/4 + x^4/64 - (11 x^6)/2304 + ....

And that is what I get and also Mathematica:

I do not have screen shot now of the page from the book to show. It is from an old textbook. Will try to make screen shot if needed.  This is problem 5, page 212 from SCHAUM's "differential equations" by Frank Ayers. 1952 edition. There is free PDF files on the net. Here is screen shot

My question is, why is Maple's series soluiton for the second basis solution y2 different? Could someone verify this? It also failes to verify it

restart;
ode:=x*diff(y(x),x$2)-3*diff(y(x),x)+x*y(x)=0;
Order:=10;
sol:=dsolve(ode,y(x),'series');
odetest(sol,ode,'series','point'=0)

 

Update

I've testsed few more problems, solved by hand and verified using Mathematica. All these problems give wrong solution by Maple for y_2. At least the solutions do not match the book and do not match my hand solution and do not match Mathematica. In all cases Mathematica's solution and my hand solution match the book. 

All these problem fall into the same difficult case of Frobenius series, where roots of indicial equation differ by integer and where y_2 can not be obtained directly using similar method used to obtain y_1. Other cases of Frobenius roots, Maple give complete correct general solutions. It is only this case where there seems to be something wrong.

In all of these problems below, y_1 solution is correct. It is the last series in y_2 shown which does not agree with book and it is this part which require using modifed method to obtain as explained on the book where these problems are solved from the above links. All the books used can be found online.

Please see attached worksheet.
 

interface(version);

`Standard Worksheet Interface, Maple 2022.2, Windows 10, October 23 2022 Build ID 1657361`

#problem  problem 5, page 212 from SCHAUM's "differential equations" by Frank Ayers. 1952 edition.
ode:=x*diff(y(x),x$2)-3*diff(y(x),x)+x*y(x)=0:
sol:=dsolve(ode,y(x),'series');
odetest(sol,ode,'series','point'=0)

y(x) = c__1*x^4*(series(1-(1/12)*x^2+(1/384)*x^4-(1/23040)*x^6+(1/2211840)*x^8+O(x^10),x,10))+c__2*(ln(x)*(series(9*x^4-(3/4)*x^6+(3/128)*x^8+O(x^10),x,10))+(series(-144-36*x^2+(1/2)*x^6-(25/1024)*x^8+O(x^10),x,10)))

Warning, unable to compute series necessary to test the given solution

FAIL

#page 19, example 5. NASA report TR R-390. By Gabriel Allen (PDF online)
ode:=x^2*diff(y(x),x$2)+x*diff(y(x),x)+(x^2-4)*y(x)=0:
sol:=dsolve(ode,y(x),'series');
odetest(sol,ode,'series','point'=0)

y(x) = c__1*x^2*(series(1-(1/12)*x^2+(1/384)*x^4-(1/23040)*x^6+(1/2211840)*x^8+O(x^10),x,10))+c__2*(ln(x)*(series(9*x^4-(3/4)*x^6+(3/128)*x^8+O(x^10),x,10))/x^2+(series(-144-36*x^2+(1/2)*x^6-(25/1024)*x^8+O(x^10),x,10))/x^2)

Warning, unable to compute series necessary to test the given solution

FAIL

# problem 20.6, page 114 from SCHAUM's "differential equations" by Richard Bronson. 1978 edition.
ode:=x^2*diff(y(x),x$2)+(x^2-2*x)*diff(y(x),x)+2*y(x)=0:
sol:=dsolve(ode,y(x),'series');
odetest(sol,ode,'series','point'=0)

y(x) = c__1*x^2*(series(1-x+(1/2)*x^2-(1/6)*x^3+(1/24)*x^4-(1/120)*x^5+(1/720)*x^6-(1/5040)*x^7+(1/40320)*x^8-(1/362880)*x^9+O(x^10),x,10))+c__2*(x*ln(x)*(series(-x+x^2-(1/2)*x^3+(1/6)*x^4-(1/24)*x^5+(1/120)*x^6-(1/720)*x^7+(1/5040)*x^8-(1/40320)*x^9+O(x^10),x,10))+x*(series(1-x+(1/4)*x^3-(5/36)*x^4+(13/288)*x^5-(77/7200)*x^6+(29/14400)*x^7-(223/705600)*x^8+(481/11289600)*x^9+O(x^10),x,10)))

Warning, unable to compute series necessary to test the given solution

FAIL

# problem 20.7, page 115 from SCHAUM's "differential equations" by Richard Bronson. 1978 edition.
ode:=x^2*diff(y(x),x$2)+x*diff(y(x),x)+(x^2-1)*y(x)=0:
sol:=dsolve(ode,y(x),'series');
odetest(sol,ode,'series','point'=0)

y(x) = c__1*x*(series(1-(1/8)*x^2+(1/192)*x^4-(1/9216)*x^6+(1/737280)*x^8+O(x^10),x,10))+c__2*(ln(x)*(series(x^2-(1/8)*x^4+(1/192)*x^6-(1/9216)*x^8+O(x^10),x,10))/x+(series(-2+(3/32)*x^4-(7/1152)*x^6+(35/221184)*x^8+O(x^10),x,10))/x)

Warning, unable to compute series necessary to test the given solution

FAIL

 


 

Download series_solutions_Frob_difference_integer.mw

 

restart

with(plottools)

with(plots)

with(CurveFitting)

Digits := 100

"g(t):=10*(e)^((-(t-4000)^(2))/(1300000))+6*(e)^((-(t-6900)^(2))/(1400000))"

proc (t) options operator, arrow, function_assign; 10*exp(-(1/1300000)*(t-4000)^2)+6*exp(-(1/1400000)*(t-6900)^2) end proc

(1)

p0 := plot(g(t), t = 0 .. 20000, color = green); plots[display]({p0})

 

````

v := .7

disp := 15

PDE := diff(C(x, t), t) = -v*(diff(C(x, t), x))+disp*(diff(C(x, t), x, x))

IBC := C(x, 0) = 0, C(0, t) = g(t), (D[1](C))(10000, t) = 0

pds := pdsolve(PDE, [IBC], time = t, range = 0 .. 10000, timestep = 10, numeric, spacestep = 10)

_m2712135358688

(2)

k := pds:-plot(x = 6500, t = 0 .. 20000, numpoints = 600); plots[display]({k})

 

NULL

"f(t):= unapply(Spline( getdata(k)[3][..,1],getdata(k)[3][..,2],'t',degree=2),t): "

D1 := 15

E := 20000

L := 6500

n := 200

lambda = `&Sqrt;`(n*Pi/L, (1/2)*D1+`&Sqrt;`((1/4)*D1^2+E(`n&pi;`/L)^2))

"p(t):=(&int;)[0]^(L)f(t)  (e(-lambda^2 t) )^dt :"

Error, Got internal error in Typesetting:-Parse : "invalid subscript selector"

"p(t):=(&int;)[0]^Lf(t)  e(-lambda^2 t) dt :"

 

C(x, t) = sum((2*sin(`n&pi;x`/L)*exp(1)/L*sin(`n&pi;x`/L))*p(t), n = 1 .. 500)

Error, (in sum) summation variable previously assigned, second argument evaluates to 200 = 1 .. 500

 

uu20000 := [seq(evalf(C(20000-i, 5000)), i = 0 .. 20000, 100)]

``

xx := [seq(i, i = 0 .. 20000, 100)]

p1 := pds:-plot(t = 33000, numpoints = 150, color = red)

plots[display]({p1})

Download 1.mw

Hi there,

i am working on an inverse z-transform in MAPLE. I would like to get the Impulse Response for a transferfunction with coefficients a, b, and c.

(z-1)^2/(a*z^2+b*z+c)

In maple, however I get the impulse response with sums over _alpha=RootOf(Z^2...). Through substitution of n = 0...end I get the right result, but for long impulse responses this takes quite a lot of time. With mathematica, however, the inverse z-transform is calculated to 1/(f(b,c)*(g(b,c,))^n+...), where f and g are functions of the coefficients. The function out of mathematica are quite faster to solve. How can I get Maple to solve this equation efficiently?

Greetings

What is the reason Maple likes to do this

arccos(sin(x));

         Pi/2 - arcsin(sin(x))

Both are correct, but the first has leaf count of only 3 and the second expression has leaf count of 11.

Surely the first is simpler to look at and read so the second form is not simpler.

What is the logic behind this automatic transformation? And did Maple always do this?

I teach high school math where we use Maple. Some times some students who use Maple 2022 on Mac computers both older and new version of the OS, experience that the document won't react to simple things like plot, solve of loading packages with the "with" command. 

Any idea could be causing this? Because the error goes away if we load a new document within Maple or restart the program.

Found integration problem which causes server.exe to crash each time. I hope this can be used to help find why server.exe keeps crashing much more than before in Maple 2022.

 

This happens each time. The above is a typical example of what I have been saying all the time above server.exe crashing. It should not do that. If it can not solve the problem, it should simply return.

I hope these problems will be fixed in Maple 2023.

Any one can figure why it crashes?

Attached worksheet.


 

interface(version);

`Standard Worksheet Interface, Maple 2022.2, Windows 10, October 23 2022 Build ID 1657361`

restart;

integrand:=(2*x^2022+1)/(x^2023+x);
int(integrand,x);

(2*x^2022+1)/(x^2023+x)


 

Download crash_feb_3_2023.mw

 

This question stems from a previous question that has been perfectly resolved by acer and Carl Love, but as Carl Love mentioned the foldl function, today I attempted to experience its functionality (In order to understand the foldl or foldr function). But I encountered a small issue. 

s:="[ (0, 1), (1, 2), (1, 10), (2, 3), (3, 4), (4, 5),
(4, 9), (5, 6), (6, 7), (7, 8),(8, 9), (10, 11), (11, 12),
(11, 16), (12, 13), (13, 14), (14, 15), (15, 16)]";
with(StringTools):
L1:= "()[]": L2:= "{}{}":
X:=foldl(SubstituteAll,s,op([L1[1],L2[1]]),op([L1[2],L2[2]]),op([L1[3],L2[3]]),op([L1[4],L2[4]]));

Error, (in StringTools:-SubstituteAll) expecting 3 arguments, but got 2

I find it strange that foldl doesn't recognize SubstituteAll with three arguments. 

Isn't s and op([L1[i], L2[i]]) providing three arguments? Of course, s is constantly changing.

 

The goal is to replace the above string with:

{ {0, 1}, {1, 2}, {1, 10}, {2, 3}, {3, 4}, {4, 5},

    {4, 9}, {5, 6}, {6, 7}, {7, 8},{8, 9}, {10, 11}, {11, 12},

    {11, 16}, {12, 13}, {13, 14}, {14, 15}, {15, 16}}

 

Hey guys

I have a question using the piecewise function:

fa := unapply(piecewise(0 < x and x < a, k1, a < x and x < b, k2), x);

simplify(fa(x)) assuming 0 < a, 0 < x and x < a;

It should return k1, but it doesn't. Does anyone have a solution?

Sincerely,

Oliveira

First 16 17 18 19 20 21 22 Last Page 18 of 43