Vous êtes sur la page 1sur 16

In[4]:=

 

1

3

- 10

Row reduce

4

2

0

5

1

6

Input:

 
     

1

3

- 10

 

row reduce

4

2

0

 

5

1

6

Result:

1

0

2

0

1

- 4

0

0

0

Matrix plot:

 
 

1 2

3

1

1

2

2

3

3

 

1 2

3

Trace:

Step -by - step solution

2

Determinant:

 

Step -by - step solution

0

Matrix rank:

 

Step -by - step solution

2

Nullity:

Step - by - step solution

1

Characteristic polynomial:

- λ 3 + 2 λ 2 - λ

Eigenvalues:

λ 1 1

Step -by - step solution

Step -by - step solution

Printed by Wolfram Mathematica Student Edition

2

λ 2  1 λ 3  0 Eigenvectors : Step -by - step solution
λ 2  1
λ 3  0
Eigenvectors :
Step -by - step solution
v 1  ( 0, 1, 0 )
v 2  ( 1, 0, 0 )
v 3  (-2, 4, 1 )
Diagonalization:
M  S . J . S - 1
where
1
0
2
M
0
1
- 4
0
0
0
-
2
0
1
S
4 1
0
1 0
0
0
0
0
J
0
1
0
0
0
1
0
0
1
S - 1 
0
1
- 4
1
0
2
In[5]:= Solve[{ x1 + x3 ⩵ 1, x2 - x3 ⩵ - 3, x1 -
In[5]:=
Solve[{ x1 + x3 ⩵ 1, x2 - x3 ⩵ - 3, x1 - x2 ⩵ 2 } , { x1, x2, x3}]
{{ x1 → 0, x2 → - 2, x3 → 1}}
Out[5]=
In[6]:=
 x 2 dy  dx - 2 x y = 3 y 4 , y ( 1) = 12
Input interpretation:
x 2 × ∂ y ( x )
- 2 x y ( x )  3 y (x ) 4 , y ( 1 ) 
∂ x
1
2 

Printed by Wolfram Mathematica Student Edition

y ( x )

2 y ( x )

x

+ 3 y ( x ) 4

x

2

3

x ) x + 3 y ( x ) 4 x 2 3 Bernoulli's equation »

Alternate forms:

x ( x y ( x ) - 2 y ( x )) 3 y ( x) 4 , y ( 1 )

1 2

x 2 y ( x ) 3 y ( x ) 4 + 2 x y ( x ) , y ( 1 )

1 2

Differential equation solutions:

Differential equation solutions: 3 5 x 2 y ( x )  3 49 - 9
3 5 x 2 y ( x )  3 49 - 9 x 5
3
5
x 2
y ( x ) 
3 49 - 9 x 5
Possible intermediate steps:
Solve Bernoulli's equation
x 2 ⅆ y ( x )
- 2 x y ( x )  3 y( x ) 4
ⅆ x
, such that
y ( 1 ) 
1
ⅆ v ( x ) + 6 v ( x )
9
 -
ⅆ x
x
x 2

Approximate form

Solve as Bernoulli's equation |

6 v ( x ) 9  - ⅆ x x x 2 A p p

Printed by Wolfram Mathematica Student Edition

Hide steps

 

2

:

Divide both sides by

 
 

1

x 2 y ( x ) 4

- 3

 

:

 

3 y ( x )

6

9

 

x

-

y

( x ) 4 + x y ( x ) 3 - x 2

Let v ( x )

 

 
 

1

, which

y

( x ) 3

 

gives v ( x )

x

 
 

3 y( x )

 

x

:

-

 

y

( x )

4

4

Let μ ( x )  ⅇ x x x 6

Multiply both sides by

.

μ

( x )

:

x 6 v ( x )

+ 6 x 5 v ( x ) - 9 x 4

x

Substitute 6 x 5 x x 6

 

:

x 6 v ( x )

+

x x 6 v ( x ) - 9 x 4

 

x

Apply the reverse product rule

 

f g

x

+ g f

x

x ( f g )

 

to the

left-hand side:

x x 6 v ( x )  - 9 x 4

 

Integrate both sides with respect to x

:

x x 6 v ( x ) ⅆ x - 9 x 4 x

Evaluate the integrals:

 

x 6 v ( x ) - 5

9 x 5

+ c 1 , where c 1 is an arbitrary constant.

Divide both sides by

 

μ

( x )

x 6

:

 

- 9 x 5

+ c 1

v ( x )

5

x

6

Solve for y ( x )

in v ( x )

y ( x ) -

1

y ( x ) 3

3

-

5

x

2

or y ( x )

x

2

or y ( x )

(-

1 ) 2 / 3 x 2

Printed by Wolfram Mathematica Student Edition

:

3

-

9 x 5 + 5 c 1

3

- 9 x 5

+ c 1

3

- 9 x 5

+ c 1

 

5

5

Simplify the arbitrary constants:

 
 

3

-

5

x

2

x

2

(-

1 ) 2 / 3 x 2

y ( x ) -

or y ( x )

or y ( x)

 

3

-

9 x 5 + c 1

3

- 9 x 5

+ c 1

3

- 9 x 5

+ c 1

 

5

5

For y ( x )

5

2 3 5 - x - , solve for 3 - 9 x 5 +
2
3 5
-
x
-
,
solve for
3
- 9 x 5 + c 1
c 1
using the
initial conditions:
Substitute y ( 1 )  1
2
into y ( x )
3
2
-
5
x
-
:
3
-
9 x 5 + c 1
3
-
5
1
-
3
2
c 1 - 9
The equation has no solution.
y ( x )
2
3 5
-
x
-
3
- 9 x 5 + c 1
cannot satisfy the initial condition, which means no solution exists.
For y ( x )
2
x
,
solve for
9 x 5
3
- 5 + c 1
c 1
using the
initial conditions:
Substitute y ( 1 )  1
2

into y ( x )

Printed by Wolfram Mathematica Student Edition

6

 2 x : 9 x 5 3 - 5 + c 1 1 1
2
x
:
9
x 5
3
-
5 + c 1
1
1
2
c 1 - 9
3
5
Solve the equation:
49
c 1 
5
Substitute c 1  49
5
into y ( x )
2
x
:
9 x 5
3
- 5 + c 1
2
x
y ( x ) 
- 9 x 5
49
+
3
5
5
For y ( x )
1 ) 2 / 3 x 2
(-
, solve for
9 x 5
3
- 5 + c 1
c 1
using the
initial conditions:
Substitute y ( 1 )  1
2
into y ( x )
1 ) 2 / 3 x 2
(-
:
9 x 5
3
- 5 + c 1
(- 1 ) 2 / 3
1

3

c 1 - 9

5

2

Printed by Wolfram Mathematica Student Edition

y

(- 1 ) 2 / 3 x 2

9 x 5

3 - 5 + c 1

7

cannot satisfy the initial condition, which means no solution exists.

Collect solutions:

Answer:

y ( x )

3

x 2

- 9 x 5

+

49

5 5

Plots of the solution:

y

)  3 x 2 - 9 x 5 + 49 5 5 Plots of the

