""" @brief  A module for computing norms of vectors. """

def norm2(u):

  """ @brief  Returns the square norm of the two-dimensional vector u.

      @param u  The two-dimensional vector u = [u_1, u_2].

      @return   The square norm of u. """

  return (u[0] * u[0]) + (u[1] * u[1]);