<?xml version="1.0" encoding="UTF-8"?>
<rss version="2.0" xmlns:atom="http://www.w3.org/2005/Atom">
 <channel>
  <atom:link href="http://www.comsol.eu/community/forums/matlab/rss/thread/1715.rss" rel="self" type="application/rss+xml"/>
  <title>COMSOL Forums: Exporting Comsol data to Matlab?</title>
  <link>http://www.comsol.eu/community/forums/general/thread/1715/</link>
  <description>Most recent forum messages</description>
  <pubDate>Fri, 10 Feb 2012 11:30:40 +0000</pubDate>
  <image>
   <title>COMSOL Forums: Exporting Comsol data to Matlab?</title>
   <url>http://www.comsol.eu/shared/images/logos/comsol_logo.gif</url>
   <link>http://www.comsol.eu/community/forums/general/thread/1715/</link>
  </image>
  <item>
   <title>Re: Exporting Comsol data to Matlab?</title>
   <link>http://www.comsol.eu/community/forums/general/thread/1715/#p70415</link>
   <description>&lt;div class=&quot;quote&quot;&gt;&lt;br /&gt;&#13;
Hello,&lt;br /&gt;&#13;
 I know this must be a simple operation but how do you export just the eigenvalue/eigenfrequency in the new versions of Comsol? In 3.5a I used &amp;quot;x=fem.sol.lambda;&amp;quot;but now in Comsol 4.2 I have tried different variations of mpheval and mphglobal but have not been able to get the syntax right. Thanks for any assistance.&lt;br /&gt;&#13;
&lt;/div&gt;&lt;br /&gt;&#13;
&lt;br /&gt;&#13;
One way is to reverse engineer things that are not yet documented. For your purpose, there is an &amp;quot;Export Data&amp;quot; node available for the Results section. Right click on the results node and add an Export. There you will be able to select the different native and user-derived variable (if any) as export data. Save the model as an .m file and open it in a text editor, you will see the commands you can use in MATLAB.&lt;br /&gt;&#13;
&lt;br /&gt;&#13;
best,&lt;br /&gt;&#13;
Kodanda</description>
   <pubDate>Fri, 10 Feb 2012 11:30:40 +0000</pubDate>
   <guid isPermaLink="false">1715.1328873440.70415</guid>
  </item>
  <item>
   <title>Re: Exporting Comsol data to Matlab?</title>
   <link>http://www.comsol.eu/community/forums/general/thread/1715/#p70274</link>
   <description>Hello,&lt;br /&gt;&#13;
 I know this must be a simple operation but how do you export just the eigenvalue/eigenfrequency in the new versions of Comsol? In 3.5a I used &amp;quot;x=fem.sol.lambda;&amp;quot;but now in Comsol 4.2 I have tried different variations of mpheval and mphglobal but have not been able to get the syntax right. Thanks for any assistance. </description>
   <pubDate>Wed, 08 Feb 2012 21:42:58 +0000</pubDate>
   <guid isPermaLink="false">1715.1328737378.70274</guid>
  </item>
  <item>
   <title>Re: Exporting Comsol data to Matlab?</title>
   <link>http://www.comsol.eu/community/forums/general/thread/1715/#p55176</link>
   <description>&lt;div class=&quot;quote&quot;&gt;&lt;br /&gt;&#13;
Hi,&lt;br /&gt;&#13;
&lt;br /&gt;&#13;
I didn't discover the way to export the maximum von Mises stress from COMSOL to MATLAB. I've read the document llmatlab_ug.pdf, but it's hard to understand for a MATLAB and COMSOL rookie like me. I'm using COMSOL 4.0a by the way. Do you have any experience with exporting data from COMSOL to MATLAB in COMSOL 4.0a or is it maybe the same as 4.1?&lt;br /&gt;&#13;
&lt;br /&gt;&#13;
Best regards,&lt;br /&gt;&#13;
Arnoud&lt;br /&gt;&#13;
&lt;/div&gt;&lt;br /&gt;&#13;
&lt;br /&gt;&#13;
Hello,&lt;br /&gt;&#13;
&lt;br /&gt;&#13;
it need this information too. :)&lt;br /&gt;&#13;
I want to export only the von Mises stress data calculated in Comsol into Matlab for postprocessing. I know how to export to an txt-file. Of course I can copy paste the whole data, but this is to much handwork.&lt;br /&gt;&#13;
&lt;br /&gt;&#13;
Greetings&lt;br /&gt;&#13;
</description>
   <pubDate>Mon, 04 Jul 2011 04:20:54 +0000</pubDate>
   <guid isPermaLink="false">1715.1309753254.55176</guid>
  </item>
  <item>
   <title>Re: Exporting Comsol data to Matlab?</title>
   <link>http://www.comsol.eu/community/forums/general/thread/1715/#p53875</link>
   <description>&lt;div class=&quot;quote&quot;&gt;&lt;br /&gt;&#13;
