<html xmlns:v="urn:schemas-microsoft-com:vml" xmlns:o="urn:schemas-microsoft-com:office:office" xmlns:w="urn:schemas-microsoft-com:office:word" xmlns:m="http://schemas.microsoft.com/office/2004/12/omml" xmlns="http://www.w3.org/TR/REC-html40"><head><META HTTP-EQUIV="Content-Type" CONTENT="text/html; charset=us-ascii"><meta name=Generator content="Microsoft Word 14 (filtered medium)"><style><!--
/* Font Definitions */
@font-face
        {font-family:Wingdings;
        panose-1:5 0 0 0 0 0 0 0 0 0;}
@font-face
        {font-family:Wingdings;
        panose-1:5 0 0 0 0 0 0 0 0 0;}
@font-face
        {font-family:Calibri;
        panose-1:2 15 5 2 2 2 4 3 2 4;}
@font-face
        {font-family:Monospaced;
        panose-1:0 0 0 0 0 0 0 0 0 0;}
/* Style Definitions */
p.MsoNormal, li.MsoNormal, div.MsoNormal
        {margin:0cm;
        margin-bottom:.0001pt;
        font-size:11.0pt;
        font-family:"Calibri","sans-serif";
        mso-fareast-language:EN-US;}
a:link, span.MsoHyperlink
        {mso-style-priority:99;
        color:blue;
        text-decoration:underline;}
a:visited, span.MsoHyperlinkFollowed
        {mso-style-priority:99;
        color:purple;
        text-decoration:underline;}
pre
        {mso-style-priority:99;
        mso-style-link:"Pr\00E9format\00E9 HTML Car";
        margin:0cm;
        margin-bottom:.0001pt;
        font-size:10.0pt;
        font-family:"Courier New";}
p.MsoListParagraph, li.MsoListParagraph, div.MsoListParagraph
        {mso-style-priority:34;
        margin-top:0cm;
        margin-right:0cm;
        margin-bottom:0cm;
        margin-left:36.0pt;
        margin-bottom:.0001pt;
        font-size:11.0pt;
        font-family:"Calibri","sans-serif";
        mso-fareast-language:EN-US;}
span.EmailStyle17
        {mso-style-type:personal-compose;
        font-family:"Calibri","sans-serif";
        color:windowtext;}
span.PrformatHTMLCar
        {mso-style-name:"Pr\00E9format\00E9 HTML Car";
        mso-style-priority:99;
        mso-style-link:"Pr\00E9format\00E9 HTML";
        font-family:"Courier New";
        mso-fareast-language:FR;}
.MsoChpDefault
        {mso-style-type:export-only;
        font-family:"Calibri","sans-serif";
        mso-fareast-language:EN-US;}
@page WordSection1
        {size:612.0pt 792.0pt;
        margin:70.85pt 70.85pt 70.85pt 70.85pt;}
div.WordSection1
        {page:WordSection1;}
/* List Definitions */
@list l0
        {mso-list-id:2025788256;
        mso-list-type:hybrid;
        mso-list-template-ids:1483516758 726043434 67895299 67895301 67895297 67895299 67895301 67895297 67895299 67895301;}
@list l0:level1
        {mso-level-start-at:16;
        mso-level-number-format:bullet;
        mso-level-text:-;
        mso-level-tab-stop:none;
        mso-level-number-position:left;
        text-indent:-18.0pt;
        font-family:"Calibri","sans-serif";
        mso-fareast-font-family:Calibri;
        mso-bidi-font-family:"Times New Roman";}
@list l0:level2
        {mso-level-number-format:bullet;
        mso-level-text:o;
        mso-level-tab-stop:none;
        mso-level-number-position:left;
        text-indent:-18.0pt;
        font-family:"Courier New";}
@list l0:level3
        {mso-level-number-format:bullet;
        mso-level-text:\F0A7;
        mso-level-tab-stop:none;
        mso-level-number-position:left;
        text-indent:-18.0pt;
        font-family:Wingdings;}
@list l0:level4
        {mso-level-number-format:bullet;
        mso-level-text:\F0B7;
        mso-level-tab-stop:none;
        mso-level-number-position:left;
        text-indent:-18.0pt;
        font-family:Symbol;}
