Discussion Closed This discussion was created more than 6 months ago and has been closed. To start a new discussion with a link back to this one, click here.

Exporting COMSOL data into MATLAB

Please login with a confirmed email address before reporting spam

Hi there,

I am new to COMSOL and currently running a very basic simulation adding strain to a 2D custom geometry. I am just wondering how i would go about exporting the post processed stress map (the von Mises stress value at each point of the mesh) into MATLAB. Is there a way to achieve this?

Thanks in advance

3 Replies Last Post 2017年2月6日 GMT-5 09:39
Jeff Hiller COMSOL Employee

Please login with a confirmed email address before reporting spam

Posted: 8 years ago 2016年1月15日 GMT-5 08:42
Yes, this is feasible with LiveLink for MATLAB. If your license includes that product, you can access its documentation (Introduction to LiveLink for MATLAB manual and LiveLink for MATLAB User's Guide manual), like all COMSOL documentation, through the File > Help >Documentation. If you do not have a license for that product, please contact you COMSOL representative.
Best,
Jeff
Yes, this is feasible with LiveLink for MATLAB. If your license includes that product, you can access its documentation (Introduction to LiveLink for MATLAB manual and LiveLink for MATLAB User's Guide manual), like all COMSOL documentation, through the File > Help >Documentation. If you do not have a license for that product, please contact you COMSOL representative. Best, Jeff

Franky Leonardo Prieto Téllez

Please login with a confirmed email address before reporting spam

Posted: 7 years ago 2017年2月5日 GMT-5 08:58
Livelink is not needed, you can export the data as text and then import in MATLAB... I don't have knowledge about your simulation problem, but with an excercise it was easier to do that than Import with livelink directly... should not be but it was.
Livelink is not needed, you can export the data as text and then import in MATLAB... I don't have knowledge about your simulation problem, but with an excercise it was easier to do that than Import with livelink directly... should not be but it was.

Lars Gregersen COMSOL Employee

Please login with a confirmed email address before reporting spam

Posted: 7 years ago 2017年2月6日 GMT-5 09:39
Hi

If you have LiveLink for Matlab you can use the function mpheval to evaluate any expression in all mesh elements. You can use the option 'refine' to evaluate higher order elements.

--
Lars Gregersen
Comsol Denmark
Hi If you have LiveLink for Matlab you can use the function mpheval to evaluate any expression in all mesh elements. You can use the option 'refine' to evaluate higher order elements. -- Lars Gregersen Comsol Denmark

Note that while COMSOL employees may participate in the discussion forum, COMSOL® software users who are on-subscription should submit their questions via the Support Center for a more comprehensive response from the Technical Support team.