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.

Can I extract the algorithm that corresponds to the COMSOL solution?

Panagiotis Dimakopoulos

Please login with a confirmed email address before reporting spam

Hi!
I would like to extract the code of a COMSOL file so that I can interfere when ever I want,
How can I do that? Is there any idea?

Thank you in advance!

PD

3 Replies Last Post Feb 24, 2017, 8:30 a.m. EST

Please login with a confirmed email address before reporting spam

Posted: 8 years ago Apr 13, 2016, 7:49 p.m. EDT
What do you mean by Extraction of algorithm? As far as I know, COMSOL is not an open-source code, hence not possible to obtain the source code.

--
Pu, ZHANG
DTU Fotonik
What do you mean by Extraction of algorithm? As far as I know, COMSOL is not an open-source code, hence not possible to obtain the source code. -- Pu, ZHANG DTU Fotonik

Panagiotis Dimakopoulos

Please login with a confirmed email address before reporting spam

Posted: 8 years ago Apr 16, 2016, 2:30 p.m. EDT
Hi again,
I am aware of this fact. But I have some thoughts.
First of all I have on my mind the ANSYS software example, where I can extract the model of my problem in a .txt file in a code form. This is feasible in ANSYS software as there are commands that helps me to convert each simulation to an algorithm.
But COMSOL does not include something relative. As I know, I should use the LiveLink for MATLAB.
Then, using MATLAB I can write a code which will do the same thing as the model which I did construct in the COMSOL interface.
And my question is,
Do I have the possibility to extract a (MATLAB) code form COMSOL interface as I do it in ANSYS software? (I don't mean that COMSOL is an open-source code)

P.S. The code that I write in ANSYS software doesn't have any relationship with MATLAB. I use it as an example.

Thank you in advance for your time
Hi again, I am aware of this fact. But I have some thoughts. First of all I have on my mind the ANSYS software example, where I can extract the model of my problem in a .txt file in a code form. This is feasible in ANSYS software as there are commands that helps me to convert each simulation to an algorithm. But COMSOL does not include something relative. As I know, I should use the LiveLink for MATLAB. Then, using MATLAB I can write a code which will do the same thing as the model which I did construct in the COMSOL interface. And my question is, Do I have the possibility to extract a (MATLAB) code form COMSOL interface as I do it in ANSYS software? (I don't mean that COMSOL is an open-source code) P.S. The code that I write in ANSYS software doesn't have any relationship with MATLAB. I use it as an example. Thank you in advance for your time

Jeff Hiller COMSOL Employee

Please login with a confirmed email address before reporting spam

Posted: 7 years ago Feb 24, 2017, 8:30 a.m. EST
Reading between the lines of your post, I get the sense that you think creating the .m file from scratch is your only option. It is not. You can save a model you've created in the COMSOL graphical user interface as a .m file.
See the Introduction to LiveLink for MATLAB manual, version 5.2a, page 28.
Best,
Jeff
Reading between the lines of your post, I get the sense that you think creating the .m file from scratch is your only option. It is not. You can save a model you've created in the COMSOL graphical user interface as a .m file. See the Introduction to LiveLink for MATLAB manual, version 5.2a, page 28. Best, Jeff

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.