# University of Florida/Egm4313/IEA-f13-team10/R3
## Report 3
### Problem 1
#### Problem Statement

Find the complete homogeneous solution using variation of parameters $16y''+8y'+y=r(x)$

#### Solution

$16y''+8y'+y=0$
The solution is $y=e^{rx}$ Therefore, $y'=re^{rx}$ and $y''=r^{2}e^{rx}$
Plugging this back into the original homogeneous equation, $e^{rx}(16r^{2}+8r+1)=0$ $16r^{2}+8r+1=0$ $(4r+1)(4r+1)=0$ so $r=-1/4$ $y_{h}=y_{1,h}+y_{2,h}=y_{1,h}+xy_{1,h}$ $y_{h}(x)=cbar_{1}e^{-x/4}+cbar_{2}xe^{-x/4}$
Checking the answer $y_{2}=u(x)y_{1}$ $y=e^{-x/4}$ $y=-1/4*e^{-x/4}$ $y=1/16*e^{-x/4}$ $y'_{2}=u'y_{1}+uy'_{1}$ $y''_{2}=u''y_{1}+2u'y'_{1}+uy''$
Plugging this into the original homogeneous equation $16(u''y_{1}+2u'y'_{1}+uy''_{1})+8(u'y_{1}+uy'_{1})+(uy)=0$
Plugging in values for y and its derivatives, everything cancels out to zero.

#### Honor Pledge

On our honor, we solved this problem on our own, without aid from online solutions or solutions from previous semesters.

### Problem 2
#### Problem Statement

Find and plot the solution for the L2-ODE_CC
$y''-10y'+25y=r(x)$ $y(0)=1,y'(0)=1,r(x)=0$

#### Solution

