<?xml version="1.0" encoding="UTF-8"?>
<rss version="2.0">
  <channel>
    <link>http://www.mathworks.com/matlabcentral/newsreader/view_thread/249590</link>
    <title>MATLAB Central Newsreader - Simple Compiler Issues</title>
    <description>Feed for thread: Simple Compiler Issues</description>
    <language>en-us</language>
    <copyright>&amp;copy;1994-2012 by MathWorks, Inc.</copyright>
    <webmaster>webmaster@mathworks.com</webmaster>
    <generator>MATLAB Central Newsreader</generator>
    <docs>http://blogs.law.harvard.edu/tech/rss</docs>
    <ttl>60</ttl>
    <image>
      <title>MathWorks</title>
      <url>http://www.mathworks.com/images/membrane_icon.gif</url>
    </image>
    <item>
      <pubDate>Tue, 21 Apr 2009 17:36:02 -0400</pubDate>
      <title>Simple Compiler Issues</title>
      <link>http://www.mathworks.com/matlabcentral/newsreader/view_thread/249590#644412</link>
      <author>Andy </author>
      <description>I'm having trouble creating a stand-alone EXE file from an m-file with Matlab Compiler.  I can successfully create a stand-alone exe file from an m-file, but it only runs on the computer that i used to run the compiler.  It does not work on any other computer.&lt;br&gt;
&lt;br&gt;
This is the command I use...&lt;br&gt;
&quot;&amp;gt;&amp;gt; mcc -m sagittafinder&quot;&lt;br&gt;
&lt;br&gt;
This is the error that occurs on other computer....&lt;br&gt;
&quot;Unable to Locate Component - This application has failed to start because libmat.dll was not found.  Re-installing the application max fix this problem.&lt;br&gt;
&lt;br&gt;
It does work great on my PC only.  This is the versions of Matlab and compiler that I'm using on a Dell desktop with Windows XP SP2&lt;br&gt;
&lt;br&gt;
Matlab Version 6.5.2.202935 Release 13 (Service Pack 2)&lt;br&gt;
MCC MATLAB to C/C++ Compiler (Version 3.0)&lt;br&gt;
&lt;br&gt;
And here is my code. I've been searching but most issues on this forum are much more complicated, so i'm optimistic that someone here can help me.&lt;br&gt;
&lt;br&gt;
function sagittafinder&lt;br&gt;
clear&lt;br&gt;
n = 'y';&lt;br&gt;
&lt;br&gt;
while strcmp(n,'y') | strcmp(n,'Y');&lt;br&gt;
&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;clc&lt;br&gt;
&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;D = input('Enter Diameter (in): ');&lt;br&gt;
&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;M = input('Enter Area (in2): ');&lt;br&gt;
&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;R = D/2;&lt;br&gt;
&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;A = pi*R^2;&lt;br&gt;
&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;K = A - M;&lt;br&gt;
&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;h2 = 0;&lt;br&gt;
&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;Kg = 0;&lt;br&gt;
&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;while Kg &amp;lt; K&lt;br&gt;
&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;h2 = h2 + 0.001;&lt;br&gt;
&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;Kg = (D/2)^2*acos((R-h2)/R)-(R-h2)*sqrt(2*R*h2-h2^2);      &lt;br&gt;
&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;end  &lt;br&gt;
&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;disp(sprintf('The Area Check is %g',A - Kg))&lt;br&gt;
&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;disp(sprintf('The Height is %g',h2))&lt;br&gt;
&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;n = input('Run Again? ','s');&lt;br&gt;
end</description>
    </item>
    <item>
      <pubDate>Wed, 22 Apr 2009 08:11:09 -0400</pubDate>
      <title>Re: Simple Compiler Issues</title>
      <link>http://www.mathworks.com/matlabcentral/newsreader/view_thread/249590#644577</link>
      <author>Titus</author>
      <description>&lt;br&gt;
