The generalized-alpha method applied to conservative Duffing oscillators