Fixed matrix opperations

matricies generate and multiply correctly