x

y

x 2 - 9 x 5 + 49 5 5 Plots of the solution: y x

y

Interactive differential equation solution plots:

y

3.0 2.5 2.0 y ( x) 1.5 1.0 x 1.1 1.2 1.3 0.0
3.0
2.5
2.0
y
( x)
1.5
1.0
x
1.1
1.2
1.3
0.0
Initial conditions: More controls

Initial conditions:

More controls

In[7]:=

dy/dx = y 2 + yx  x 2

Printed by Wolfram Mathematica Student Edition

 dy/dx =  y 2 + yx   x 2 Printed by Wolfram Mathematica

8

y ( x )

x

ODE names :

y

( x ) 2 + y ( x ) x

x

2

Bernoulli's equation:

y ( x )

y ( x ) + y ( x ) 2

x

x

2

Homogeneous equation:

y ( x )

y

( x ) 1 + y ( x )

x

x

1 + y ( x )  x x Homogeneous equation » Alternate form: y ′

Alternate form:

y ( x )

y ( x ) ( y ( x ) + x )

x 2

y ′ ( x )  y ( x ) ( y ( x ) +

Expanded form:

y ( x )

y ( x ) 2 + y ( x )

x

2

x

Differential equation solutions:

x y ( x )  c 1 - log ( x ) Possible intermediate
x
y ( x ) 
c 1 - log ( x )
Possible intermediate steps:
 y ( x ) 2 + x y ( x )
Solve ⅆ y ( x )
ⅆ x
x 2
Let y ( x )  x v( x )
, which gives
ⅆ y ( x )  x ⅆ v ( x )
+ v ( x )
ⅆ x
ⅆ x
ⅆ v ( x )
x 2 v ( x ) 2 + x 2 v ( x )
x
+ v ( x ) 
ⅆ x
x 2
Simplify:
ⅆ v ( x )
x
+ v ( x )  ( v ( x ) + 1 ) v (x )

Solve as a homogeneous equation |

) + 1 ) v (x ) ⅆ Solve as a homogeneous equation | ▾ Printed

