def METHOD_NAME(self):
    "Return the underlying Sobolev space of the TensorProductElement."
    elements = self._sub_elements
    if all(e.METHOD_NAME() == elements[0].METHOD_NAME()
           for e in elements):
        return elements[0].METHOD_NAME()
    else:
        # Generate a DirectionalSobolevSpace which contains
        # continuity information parametrized by spatial index
        orders = []
        for e in elements:
            e_dim = e.cell().geometric_dimension()
            e_order = (e.METHOD_NAME()._order,) * e_dim
            orders.extend(e_order)
        return DirectionalSobolevSpace(orders)