&quot;Andy &quot; &amp;lt;ahunsberger@miti.cc&amp;gt; schrieb im Newsbeitrag &lt;br&gt;
news:gsl062$h1l$1@fred.mathworks.com...&lt;br&gt;
&amp;gt; I'm having trouble creating a stand-alone EXE file from an m-file with &lt;br&gt;
&amp;gt; Matlab Compiler.  I can successfully create a stand-alone exe file from an &lt;br&gt;
&amp;gt; m-file, but it only runs on the computer that i used to run the compiler. &lt;br&gt;
&amp;gt; It does not work on any other computer.&lt;br&gt;
&amp;gt;&lt;br&gt;
&amp;gt; This is the command I use...&lt;br&gt;
&amp;gt; &quot;&amp;gt;&amp;gt; mcc -m sagittafinder&quot;&lt;br&gt;
&amp;gt;&lt;br&gt;
&amp;gt; This is the error that occurs on other computer....&lt;br&gt;
&amp;gt; &quot;Unable to Locate Component - This application has failed to start because &lt;br&gt;
&amp;gt; libmat.dll was not found.  Re-installing the application max fix this &lt;br&gt;
&amp;gt; problem.&lt;br&gt;
&amp;gt;&lt;br&gt;
&amp;gt; It does work great on my PC only.  This is the versions of Matlab and &lt;br&gt;
&amp;gt; compiler that I'm using on a Dell desktop with Windows XP SP2&lt;br&gt;
&amp;gt;&lt;br&gt;
&amp;gt; Matlab Version 6.5.2.202935 Release 13 (Service Pack 2)&lt;br&gt;
&amp;gt; MCC MATLAB to C/C++ Compiler (Version 3.0)&lt;br&gt;
&amp;gt;&lt;br&gt;
&amp;gt; And here is my code. I've been searching but most issues on this forum are &lt;br&gt;
&amp;gt; much more complicated, so i'm optimistic that someone here can help me.&lt;br&gt;
&amp;gt;&lt;br&gt;
&amp;gt; function sagittafinder&lt;br&gt;
&amp;gt; clear&lt;br&gt;
&amp;gt; n = 'y';&lt;br&gt;
&amp;gt;&lt;br&gt;
&amp;gt; while strcmp(n,'y') | strcmp(n,'Y');&lt;br&gt;
&amp;gt;    clc&lt;br&gt;
&amp;gt;    D = input('Enter Diameter (in): ');&lt;br&gt;
&amp;gt;    M = input('Enter Area (in2): ');&lt;br&gt;
&amp;gt;    R = D/2;&lt;br&gt;
&amp;gt;    A = pi*R^2;&lt;br&gt;
&amp;gt;    K = A - M;&lt;br&gt;
&amp;gt;    h2 = 0;&lt;br&gt;
&amp;gt;    Kg = 0;&lt;br&gt;
&amp;gt;    while Kg &amp;lt; K&lt;br&gt;
&amp;gt;        h2 = h2 + 0.001;&lt;br&gt;
&amp;gt;        Kg = (D/2)^2*acos((R-h2)/R)-(R-h2)*sqrt(2*R*h2-h2^2);&lt;br&gt;
&amp;gt;    end&lt;br&gt;
&amp;gt;    disp(sprintf('The Area Check is %g',A - Kg))&lt;br&gt;
&amp;gt;    disp(sprintf('The Height is %g',h2))&lt;br&gt;
&amp;gt;    n = input('Run Again? ','s');&lt;br&gt;
&amp;gt; end&lt;br&gt;
&lt;br&gt;
Hi,&lt;br&gt;
you need to install those libraries on the deployment machine. There is a &lt;br&gt;
chapter in the doc describing this. In MATLAB\toolbox\compiler\win32 (or &lt;br&gt;
similar) should be a file mglInstaller.exe. Run this on the machine where &lt;br&gt;
you want to run the compiled application.&lt;br&gt;
&lt;br&gt;
Titus </description>
    </item>
  </channel>
</rss>

