<html>
<head>
<meta content="text/html; charset=windows-1252"
http-equiv="Content-Type">
</head>
<body bgcolor="#FFFFFF" text="#000000">
<div class="moz-cite-prefix">what is "i" in your example ? Is there
a loop somewhere ? Matlab will be obviously better for this kind
of explicit loop because it uses JIT compilation.<br>
<br>
S. <br>
<br>
Le 02/03/2017 à 16:41, Michael Benguigui a écrit :<br>
</div>
<blockquote
cite="mid:CALvM90JoR+rx8qXF4H2Pzdgh90_xx_GdpRz+B5fPRrqkCgkGwg@mail.gmail.com"
type="cite">
<div dir="ltr">
<div>Sorry .. for sure! (and thank you for your quick answer)</div>
<div>Scilab 6.0.0</div>
<div><br>
</div>
<div>++</div>
<div>Michael</div>
</div>
<div class="gmail_extra"><br>
<div class="gmail_quote">2017-03-02 16:33 GMT+01:00 Stéphane
Mottelet <span dir="ltr"><<a moz-do-not-send="true"
href="mailto:stephane.mottelet@utc.fr" target="_blank">stephane.mottelet@utc.fr</a>></span>:<br>
<blockquote class="gmail_quote" style="margin:0 0 0
.8ex;border-left:1px #ccc solid;padding-left:1ex">
<div text="#000000" bgcolor="#FFFFFF">
<div class="m_6431114350832403523moz-cite-prefix">Hello,<br>
<br>
Can you precise your Scilab version ? 5.5.2 ? 6.0.0 ? Or
another one...<br>
<br>
S.<br>
<br>
Le 02/03/2017 à 16:29, Michael Benguigui a écrit :<br>
</div>
<blockquote type="cite">
<div dir="ltr">
<div>Hi all,</div>
<div>As a Scilab user, I am currently fighting to
reach Matlab performance..My current scilab program
takes 4x more than my matlab's vesion. Here are some
instructions requiring some optimizations.. If you
have an idea... thanks a lot!</div>
<div><br>
</div>
<div>All times are cumulative times after the
execution (iterations)<br>
I used the Matlab and Scilab profilers<br>
tooth_psi_angle is a 70000x4 2D matrix of real
numbers<br>
tool.forces.cutting_forces_<wbr>teeth_TCS is a
72000x4x3 matrix of real numbers<br>
process.fz is a scalar <br>
tool.kappa is a scalar</div>
<div><br>
if tool_angle(i) < tool.pitch_angle then<br>
h_total(i) = process.fz *
sin(tooth_psi_angle(i,tooth)) * sin(tool.kappa);</div>
<div><br>
</div>
<div>=> Matlab:<0.01s vs Scilab 4.8s</div>
<div><br>
ROT_LCS_TCS =[-cos(tooth_psi_angle(i,<wbr>tooth))
-sin(tool.kappa)*sin(tooth_<wbr>psi_angle(i,tooth))
-cos(tool.kappa)*sin(tooth_<wbr>psi_angle(i,tooth));
sin(tooth_psi_angle(i,tooth))
-sin(tool.kappa)*cos(tooth_<wbr>psi_angle(i,tooth))
-cos(tool.kappa)*cos(tooth_<wbr>psi_angle(i,tooth));
0 cos(tool.kappa) -sin(tool.kappa)]; // result is a
3x3 matrix</div>
<div><br>
=> Matlab:0.67s vs Scilab 4s</div>
<div><br>
tool.forces.cutting_forces_<wbr>teeth_TCS(i,tooth,:)
= ROT_LCS_TCS*[ft;fr;fa];</div>
<div><br>
=> Matlab:0.55s vs Scilab 1.3s</div>
<div><br>
Regards<br>
Michael</div>
</div>
<br>
<fieldset
class="m_6431114350832403523mimeAttachmentHeader"></fieldset>
<br>
<pre>______________________________<wbr>_________________
users mailing list
<a moz-do-not-send="true" class="m_6431114350832403523moz-txt-link-abbreviated" href="mailto:users@lists.scilab.org" target="_blank">users@lists.scilab.org</a>
<a moz-do-not-send="true" class="m_6431114350832403523moz-txt-link-freetext" href="http://lists.scilab.org/mailman/listinfo/users" target="_blank">http://lists.scilab.org/<wbr>mailman/listinfo/users</a><span class="HOEnZb"><font color="#888888">
</font></span></pre><span class="HOEnZb"><font color="#888888">
</font></span></blockquote><span class="HOEnZb"><font color="#888888">
<p>
</p>
<pre class="m_6431114350832403523moz-signature" cols="72">--
Département de Génie Informatique
EA 4297 Transformations Intégrées de la Matière Renouvelable
Université de Technologie de Compiègne - CS 60319
60203 Compiègne cedex</pre>
</font></span></div>
______________________________<wbr>_________________
users mailing list
<a moz-do-not-send="true" href="mailto:users@lists.scilab.org">users@lists.scilab.org</a>
<a moz-do-not-send="true" href="http://lists.scilab.org/mailman/listinfo/users" target="_blank" rel="noreferrer">http://lists.scilab.org/<wbr>mailman/listinfo/users</a>
</blockquote></div>
--
<div class="gmail_signature" data-smartmail="gmail_signature"><div dir="ltr"><div>Michael Benguigui, Activeeon
+33 6 304 37 37 0
<a moz-do-not-send="true" href="https://fr.linkedin.com/in/micha%C3%ABl-benguigui-23a85921" target="_blank">https://fr.linkedin.com/in/micha%C3%ABl-benguigui-23a85921</a>
skype: <a moz-do-not-send="true" href="mailto:michael.benguigui@hotmail.fr" target="_blank">michael.benguigui@hotmail.fr</a></div></div></div>
</div>
<fieldset class="mimeAttachmentHeader"></fieldset>
<pre wrap="">_______________________________________________
users mailing list
<a class="moz-txt-link-abbreviated" href="mailto:users@lists.scilab.org">users@lists.scilab.org</a>
<a class="moz-txt-link-freetext" href="http://lists.scilab.org/mailman/listinfo/users">http://lists.scilab.org/mailman/listinfo/users</a>
</pre>
</blockquote>
<p>
</p><pre class="moz-signature" cols="72">--
Département de Génie Informatique
EA 4297 Transformations Intégrées de la Matière Renouvelable
Université de Technologie de Compiègne - CS 60319
60203 Compiègne cedex</pre></body></html>