Importing .FEB file fails when importing named surfaces
issueid=734 02-09-2016 12:02 PM
Member
Importing .FEB file fails when importing named surfaces
Importing .FEB file fails when importing named surfaces

Hi,

When using the named surface specification in a .FEB file, PreView crashes on import of the file.

The format I'm referring to is:
Code:
<Surface name="named_surface">
     <quad4 id="1">1,2,3,4</quad4>
            <...>
</Surface>
Here is the documentation addressing this specification.

It would be nice to implement this functionality or at least explain PreView's limitation with an error message.

Thanks in advance,

Mike
Issue Details
Issue Number 734
Project PreView
Category Unknown
Status Not a Bug
Priority Unknown
Affected Version Unknown
Fixed Version (none)
Users able to reproduce bug 0
Users unable to reproduce bug 0
Assigned Users (none)
Tags (none)




02-11-2016 07:54 AM
Lead Code Developer
Hi Mike,

I cannot reproduce this error with our latest version. If you are not using the latest version yet, please download it from our website and I try again. If the problem persists, can you send me a (small) example file. I want to make sure it's not something else. If not, I'll try to get our latest development version uploaded to the web.

Thanks,

Steve

02-11-2016 10:59 AM
Member
Hi Steve,

I'm using PreView 1.18.0. This code does not import for me (I get an error message about the Geometry tag), but if I delete the second surface definition, it works.:

