Matlab and Ansys Interface
Matlab and Ansys Interface
(OP)
I am working on optimization with Matlab, I have a program written in Matlab for optimization of a structure.For Analysis I have ansys. I have to continuously interface Matlab and Ansys,such as input file from Matlab to Ansys,running Ansys,and results file from ansys to Matlab this process is continuous.
Please someone can help me how to do this ?
Please someone can help me how to do this ?





RE: Matlab and Ansys Interface
What Matlab command do you need to make a command line call?
Cheers
Greg Locock
Please see FAQ731-376 for tips on how to make the best use of Eng-Tips.
RE: Matlab and Ansys Interface
I have a matlab file consisting of node number,X and Y coordinates, E (modulus of elasticity) and Area of cross-section of each member. This input file I have to pass to ansys from matlab and run the truss in ansys and get the results and these results file I have to pass again to matlab
RE: Matlab and Ansys Interface
the best you can do, I think, is to manage this via text in / out files. Embedding Ansys batch inside a Matlab script, or calling Matlab from within Ansys are, in my opinion, very complex tasks that don't pay for the time needed to implement them.
Regards
RE: Matlab and Ansys Interface
Cheers
Greg Locock
Please see FAQ731-376 for tips on how to make the best use of Eng-Tips.
RE: Matlab and Ansys Interface
GregLocock, sounds very interesting: you mean you have managed to call Ansys batch from another program? Once I tried with MathLink and I gave up...
I agree that tens of back-and-forth runs would be a pain to do by hand.
Regi, is the Matlab routine calling mathematical functions which you could not reproduce with APDL? If not, then re-writing the routine with Ansys' APDL would probably be faster (and also faster from an execution point of view). Just an idea, though...
Regards
RE: Matlab and Ansys Interface
Are you working in Model Updating? It seems to me after reading your post.
I'm developing a FEMU code using ANSYS and Scilab.
It is rather easy to manage this by employing the /SYS command in ANSYS and by executing ANSYS from the command line from Scilab.
Andrea
-------------------------------------------
Andrea Mordini, Civil Engineer, Ph.D.
http://www.andreamordini.com
-------------------------------------------
RE: Matlab and Ansys Interface
Cheers
Greg Locock
Please see FAQ731-376 for tips on how to make the best use of Eng-Tips.