first of all, thanks for providing such an excellent place for interesting discussions about FAST!
I have two issues which I have encountered lately using the FAST/Simulink interface of version 8.12/8.15.
The first one concerns the so-called Checkpoint-Restart capability which was added in FASTv8.12. As background information: I am using this feature to perform distinct Checkpoint restarts (let’s say every 10 milli-secs) since the Checkpoint restart is up to now the only way to initialize FAST/Simulink with all its internal states accurately. My implementation worked good so far with FASTv8.12 if the simulation time remains small.
Though, the problem with this feature “Chkpoint-Restart” is in general that on every restart from a Checkpoint file the “Matlab used memory” rises by approx. 5 MB. Unfortunately, the allocated memory by the Rountines “FAST_Restart()” or “FAST_CreateCheckpoint()” is NOT set free after restart.
Thus, it accumulates and Matlab breaks eventually down due to “Out of Memory” error (in my case after ~1000 iterations equival. to additional 5GB memory usage). Since the memory is allocated by the Fortran FAST_Restart() Routine and not by the Simulink sfunction directly, I haven’t found a suitable way to resolve this issue yet.
I think, there is an awareness for this problem since in the README_FAST8.pdf it says:
“Before FAST creates a checkpoint file, it doubles the amount of memory in use in the simulation because all of the data is packed into three arrays that are then written to a file. Thus, it is likely that 32-bit simulations will not be able to create checkpoint files”.
Has someone else encountered this effect before and might know a solution to it?
The second issue:
Apart from problem 1, I migrated my simulation environment from 8.12 to 8.15. After updating the FAST-Inputfiles and copying the new FAST-code (FAST_Library_x64.dll, FAST_Library_x64.lib and MAP_x64.dll) the simulation worked perfectly. But only as long as I do not request a FAST_Restart() explicitly. If the latter routine is called now (with FASTv8.15), Matlab breaks also down when trying to execute FAST_Restart() from the simulink sfunction.
Since exactly the same code worked - in general - perfectly with FASTv8.12 and I only changed the above mentioned Inputfiles and FAST source code, I do assume that the problem lies within the fortran code.
What has changed in the new version of FAST compared to the one from last October with respect to the restart-capability?
Kindest Regards from Germany,