/ proof-of-concept / plate-dynamics-lab-2
Sign in
proof-of-concept / plate-dynamics-lab-2
plate-dynamics-lab-2 / packages / core / src / m / plate_fem_rhs.m
17 lines · 702 BCodeBlameHistory
2004981Plate dynamics lab 2: a hammer on a hung plate by Rayleigh-Ritz and by Mindlin-Reissner finite elementsJeremy Magland 1function dy = plate_fem_rhs(y, phi, nm, omega, twozw, contact_k, hunt_crossley, hammer_mass)
2% PLATE_FEM_RHS Time derivative of the coupled hammer/plate state.
3%
4% dy = plate_fem_rhs(y, phi, nm, omega, twozw, contact_k, hunt_crossley, m)
5% for the state y = [q; v; x_h; v_h]:
6%
7% q_tt = phi F - 2 zeta omega q_t - omega^2 q (each mode, mass-normalized)
8% x_h_tt = -F / m (the hammer)
9%
10% with F the contact force of plate_fem_force and twozw = 2 zeta omega.
12q = y(1:nm);
13v = y(nm + 1:2 * nm);
14F = plate_fem_force(y, phi, nm, contact_k, hunt_crossley);
15qdd = phi' * F - twozw .* v - omega.^2 .* q;
16dy = [v; qdd; y(2 * nm + 2); -F / hammer_mass];
17end
↑↓ move↵openescclose