OpenFAST / openfast

Main repository for the NREL-supported OpenFAST whole-turbine and FAST.Farm wind farm simulation codes.
http://openfast.readthedocs.io
Apache License 2.0
655 stars 447 forks source link

hydrodyn with matlab/simulink #2259

Open HANloading opened 1 month ago

HANloading commented 1 month ago

Dear All: I want to call hydrodyn module in matlab/simulink now, but I didn't find any case or description about it, does anyone know the steps about calling this module, and what are the difficulties to call this module in matlab/simulink? Or what is the difficulty compared to python?

jjonkman commented 1 month ago

Dear @HANloading,

Can you clarify what you are trying to do? Are you referring to the standalone driver of HydroDyn or HydroDyn coupled within OpenFAST? What feature of HydroDyn do you want to control via MATLAB/Simulink/?

Best regards,

HANloading commented 1 month ago

Dear @jjonkman What I mean is that I want to reference the dll hydrodyn in matlab/simulink and apply it to my own simulink model, and I want to use the dll hydro dyn to compute the load on the platform of my model in each time step based on the running state of my model platform. What I want to know is is this achievable, or what is the difficulty? Best regards,

jjonkman commented 1 month ago

Dear @HANloading,

It sounds like you want to couple HydroDyn to your own structural solver implemented in MATLAB/Simulink, including rigid-body motion and/or hydro-elasticity. I'm sure such a coupling would be possible, but it would require source code development.

One challenge you'll likely run into is the numerical stability of the coupling. The HydroDyn loads are dependent on structural motion (displacements, velocities, and accelerations), with the hydrodynamic added mass loads dependent on acceleration. Given that the structural acceleration will directly depend on this hydrodynamic load, the coupling between HydroDyn and the structural code is implicit. This implicit coupling is solved directly in the OpenFAST glue code and would have to be solved in the interface you'd have to develop as well.

Best regards,

HANloading commented 1 month ago

Dear @jjonkman Thank you for your answer, the answers I got from your reply are:

  1. i need to redo the source code development, only then i can achieve the implicit coupling between my own model and hydrodyn, this thing sounds quite challenging. Secondly, I would like to know the difference between coupling hydrodyn to the model in python and coupling it in sinmulink? Also, what exactly does implicit coupling represent? Best ragards,
jjonkman commented 1 month ago

Daer @HANloading,

Regarding implicit coupling, similar questions have been discussed in the following OpenFAST issues: https://github.com/OpenFAST/openfast/issues/282 https://github.com/OpenFAST/openfast/issues/893 https://github.com/OpenFAST/openfast/issues/943

We have drafted a publication that explains the original loose coupling algorithm currently used by OpenFAST (including support for implicit coupling), as well as the new tight coupling algorithm being developed within OpenFAST. This publication provides the mathematical details of the coupling approach, but will be submitted later this summer.

Implicit coupling will have to be used whether you couple HydroDyn to MATLAB/Simulink or Python. Python may be easier though, because a python wrapper around HydroDyn has already been developed.

See the following OpenFAST issue for a related discussion on HydroDyn wrappers for MATLAB/Simulink: https://github.com/OpenFAST/openfast/issues/1013.

Best regards,