How MATLAB calls ANSYS

Source: Internet
Author: User
Referring to the relevant posts on the steel structure forum, we tried to use MATLAB to call ANSYS and transmit parameters in the middle. After several attempts, the operation was successful. This post is sent to the MATLAB edition for your preference.
Here is a brief description:
% Hanyang University, Wang Xiaoyong, 2007,10, 24
AA = [0.5 1.0 1.2; 0.6 1.0 1.3]
FID = fopen ('C: \ duqu.txt ', 'wt ')
Fprintf (FID, '% 6.2f % 6.2f % 6.2f \ n', ')......... MATLAB computation results are written into files
Fclose (FID)
System ('d: \ ANSYS \ v80 \ ANSYS \ bin \ intel \ ansys80-B-P ane3fl-I c: \ zuixinmoliang.txt-o c: \ vm5.out ')
C: \ zuixinmoliang.txt is a command stream file.
C: \ vm5.out is the location of the output file, and the output file is savedProgramRunning information.

Read computational parameters from the MATLAB output file in the ANSYS command stream. .
* Create, FF
* Dim, exa, 2, 3
* Vread, exa (), c: \ duqu, txt, jik
(3f6. 2)
* End
/Input, FF
Through this method, MATLAB can call ANSYS.
The attachment contains the MATLAB program and the ANSYS command stream.

Matrixwrite.rar

Zuixinmoliang.rar

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.