here is the solution to your problem
Euler-bernoulli cantilever beam deflection equation
Solution by using finite difference method
D4y/dx4 =- p/ EI
In the finite difference method, the derivatives can be approximated by the following expressions :
dy/dx|i ~ (yi+1 - yi )/ 2(Δx)
d2y/dx2|i ~ (yi+1 - 2yi + yi-1)/( Δx)2
d3y/dx3|i ~ (yi+2 - 2yi+1 +2 yi-1 - yi-2)/ 2(Δx)3
d4y/dx4|i ~ (yi+2 - 4yi+1 +6 yi - 4 yi-1 + yi-2)/ (Δx)4
Where i is the node sequence.
xi = i/(n-1) where n = number of nodes
Applying the boundary conditions:
y(x=0) =0 , gives y0 = 0.
dy(x=0)/dx = 0,
dy/dx|x=0 ~ (yi+1 - yi )/ 2(Δx) ; gives y1 = y-1
d2y(x=L)/dx2 = 0,
d3y(x=L)/dx3 = 0, at end node
Solution: for n=7,
at node 0,
dy/dx|0 = 0
at node 1
d4y/dx4|1 ~ (y1+2 - 4y1+1 +6 y1 - 4 y1-1 + y1-2)/ (Δx)4
~ (y3 - 4y2 +6 y1 - 4 y0 + y-1)/ (Δx)4
~ (y3 - 4y2 +7 y1)/ (Δx)4
at node 2
d4y/dx4|2 ~ (y2+2 - 4y2+1 +6 y2 - 4 y2-1 + y2-2)/ (Δx)4
~ (y4 - 4y3 +6 y2 - 4 y1 + y0)/ (Δx)4
~ (y4 - 4y3 +6 y2 - 4 y1 )/ (Δx)4
at node 3
d4y/dx4|3 ~ (y3+2 - 4y3+1 + 6 y3 - 4 y3-1 + y3-2)/ (Δx)4
~ (y5 - 4y4 +6 y3 - 4 y2 + y1)/ (Δx)4
at node 4
d4y/dx4|4 ~ (y4+2 - 4y4+1 + 6 y4 - 4 y4-1 + y4-2)/ (Δx)4
~ (y6 - 4y5 + 6 y4 - 4 y3 + y2)/ (Δx)4
at node 5
d4y/dx4|5 ~ (y5+2 - 4y5+1 + 6 y5 - 4 y5-1 + y5-2)/ (Δx)4
~ (y7 - 4y6 + 6 y5 - 4 y4 + y3)/ (Δx)4
From the Boundary conditions:
d2y/dx2|i@x=L ~ (yi+1 - 2yi + yi-1)/( Δx)2
~(yi+1 - 2yi + yi-1) = 0
~(y7 - 2y6 + y5) = 0
≡ y7 = 2y6 - y5
d4y/dx4|5 ~ (2y6 - y5 - 4y6 + 6 y5 - 4 y4 + y3)/ (Δx)4
~ (– 2y6 + 5 y5 - 4 y4 + y3)/ (Δx)4
at node 6
d4y/dx4|6 ~ (y6+2 - 4y6+1 + 6 y6 - 4 y6-1 + y6-2)/ (Δx)4
~ (y8 - 4y7 + 6 y6 - 4 y5 + y4)/ (Δx)4
Use boundary conditions at end note (x=L)
d3y/dx3|i@x=L ~ (yi+2 - 2yi+1 +2 yi-1 - yi-2)/ 2(Δx)3
~ (y6+2 - 2y6+1 +2 y6-1 - y6-2)/ 2(Δx)3
~ (y8 - 2y7 +2 y5 - y4)/ 2(Δx)3 = 0
≡ y8 - 2y7 = -2 y5 + y4
d4y/dx4|6 ~ (y8 - 2y7 - 2y7 + 6 y6 - 4 y5 + y4)/ (Δx)4
~ (-2 y5 + y4 - 2y7 +6 y6 - 4 y5 + y4)/ (Δx)4
~ ( - 2y7 + 6 y6 - 6 y5 + 2 y4)/ (Δx)4
y7 = 2y6 - y5
d4y/dx4|6 ~ ( - 2(2y6 - y5 ) + 6 y6 - 6 y5 + 2 y4)/ (Δx)4
~( ( - 4y6 + 2 y5 ) + 6 y6 - 6 y5 + 2 y4)/ (Δx)4
~ ( 2 y6 - 4 y5 + 2 y4)/ (Δx)4
Arrange equations :
Solving the above linear equations gives the values of yi which is the deflection of the beam at each node.
yi = 1.0e-4
y0 y1 y2 y3 y4 y5 y6
0 -0.479 -1.623 -3.193 -5.002 -6.918 -8.860
increase number of nodes for more accurate solution
No of nodes RMS %
7 5.79
21 0.97
51 0.24
101 0.08
with my complements .... sumaia
sumaia@onetel.com