(
        self,
        outer_radius,
        inner_radius,
        length,
        R=np.eye(3),
        x0=np.array([0.0, 0.0, 0.0]),
        mesh_size=None,
    )
return vol
Hollow cylinder.
        Define a ring, extrude it by translation.
Hollow cylinder.
        Define a ring, extrude it by translation.
Hollow cylinder . Define a ring extrude it by translation .
def _add_pipe_by_circle_extrusion(
        self,
        outer_radius,
        inner_radius,
        length,
        R=np.eye(3),
        x0=np.array([0.0, 0.0, 0.0]),
        mesh_size=None,
    ):
        """Hollow cylinder.
        Define a ring, extrude it by translation.
        """
        # Define ring which to Extrude by translation.
        Rc = np.array([[0.0, 0.0, 1.0], [1.0, 0.0, 0.0], [0.0, 1.0, 0.0]])
        c_inner = self.add_circle(
            x0,
            inner_radius,
            mesh_size=mesh_size,
            R=np.dot(R, Rc),
            make_surface=False,
        )
        circ = self.add_circle(
            x0,
            outer_radius,
            mesh_size=mesh_size,
            R=np.dot(R, Rc),
            holes=[c_inner.curve_loop],
        )

        # Now Extrude the ring surface.
        _, vol, _ = self.extrude(
            circ.plane_surface, translation_axis=np.dot(R, [length, 0, 0])
        )
        return vol
def _add_pipe_by_circle_extrusion ( self , outer_radius , inner_radius , length , R = np . eye ( 3 ) , x0 = np . array ( [ 0.0 , 0.0 , 0.0 ] ) , mesh_size = None , ) : # Define ring which to Extrude by translation. Rc = np . array ( [ [ 0.0 , 0.0 , 1.0 ] , [ 1.0 , 0.0 , 0.0 ] , [ 0.0 , 1.0 , 0.0 ] ] ) c_inner = self . add_circle ( x0 , inner_radius , mesh_size = mesh_size , R = np . dot ( R , Rc ) , make_surface = False , ) circ = self . add_circle ( x0 , outer_radius , mesh_size = mesh_size , R = np . dot ( R , Rc ) , holes = [ c_inner . curve_loop ] , ) # Now Extrude the ring surface. _ , vol , _ = self . extrude ( circ . plane_surface , translation_axis = np . dot ( R , [ length , 0 , 0 ] ) ) return vol