Matrix impl, first steps