Frequency dependent mass and stiffness matrices of bar and beam elements and their equivalency with the dynamic stiffness matrix