How to connect MATLAB with EES(engineering equation solver) using MATLAB code?
32 Ansichten (letzte 30 Tage)
Ältere Kommentare anzeigen
I have wrote some MATLAB code, using some parameters from genetic algorithm input to EES for calculating thermodynamic properties. Then I get the calculated result and output from EES to matlab. But I met some problems, here is the connecting matlab code below:

Because I have bought the academic version EES software, I input the parameters into EES by writing parameter value in dat file, and EES got the data from dat file. However, the calculating process stopped in the EES interface, no command have executed after that. If the program runs successfully, EES should return calculating results to MATLAB within seconds.
I have no idea what wrong with it, can anyone help me? I can't thank you enough.
0 Kommentare
Antworten (1)
David Sebastian Arcila Cortina
am 11 Okt. 2020
Bearbeitet: David Sebastian Arcila Cortina
am 11 Okt. 2020
According to what I found trying to use EES as the Maltab calculator to solve systems of nonlinear equations that matlab does not solve for me as far as I know, the page http://fchart.com/, repeatedly mentions that to communicate EES with other programs, the professional version is necessary, but try to base yourself on this page http://fchart.com/ees/eeshelp/hs605.htm, which I do not rule out that you have already seen it. From what I understood if EES stops calculating, it's definitely very strange.
This is enough for me, for matlab to demand a solution from EES, regardless of whether there is in each of the programs, just to solve.
chan = ddeinit('EES','DDE');
rc = ddeexec(chan,'[Solve]');
Important, as far as I know from what I did, it only works for me if the Matlab and EES files are in the same folder, that is, the .m and .ees files and the information files (.dat, .csv ... ) in the same folder.
1 Kommentar
Mike
am 28 Mai 2024
Hey there!
I found your exploration of using EES as a Matlab calculator to solve systems of nonlinear equations really interesting. It's cool how you've worked around Matlab's limitations and found solutions using EES, despite the professional version's constraints.
The fact that EES stops calculating is strange and needs further investigation. Your clever workaround of having Matlab demand a solution from EES is impressive. The code snippet you shared:
```
chan = ddeinit('EES','DDE');
rc = ddeexec(chan,'[Solve]');
```
clearly shows this approach.
Your observation about needing the Matlab and EES files in the same folder is crucial. It can save others time and frustration. Practical insights like these make a difference when implementing solutions. Keep up the great work!
Siehe auch
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!