<HTML><BODY style="word-wrap: break-word; -khtml-nbsp-mode: space; -khtml-line-break: after-white-space; "><DIV>As I mentioned, there is no "casting" or conversion operation which would give you a FEM mesh from an ITK mesh. The plan was to originally derive the FEM mesh from the ITK mesh but this proved to be prohibitively difficult. Custom meshing is performed by creating a mesh using some external program and then feeding that directly into the FEM project (e.g. into the itkFEMRegistrationFilter class). This is definitely an area of improvement for the FEM library.</DIV><DIV><BR class="khtml-block-placeholder"></DIV><DIV>As regards the other question --- the current incarnation of the FEM library requires that each regularization scheme (e.g. membrane) be instantiated in a separate class for each element type. This is why there exists one membrane class for the hexahedral elements as well as a separate membrane class for the tetrahedral elements. Only one element type is used (the default is hexahedral). The other declaration is superfluous.</DIV><DIV><BR class="khtml-block-placeholder"></DIV><DIV>Nick</DIV><DIV><BR class="khtml-block-placeholder"></DIV><BR><DIV><DIV>On Jun 12, 2006, at 11:57 AM, Markus Weigert wrote:</DIV><BR class="Apple-interchange-newline"><BLOCKQUOTE type="cite"><SPAN class="Apple-style-span" style="border-collapse: separate; border-spacing: 0px 0px; color: rgb(0, 0, 0); font-family: Helvetica; font-size: 12px; font-style: normal; font-variant: normal; font-weight: normal; letter-spacing: normal; line-height: normal; text-align: auto; -khtml-text-decorations-in-effect: none; text-indent: 0px; -apple-text-size-adjust: auto; text-transform: none; orphans: 2; white-space: normal; widows: 2; word-spacing: 0px; "><DIV><FONT face="Arial" size="2"><SPAN class="Apple-style-span" style="font-family: Arial; font-size: 10px; ">Hi Nick,</SPAN></FONT></DIV><DIV><FONT face="Arial" size="2"></FONT> </DIV><DIV><FONT face="Arial" size="2"><SPAN class="Apple-style-span" style="font-family: Arial; font-size: 10px; ">if I see this the right way, the only way to achieve this kind of meshing would</SPAN></FONT></DIV><DIV><FONT face="Arial" size="2"><SPAN class="Apple-style-span" style="font-family: Arial; font-size: 10px; ">be to use the ITK - Mesh and create a mesh - input file from this mesh, which the FEM - Filter</SPAN></FONT></DIV><DIV><FONT face="Arial" size="2"><SPAN class="Apple-style-span" style="font-family: Arial; font-size: 10px; ">can read, right?</SPAN></FONT></DIV><DIV><FONT face="Arial" size="2"><SPAN class="Apple-style-span" style="font-family: Arial; font-size: 10px; ">I didn't have a look at the itk mesh yet, but is it appropriate for tatrahedral mesh generation which</SPAN></FONT></DIV><DIV><FONT face="Arial" size="2"><SPAN class="Apple-style-span" style="font-family: Arial; font-size: 10px; ">can be used to create a fem - mesh?</SPAN></FONT></DIV><DIV><FONT face="Arial" size="2"></FONT> </DIV><DIV><FONT face="Arial" size="2"><SPAN class="Apple-style-span" style="font-family: Arial; font-size: 10px; ">Further question:</SPAN></FONT></DIV><DIV><FONT face="Arial" size="2"></FONT> </DIV><DIV><FONT face="Arial" size="2"><SPAN class="Apple-style-span" style="font-family: Arial; font-size: 10px; ">What is the concrete function of these lines (taken from software guide), why two different</SPAN></FONT></DIV><DIV><FONT face="Arial" size="2"><SPAN class="Apple-style-span" style="font-family: Arial; font-size: 10px; ">membrane - types, which one is actually created?:</SPAN></FONT></DIV><DIV><FONT face="Arial" size="2"></FONT> </DIV><DIV><FONT face="Arial" size="2"><SPAN class="Apple-style-span" style="font-family: Arial; font-size: 10px; "> typedef itk::fem::Element3DC0LinearHexahedronMembrane Element3DType;</SPAN><BR style="font-family: Arial; font-size: 10px; "><SPAN class="Apple-style-span" style="font-family: Arial; font-size: 10px; "> typedef itk::fem::Element3DC0LinearTetrahedronMembrane Element3DType2;</SPAN><BR style="font-family: Arial; font-size: 10px; "></FONT></DIV><FONT face="Arial" size="2"></FONT><DIV><FONT face="Arial" size="2"><SPAN class="Apple-style-span" style="font-family: Arial; font-size: 10px; "> {</SPAN><BR style="font-family: Arial; font-size: 10px; "><SPAN class="Apple-style-span" style="font-family: Arial; font-size: 10px; ">// Software Guide : BeginCodeSnippet</SPAN><BR style="font-family: Arial; font-size: 10px; "><SPAN class="Apple-style-span" style="font-family: Arial; font-size: 10px; "> Element3DType::LoadImplementationFunctionPointer fp = </SPAN><BR style="font-family: Arial; font-size: 10px; "><SPAN class="Apple-style-span" style="font-family: Arial; font-size: 10px; "> &itk::fem::ImageMetricLoadImplementation<ImageLoadType>::ImplementImageMetricLoad;</SPAN><BR style="font-family: Arial; font-size: 10px; "><SPAN class="Apple-style-span" style="font-family: Arial; font-size: 10px; "> DispatcherType::RegisterVisitor((ImageLoadType*)0,fp);</SPAN><BR style="font-family: Arial; font-size: 10px; "><SPAN class="Apple-style-span" style="font-family: Arial; font-size: 10px; ">// Software Guide : EndCodeSnippet </SPAN><BR style="font-family: Arial; font-size: 10px; "><SPAN class="Apple-style-span" style="font-family: Arial; font-size: 10px; "> }</SPAN><BR style="font-family: Arial; font-size: 10px; "><SPAN class="Apple-style-span" style="font-family: Arial; font-size: 10px; "> {</SPAN><BR style="font-family: Arial; font-size: 10px; "><SPAN class="Apple-style-span" style="font-family: Arial; font-size: 10px; "> Element3DType2::LoadImplementationFunctionPointer fp =</SPAN><BR style="font-family: Arial; font-size: 10px; "><SPAN class="Apple-style-span" style="font-family: Arial; font-size: 10px; "> &itk::fem::ImageMetricLoadImplementation<ImageLoadType>::ImplementImageMetricLoad;</SPAN><BR style="font-family: Arial; font-size: 10px; "><SPAN class="Apple-style-span" style="font-family: Arial; font-size: 10px; "> DispatcherType2::RegisterVisitor((ImageLoadType*)0,fp);</SPAN><BR style="font-family: Arial; font-size: 10px; "><SPAN class="Apple-style-span" style="font-family: Arial; font-size: 10px; "> }</SPAN></FONT></DIV><DIV><FONT face="Arial" size="2"></FONT> </DIV><DIV><FONT face="Arial" size="2"></FONT> </DIV><DIV><FONT face="Arial" size="2"><SPAN class="Apple-style-span" style="font-family: Arial; font-size: 10px; ">Regards,</SPAN></FONT></DIV><DIV><FONT face="Arial" size="2"><SPAN class="Apple-style-span" style="font-family: Arial; font-size: 10px; ">Markus</SPAN></FONT></DIV><BLOCKQUOTE style="PADDING-RIGHT: 0px; PADDING-LEFT: 5px; MARGIN-LEFT: 5px; BORDER-LEFT: #000000 2px solid; MARGIN-RIGHT: 0px"><DIV style="FONT: 10pt arial; font-family: arial; font-size: 13.3333px; "><SPAN class="Apple-style-span" style="font-family: arial; font-size: 13.3333px; ">----- Original Message -----</SPAN></DIV><DIV style="BACKGROUND: #e4e4e4; FONT: 10pt arial; font-color: black; font-family: arial; font-size: 13.3333px; "><B style="font-family: arial; font-size: 13.3333px; font-weight: bold; "><SPAN class="Apple-style-span" style="font-family: arial; font-size: 13.3333px; font-weight: bold; ">From:</SPAN></B><SPAN class="Apple-style-span" style="font-family: arial; font-size: 13.3333px; "> </SPAN><A title="ntustison@gmail.com" href="mailto:ntustison@gmail.com"><SPAN class="Apple-style-span" style="color: rgb(0, 0, 238); font-family: arial; font-size: 13.3333px; -khtml-text-decorations-in-effect: underline; ">Nicholas Tustison</SPAN></A><SPAN class="Apple-style-span" style="font-family: arial; font-size: 13.3333px; "></SPAN></DIV><DIV style="FONT: 10pt arial; font-family: arial; font-size: 13.3333px; "><B style="font-family: arial; font-size: 13.3333px; font-weight: bold; "><SPAN class="Apple-style-span" style="font-family: arial; font-size: 13.3333px; font-weight: bold; ">To:</SPAN></B><SPAN class="Apple-style-span" style="font-family: arial; font-size: 13.3333px; "> </SPAN><A title="m.weigert@fz-juelich.de" href="mailto:m.weigert@fz-juelich.de"><SPAN class="Apple-style-span" style="color: rgb(0, 0, 238); font-family: arial; font-size: 13.3333px; -khtml-text-decorations-in-effect: underline; ">Markus Weigert</SPAN></A><SPAN class="Apple-style-span" style="font-family: arial; font-size: 13.3333px; "></SPAN></DIV><DIV style="FONT: 10pt arial; font-family: arial; font-size: 13.3333px; "><B style="font-family: arial; font-size: 13.3333px; font-weight: bold; "><SPAN class="Apple-style-span" style="font-family: arial; font-size: 13.3333px; font-weight: bold; ">Cc:</SPAN></B><SPAN class="Apple-style-span" style="font-family: arial; font-size: 13.3333px; "> </SPAN><A title="insight-users@itk.org" href="mailto:insight-users@itk.org"><SPAN class="Apple-style-span" style="color: rgb(0, 0, 238); font-family: arial; font-size: 13.3333px; -khtml-text-decorations-in-effect: underline; ">insight-users@itk.org</SPAN></A><SPAN class="Apple-style-span" style="font-family: arial; font-size: 13.3333px; "></SPAN></DIV><DIV style="FONT: 10pt arial; font-family: arial; font-size: 13.3333px; "><B style="font-family: arial; font-size: 13.3333px; font-weight: bold; "><SPAN class="Apple-style-span" style="font-family: arial; font-size: 13.3333px; font-weight: bold; ">Sent:</SPAN></B><SPAN class="Apple-style-span" style="font-family: arial; font-size: 13.3333px; "> Monday, June 12, 2006 5:41 PM</SPAN></DIV><DIV style="FONT: 10pt arial; font-family: arial; font-size: 13.3333px; "><B style="font-family: arial; font-size: 13.3333px; font-weight: bold; "><SPAN class="Apple-style-span" style="font-family: arial; font-size: 13.3333px; font-weight: bold; ">Subject:</SPAN></B><SPAN class="Apple-style-span" style="font-family: arial; font-size: 13.3333px; "> Re: [Insight-users] Adaptive Meshing for FEM - Registration</SPAN></DIV><DIV><FONT face="Arial" size="2"></FONT><FONT face="Arial" size="2"></FONT><FONT face="Arial" size="2"></FONT><BR></DIV><DIV>Hi Markus,</DIV><DIV><FONT face="Arial" size="2"></FONT><FONT face="Arial" size="2"></FONT><BR class="khtml-block-placeholder"></DIV><DIV>A straightforward conversion between an ITK mesh and a FEM mesh is non-existent. I'm reworking the FEM mesh class now and maybe I'll come up with something but until then...</DIV><DIV><FONT face="Arial" size="2"></FONT><FONT face="Arial" size="2"></FONT><BR class="khtml-block-placeholder"></DIV><DIV>The current FEM framework allows for an external mesh to be brought into the FEM project but that, in addition to the default rectilinear mesh that is created when no external mesh is specified, is the extent of the current FEM library meshing capabilities. </DIV><DIV><BR class="khtml-block-placeholder"></DIV><DIV>Nick Tustison</DIV><DIV><BR class="khtml-block-placeholder"></DIV><BR><DIV><DIV>On Jun 12, 2006, at 11:32 AM, Markus Weigert wrote:</DIV><BR class="Apple-interchange-newline"><BLOCKQUOTE type="cite"><DIV style="color: rgb(0, 0, 221); "><FONT face="Arial" size="2"><SPAN class="Apple-style-span" style="color: rgb(0, 0, 221); font-family: Arial; font-size: 10px; ">Hi all,</SPAN></FONT></DIV><DIV style="color: rgb(0, 0, 221); "><FONT face="Arial" size="2"></FONT><SPAN class="Apple-style-span" style="color: rgb(0, 0, 221); "> </SPAN></DIV><DIV style="color: rgb(0, 0, 221); "><FONT face="Arial" size="2"><SPAN class="Apple-style-span" style="color: rgb(0, 0, 221); font-family: Arial; font-size: 10px; ">in the insight book ("Insight into Images") from Terry S. Yoo,</SPAN></FONT></DIV><DIV style="color: rgb(0, 0, 221); "><FONT face="Arial" size="2"><SPAN class="Apple-style-span" style="color: rgb(0, 0, 221); font-family: Arial; font-size: 10px; ">there is a nice example of adaptive lung meshing (page 331).</SPAN></FONT></DIV><DIV style="color: rgb(0, 0, 221); "><FONT face="Arial" size="2"><SPAN class="Apple-style-span" style="color: rgb(0, 0, 221); font-family: Arial; font-size: 10px; ">My question is, how can such a meshing be obtained with ITK </SPAN></FONT><FONT face="Arial" size="2"><SPAN class="Apple-style-span" style="color: rgb(0, 0, 221); font-family: Arial; font-size: 10px; ">in 3D?</SPAN></FONT></DIV><DIV style="color: rgb(0, 0, 221); "><FONT face="Arial" size="2"><SPAN class="Apple-style-span" style="color: rgb(0, 0, 221); font-family: Arial; font-size: 10px; ">I suppose, one can use the ITK - Mesh framework for this task,</SPAN></FONT></DIV><DIV style="color: rgb(0, 0, 221); "><FONT face="Arial" size="2"><SPAN class="Apple-style-span" style="color: rgb(0, 0, 221); font-family: Arial; font-size: 10px; ">but the ITK Mesh would need to be casted to a FEM - Mesh.</SPAN></FONT></DIV><DIV style="color: rgb(0, 0, 221); "><FONT face="Arial" size="2"><SPAN class="Apple-style-span" style="color: rgb(0, 0, 221); font-family: Arial; font-size: 10px; ">Can this casting be done in a straight forward way, or is it more complicated?</SPAN></FONT></DIV><DIV style="color: rgb(0, 0, 221); "><FONT face="Arial" size="2"></FONT><SPAN class="Apple-style-span" style="color: rgb(0, 0, 221); "> </SPAN></DIV><DIV style="color: rgb(0, 0, 221); "><FONT face="Arial" size="2"><SPAN class="Apple-style-span" style="color: rgb(0, 0, 221); font-family: Arial; font-size: 10px; ">Also, this would be interesting because one could start to segment an image</SPAN></FONT></DIV><DIV style="color: rgb(0, 0, 221); "><FONT face="Arial" size="2"><SPAN class="Apple-style-span" style="color: rgb(0, 0, 221); font-family: Arial; font-size: 10px; ">and mesh individual surfaces to model each tissue with different elasticity.</SPAN></FONT></DIV><DIV style="color: rgb(0, 0, 221); "><FONT face="Arial" size="2"><SPAN class="Apple-style-span" style="color: rgb(0, 0, 221); font-family: Arial; font-size: 10px; ">Any idears on this???</SPAN></FONT></DIV><DIV style="color: rgb(0, 0, 221); "><FONT face="Arial" size="2"></FONT><SPAN class="Apple-style-span" style="color: rgb(0, 0, 221); "> </SPAN></DIV><DIV style="color: rgb(0, 0, 221); "><FONT face="Arial" size="2"><SPAN class="Apple-style-span" style="color: rgb(0, 0, 221); font-family: Arial; font-size: 10px; ">Regards,</SPAN></FONT></DIV><DIV style="color: rgb(0, 0, 221); "><FONT face="Arial" size="2"><SPAN class="Apple-style-span" style="color: rgb(0, 0, 221); font-family: Arial; font-size: 10px; ">Markus</SPAN></FONT></DIV><DIV style="color: rgb(0, 0, 221); "><FONT face="Arial" size="2"></FONT><SPAN class="Apple-style-span" style="color: rgb(0, 0, 221); "> </SPAN></DIV><DIV style="color: rgb(0, 0, 221); "><FONT face="Arial" size="2"></FONT><SPAN class="Apple-style-span" style="color: rgb(0, 0, 221); "> </SPAN></DIV><DIV style="color: rgb(0, 0, 221); "><FONT face="Arial" size="2"></FONT><SPAN class="Apple-style-span" style="color: rgb(0, 0, 221); "> </SPAN></DIV><DIV style="MARGIN: 0px; color: rgb(0, 0, 221); "><SPAN class="Apple-style-span" style="color: rgb(0, 0, 221); ">_______________________________________________</SPAN></DIV><DIV style="MARGIN: 0px; color: rgb(0, 0, 221); "><SPAN class="Apple-style-span" style="color: rgb(0, 0, 221); ">Insight-users mailing list</SPAN></DIV><DIV style="MARGIN: 0px; color: rgb(0, 0, 221); "><A href="mailto:Insight-users@itk.org"><SPAN class="Apple-style-span" style="color: rgb(0, 0, 238); -khtml-text-decorations-in-effect: underline; ">Insight-users@itk.org</SPAN></A></DIV><DIV style="MARGIN: 0px; color: rgb(0, 0, 221); "><A href="http://www.itk.org/mailman/listinfo/insight-users"><SPAN class="Apple-style-span" style="color: rgb(0, 0, 238); -khtml-text-decorations-in-effect: underline; ">http://www.itk.org/mailman/listinfo/insight-users</SPAN></A></DIV></BLOCKQUOTE></DIV><BR></BLOCKQUOTE><BR class="Apple-interchange-newline"></SPAN></BLOCKQUOTE></DIV><BR></BODY></HTML>