fixed vectorization