Printed by Wolfram Mathematica Student Edition

Hide steps

:

:

x

9

Solve for v ( x )

x

v ( x )

x

v

( x ) 2

x

:

Divide both sides by v ( x ) 2

 

:

v ( x )

 

x

1

v ( x ) 2 x

 

Integrate both sides with respect to x

:

v ( x )

v

) 2 x

x

( x

1

x

x

Evaluate the integrals:

 
 

1

- v ( x ) log ( x ) + c 1 , where c 1 is an arbitrary constant.

 

Solve for v ( x )

 

:

1

v ( x ) -

log ( x ) + c 1

 

Substitute back for y ( x )

 

x v ( x )

 

:

Answer:

y ( x ) -

x

log ( x ) + c 1

Plots of sample individual solution:

y

log ( x ) + c 1 Plots of sample individual solution: y y ′ y

y

x ) + c 1 Plots of sample individual solution: y y ′ y ( 1

y ( 1 ) 1

Printed by Wolfram Mathematica Student Edition

log ( x ) is the natural logarithm »

10

y x Sample solution family: y 600 400 ( sampling y ( 1 )) 200
y
x
Sample solution family:
y
600
400
(
sampling y ( 1 ))
200
x
1.2
1.4
1.6
1.8
2.0
2.2
2.4
Interactive differential equation solution plots:
y (1 )  1.
y
60
40
y
( x)
20
x
1.5
2.0
2.5
- 20
Initial conditions:
y ( 1 )
More controls
In[10]:=  dy  dx = x   x 2 y + 4 y
In[10]:=
 dy  dx = x   x 2 y + 4 y ,y(1)=1
Input interpretation:
 ∂ y ( x )
x
+ 4 y ( x ) , y( 1 )  1
∂ x
x 2 y ( x )
Separable equation:
x
y ′ ( x ) y ( x ) 
4 + x 2

Printed by Wolfram Mathematica Student Edition

11

11

Alternate form:

y ( x )

x 2 +

x 4y ( x ) , y ( 1 ) 1

Alternate form assuming x is positive:

x

 x 2 + 4y ( x ) y ( x ) , y ( 1 ) 1

Differential equation solutions:

Differential equation solutions: Possible intermediate steps: Solve ⅆ y ( x ) ⅆ x  ,

Possible intermediate steps:

Solve y ( x )

x

, such that

This means

x

4 y ( x )+ x 2 y ( x )

Printed by Wolfram Mathematica Student Edition

Approximate form

Transform into an exact equation |

Hide steps

y

( x )

logx 2 + 4+ 1 - log ( 5 )

y ( x )  log  x 2 + 4  + 1 - log

y

( 1 ) 1

:

Rewrite the equation:

 

-

x x 2 y ( x ) + y( x )

x

4 y ( x ) +

0

 

Let R ( x , y )

 
 

-

x 4 y + x 2 y

and

 

S

( x , y )

1

.

This is not an exact equation, because

 

x

 
 

-

R ( x , y)

y

4 y +

x 2 y 1 S ( x , y )

x

Find an integrating factor μ ( y ) such that

μ ( y ) R( x , y) + y ( x ) μ ( y ) S ( x , y ) 0

x

 

.

is exact.

12

y ( μ ( y ) R ( x , y ))

x ( μ ( y ) S ( x , y ))

 

:

 

ⅆμ ( y )

y

x 2 + μ ( y ) x x 2 + 4

x

4 y + y x 2 2

 

-

0

4 y + y

Isolate μ ( y ) to the left-hand side:

 

∂μ ( y )

 

1

y

 

μ ( y )

y

Integrate both sides with respect to y log ( μ ( y )) log ( y)

 

:

Take exponentials of both sides:

 

μ ( y ) y

 

Multiply both sides of

 

-

4 y ( x )+x 2 y ( x ) + y ( x )

x

x

0

 

by

μ ( y ( x ))

 

:

-

+ 4 + y ( x ) y( x )

x

x

0

 

x

2

Let P ( x , y ) - x

x 2 + 4

 

and

 

Q

( x , y ) y

 

.

This is an exact equation, because

 

P ( x , y )

 

y

0

Q ( x , y )

 

.

x

Define f ( x , y ) such that

f ( x , y )

x

P( x , y )

Printed by Wolfram Mathematica Student Edition

and

13

∂ f ( x , y )  Q ( x, y ) ∂ y
∂ f ( x , y )
 Q ( x, y )
∂ y
.
:
Then, the solution will be given by
f
( x , y )  c 1
, where
c
1
is an arbitrary constant.
Integrate ∂ f ( x , y )
x
with respect to
x
in order to find
f ( x , y )
:
f ( x , y )
∫ - x
4 ⅆ x
2
x
+
1
logx 2 + 4 + g ( y )
where
- 2
g
( y )
is an arbitrary function of
y
.
Differentiate
f ( x , y )
with respect to
y
in order to find
g ( y )
∂ f ( x, y )
:
1
ⅆ g ( y)
- 2 log x 2 + 4 + g ( y )
∂ y
∂ y
ⅆ y
Substitute into
f ( x , y )
Q ( x, y )
:
∂ y

g ( y )

y

y

Integrate g ( y )

y

Printed by Wolfram Mathematica Student Edition

14

with respect to y

g

( y )

 

:

 

y y

 

 

y

2

2

 

Substitute g ( y ) into f ( x , y )

 

:

f

( x , y )

y

2

2

1

- 2 logx 2 + 4

 

The solution is

 

f

( x , y ) c 1

 

:

y

2

 

1

2

- 2 logx 2 + 4 c 1

 

Solve for y

 

:

y

( x ) -

 

logx 2 + 4+ 2 c 1

 

or y ( x )

logx 2 + 4+ 2 c 1

Simplify the arbitrary constants:

 

y

( x ) -

 

logx 2 + 4+ c 1

or y ( x )

logx 2 + 4+ c 1

For y ( x )

 

 

-

logx 2 + 4+ c 1

 

, solve for

c

1

using the

initial conditions:

 

Substitute y ( 1 ) 1 into y ( x )

 

-

logx 2 + 4+ c 1

 

:

-

c 1 + log ( 5 )

1

Printed by Wolfram Mathematica Student Edition

y ( x )

-

logx 2 + 4+ c 1

15

cannot satisfy the initial condition, which means no solution exists.

For y ( x )

logx 2 + 4+ c 1

, solve for

c 1

using the

initial conditions:

Substitute y ( 1 ) 1 into y ( x )

logx 2 + 4+ c 1

:

c 1 + log ( 5 )

1

Solve the equation:

c 1 1 - log ( 5 )

Substitute c 1 1 - log( 5 ) into y ( x )

 

logx 2 + 4+ c 1

:

y ( x )

logx 2 + 4+ 1 - log ( 5 )

Collect solutions:

Answer:

y ( x )

logx 2 + 4+ 1 - log( 5 )

Plots of the solution:

y

2 + 4  + 1 - log ( 5 ) Plots of the solution: y

x

y

 + 1 - log ( 5 ) Plots of the solution: y x y ′

y

Printed by Wolfram Mathematica Student Edition

log ( x ) is the natural logarithm »

16

Interactive differential equation solution plots: y 1.8 1.6 y ( x) 1.4 1.2 x 2
Interactive differential equation solution plots:
y
1.8
1.6
y ( x)
1.4
1.2
x
2
3
4
5
0.8
Initial conditions:
More controls

Printed by Wolfram Mathematica Student Edition