def apply_matrix_pt((a, b, c, d, e, f), (x, y)):
 return ((((a * x) + (c * y)) + e), (((b * x) + (d * y)) + f))

def apply_matrix_pt ( ( a , b , c , d , e , f ) , ( x , y ) ) : return ( ( ( ( a * x ) + ( c * y ) ) + e ) , ( ( ( b * x ) + ( d * y ) ) + f ) )
applies a matrix to a point .