Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Wave Excitation model generation in state-space (*.ssexctn input file) #397

Closed
jonmtz opened this issue Feb 25, 2020 · 36 comments
Closed

Wave Excitation model generation in state-space (*.ssexctn input file) #397

jonmtz opened this issue Feb 25, 2020 · 36 comments

Comments

@jonmtz
Copy link

jonmtz commented Feb 25, 2020

Hi,

I am using a platform for which I have the .hst, .1 and .3 files.
My aim is to perform a full-system linearization using #350. As I have seen, for being able to perform the linearization in the HydroDyn Submodule, it is necessary to set both ExctnMod and RdtnMod to 2 (state-space model).

For the Radiation memory-effect model (RdtnMod), I have been able to create the .ss file using the SS_Fitting MATLAB Toolbox (https://nwtc.nrel.gov/SS_Fitting), but I was not able to find any toolbox for creating the *.ssexctn input file.

Between r-tests, I see that the marin_semi.ssexctn was created using SS_Excitation_Fitting v1.00.01, but I did not find this toolbox on the net.

Does anyone know how could I get that toolbox, or create the *.ssexctn file in another way?

Thanks in advance,

Jon

@jonmtz jonmtz changed the title Wave Excitation model generation in State-space (*.ssexctn input file) Wave Excitation model generation in state-space (*.ssexctn input file) Feb 25, 2020
@andrew-platt
Copy link
Collaborator

@ghaymanNREL do you have any comments?

@jjonkman
Copy link
Collaborator

Alan Wright of NREL has developed a MATLAB-based preprocessor called SS_Excitation_Fitting--similar to SS_Fitting for fitting state-space wave-radiation models, but for fitting the state-space wave-excitation models. SS_Excitation_Fitting is not yet ready for general release, but I've asked Alan Wright to respond here as to the status.

@jonmtz
Copy link
Author

jonmtz commented Feb 26, 2020

Alright, thank you @andrew-platt and @jjonkman. I will wait for Alan Wright's answer.

On the other hand, @ghaymanNREL, is there any other way to perform linearization of the HydroDyn submodule using a platform without the state-space wave-excitation model?

Thank you and best regards,

Jon

@jjonkman
Copy link
Collaborator

@jonmtz,

If you don't have a linearized state-space representation of the wave-excitation loads, you can always disable wave excitation loads during the linearization process (ExctnMod = 0), but then the impact of perturbations in wave elevation will not be included in the linearized system (i.e., there will be no B and D matrices associated with a du for perturbations in wave elevation).

Best regards,

@jonmtz
Copy link
Author

jonmtz commented Feb 26, 2020

Dear @jjonkman,

I already tried that, but I got the following error when trying to do so.

Error_linOC4

That is why in my first message I said that as I have seen, both ExctnMod and RdtnMod must be 2. Nevertheless, it may happen that the error is due to another cause.

Any ideas?

Thank you in advance,

Jon

@jjonkman
Copy link
Collaborator

Well, it is hard for me to guess what is causing this problem...and whether it is a problem with your simulation set up or a bug in the source code. Do you run into the same segmentation fault when you linearize while setting ExctnMod = RdtnMod = 0 with one of the sample models NREL has provided? I would suggest compiling and running in debug mode to more precisely isolate the problem.

@alandwright
Copy link

Hi @jonmtz,

We don't have a formal release of the SS_Excitation_Fitting which is why you haven't found it on the github repository. I can work with you one-on-one to send the alpha version to you and help you through it to generate the *.ssexctn files you need for a complete linearization. Please email me at Alan.Wright@nrel.gov. Thanks.

@jonmtz
Copy link
Author

jonmtz commented Mar 2, 2020

Thank you both @jjonkman and @alandwright for your answers.

@jjonkman I tried with the NREL model and had that problem, but as you suggest I will try compiling in debug mode to get more information.
@alandwright, I will contact you at your email, thank you for your help.

Best regards,

Jon

@ramisetti
Copy link

ramisetti commented Nov 17, 2020

I tried to run linearisation test setting ExctnMod = RdtnMod = 0 for IEA 15MW semisubermisble case but openfast fails with segmentation fault. I repeated this with 5MW OC4 semisubmersible case available within the NREL test cases and I found it fails with similar problem. I used both OpenFast v2.4.0 to run the above two test cases.

As suggested by @jjonkman (https://wind.nrel.gov/forum/wind/viewtopic.php?f=4&t=2516&p=15915#p15915), I tried to repeat the linearisation run for the 5MW OC4 Semi case ( ExctnMod = RdtnMod = 0) with the code from pull request 537 but openfast aborted with an error (see below) during the initialisation. I am not aware of the changes that needs to be made to the HydroDyn.dat file in order to make it run with the pull 537 version. Is there any example HydroDyn.dat file compatible with pull 537 code?


FAST_InitializeAll:HydroDyn_Init:HydroDynInput_GetInput:Invalid numerical input for file
"./NRELOffshrBsline5MW_OC4DeepCwindSemi_HydroDyn.dat" occurred while trying to read ExctnMod.

FAST encountered an error during module initialization.
Simulation error level: FATAL ERROR

Can you please let me know if there is any fix to this problem?

@jjonkman
Copy link
Collaborator

Dear @ramisetti,

Please find attached a sample HydroDyn input file that is compatible with the HydroDyn changes in pull request #537.

NRELOffshrBsline5MW_OC4DeepCwindSemi_HydroDyn_New4.txt

Does upgrading from OpenFAST v2.4 to this branch of OpenFAST resolve the segmentation fault you are reporting?

Best regards,

@ramisetti
Copy link

Dear @jjonkman,

Thanks for sharing the sample HydroDyn input file. I tried to use it with the 5MW OC4 semi case but I still get initialisation error (see below).
I think I don't have any answer yet to your question about the segmentation fault with the pull 537 version until I succeed running openfast with the appropriate HydroDyn.dat file.


FAST_InitializeAll:HydroDyn_Init:HydroDynInput_GetInput:ReadOutputList: Did not find the required
number of Potfile strings on the input file line: only found 1.

FAST encountered an error during module initialization.
Simulation error level: FATAL ERROR

@jjonkman
Copy link
Collaborator

Dear @ramisetti,

This error sounds like you've specified 3 potential-flow bodies (NBody = 3), but only specified properties of one of them. You should set NBody = 1 if you only want one potential-flow body.

Best regards,

@ramisetti
Copy link

ramisetti commented Nov 18, 2020

Dear @jjonkman,

I have used the sample HydroDyn.dat file that you shared without making any major changes to run linearisation for the 5MW OC4 Semisubmersible case. As you suggested, I changed NBody to 1 but openfast is still aborting due to some other errors. I see there are some changes in inputs to the HydroDyn.dat file between v2.4.0 and pull537 code. I also noticed the AddF0 and AddCLin matrices in the PLATFORM ADDITIONAL STIFFNESS AND DAMPING section are changed. Could you please suggest how to fix this issue?


OpenFAST

Copyright (C) 2020 National Renewable Energy Laboratory
Copyright (C) 2020 Envision Energy USA LTD

This program is licensed under Apache License Version 2.0 and comes with ABSOLUTELY NO WARRANTY.
See the "LICENSE" file distributed with this software for details.


OpenFAST-v2.4.0-421-g93269618-dirty
Compile Info:

  • Compiler: GCC version 7.1.0
  • Architecture: 64 bit
  • Precision: double
  • Date: Nov 17 2020
  • Time: 10:36:33
    Execution Info:
  • Date: 11/18/2020
  • Time: 10:40:14+0530

OpenFAST input file heading:
FAST Certification Test #25: NREL 5.0 MW Baseline Wind Turbine with OC4-DeepCwind semi
configuration, for use in offshore analysis

Running ElastoDyn.
Nodal outputs section of ElastoDyn input file not found or improperly formatted.
Running ServoDyn.
Running HydroDyn.
Setting WaveTMax to 0.0 since WaveMod = 0
WARNING: The random number generator in use differs from the original code provided by NREL.
This pRNG uses 33 seeds instead of the 2 in the input file.
Reading in WAMIT output with root name "./../5MW_Baseline/HydroData/marin_semi".
Computing radiation impulse response functions and wave diffraction forces.

MAP++ environment properties (set externally)...
Gravity constant [m/s^2] : 9.81
Sea density [kg/m^3] : 1025.00
Water depth [m] : 200.00
Vessel reference position [m] : 0.00 , 0.00 , 0.00
Time: 0 of 10 seconds.
Time: 4 of 10 seconds. Estimated final completion at 10:40:37.
FAST_Solution:FAST_AdvanceStates:ED_ABM4:ED_CalcContStateDeriv:SetCoordSy:Small angle assumption
violated in SUBROUTINE SmllRotTrans() due to a large platform displacement (ElastoDyn
SetCoordSy). The solution may be inaccurate. Simulation continuing, but future warnings from
SmllRotTrans() will be suppressed.
Additional debugging message from SUBROUTINE SmllRotTrans(): 4.4625 s
FAST_Solution:CalcOutputs_And_SolveForInputs:SolveOption1:ED_HD_InputOutputSolve:HydroDyn_CalcOutp
ut: Angles in GetSmllRotAngs() are larger than 0.4 radians.
HydroDyn_CalcOutput: Angles in GetSmllRotAngs() are larger than 0.4 radians.
ED_HD_InputOutputSolve:HydroDyn_CalcOutput: Angles in GetSmllRotAngs() are larger than 0.4
radians.
HydroDyn_CalcOutput: Angles in GetSmllRotAngs() are larger than 0.4 radians.

FAST_Solution:CalcOutputs_And_SolveForInputs:SolveOption1:ED_HD_InputOutputSolve:HydroDyn_CalcOutp
ut: Angles in GetSmllRotAngs() are larger than 0.4 radians.
HydroDyn_CalcOutput: Angles in GetSmllRotAngs() are larger than 0.4 radians.
ED_HD_InputOutputSolve:HydroDyn_CalcOutput: Angles in GetSmllRotAngs() are larger than 0.4
radians.
HydroDyn_CalcOutput: Angles in GetSmllRotAngs() are larger than 0.4 radians.

FAST_Solution:FAST_AdvanceStates:ED_ABM4:ED_CalcContStateDeriv:LAPACK_DGETRF: U( 13,
13)=0. Factor U is exactly singular.

FAST encountered an error at simulation time 6.9125 of 10 seconds.
Simulation error level: FATAL ERROR

Aborting OpenFAST

Regards,

@jjonkman
Copy link
Collaborator

Dear @ramisetti,

Well, at least you got past the model initialization errors. It looks like your model has gone numerically unstable, likely due to something improperly set in the updated HydroDyn file. Have you transferred all of the inputs from the original OC5 semi linearization test (https://github.com/OpenFAST/r-test/blob/master/glue-codes/openfast/5MW_OC4Semi_Linear/NRELOffshrBsline5MW_OC4DeepCwindSemi_HydroDyn.dat) to the new file format?

Regardless, my understanding is the only reason you are using this branch of OpenFAST is to see if the model seg faults when running a linearization with ExctnMod = RdtnMod = 0. You could try that now by linearizing right away at time zero (LinTimes = 0).

Best regards,

@ramisetti
Copy link

Dear @jjonkman,

Yes, indeed I got past the model initialisation errors. I did try to transfer all the inputs from the original OC4 semisubmersible case except the AddF0 and AddCLin matrices because of the difference between two formats. The size of AddF0 and AddCLin is different and it's not very clear how to adapt the new format with the values from the original case. could you please explain why this difference between the original case and new hydrodynamics file?

@jjonkman
Copy link
Collaborator

Dear @ramisetti,

NBody is the number of potential-flow bodies (historically this was always one; in the new branch, HydroDyn supports more than one body). The additional preload, stiffness, and damping are now just dimensioned by the number of bodies. When doing this, we also transposed how AddF0 is entered. Before it was 1 x 6, now it is 6 x NBody. See the comments after the variable names.

Best regards,

@ramisetti
Copy link

Thank you @jjonkman for your help. I am now able to run the linearisation with ExctnMod = RdtnMod = 0 for the IEA 15MW semisubmersible case using the pull 537 code.

Just a comment related to representation of the vectors/matrices used in PLATFORM ADDITIONAL STIFFNESS AND DAMPING section. In my opinion, I think the new representation of AddF0 and other Matrices is not really user-friendly. Instead, I prefer to use the vectors/matrices for NBody in new rows as this will also work with previous openfast versions and it is easy to prepare the HydroDyn.dat file. Hope this is clear.

@jjonkman
Copy link
Collaborator

Dear @ramisetti,

When extending the platform additional stiffness and damping to work with NBody and NBodyMod, we had to change the dimensions of the matrices and vectors. In this process, we thought it was confusing that AddF0 was input transposed in prior versions of HydroDyn, unlike the other matrices. We corrected this in the updated version of HydroDyn.

Best regards,

@mftatfcyclone
Copy link

Hi @jonmtz,

We don't have a formal release of the SS_Excitation_Fitting which is why you haven't found it on the github repository. I can work with you one-on-one to send the alpha version to you and help you through it to generate the *.ssexctn files you need for a complete linearization. Please email me at Alan.Wright@nrel.gov. Thanks.

Dear @alandwright
I need to generate the ssexctn file. Could you help me to generate it for NREL 5MW?

@jjonkman
Copy link
Collaborator

Dear @mftatfcyclone,

For which floating platform do you want the *.ssexctn file for?

Best regards,

@mftatfcyclone
Copy link

Dear @jjonkman
Thanks for your prompt response
I need it for spar platform

@jjonkman
Copy link
Collaborator

Dear @mftatfcyclone,

Alan Wright just sent me the attached *.ssexctn file for the OC3-Hywind spar that supports the NREL 5-MW baseline wind turbine. I added a .txt file extension to attach it (rename it to spar.ssexxctn for use with OpenFAST).

spar.ssexctn.txt

I hope that helps.

Best regards,

@mftatfcyclone
Copy link

Dear @jjonkman

Thank you very much for your considerations.
But I have a question, Is this state space valid for all wave conditions (operating points) of the spar platform of the 5MW wind turbine?

Best regards,

@jjonkman
Copy link
Collaborator

Dear @mftatfcyclone,

This model should be valid for any sea state (wave height, period) with zero-degree wave heading; it is not valid for other wave propagation directions.

Best regards,

@Ian-Ammerman
Copy link

Alan Wright of NREL has developed a MATLAB-based preprocessor called SS_Excitation_Fitting--similar to SS_Fitting for fitting state-space wave-radiation models, but for fitting the state-space wave-excitation models. SS_Excitation_Fitting is not yet ready for general release, but I've asked Alan Wright to respond here as to the status.

Dear @alandwright ,

Was this pre-processor developed further? Would you be willing to make it available?

Best,
Ian

@jjonkman
Copy link
Collaborator

jjonkman commented Jun 2, 2023

Dear @Ian-Ammerman,

See also the discussion on SS_Excitation_Fitting here: #1053. If you provide your e-mail address, I can send you the alpha release of SS_Excitation_Fitting via WeTransfer.

Best regards,

@Ian-Ammerman
Copy link

Dear @Ian-Ammerman,

See also the discussion on SS_Excitation_Fitting here: #1053. If you provide your e-mail address, I can send you the alpha release of SS_Excitation_Fitting via WeTransfer.

Best regards,

Dear @jjonkman ,

My email is: ian.ammerman@maine.edu

Best,
Ian

@jjonkman
Copy link
Collaborator

jjonkman commented Jun 2, 2023

Dear @Ian-Ammerman,

I've sent you the alpha release of SS_Excitation_Fitting via WeTransfer.

Best regards,

@Hamedfath
Copy link

Dear @jjonkman,

Could you please send me SS_Excitation_Fitting for the OC4 semisubmersible platform that supports the NREL 5-MW baseline wind turbine, and its manual for me?

My Email is: hfathnejat@bcamath.org

Best regards,
Hamed

@jjonkman
Copy link
Collaborator

Dear @Hamedfath,

I've sent you the alpha release of SS_Excitation_Fitting via WeTransfer.

Best regards,

@Hamedfath
Copy link

Hamedfath commented Mar 25, 2024 via email

@jiayaomeng
Copy link

Dear @Ian-Ammerman,

See also the discussion on SS_Excitation_Fitting here: #1053. If you provide your e-mail address, I can send you the alpha release of SS_Excitation_Fitting via WeTransfer.

Best regards,

Dear @jjonkman,

Could I please also ask for the alpha release of SS_Excitation_Fitting, so that I can compare my fitting method with it? Thank you so much! My email: jiayao.meng@wolfson.ox.ac.uk

Best wishes,
Jiayao

@jjonkman
Copy link
Collaborator

Dear @jiayaomeng,

I've sent you the alpha release of SS_Excitation_Fitting via WeTransfer.

Best regards,

@jiayaomeng
Copy link

Dear @jiayaomeng,

I've sent you the alpha release of SS_Excitation_Fitting via WeTransfer.

Best regards,

Thank you very much, @jjonkman, for always being so helpful!

@MuhammadSharjil
Copy link

hi @alandwright
I require the SS_Excitation_Fitting for wave disturbance analysis of OC3-Hywind spar-type wind turbine.
It would be a great support if I can get it.
Thanks

Regards,
Muhammad Sharjil

@jjonkman
Copy link
Collaborator

Dear @MuhammdSharjil,

I've sent you the alpha release of SS_Excitation_Fitting via WeTransfer.

Best regards,

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests