I am doing membrane-based gas separation modeling in Apsen HYSYS , membrane code done in visual basic (VB), now if I want to control HYSYS flow sheet via Matlab by creating for loop, How can I do it?
Rasel Ahmed Put both files, Hysys simulation case (.hsc) & the following matlab script (.m) in the same folder. Matlab Code, please modify simulation name ("Distill_Example.hsc") accondingly:
Now, I am getting it difficult to connect any excel file with hysys, . how can I code the relevant data of excel file in matlab then optimize it by using Matlab. I have downloaded so many articles, but there is no specific guidelines or coding available for it.
Hysys can be linked with any programming language with COM (common object model) capabilities like Excel visual basic, python, R, Java, C++, C#, Matlab and among others. Then, to make the connection its only necessary the code sintax of those programming language to use COM capabilities, for example in matlab "actxserver" is used like COM function, in excel "CreateObject" function is used for that, in python "win32.Dispatch" function is used for that, etc. Likewise, Excel & Matlab can be linked using the same COM thechnology, however you must select the application (Matlab, Excel, Python, etc) that will manage the connections and procedures, for example, you can select excel like manager app linked wit Hysys & Matlab, working like data/procedures tranfer/run manager to other both programs or use Matlab like manager app linked with Excel & Matab, performing optimization taks and saving optimization results in Excel.
I have a class recorded where I explain the connection between Excel and Hysys, please contact me: [email protected]
Hello everyone. Ive run into the same problem linking aspen hysys and matlab and have done the procedure you commented Mr. @Andres Felipe Abril Duran but didnt make any good. I got your email, wanted to ask may I contact for further help?