Extended and rebuilt vector math