Hi&lt;br /&gt;&#13;
&lt;br /&gt;&#13;
You need to get your link between COMSOL and Matlab up running, either you missed a step during the installation of COMSOL or some of the files added to matlab are not set up correctly. Have a look at the installation documentation of COMSOL (I beleive ther are other comments in the forum and on the support KB pages).&lt;br /&gt;&#13;
&lt;br /&gt;&#13;
Once you have the link running, you can (in V3.5a) just do a File &amp;quot;connect&amp;quot; to matlab from the COSOL GUI and export the &amp;quot;fem&amp;quot; structure to Matlab by a CNTRL-F.&lt;br /&gt;&#13;
&lt;br /&gt;&#13;
then you need to understand the &amp;quot;fem&amp;quot; structure (see mlinterface.pdf in the COMSOL doc) to extract the data in binay mode and you can continue your processing at will.&lt;br /&gt;&#13;
&lt;br /&gt;&#13;
Good luck&lt;br /&gt;&#13;
Ivar&lt;br /&gt;&#13;
&lt;/div&gt;&lt;br /&gt;&#13;
&lt;br /&gt;&#13;
&lt;br /&gt;&#13;
Sorry, but this answer does not help.&lt;br /&gt;&#13;
&lt;br /&gt;&#13;
First of all &amp;quot;when or where&amp;quot; do I have to press ctrl+f. Second I of course want to automatically return values that comsol computes to the matlab script (i.e. without gui ... Matlab calls Comsol and then uses the matrix that comsol produces for further Processing). &lt;br /&gt;&#13;
&lt;br /&gt;&#13;
Second ... mlinterface.doc - I have not found it and cannot find it. Is it to much to ask for a link if there is a documentation...&lt;br /&gt;&#13;
&lt;br /&gt;&#13;
The comsol Matlab interface is really a joke. It is a real struggle to do the simplest thing like give a single value from Comsol to Matlab. Sorry, but this is unacceptable.&lt;br /&gt;&#13;
&lt;br /&gt;&#13;
I hope you will prepare a good solution soon, as I see the necessity to spread this word in the community...&lt;br /&gt;&#13;
&lt;br /&gt;&#13;
Michael&lt;br /&gt;&#13;
</description>
   <pubDate>Fri, 17 Jun 2011 11:17:58 +0000</pubDate>
   <guid isPermaLink="false">1715.1308309478.53875</guid>
  </item>
  <item>
   <title>Re: Exporting Comsol data to Matlab?</title>
   <link>http://www.comsol.eu/community/forums/general/thread/1715/#p52088</link>
   <description>Hi,&lt;br /&gt;&#13;
&lt;br /&gt;&#13;
I didn't discover the way to export the maximum von Mises stress from COMSOL to MATLAB. I've read the document llmatlab_ug.pdf, but it's hard to understand for a MATLAB and COMSOL rookie like me. I'm using COMSOL 4.0a by the way. Do you have any experience with exporting data from COMSOL to MATLAB in COMSOL 4.0a or is it maybe the same as 4.1?&lt;br /&gt;&#13;
&lt;br /&gt;&#13;
Best regards,&lt;br /&gt;&#13;
Arnoud</description>
   <pubDate>Sat, 04 Jun 2011 15:27:43 +0000</pubDate>
   <guid isPermaLink="false">1715.1307201263.52088</guid>
  </item>
  <item>
   <title>Re: Exporting Comsol data to Matlab?</title>
   <link>http://www.comsol.eu/community/forums/general/thread/1715/#p52040</link>
   <description>Hi,&lt;br /&gt;&#13;
&lt;br /&gt;&#13;
Did you find out the way to export the vonMises stress per element basis into MATLAB? &lt;br /&gt;&#13;
&lt;br /&gt;&#13;
My requirement is to do it in V4.1, but not in V3.5a. I know that there are different access methods to interact with the data models in V4.1. For example, I figured out how to get/set domain information on geomety objects. However, the solid mechanis variables appear to be not documented yet.&lt;br /&gt;&#13;
&lt;br /&gt;&#13;
Best regards,&lt;br /&gt;&#13;
Kodanda</description>
   <pubDate>Fri, 03 Jun 2011 11:15:26 +0000</pubDate>
   <guid isPermaLink="false">1715.1307099726.52040</guid>
  </item>
  <item>
   <title>Re: Exporting Comsol data to Matlab?</title>
   <link>http://www.comsol.eu/community/forums/general/thread/1715/#p51653</link>
   <description>Hello everybody,&lt;br /&gt;&#13;
