Integrating HydroDyn with Multibody Dynamics Model in Simulink for Two-Way Data Interchang

Hello everyone,

I am currently working on a multibody dynamics model in Simulink (specifically using Simscape) and am looking to integrate HydroDyn for conducting hydrodynamics calculations. My goal is to establish a two-way data interchange between HydroDyn and my Simscape model. I would appreciate any detailed hints or guidance on how to achieve this.

So far, I’ve explored using the FAST_SFunc in Simulink, but it seems primarily focused on controller data interchange, and I’m unsure how to adapt it for hydrodynamics data exchange. Specifically, I’m looking to exchange the floating platform’s motion and the Simscape model’s motion between the two systems.

I am currently using Matlab_R2023b, OpenFAST version 3.5.2, and running on MacOS 14.2.1 with an M-series chip

Thank you in advance for your assistance.

Warm regards,
Chaozhi Qiu

Dear @Chaozhi.Qium,

If you were to modify the existing OpenFAST S-Function to support hydro-elastic coupling rather than turbine-control coupling, the challenge I suspect you’ll run into is that this S-Function is set up as a discrete-time block. That is, Simulink sends inputs to the S-Function at time step “n” and the S-Function (OpenFAST) will time-integrate and return outputs back to Simulink at time step “n+1”. If this S-Function were to be sent motions (displacement, velocity, acceleration) as input and return loads (force, moment, including added mass) as output, I would expect the hydro-elastic coupling to be numerically unstable because of the one time-step delay in the acceleration-added mass coupling. We get around this issue within the OpenFAST glue code when coupling HydroDyn with ElastoDyn/SubDyn by rigorously solving inputs and outputs together within a time step to ensure that the accelerations are consistent with the added mass loads. I’m not fully sure how this implicit coupling could be achieved within Simulink and S-Functions (it could be possible, I’m just not aware). Perhaps someone else on this forum can comment or you could search the MATLAB/Simulink documentation or reach out to MathWorks technical support.

Best regards,

Dear @Jason.Jonkman,

Thank you very much for the reply.
The remainder of the numerically unstable is very crucial. Can you please explain the “implicit coupling” a little bit more in this coupling task?
Besides, I am thinking of compiling HydroDy as a dynamics link library and using S-Function to manage the data interchange and sync, but I am not sure if this approach is valid or not.

Thank you again for the kind reply.

Dear @Chaozhi.Qiu,

The topic of implicit coupling used by OpenFAST has been discussed before, e.g., in the following issue on the OpenFAST GitHub site: Loads and response transferring in OpenFAST · Issue #282 · OpenFAST/openfast · GitHub. We are currently working on a paper to be submitted to the Wind Energy Science journal that explains the existing implicit loose coupling approach we’ve implemented within OpenFAST, as well as the new tight coupling approach we are finalizing now. We anticipate submitting this paper for to WES in April.

How these couplings could be supported within MATLAB / Simulink is likely a better question for MathWorks technical support.

Best regards,

Dear @Jason.Jonkman ,

Thank you very much.

Best regards,
Chaozhi QIu

Dear Jonkman, You mentioned that you might publish a paper in Wind Energy Science journal explaining the existing implicit loose coupling approach you’ve implemented within OpenFAST. Can you send me the tittle of this paper? I can not find related paper in WES.

Dear @RenQiang.Xi,

While we have drafted this paper, we are awaiting the final results from our tight coupling implementation before we submit it to the journal–hopefully that is within the next month.

Best regards,

Dear Jonkman,
This is great news, and I am looking forward to reading your paper. Besides this paper, are there any reports or materials that provide a detailed introduction to existing implicit loosely coupled methods, particularly regarding Input-Output Solve Option 1?

Dear @RenQiang.Xi,

The following implementation plan available in the OpenFAST documentation explains the difference between option 1 and option 2 solves in the existing implicit loose coupling scheme used by the OpenFAST glue code: https://openfast.readthedocs.io/en/main/_downloads/10fd11ae468eb09b7b8affb36a9ac603/ProposedPCApproach_Rev4.docx. This algorithm, along with the new tight coupling scheme, will be further explained in the upcoming WES paper.

Best regards,