Rouben Rostamian

MaplePrimes Activity


These are replies submitted by Rouben Rostamian

@verdin The original eq[2] was undefined at (0,0,0).  The modified one is well-defined at (0,0,0), however it is not differentiable there, and therefore the equation cannot be linearized.  Here are the details.

restart;

Let's focus on eq[2]:

eq[2]:=diff(x2(t), t)+((N1*N2*N3+(x3(t)+V1)*(x2(t)+N1*N2*N3))*(x1(t)+N1*N2*N3)-2*N3*N1*N2*(x2(t)+N1*N2*N3))*x1(t)*(x2(t)+N1*N2*N3)^2/(N2*N1*(((-N1*N2-x2(t)-N1*N2*N3)*(x1(t)+N1*N2*N3)+N3*N1*N2*(x2(t)+N1*N2*N3))*ln(((N1*N2+x2(t)+N1*N2*N3)*(x1(t)+N1*N2*N3)-N3*N1*N2*(x2(t)+N1*N2*N3))/(N1*N2*(x1(t)+N1*N2*N3)))+(x2(t)+N1*N2*N3)*x1(t))*(x1(t)+N1*N2*N3)):

Rearrange eq[2] so that the term with derivative is on the left-hand side:

de2 := isolate(eq[2], diff);

diff(x2(t), t) = -((N1*N2*N3+(x3(t)+V1)*(x2(t)+N1*N2*N3))*(x1(t)+N1*N2*N3)-2*N3*N1*N2*(x2(t)+N1*N2*N3))*x1(t)*(x2(t)+N1*N2*N3)^2/(N2*N1*(((-N1*N2-x2(t)-N1*N2*N3)*(x1(t)+N1*N2*N3)+N3*N1*N2*(x2(t)+N1*N2*N3))*ln(((N1*N2+x2(t)+N1*N2*N3)*(x1(t)+N1*N2*N3)-N3*N1*N2*(x2(t)+N1*N2*N3))/(N1*N2*(x1(t)+N1*N2*N3)))+(x2(t)+N1*N2*N3)*x1(t))*(x1(t)+N1*N2*N3))

On the right-hand side of de2, replace x1(t) by x1, etc.;

F := subs(x1(t)=x1, x2(t)=x2, x3(t)=x3, rhs(de2));

-((N1*N2*N3+(x3+V1)*(N1*N2*N3+x2))*(N1*N2*N3+x1)-2*N3*N1*N2*(N1*N2*N3+x2))*x1*(N1*N2*N3+x2)^2/(N2*N1*(((-N1*N2*N3-N1*N2-x2)*(N1*N2*N3+x1)+N3*N1*N2*(N1*N2*N3+x2))*ln(((N1*N2*N3+N1*N2+x2)*(N1*N2*N3+x1)-N3*N1*N2*(N1*N2*N3+x2))/(N1*N2*(N1*N2*N3+x1)))+(N1*N2*N3+x2)*x1)*(N1*N2*N3+x1))

The expression F is well-defined at (0,0,0):

eval(F, [x1=0,x2=0,x3=0]);

0

However, F is not differentiable at (0,0,0) as expanding it in Taylor series about (x1,x2,x3)=(0,0,0) fails:

mtaylor(F, [x1,x2,x3]);

Error, (in mtaylor) does not have a Taylor expansion

To investigate the source of the problem, we look at the numerator and denominator of F separately:

n := numer(F);

(N1^2*N2^2*N3^2*V1+N1^2*N2^2*N3^2*x3-N1^2*N2^2*N3^2+N1*N2*N3*V1*x1+N1*N2*N3*V1*x2+N1*N2*N3*x1*x3+N1*N2*N3*x2*x3+N1*N2*N3*x1-2*N1*N2*N3*x2+V1*x1*x2+x1*x2*x3)*x1*(N1*N2*N3+x2)^2

d := denom(F);

