implemented dyn_init