Local controllability of generalized quantum mechanical systems