@list l0:level5
        {mso-level-number-format:bullet;
        mso-level-text:o;
        mso-level-tab-stop:none;
        mso-level-number-position:left;
        text-indent:-18.0pt;
        font-family:"Courier New";}
@list l0:level6
        {mso-level-number-format:bullet;
        mso-level-text:\F0A7;
        mso-level-tab-stop:none;
        mso-level-number-position:left;
        text-indent:-18.0pt;
        font-family:Wingdings;}
@list l0:level7
        {mso-level-number-format:bullet;
        mso-level-text:\F0B7;
        mso-level-tab-stop:none;
        mso-level-number-position:left;
        text-indent:-18.0pt;
        font-family:Symbol;}
@list l0:level8
        {mso-level-number-format:bullet;
        mso-level-text:o;
        mso-level-tab-stop:none;
        mso-level-number-position:left;
        text-indent:-18.0pt;
        font-family:"Courier New";}
@list l0:level9
        {mso-level-number-format:bullet;
        mso-level-text:\F0A7;
        mso-level-tab-stop:none;
        mso-level-number-position:left;
        text-indent:-18.0pt;
        font-family:Wingdings;}
ol
        {margin-bottom:0cm;}
ul
        {margin-bottom:0cm;}
--></style><!--[if gte mso 9]><xml>
<o:shapedefaults v:ext="edit" spidmax="1026" />
</xml><![endif]--><!--[if gte mso 9]><xml>
<o:shapelayout v:ext="edit">
<o:idmap v:ext="edit" data="1" />
</o:shapelayout></xml><![endif]--></head><body lang=FR link=blue vlink=purple><div class=WordSection1><p class=MsoNormal><span lang=EN-US>Dear All<o:p></o:p></span></p><p class=MsoNormal><span lang=EN-US><o:p> </o:p></span></p><p class=MsoNormal><span lang=EN-US>How can I convert a matrix of characters into integers when the separator has different number of spaces ?<o:p></o:p></span></p><p class=MsoNormal><span lang=EN-US><o:p> </o:p></span></p><p class=MsoNormal><span lang=EN-US>The spaces come probably  from a printf format such as :     printf(“%10d\n”,var)<o:p></o:p></span></p><p class=MsoNormal><span lang=EN-US><o:p> </o:p></span></p><pre><span lang=EN-US style='font-size:11.0pt;font-family:"Calibri","sans-serif";mso-fareast-language:EN-US'>I ‘m currently using <b><u>csvTextScan</u></b> and I’ve some troubles/errors  with <b><u>csvRead</u></b> …<o:p></o:p></span></pre><p class=MsoNormal><span lang=EN-US><o:p> </o:p></span></p><p class=MsoNormal><u><span lang=EN-US>Example</span></u><span lang=EN-US> :<o:p></o:p></span></p><p class=MsoNormal><span lang=EN-US>! 300006     12799     24678     17504     21558    212801     24680     17508     21560 !<o:p></o:p></span></p><p class=MsoNormal><span lang=EN-US><o:p> </o:p></span></p><p class=MsoNormal><span lang=EN-US>NB:<o:p></o:p></span></p><p class=MsoListParagraph style='text-indent:-18.0pt;mso-list:l0 level1 lfo1'><![if !supportLists]><span lang=EN-US><span style='mso-list:Ignore'>-<span style='font:7.0pt "Times New Roman"'>          </span></span></span><![endif]><span lang=EN-US>I read first an ascii file<o:p></o:p></span></p><p class=MsoListParagraph style='text-indent:-18.0pt;mso-list:l0 level1 lfo1'><![if !supportLists]><span lang=EN-US><span style='mso-list:Ignore'>-<span style='font:7.0pt "Times New Roman"'>          </span></span></span><![endif]><span lang=EN-US>I removed some specific lines directly in the matrix<o:p></o:p></span></p><p class=MsoListParagraph style='text-indent:-18.0pt;mso-list:l0 level1 lfo1'><![if !supportLists]><span lang=EN-US><span style='mso-list:Ignore'>-<span style='font:7.0pt "Times New Roman"'>          </span></span></span><![endif]><span lang=EN-US>Then I’m trying to convert the matrix of characters into a matrix of intergers<o:p></o:p></span></p><p class=MsoListParagraph><span lang=EN-US><o:p> </o:p></span></p><p class=MsoNormal><span lang=EN-US>Thanks for any suggestion<o:p></o:p></span></p><p class=MsoNormal><span lang=EN-US><o:p> </o:p></span></p><p class=MsoNormal><span lang=EN-US>Paul<o:p></o:p></span></p><p class=MsoNormal><span lang=EN-US><o:p> </o:p></span></p><p class=MsoNormal><span lang=EN-US>#########################################<o:p></o:p></span></p><pre><span lang=EN-US style='font-size:14.0pt;font-family:"Monospaced","serif";color:black'>PATH_FILE</span><span lang=EN-US style='font-size:14.0pt;font-family:"Monospaced","serif"'> <span style='color:#5C5C5C'>=</span> <span style='color:#32B9B9'>get_absolute_file_path</span><span style='color:#4A55DB'>(</span><span style='color:rosybrown'>"lecture.sce"</span><span style='color:#4A55DB'>)</span><span style='color:black'>;</span> <o:p></o:p></span></pre><pre><span lang=EN-US style='font-size:14.0pt;font-family:"Monospaced","serif";color:black'>FILE_NAME</span><span lang=EN-US style='font-size:14.0pt;font-family:"Monospaced","serif"'> <span style='color:#5C5C5C'>=</span> <span style='color:rosybrown'>'topology_elem.rad'</span><span style='color:black'>;</span><o:p></o:p></span></pre><pre><span lang=EN-US style='font-size:14.0pt;font-family:"Monospaced","serif"'><o:p> </o:p></span></pre><pre><span lang=EN-US style='font-size:14.0pt;font-family:"Monospaced","serif";color:#32B9B9'>stacksize</span><span lang=EN-US style='font-size:14.0pt;font-family:"Monospaced","serif";color:#4A55DB'>(</span><span lang=EN-US style='font-size:14.0pt;font-family:"Monospaced","serif";color:rosybrown'>'max'</span><span lang=EN-US style='font-size:14.0pt;font-family:"Monospaced","serif";color:#4A55DB'>)</span><span lang=EN-US style='font-size:14.0pt;font-family:"Monospaced","serif";color:black'>;</span><span lang=EN-US style='font-size:14.0pt;font-family:"Monospaced","serif"'> <o:p></o:p></span></pre><pre><span lang=EN-US style='font-size:14.0pt;font-family:"Monospaced","serif";color:black'>M</span><span lang=EN-US style='font-size:14.0pt;font-family:"Monospaced","serif"'> <span style='color:#5C5C5C'>=</span> <span style='color:#32B9B9'>mopen</span><span style='color:#4A55DB'>(</span><span style='color:black'>PATH_FILE</span> <span style='color:#5C5C5C'>+</span> <span style='color:rosybrown'>"/"</span> <span style='color:#5C5C5C'>+</span> <span style='color:black'>FILE_NAME,</span><span style='color:rosybrown'>'r'</span><span style='color:#4A55DB'>)</span><span style='color:black'>;</span><o:p></o:p></span></pre><pre><span lang=EN-US style='font-size:14.0pt;font-family:"Monospaced","serif";color:black'>record</span><span lang=EN-US style='font-size:14.0pt;font-family:"Monospaced","serif"'> <span style='color:#5C5C5C'>=</span> <span style='color:#32B9B9'>mgetl</span><span style='color:#4A55DB'>(</span><span style='color:black'>M</span><span style='color:#4A55DB'>)</span><span style='color:black'>;</span><o:p></o:p></span></pre><pre><span lang=EN-US style='font-size:14.0pt;font-family:"Monospaced","serif";color:#4A55DB'>[</span><span lang=EN-US style='font-size:14.0pt;font-family:"Monospaced","serif";color:black'>nl,nc</span><span lang=EN-US style='font-size:14.0pt;font-family:"Monospaced","serif";color:#4A55DB'>]</span><span lang=EN-US style='font-size:14.0pt;font-family:"Monospaced","serif"'> <span style='color:#5C5C5C'>=</span> <span style='color:#32B9B9'>size</span><span style='color:#4A55DB'>(</span><span style='color:black'>record</span><span style='color:#4A55DB'>)</span><span style='color:black'>;</span><o:p></o:p></span></pre><pre><span lang=EN-US style='font-size:14.0pt;font-family:"Monospaced","serif"'><o:p> </o:p></span></pre><pre><span lang=EN-US style='font-size:14.0pt;font-family:"Monospaced","serif";color:black'>nbre_elem</span><span lang=EN-US style='font-size:14.0pt;font-family:"Monospaced","serif"'> <span style='color:#5C5C5C'>=</span> <span style='color:#4A55DB'>(</span><span style='color:black'>nl</span> <span style='color:#5C5C5C'>/</span> <span style='color:rosybrown'>3</span><span style='color:#4A55DB'>)</span><span style='color:black'>;</span><o:p></o:p></span></pre><pre><span lang=EN-US style='font-size:14.0pt;font-family:"Monospaced","serif";color:black'>Nodes_char</span><span lang=EN-US style='font-size:14.0pt;font-family:"Monospaced","serif";color:#4A55DB'>(</span><span lang=EN-US style='font-size:14.0pt;font-family:"Monospaced","serif";color:rosybrown'>1</span><span lang=EN-US style='font-size:14.0pt;font-family:"Monospaced","serif";color:#FFAA00'>:</span><span lang=EN-US style='font-size:14.0pt;font-family:"Monospaced","serif";color:black'>nbre_elem</span><span lang=EN-US style='font-size:14.0pt;font-family:"Monospaced","serif";color:#4A55DB'>)</span><span lang=EN-US style='font-size:14.0pt;font-family:"Monospaced","serif"'> <span style='color:#5C5C5C'>=</span> <span style='color:black'>record</span><span style='color:#4A55DB'>(</span><span style='color:rosybrown'>1</span><span style='color:#FFAA00'>:</span><span style='color:rosybrown'>3</span><span style='color:#FFAA00'>:</span><span style='color:black'>nl</span><span style='color:#4A55DB'>)</span><span style='color:black'>;</span><o:p></o:p></span></pre><pre><span lang=EN-US style='font-size:14.0pt;font-family:"Monospaced","serif"'><o:p> </o:p></span></pre><pre><i><span style='font-size:14.0pt;font-family:"Monospaced","serif";color:#64AE64'>// convert</span></i><span style='font-size:14.0pt;font-family:"Monospaced","serif"'><o:p></o:p></span></pre><pre><span style='font-size:14.0pt;font-family:"Monospaced","serif";color:black'>Nodes</span><span style='font-size:14.0pt;font-family:"Monospaced","serif"'> <span style='color:#5C5C5C'>=</span> <span style='color:#32B9B9'>csvTextScan</span><span style='color:#4A55DB'>(</span><span style='color:black'>Nodes_char,</span><span style='color:rosybrown'>"     "</span><span style='color:#4A55DB'>)</span><span style='color:black'>; </span><i><span style='color:#64AE64'>// !!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!</span></i><o:p></o:p></span></pre><pre><span style='font-size:14.0pt;font-family:"Monospaced","serif"'><o:p> </o:p></span></pre><pre><span lang=EN-US style='font-size:14.0pt;font-family:"Monospaced","serif";color:#32B9B9'>mclose</span><span lang=EN-US style='font-size:14.0pt;font-family:"Monospaced","serif";color:#4A55DB'>(</span><span lang=EN-US style='font-size:14.0pt;font-family:"Monospaced","serif";color:black'>M</span><span lang=EN-US style='font-size:14.0pt;font-family:"Monospaced","serif";color:#4A55DB'>)</span><span lang=EN-US style='font-size:14.0pt;font-family:"Monospaced","serif"'><o:p></o:p></span></pre><p class=MsoNormal><span lang=EN-US><o:p> </o:p></span></p><p class=MsoNormal><span lang=EN-US><o:p> </o:p></span></p><p class=MsoNormal><span lang=EN-US><o:p> </o:p></span></p></div></body></html>
<pre>--------------------------------------------------------------------------------


Le présent mail et ses pièces jointes sont confidentiels et destinés à la personne ou aux personnes visée(s) ci-dessus. Si vous avez reçu cet e-mail par erreur, veuillez contacter immédiatement l'expéditeur et effacer le message de votre système. Toute divulgation, copie ou distribution de cet e-mail est strictement interdite.

This email and any files transmitted with it are confidential and intended solely for the use of the individual or entity to whom they are addressed. If you have received this email in error, please contact the sender and delete the email from your system. If you are not the named addressee you should not disseminate, distribute or copy this email.