generalized initialization