I would like to implement the time-dynamics of the first mode of a homogeneous cantilever, $w_1(x, t)$. I have found the equation for the first mode in wikipedia:
https://en.wikipedia.org/wiki/Euler%E2%80%93Bernoulli_beam_theory#Example:_Cantilevered_beam
The equation is
$w_n(x) = A_n (\cosh(b_n x) - \cos(b_n x) + \frac{\cos(b_n L) + \cosh(b_n L)}{\sin(b_n L) + \sinh(b_n L)}(\sin(b_n x) - \sinh(b_n x)))$
where $L$ is the cantilever length, $A_n$ is modal magnitude, and $b_1 = 0.59686 \frac{\pi}{L}$ for the first mode.
The article also says that the time-dynamics of the cantilever is given by
$w_n(x,t) = \Re(w_n(x)e^{i \omega_n t})$
where $\omega_n \sim b_n^2$ is the resonance frequency.
Question: If the above expression for the time-dynamics was right, the beam would change length over time. Its length would be precisely $L$ when $\cos(\omega_n t) = 0$ and more than $L$ at all other times. What is wrong?
Edit: It was noted to me that the expression above is only accurate for small angles, where the mentioned change of length is neglectable. What I am really looking for is a general expression to approximate the cantilever dynamics with relatively large bending angles (valid up to $\pm pi/4$). I would like to avoid numerical solutions. Instead, I am looking for an expansion into modes, with intention of keeping only those that actually occur in my use case. The original wiki article links to yet another article with a more general theory. However, modal expansion is not provided there
https://en.wikipedia.org/wiki/Timoshenko_beam_theory
Edit 2: It seems that a solution to my exact problem has just been published. It is rather lengthy, so I will just refer to the article
http://journals.plos.org/ploscompbiol/article?id=10.1371/journal.pcbi.1006032