adding in calculation of y and yTranspsoe