$y''-10y'+25y=r(x)$
$y''-10y'+25y=0$
This is a linear, first order ODE with constant coefficients.
To find the general solution to this ODE set $y=e^{rx}$
so that $y'=re^{rx}$ and $y''=r^{2}e^{rx}$
Substituting in y to the ODE and factoring out $e^{rx}$ we get:
$r^{2}-10r+25=0$
Using the quadratic formula to solve for r we get
$r={\frac {-b\pm {\sqrt {b^{2}-4ac}}}{2a}}$ where $a=1,b=-10,$ and $c=25$
Solving to get $r=5$
Since we have a repeated root, we need to find v(x) so that y2(x) = v(x)y1(x)
Taking the first and second derivative of y2(x) we get:
$y_{2}'(x)=v'(x)y_{1}(x)+v(x)y_{1}'(x)$
$y_{2}''(x)=v''(x)y_{1}(x)+2v'(x)y_{1}(x)+v(x)y_{1}''(x)$
Substituting into the original ODE, we get:
$(v''(x)y_{1}(x)+2v'(x)y_{1}(x)+v(x)y_{1}''(x))-10(v'(x)y_{1}(x)+v(x)y_{1}'(x))+25(v(x)y1(x))=0$
solving for $v''(x)=0$ so v(x) = kx + c
So y2(x) = x y1(x)
We get the general solution $y(x)=C_{1}e^{5x}+C_{2}xe^{5x}$
Now with the initial values y(0) = 1 and y'(0) = 0
$y(0)=C_{1}=1$
$y'(0)=5(1)+C_{2}=0$
$C_{1}=1$ , $C_{2}=-5$
$y(x)=e^{5x}-5xe^{5x}$

#### Honor Pledge

On our honor, we solved this problem on our own, without aid from online solutions or solutions from previous semesters.

### Problem 3
#### Problem Statement
##### Problem Sec 2.4 problem 3

How does the frequency of the harmonic oscillation change if we (i) double the mass (ii) take a spring of twice the modulus?

##### Problem Sec 2.4 problem 4

Could you make a harmonic oscillation move faster by giving the body a greater push?

#### Solution
##### Problem Sec 2.4 problem 3
###### Part 1

$\omega ={\sqrt {\frac {k}{m}}}$
$f={\frac {\omega }{2\pi }}={\frac {\sqrt {\frac {k}{m}}}{2\pi }}$
Now double the mass
$f={\frac {\omega }{2\pi }}={\frac {\sqrt {\frac {k}{2m}}}{2\pi }}$
$f={\frac {\sqrt {\frac {k}{m}}}{2{\sqrt {2}}\pi }}$
The frequency is decreased by ${\sqrt {2}}$.

###### Part 2

Multiply k by 2
$f={\frac {{\sqrt {2}}{\sqrt {\frac {k}{m}}}}{2\pi }}$ The frequency is increased by ${\sqrt {2}}$.

##### Problem Sec 2.4 problem 4

No because frequency depends on the ratio of the spring modulus and mass.

#### Honor Pledge

On our honor, we solved this problem on our own, without aid from online solutions or solutions from previous semesters.

### Problem 4
#### Problem Statement
##### Section 2.4 Problem 16

Show the maxima of an underdamped motion occur at equidistant t-values and find the distance.

##### Section 2.4 Problem 17

Determine the values of t corresponding to the maxima and minima of the oscillation $y(t)=e^{-t}sin(t)$. Check your result by graphing y(t).

#### Part 1=

The general solution of underdamped motion is
$y(t)=Ce^{\alpha t}cos(\omega ^{*}t-\delta )$ The maximas occur at $y(t)=Ce^{\alpha t}$ Set the two equations equal to each other a solve for t.
$Ce^{\alpha t}=Ce^{\alpha t}cos(\omega ^{*}t-\delta )$ $1=cos(\omega ^{*}t-\delta )$ $\cos ^{-1}(1)=\omega ^{*}t-\delta$ $t={\frac {2\pi n+\delta }{\omega ^{*}}}$ where n=0,1,2,3.....

###### Part 2

$tan(\delta )={\frac {B}{A}}$ shows delta is a constant.
The periodic distance between maximas is ${\frac {2\pi }{\omega }}$

##### Section 2.4 Problem 17

$y(t)=e^{-t}sin(t)$ $y'(t)=e^{-t}[-sin(t)+cos(t)]$
To find critical points, set y'(t)=0
$e^{-t}[-sin(t)+cos(t)]=0$ $[-sin(t)+cos(t)]=0$ $sin(t)=cos(t)$ ${\frac {sin(t)}{cos(t)}}=1$ $tan(t)=1$ $t=\tan ^{-1}(1)$ $t=n\pi +{\frac {\pi }{4}}$where n=0,1,2,3...
As seen in the graph, the maximum of t was at ${\frac {\pi }{4}}$ and the minimum was at ${\frac {5\pi }{4}}$.

#### Honor Pledge

On our honor, we solved this problem on our own, without aid from online solutions or solutions from previous semesters.

### Problem 5
#### Problem Statement

Using the formula for Taylor series at x = 0 (the origin, i.e., McLaurin series), develop into Taylor series at the origin x = 0 for the following functions: cos x, sin x, exp(x), tan x, and write these series in compact form with the summation sign and a single summand.

#### Solution

Part 1
cos x
Taylor Series: $f(x)=sum({\frac {1}{n!}})(f^{n)(x_{o}))(x-x_{o})^{n})$
when $x_{o}=0$
$f(x)=\cos(x):$
$f(0)=\cos(0)=1$
$f'(0)=-\sin(0)=0$
$f''(0)=-\cos(0)=-1$
$f'''(0)=\sin(0)=0$
$f(0)=sum({\frac {(-1)^{n}x^{2}n}{2n!}})$
$f(0)=1-{\frac {x^{2}}{2!}}+{\frac {x^{4}}{4!}}-{\frac {x^{6}}{6!}}+{\frac {x^{8}}{8!}}-{\frac {x^{1}0}{10!}}+....$
n = 0, 1, 2, 3 ... N
2n = 0, 2, 4, 6, ... 2N
$cos(x)=sum({\frac {(-1)^{n}x^{2}n}{2n!}})$
Part 2
sin x
Taylor Series: $f(x)=sum({\frac {1}{n!}})(f^{n)(x_{o}))(x-x_{o})^{n})$
when $x_{o}=0$
$f(x)=\sin(x):$
$f(0)=\sin(0)=0$
$f'(0)=\cos(0)=1$
$f''(0)=-\sin(0)=0$
$f'''(0)=-\cos(0)=-1$
$f(0)=(-1)^{n+1)sum({\frac {x^{2n-1)}{(2n-1)!}})$
$sin(x)={\frac {x}{1!}}-{\frac {x^{2}}{3!}}+{\frac {x^{5}}{5!}}-{\frac {x^{7}}{7!}}+....$
$sin(x)=(-1)^{n+1)sum({\frac {x^{2n-1)}{(2n-1)!}})$
Part 3
exp x
Taylor Series: $f(x)=sum({\frac {1}{n!}})(f^{n)(x_{o}))(x-x_{o})^{n})$
when $x_{o}=0$
$f(x)=e^{x}:$
$f(0)=e^{0}=1$
$f'(0)=e^{0}=1$
$f''(0)=e^{0}=1$
$f'''(0)=e^{0}=1$
$e^{x}={\frac {x}{1!}}+{\frac {x^{2}}{2!}}+{\frac {x^{3}}{3!}}+{\frac {x^{4}}{4!}}+....$
$e^{x}=sum({\frac {x^{n}}{n!}})$

#### Honor Pledge

On our honor, we solved this problem on our own, without aid from online solutions or solutions from previous semesters.

### Problem 6
#### Problem Statement

Part 1
Find and plot the solution for the L2-ODE-CC
$y''+4y'+13y=r(x)$
Initial conditions: y(0) = 1, y'(0) = 0
No excitation: r(x) = 0
Part 2
In another Fig., superpose 3 Figs.: (a) this Fig., (b) the Fig. in R2.6 P. 5-6, (c) the Fig. in R2.1 P. 3-7.

#### Solution

Part 1
$y''+4y'+13y=0$
The characteristic equation of the given ODE is:
$\lambda ^{2}+4\lambda +13=0$
Using the quadratic formula to solve for $\lambda$
$\lambda ={\frac {-b\pm {\sqrt {b^{2}-4ac}}}{2a}}$ where $a=1,b=4,c=13$
Solving to get $\lambda ={\frac {-4\pm 6i}{2}}$
$\lambda _{1}=-2+3i$, $\lambda _{2}=-2-3i$
Therefore, the general solution of the given ODE is $y=e^{-2x}[C_{1}\cos 3x+C_{2}\sin 3x]$
Now we solve for $C_{1}$, $C_{2}$ using the given initial conditions
We have $y(0)=1$
Substituting $x=0,y=1$ into $y=e^{-2x}[C_{1}\cos 3x+C_{2}\sin 3x]$,
We get,
$1=e^{-2(0)}[C_{1}\cos 3(0)+C_{2}\sin 3(0)]$
$1=C_{1}\cos 3(0)+C_{2}\sin 3(0)$
$1=C_{1}$
We have $y'(0)=0$
Differentiating $y=e^{-2x}[C_{1}\cos 3x+C_{2}\sin 3x]$, we get:
$y'=-2e^{-2x}[C_{1}\cos 3x+C_{2}\sin 3x]+e^{-2x}[-3C_{1}\cos 3x+3C_{2}\sin 3x]$ .
Substituting $x=0,y'=0$ into $y'=-2e^{-2x}[C_{1}\cos 3x+C_{2}\sin 3x]+e^{-2x}[-3C_{1}\cos 3x+3C_{2}\sin 3x]$, we get:
$0=-2e^{-2(0)}[C_{1}\cos 3(0)+C_{2}\sin 3(0)]+e^{-2(0)}[-3C_{1}\cos 3(0)+3C_{2}\sin 3(0)]$
$0=-2C_{1}+3C_{2}$
$2C_{1}=3C_{2}$
$2(1)=3C_{2}$
$C_{2}=2/3$
Therefore, we get $C_{1}=1,C_{2}=2/3$
Hence the solution of the given ODE is $y=e^{-2x}[\cos 3x+2/3\sin 3x]$
Fig. 1:
Part 2
$x=0:0.2:20$
$y=e^{-2x}[\cos 3x+2/3\sin 3x]$
$y_{2}=e^{5x}-5xe^{5x}$
$y_{3}={\frac {5}{7}}e^{-2x}+{\frac {2}{7}}e^{5x}$
Fig. 2:
Fig. 3:
Fig. 4:

#### Honor Pledge

On our honor, we solved this problem on our own, without aid from online solutions or solutions from previous semesters.

### Problem 7
#### Problem Statement

Consider the same system as in the Example p.7-3, i.e., the same L2-ODE-CC (4) p.5-5 and initial condi- (2) p.3-4, but with the following excitation: $r(x)=7e^{5x}-2x^{2}$

#### Solution

$y''-10y'+25y=7e6{5x}-2x^{2}$
$y_{p}=C_{1}x^{2}e^{5x}-C_{2}x^{3}$
Replacing $y$ with $y_{p}$ and after simplifying we get,
$2C_{1}e^{5x}-C_{2}x(25x^{2}-30x+6)=7e^{5x}-2x$
The root here is $\lambda =5$. So we can solve for our constants,
$C_{1}={\frac {7}{2}}$ $C_{2}={\frac {2}{481}}$
$y(x)=y_{h}+y_{p}=c_{1}e^{5x}+c_{2}xe^{5x}+{\frac {7}{2}}x^{2}e^{5x}-{\frac {2}{481}}x^{3}$
Using the initial conditions y(0)=4 and y'(0)=-5 we can solve for our constants,
$c_{1}=4$ $c_{2}=-1$
So the solution is,
$y=4e^{5x}+xe^{5x}+{\frac {7}{2}}x^{2}e^{5x}-{\frac {2}{481}}x^{3}$

#### Honor Pledge

On our honor, we solved this problem on our own, without aid from online solutions or solutions from previous semesters.

### Problem 8
#### Problem Statement

Plot the error between the exact derivative and the approximate derivative, i.e.
$xe^{\lambda x}-{\frac {e^{(\lambda +\epsilon )x}-e^{\lambda x}}{\epsilon }}$ from
$-15\leq x\leq 15$
For ε = .0001, .0003, .0006, and .001 and λ =.3

#### Solution

Since the above equation is the error between the exact derivative and the approximate derivative, it must be plotted with the correct values of \epsilon and \lambda, from x = -15 to 15

##### Case 1

ε=.0001

##### Case 2

ε=.0003

##### Case 3

ε=.0006

##### Case 4

ε=.001

#### Honor Pledge

On our honor, we solved this problem on our own, without aid from online solutions or solutions from previous semesters.

### Problem 9
#### Problem Statement

Find the complete solution for $y''-3y'+2y=4x^{2}$, with the initial conditions $y(0)=1$, $y'(0)=0$ plot the solution y(x)

#### Solution

Particular Solution $y_{p}(x)=Ax^{2}+Bx+c$ $y_{p}'=2Ax+B$ $y_{p}''=2A$ $2A-6Ax-3B+2Ax^{2}+2Bx+2c=4x^{2}$ $2A=4$
$-6A+2B=0$
$2A-3B+2C=0$
$A=2$ $B=6$ $C=7$
$y_{p}(x)=2x^{2}+6x+7$
Homogeneous Solution $y_{h}(x)=c_{1}e^{x}+c_{2}e^{2x)$ $y_{h}'=c_{1}e^{x}+2c_{2}e^{2x)$
Initial conditions $y(0)=1$ $1=c_{1}+c_{2}$ $y'(0)=0$ $0=c_{1}+2c_{2}$
$c_{1}=2,c_{2}=-1$
General Solution $y_{g}=2e^{x}-e^{2x)+2x^{x}+6x+7$

#### Honor Pledge

On our honor, we solved this problem on our own, without aid from online solutions or solutions from previous semesters.