N2*N1*(N1^2*N2^2*N3*ln(((N1*N2*N3+N1*N2+x2)*(N1*N2*N3+x1)-N3*N1*N2*(N1*N2*N3+x2))/(N1*N2*(N1*N2*N3+x1)))+N1*N2*N3*ln(((N1*N2*N3+N1*N2+x2)*(N1*N2*N3+x1)-N3*N1*N2*(N1*N2*N3+x2))/(N1*N2*(N1*N2*N3+x1)))*x1-x1*N1*N2*N3+N1*N2*ln(((N1*N2*N3+N1*N2+x2)*(N1*N2*N3+x1)-N3*N1*N2*(N1*N2*N3+x2))/(N1*N2*(N1*N2*N3+x1)))*x1+ln(((N1*N2*N3+N1*N2+x2)*(N1*N2*N3+x1)-N3*N1*N2*(N1*N2*N3+x2))/(N1*N2*(N1*N2*N3+x1)))*x1*x2-x2*x1)*(N1*N2*N3+x1)

Expand the numerator and the denominator separately in Taylor series:

n_expanded := mtaylor(n, [x1,x2,x3], 3);

N1^4*N2^4*N3^4*(V1-1)*x1+N1^3*N2^3*N3^3*(V1+1)*x1^2+N1^3*N2^3*N3^3*(3*V1-4)*x2*x1+N1^4*N2^4*N3^4*x3*x1

d_expanded := mtaylor(d, [x1,x2,x3], 3);

(1/2)*N1^2*N2^2*N3^2*x1^2

The right-hand side of the the differential equation is the ratio of those two:

simplify(n_expanded/d_expanded);

2*N1*(N2*N3*(V1+x3-1)*N1+(x1+3*x2)*V1+x1-4*x2)*N2*N3/x1

The x1 in the denominator indicates that eq[2] cannot be linearized about (x1,x2,x3)=(0,0,0).

 

Download mw.mw

In your worksheet you have eq[1], eq[3], eq[3].  I assume that the middle one is meant to be eq[2].

Let's evaluate your eq[2] at (x1,x2,x3)=(0,0,0):
eval(eq[2], [x1(t)=0, x2(t)=0, x3(t)=0]);

We see that Maple complains with:
Error, numeric exception: division by zero

This says that your eq[2] is undefined at (x1,x2,x3)=(0,0,0), therefore linearizing about (x1,x2,x3)=(0,0,0) is not meaningful. You need to think that over.

 

@Carl Love As the parameter y changes, the graph of the function makes a transition from having two extrema (the blue curve below), to having a flat plateau (red curve) to monotone decreasing (green curve).  At the plateau both the first and second derivatives are zero.

restart;

F := (x,y) -> x^2+y*(1-x)^(3/4);

proc (x, y) options operator, arrow; x^2+y*(1-x)^(3/4) end proc

solve({diff(F(x,y),x) = 0, diff(F(x,y),x,x) = 0}); evalf(%);

{x = 4/5, y = (32/75)*5^(3/4)}

{x = .8000000000, y = 1.426645984}

plot([F(x,1.3),  F(x,1.4266), F(x,1.6)], x=0..1, color=[blue,red,"Green"]);

@jan123 The labels (x and y in this case) are taken from the names of the variables in the equations in sys, but you may override them by specifying labels explicitly.  For instance,

 

DEtools:-DEplot(sys, [x(t),y(t)], t=-2..2, [ic], x=-1..1, y=-1..1,
    linecolor=blue, color=red, thickness=1, tickmarks=[0,0],
    labels=[e__1, e__2]);

There is no direct way of specifying label positions; they are placed automatically by Maple. For full control, you may disable the labels altogether, as in:
p1 := DEtools:-DEplot(sys, [x(t),y(t)], t=-2..2, [ic], x=-1..1, y=-1..1,
    linecolor=blue, color=red, thickness=1, tickmarks=[0,0],
    labels=["",""]);

and then design your own labels with the help of plots:-textplot(), as in

p2 := plots:-textplot([[0.9,-0.1,e__1], [0.1,0.9,e__2]]);

and then display p1 and p2 together:

plots:-display([p1,p2]);

 

@Carl Love I also see the behavior described by the OP.  Perhaps that's specific to Linux.  Here's what I see:

restart;

kernelopts(version);

`Maple 2018.1, X86 64 LINUX, Jun 8 2018, Build ID 1321769`

interface(version);

