A superposition method for the dynamic analysis and simulation of flexible manipulators