def centroid_refine_triangulation_by_triangles(self, triangles):
        """
        return points defining a refined triangulation obtained by bisection of all edges
        in the triangulation that are associated with the triangles in the list provided.

        Notes
        -----
         The triangles are here represented as a single index.
         The vertices of triangle i are given by self.simplices[i].
        """

        # Remove duplicates from the list of triangles

        triangles = np.unique(np.array(triangles))

        xi, yi = self.face_midpoints(simplices=self.simplices[triangles])

        x_v1 = np.concatenate((self.x, xi), axis=0)
        y_v1 = np.concatenate((self.y, yi), axis=0)

        return x_v1, y_v1
def centroid_refine_triangulation_by_triangles ( self , triangles ) : triangles = np . unique ( np . array ( triangles ) ) xi , yi = self . face_midpoints ( simplices = self . simplices [ triangles ] ) x_v1 = np . concatenate ( ( self . x , xi ) , axis = 0 ) y_v1 = np . concatenate ( ( self . y , yi ) , axis = 0 ) return x_v1 , y_v1
return points defining a refined triangulation obtained by bisection of all edges
        in the triangulation that are associated with the triangles in the list provided.

        Notes
        -----
         The triangles are here represented as a single index.
         The vertices of triangle i are given by self.simplices[i].