Code:
<?xml version='1.0' encoding='ASCII'?>
<febio_spec version="2.0">
	<Globals>
		<Constants>
			<T>0</T>
			<R>0</R>
			<Fc>0</Fc>
		</Constants>
	</Globals>
	<Geometry>
		<Nodes>
		<node id="1">5.0, -10.0, 5.0</node><node id="2">5.0, 10.0, 5.0</node><node id="3">5.0, -6.0, 5.0</node><node id="4">5.0, -2.0, 5.0</node><node id="5">5.0, 2.0, 5.0</node><node id="6">5.0, 6.0, 5.0</node><node id="7">-5.0, 10.0, 5.0</node><node id="8">1.666667, 10.0, 5.0</node><node id="9">-1.666667, 10.0, 5.0</node><node id="10">-5.0, -10.0, 5.0</node><node id="11">-5.0, 6.0, 5.0</node><node id="12">-5.0, 2.0, 5.0</node><node id="13">-5.0, -2.0, 5.0</node><node id="14">-5.0, -6.0, 5.0</node><node id="15">-1.666667, -10.0, 5.0</node><node id="16">1.666667, -10.0, 5.0</node><node id="17">1.666667, -6.0, 5.0</node><node id="18">1.666667, -2.0, 5.0</node><node id="19">1.666667, 2.0, 5.0</node><node id="20">1.666667, 6.0, 5.0</node><node id="21">-1.666667, -6.0, 5.0</node><node id="22">-1.666667, -2.0, 5.0</node><node id="23">-1.666667, 2.0, 5.0</node><node id="24">-1.666667, 6.0, 5.0</node><node id="25">5.0, 10.0, -5.0</node><node id="26">5.0, -10.0, -5.0</node><node id="27">5.0, 6.0, -5.0</node><node id="28">5.0, 2.0, -5.0</node><node id="29">5.0, -2.0, -5.0</node><node id="30">5.0, -6.0, -5.0</node><node id="31">-5.0, -10.0, -5.0</node><node id="32">1.666667, -10.0, -5.0</node><node id="33">-1.666667, -10.0, -5.0</node><node id="34">-5.0, 10.0, -5.0</node><node id="35">-5.0, -6.0, -5.0</node><node id="36">-5.0, -2.0, -5.0</node><node id="37">-5.0, 2.0, -5.0</node><node id="38">-5.0, 6.0, -5.0</node><node id="39">-1.666667, 10.0, -5.0</node><node id="40">1.666667, 10.0, -5.0</node><node id="41">1.666667, 6.0, -5.0</node><node id="42">1.666667, 2.0, -5.0</node><node id="43">1.666667, -2.0, -5.0</node><node id="44">1.666667, -6.0, -5.0</node><node id="45">-1.666667, 6.0, -5.0</node><node id="46">-1.666667, 2.0, -5.0</node><node id="47">-1.666667, -2.0, -5.0</node><node id="48">-1.666667, -6.0, -5.0</node><node id="49">-5.0, -10.0, 1.666667</node><node id="50">-5.0, -10.0, -1.666667</node><node id="51">5.0, -10.0, 1.666667</node><node id="52">5.0, -10.0, -1.666667</node><node id="53">-1.666667, -10.0, 1.666667</node><node id="54">-1.666667, -10.0, -1.666667</node><node id="55">1.666667, -10.0, 1.666667</node><node id="56">1.666667, -10.0, -1.666667</node><node id="57">-5.0, 10.0, 1.666667</node><node id="58">-5.0, 10.0, -1.666667</node><node id="59">-5.0, 6.0, 1.666667</node><node id="60">-5.0, 6.0, -1.666667</node><node id="61">-5.0, 2.0, 1.666667</node><node id="62">-5.0, 2.0, -1.666667</node><node id="63">-5.0, -2.0, 1.666667</node><node id="64">-5.0, -2.0, -1.666667</node><node id="65">-5.0, -6.0, 1.666667</node><node id="66">-5.0, -6.0, -1.666667</node><node id="67">5.0, 10.0, 1.666667</node><node id="68">5.0, 10.0, -1.666667</node><node id="69">1.666667, 10.0, 1.666667</node><node id="70">1.666667, 10.0, -1.666667</node><node id="71">-1.666667, 10.0, 1.666667</node><node id="72">-1.666667, 10.0, -1.666667</node><node id="73">5.0, -6.0, 1.666667</node><node id="74">5.0, -6.0, -1.666667</node><node id="75">5.0, -2.0, 1.666667</node><node id="76">5.0, -2.0, -1.666667</node><node id="77">5.0, 2.0, 1.666667</node><node id="78">5.0, 2.0, -1.666667</node><node id="79">5.0, 6.0, 1.666667</node><node id="80">5.0, 6.0, -1.666667</node><node id="81">-1.666667, -6.0, 1.666667</node><node id="82">-1.666667, -6.0, -1.666667</node><node id="83">-1.666667, -2.0, 1.666667</node><node id="84">-1.666667, -2.0, -1.666667</node><node id="85">-1.666667, 2.0, 1.666667</node><node id="86">-1.666667, 2.0, -1.666667</node><node id="87">-1.666667, 6.0, 1.666667</node><node id="88">-1.666667, 6.0, -1.666667</node><node id="89">1.666667, -6.0, 1.666667</node><node id="90">1.666667, -6.0, -1.666667</node><node id="91">1.666667, -2.0, 1.666667</node><node id="92">1.666667, -2.0, -1.666667</node><node id="93">1.666667, 2.0, 1.666667</node><node id="94">1.666667, 2.0, -1.666667</node><node id="95">1.666667, 6.0, 1.666667</node><node id="96">1.666667, 6.0, -1.666667</node></Nodes>
	<Elements elset="EB1" type="hex8"><elem id="1">10, 49, 65, 14, 15, 53, 81, 21</elem><elem id="2">49, 50, 66, 65, 53, 54, 82, 81</elem><elem id="3">50, 31, 35, 66, 54, 33, 48, 82</elem><elem id="4">14, 65, 63, 13, 21, 81, 83, 22</elem><elem id="5">65, 66, 64, 63, 81, 82, 84, 83</elem><elem id="6">66, 35, 36, 64, 82, 48, 47, 84</elem><elem id="7">13, 63, 61, 12, 22, 83, 85, 23</elem><elem id="8">63, 64, 62, 61, 83, 84, 86, 85</elem><elem id="9">64, 36, 37, 62, 84, 47, 46, 86</elem><elem id="10">12, 61, 59, 11, 23, 85, 87, 24</elem><elem id="11">61, 62, 60, 59, 85, 86, 88, 87</elem><elem id="12">62, 37, 38, 60, 86, 46, 45, 88</elem><elem id="13">11, 59, 57, 7, 24, 87, 71, 9</elem><elem id="14">59, 60, 58, 57, 87, 88, 72, 71</elem><elem id="15">60, 38, 34, 58, 88, 45, 39, 72</elem><elem id="16">15, 53, 81, 21, 16, 55, 89, 17</elem><elem id="17">53, 54, 82, 81, 55, 56, 90, 89</elem><elem id="18">54, 33, 48, 82, 56, 32, 44, 90</elem><elem id="19">21, 81, 83, 22, 17, 89, 91, 18</elem><elem id="20">81, 82, 84, 83, 89, 90, 92, 91</elem><elem id="21">82, 48, 47, 84, 90, 44, 43, 92</elem><elem id="22">22, 83, 85, 23, 18, 91, 93, 19</elem><elem id="23">83, 84, 86, 85, 91, 92, 94, 93</elem><elem id="24">84, 47, 46, 86, 92, 43, 42, 94</elem><elem id="25">23, 85, 87, 24, 19, 93, 95, 20</elem><elem id="26">85, 86, 88, 87, 93, 94, 96, 95</elem><elem id="27">86, 46, 45, 88, 94, 42, 41, 96</elem><elem id="28">24, 87, 71, 9, 20, 95, 69, 8</elem><elem id="29">87, 88, 72, 71, 95, 96, 70, 69</elem><elem id="30">88, 45, 39, 72, 96, 41, 40, 70</elem><elem id="31">16, 55, 89, 17, 1, 51, 73, 3</elem><elem id="32">55, 56, 90, 89, 51, 52, 74, 73</elem><elem id="33">56, 32, 44, 90, 52, 26, 30, 74</elem><elem id="34">17, 89, 91, 18, 3, 73, 75, 4</elem><elem id="35">89, 90, 92, 91, 73, 74, 76, 75</elem><elem id="36">90, 44, 43, 92, 74, 30, 29, 76</elem><elem id="37">18, 91, 93, 19, 4, 75, 77, 5</elem><elem id="38">91, 92, 94, 93, 75, 76, 78, 77</elem><elem id="39">92, 43, 42, 94, 76, 29, 28, 78</elem><elem id="40">19, 93, 95, 20, 5, 77, 79, 6</elem><elem id="41">93, 94, 96, 95, 77, 78, 80, 79</elem><elem id="42">94, 42, 41, 96, 78, 28, 27, 80</elem><elem id="43">20, 95, 69, 8, 6, 79, 67, 2</elem><elem id="44">95, 96, 70, 69, 79, 80, 68, 67</elem><elem id="45">96, 41, 40, 70, 80, 27, 25, 68</elem></Elements>
		<Surface name="SS1"><quad4 id="1">14, 21, 15, 10</quad4><quad4 id="2">13, 22, 21, 14</quad4><quad4 id="3">12, 23, 22, 13</quad4><quad4 id="4">11, 24, 23, 12</quad4><quad4 id="5">7, 9, 24, 11</quad4><quad4 id="6">21, 17, 16, 15</quad4><quad4 id="7">22, 18, 17, 21</quad4><quad4 id="8">23, 19, 18, 22</quad4><quad4 id="9">24, 20, 19, 23</quad4><quad4 id="10">9, 8, 20, 24</quad4><quad4 id="11">17, 3, 1, 16</quad4><quad4 id="12">18, 4, 3, 17</quad4><quad4 id="13">19, 5, 4, 18</quad4><quad4 id="14">20, 6, 5, 19</quad4><quad4 id="15">8, 2, 6, 20</quad4>
		</Surface>
		<Surface name="SS2"><quad4 id="16">66, 82, 54, 50</quad4><quad4 id="17">64, 84, 82, 66</quad4><quad4 id="18">62, 86, 84, 64</quad4><quad4 id="19">60, 88, 86, 62</quad4><quad4 id="20">58, 72, 88, 60</quad4><quad4 id="21">82, 90, 56, 54</quad4><quad4 id="22">84, 92, 90, 82</quad4><quad4 id="23">86, 94, 92, 84</quad4><quad4 id="24">88, 96, 94, 86</quad4><quad4 id="25">72, 70, 96, 88</quad4><quad4 id="26">90, 74, 52, 56</quad4><quad4 id="27">92, 76, 74, 90</quad4><quad4 id="28">94, 78, 76, 92</quad4><quad4 id="29">96, 80, 78, 94</quad4><quad4 id="30">70, 68, 80, 96</quad4>
		</Surface>
	</Geometry>
	<Output>
		<plotfile type="febio"/>
	</Output>
</febio_spec>
Mike

02-12-2016 07:45 AM
Lead Code Developer
Hi Mike,

The reason PreView doesn't like the second surface is because it is an internal surface. PreView assumes that all surfaces are on the boundary of the mesh. Was it your intention to create an internal surface? If so, I can look into expanding this capability so that it supports internal surfaces. For now, unfortunately, the only way to import this model is to delete the second surface, as you already discovered.

Cheers,

Steve

02-12-2016 12:37 PM
Member
Steve,

That makes sense, thank you so much for helping figure this out.

Mike

+ Reply