R5.3
Problem Statement
Verify using the Gramian that the following two vectors are linearly independent.


Solution

We know from (3) 8-9 that:

We obtain,


Then,

b_1 and b_2 are linearly independent
R5.6
solved by Luca Imponenti
Problem Statement
Complete the solution to the following problem

where
![{\displaystyle y_{h}=e^{-2x}[Acos(3x)+Bsin(3x)]\!}](../../792e67f127ff688d55ed48d9f0303345b9a28184.svg)
and
![{\displaystyle y_{p}=xe^{-2x}[Mcos(3x)+Nsin(3x)]\!}](../../96a697d5683642f371e1127b4a15314d1a2b93f0.svg)
Find the overall solution
corresponds to the initial condition:

Plot the solution over 3 periods.
Particular Solution
Taking the derivatives of the particular solution 
![{\displaystyle y_{p}=xe^{-2x}[Mcos(3x)+Nsin(3x)]\!}](../../96a697d5683642f371e1127b4a15314d1a2b93f0.svg)
![{\displaystyle y'_{p}=e^{-2x}[sin(3x)(N-2Nx-3Mx)+cos(3x)(3Nx+M-2Mx)]\!}](../../4229480759610de8da772b0745c06b16b70b56ae.svg)
![{\displaystyle y''_{p}=e^{-2x}[sin(3x)(12Mx-6M-5Nx-4N)+cos(3x)(6N-5Mx-4M-12Nx)]\!}](../../57b163ea521277f918af0d523c1e8f0ca8e234ff.svg)
Plugging these into the ODE yields
![{\displaystyle 13x[Mcos(3x)+Nsin(3x)]=2cos(3x)\!}](../../d9655d1493f66fa3a0f7589a9c3631d9b4476def.svg)
Equating like terms allows us to solve for M and N
![{\displaystyle sin(3x)[(12Mx-6M-5Nx-4N)+4(N-2Nx-3Mx)+13Nx]=0\!}](../../a020f3dd194ee3d5cfeabb37b2da5e9f270c8290.svg)
![{\displaystyle cos(3x)[(6N-5Mx-4M-12Nx)+4(3Nx+M-2Mx)+13Mx]=2cos(3x)\!}](../../61f7febe8c0331fa45a5d99aafb6b7551136061a.svg)



So the particular solution is

Overall Solution
The overall solution in the sum of the homogeneous and particular solutions

![{\displaystyle y(x)=e^{-2x}[Acos(3x)+Bsin(3x)]+{\frac {1}{3}}xe^{-2x}sin(3x)\!}](../../b9ba4455133d526b6750b7d4ad088a2b3ebeb60a.svg)
To find A and B we apply the initial conditions


Taking the derivative
![{\displaystyle y'(x)={\frac {d}{dx}}[e^{-2x}[cos(3x)+Bsin(3x)]+{\frac {1}{3}}xe^{-2x}sin(3x)]\!}](../../8363fdca8c2a01fd5519870363c110a30f746261.svg)
![{\displaystyle y'(x)=e^{-2x}[(3B+x-2)cos(3x)-(2B+{\frac {2}{3}}x+{\frac {8}{3}})sin(3x)]\!}](../../c86f7dc58a6220ae49af31a9fe4e261acfa83019.svg)


Giving us the overall solution
![{\displaystyle y(x)=e^{-2x}[cos(3x)+{\frac {2}{3}}sin(3x)+{\frac {1}{3}}xsin(3x)]\!}](../../c0df58d196d9072113ac3bbd23846cbeaa804059.svg)
Plot
The period for
is 
Plotting the solution
over 3 periods yields

R5.8
Solution
For
:
For substitution by parts,


Therefore:

Using the General Binomial Theorem:

Therefore:
Which we have previously found that answer as:

For
:
Initially we use the following substitutions:
First let us consider the first term: 
Next, we use the integration by parts:



Next let us consider the second term: 
Again, we will use integration by parts:



Therefore:


Re-substituting for t:



Therefore:

Using the General Binomial Theorem for the integral with t substitution
:

Therefore:
Which we have previously found that answer as:

R5.9
Solved by: Gonzalo Perez
Problem Statement
Consider the L2-ODE-CC (5) p.7b-7 with
as excitation:
(5) p.7b-7
(1) p.7c-28
and the initial conditions
.
Part A
Project the excitation
on the polynomial basis
(1)
i.e., find
such that
(2)
for x in
, and for n = 3, 6, 9.
Plot
and
to show uniform approximation and convergence.
Note that:
(3)
Solution
To solve this problem, it is important to know that the scalar product is defined as the following:
.
Therefore, it follows that:
, where
and
.
We know that if
are linearly independent, then by theorem on p.7c-37, the matrix is solvable.
According to this and (3)p.8-14:
If
exists
. (3)p.8-14
Now let's define the Gram matrix
as a function of
:
(1)p.8-13
Defining the "d" matrix as was done in (3)p.8-13, we get:
. (3)p.8-13
And according to (1)p.8-15:
(1)p.8-15
Now, we can find the values to compare
to
.
Using Matlab, this is the code that was used to produce the results:
The Matlab code above produced the following graph:
Where
is represented by the dashed line and the approximation,
, is represented by the red line. This code can work for all n values.
Part B
In a seperate series of plots, compare the approximation of the function
by Taylor series expansion about
.
Where: 
Solution
For n=1:

For n=2:

For n=3:

For n=4:

For n=5:

For n=6:

For n=7:

For n=8:

For n=9:

For n=10:

For n=11:

For n=12:

For n=13:

For n=14:

For n=15:

For n=16:

Using Matlab to plot the graph:
Part 2
Find
such that:
(1) p.7c-27
with the same initial conditions as in (2) p.7c-28.
Plot
for n = 3, 6, 9, for x in
.
In a series of separate plots, compare the results obtained with the projected excitation on polynomial basis to those with truncated Taylor series of the excitation. Plot also the numerical solution as a baseline for comparison.