`Standard Worksheet Interface, Maple 2018.1, Linux, June 8 2018 Build ID 1321769`

prettyprint=3 is the default:

interface(prettyprint);

3

solve(x^2-1,x);

1, -1

Let prettyprint=1:

interface(prettyprint=1);

                                   3, [3]

solve(x^2-1,x);

                                    1, -1

Download mw.mw

@Alger

restart;

Let

C := (n,x) -> cos(n*Pi*ln(x/a)/b);

proc (n, x) options operator, arrow; cos(n*Pi*ln(x/a)/b) end proc

where

params := a = x1, b = ln(x2/x1)/2;

a = x1, b = (1/2)*ln(x2/x1)

Let's verify that "{C(n,x): n=0.. infinity}" is an orthogonal family on the interval x1, x2

in the L^2 norm with the weight 1/x.  Maple has some difficulty in calculating the definite

integral (I don't know why), therefore I will calculate the indefinite integral first,

and then plug in the end points.

z1 := int(C(n,x)*C(m,x)/x, x);

(1/2)*b*sin(Pi*ln(x/a)*(m-n)/b)/(Pi*(m-n))+(1/2)*b*sin(Pi*ln(x/a)*(m+n)/b)/(Pi*(m+n))

z2 := eval(z1, {params});

(1/4)*ln(x2/x1)*sin(2*Pi*ln(x/x1)*(m-n)/ln(x2/x1))/(Pi*(m-n))+(1/4)*ln(x2/x1)*sin(2*Pi*ln(x/x1)*(m+n)/ln(x2/x1))/(Pi*(m+n))

Plug in the lower limit:

eval(z2, x=x1);

0

Plug in the upper limit:

eval(z2, x=x2) assuming m::integer, n::integer;

0

This shows the orthogonality of the C(n, x) functions.

 

I expect that the remaining orthogonality conditions may be verified in the same

way but I haven't actually done it.

 

 

 

 

Download orthogonality.mw

@Kitonum That's a nice animation—the red segments stand out and nicely demonstrate their equal lengths and orthogonality.

It is interesting that when one of the sides of the quadrilateral degenerates to zero length, that is, when the quadrilateral turns into a triangle (even a right triangle!), the theorem's assertion still remains valid and nontrivial.  I don't recall having seen that special case stated anywhere.  One would think that Euclid would have noticed that.

 

@Markiyan Hirnyk I invite you to go back and read (carefully now!) the reply under the heading "Yes, I have the response" and don't pull things out of your imagination, or somewhere else.

 

@Markiyan Hirnyk I am not going to stop you from laughing, but consider reading carefully what is written rather than what you imagine is written.  And an apology will not hurt either.

@Markiyan Hirnyk The introduction of biorthogonality in this discussion is a red herring.  For the purpose applying the Fourier transform, what is needed is the orthogonality of the basis functions which in the context this problem consists of the family
{ C(n,x), S(m,x) }n = 0...∞, m = 1...∞,
and where the orthogonality is relative to the given weighted L2 inner product.  I pointed out that family of functions given in the original post was not orthogonal, that's why an attempt to apply the Fourier transform was leading to an incorrect result.   The family of functions in the amended post is orthogonal, therefore applying the Fourier transform is legitimate in that case.  That's all.

 

@Alger OK, then.  After that change, the issue raised in your original post should go away.

@vv Nice application of complex algebra!

Digging through my archive of Maple files, I found this animation from some yeara ago:

prob-02-quad.mw

@ibndirac I don't quite understand the setting of this problem. On the one hand you impose boundary conditions at x=0 and x=L, perhaps implying that you seek a solution g(x,t) where 0 < x < L. On the other hand, to determine beta, you need the values of g(x,t) for all x ∈ (−∞,∞). What is the domain of g? Some clarification is needed.

You will get more helpful responses if you post a real worksheet rather than snippets, especially since the snippets that you have posted seem to be inaccurate.  For instance, what is the meaning of the derivative diff(g(x, t), v) since g(x,t) has no v in it?

To post a worksheet, click the big fat green arrow that appears in the toolbar of the window where you edit your message for posting.

First 57 58 59 60 61 62 63 Last Page 59 of 99