&lt;br /&gt;&#13;
I want to export COMSOL data (maximum von mises stress) in to Matlab. Then I want to compare the value of the maximum von mises stress from the model with an in advanced determined permissible value, to create an optimal geometry for contact lenses. I've less experience with COMSOL and MATLAB interface. &lt;br /&gt;&#13;
&lt;br /&gt;&#13;
Can someone tell me how to export the specific data to Matlab? In case it's necessary to use my model, I've attached my model.&lt;br /&gt;&#13;
&lt;br /&gt;&#13;
Thanks in advance!&lt;br /&gt;&#13;
&lt;br /&gt;&#13;
Arnoud</description>
   <pubDate>Mon, 30 May 2011 11:02:22 +0000</pubDate>
   <guid isPermaLink="false">1715.1306753342.51653</guid>
  </item>
  <item>
   <title>Re: Exporting Comsol data to Matlab?</title>
   <link>http://www.comsol.eu/community/forums/general/thread/1715/#p16537</link>
   <description>Hi Ivar,&lt;br /&gt;&#13;
&lt;br /&gt;&#13;
I have seen your reply for exporting data from comsol to matlab but when I do as u said then I get the following error&lt;br /&gt;&#13;
Error: 9016&lt;br /&gt;&#13;
Could not obtain license for SCRIPTPROMPT&lt;br /&gt;&#13;
License error.</description>
   <pubDate>Wed, 09 Jun 2010 07:12:49 +0000</pubDate>
   <guid isPermaLink="false">1715.1276067569.16537</guid>
  </item>
  <item>
   <title>Re: Exporting Comsol data to Matlab?</title>
   <link>http://www.comsol.eu/community/forums/general/thread/1715/#p4430</link>
   <description>Hi&lt;br /&gt;&#13;
&lt;br /&gt;&#13;
You need to get your link between COMSOL and Matlab up running, either you missed a step during the installation of COMSOL or some of the files added to matlab are not set up correctly. Have a look at the installation documentation of COMSOL (I beleive ther are other comments in the forum and on the support KB pages).&lt;br /&gt;&#13;
&lt;br /&gt;&#13;
Once you have the link running, you can (in V3.5a) just do a File &amp;quot;connect&amp;quot; to matlab from the COSOL GUI and export the &amp;quot;fem&amp;quot; structure to Matlab by a CNTRL-F.&lt;br /&gt;&#13;
&lt;br /&gt;&#13;
then you need to understand the &amp;quot;fem&amp;quot; structure (see mlinterface.pdf in the COMSOL doc) to extract the data in binay mode and you can continue your processing at will.&lt;br /&gt;&#13;
&lt;br /&gt;&#13;
Good luck&lt;br /&gt;&#13;
Ivar</description>
   <pubDate>Wed, 18 Nov 2009 21:06:20 +0000</pubDate>
   <guid isPermaLink="false">1715.1258578380.4430</guid>
  </item>
  <item>
   <title>Exporting Comsol data to Matlab?</title>
   <link>http://www.comsol.eu/community/forums/general/thread/1715/#p4382</link>
   <description>Hello  everybody,&lt;br /&gt;&#13;
&lt;br /&gt;&#13;
I want to postprocess Comsol data in Matlab. Since Ascii files blow up in size and I get &amp;quot;out of memory error&amp;quot;, I'm looking for some other way. I've no experience with Comsol-Matlab interface and it seems to me that this interface is not working in my system. &lt;br /&gt;&#13;
&lt;br /&gt;&#13;
Could someone please tell me, how to export Postprocessing data in some Matlab-compatible format (not Ascii)?&lt;br /&gt;&#13;
&lt;br /&gt;&#13;
I've converted a Comsol model (after executing) into an m-file and wanted to run it in Matlab (running separately from Comsol) but Matlab is probably not able to read the flbinaryfile (*.mphm). Any suggestion, what could be wrong here?&lt;br /&gt;&#13;
&lt;br /&gt;&#13;
Thanks.&lt;br /&gt;&#13;
Daniel</description>
   <pubDate>Wed, 18 Nov 2009 11:00:06 +0000</pubDate>
   <guid isPermaLink="false">1715.1258542006.4382</guid>
  </item>
 </channel>
</rss>

