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
680 stars 456 forks source link

Issues with Servodyn with VsContrl = 1 #481

Closed tchatte3 closed 4 years ago

tchatte3 commented 4 years ago

Hi openFAST team,

I am currently working on our custom DLL file for pitch and generator control through the Servodyn module. Initially, I was using VsContrl = 5, but it led to some failures in our dll and I switched to a simpler version of the variable speed generator torque model, using VsContrl = 1. I am switching on GenDoF, DrTrDoF = True. However, I see the following error:

FAST_Solution:CalcOutputs_And_SolveForInputs:SolveOption2:SrvD_CalcOutput:CalculateTorque:u%HSS_Sp d is negative. Simple variable-speed control model is not valid for motoring situations. Any suggestions/guidelines on how to overcome this?

Best Regards,

jjonkman commented 4 years ago

Hi @tchatte3,

Yes, it is true that the simple variable-speed controller (VSContrl = 1) does not support motoring situations, where the generator speed is negative. But I'm not sure what you've set up in your model that results in negative generator speeds.

Best regards,

tchatte3 commented 4 years ago

@jjonkman Thank you for the quick reply. Currently, in Elastodyn I have everything set to rigid (all DoF's = False), except, out of plane tip deflection and genDOF and DrTrDoF (both are set to True).

For servodyn, the necessary section for VsContrl = 1, is as follows:

---------------------- SIMPLE VARIABLE-SPEED TORQUE CONTROL -------------------- 7.813 VS_RtGnSp - Rated generator speed for simple variable-speed generator control (HSS side) (rpm) [used only when VSContrl=1] 1.0599e+07 VS_RtTq - Rated generator torque/constant generator torque in Region 3 for simple variable-speed generator control (HSS side) (N-m) [used only when VSContrl=1] 8.0704e+04 VS_Rgn2K - Generator torque constant in Region 2 for simple variable-speed generator control (HSS side) (N-m/rpm^2) [used only when VSContrl=1]

10 VS_SlPc - Rated generator slip percentage in Region 2 1/2 for simple variable-speed generator control (%) [used only when VSContrl=1]

I am operating with a rotor speed of 4.5 rpm. Might be VsRtTq are set up incorrectly?

jjonkman commented 4 years ago

Dear @tchatte3,

Does your OpenFAST model have a gearbox (GBRatio > 1.0 in ElastoDyn)? In this case, the simple variable-speed torque control inputs should be referenced to the high-speed shaft (generator side of the gearbox), not the low-speed shaft (rotor side of the gearbox), i.e., the speeds should be GBRatio times larger and the torques should be GBRatio time smaller.

tchatte3 commented 4 years ago

@jjonkman Thanks. I set the GBRatio = 1.0 in Elastodyn model.

jjonkman commented 4 years ago

@tchatte3 -- What is happening in the simulation (wind, generator speed, blade-pitch, deflections) before the negative generator speed is reached?

tchatte3 commented 4 years ago

@jjonkman , unfortunately, its failing pretty fast in a couple of time steps: Still this is what I could get for the first transient behaviour.

image

image image

jjonkman commented 4 years ago

@tchatte3 -- I don't see the generator speed going negative in these plots, but perhaps that happens before the results are output at the next time step?

Have you set initial conditions appropriate for you model (i.e., the initial rotor speed and blade-pitch set to their expected value for the wind speed simulated)?

Is your time step set appropriately for numerical convergence?

I would suggest simplifying the model further to debug, e.g., start by disabling everything but the generator DOF; does the model run as expected then? Which feature when enabled triggers the error?

Best regards,

tchatte3 commented 4 years ago

@jjonkman , thank you for these helpful inputs. Yes, I am pretty sure the initial conditions of the turbine are as par the operating conditions (wind speed, blade pitch angle and the initial rpm), so I would start debugging by disabling everthing but generator DOF. I will see if that helps me identify the problem I have. I have good starting point now.

rafmudaf commented 4 years ago

@tchatte3 is this resolved?

tchatte3 commented 4 years ago

@rafmudaf , @jjonkman Yes this question is resolved now.

-Tanmoy

Junruzhang627 commented 1 year ago

Hi @tchatte3,

Yes, it is true that the simple variable-speed controller (VSContrl = 1) does not support motoring situations, where the generator speed is negative. But I'm not sure what you've set up in your model that results in negative generator speeds.

Best regards,

Hi @jjonkman, I have a problem when I use "VSContrl=1". If I set "VSContrl=1", AeroPwr does not equal GenPwr(GenTrq*u%HSS_Spd). I have turned off mechnical loss or geneff loss. And the difference between AeroPwr and GenPwr is nearly 40%, which means the loss is nearly 40%. I don't know what happened. AeroPwr should always be near to or equal GenPwr?

jjonkman commented 1 year ago

Dear @Junruzhang627,

I would expect that the aerodynamic power would equal the generator power (when there are no mechanical or electrical losses) when the generator degree of freedom is enabled and when the system is in steady state, but I would not expect the aerodynamic power to equal the generator power on a time-step-by-time-step basis under transient conditions.

Best regards,

Junruzhang627 commented 1 year ago

Thank @jjonkman very much for confiming that for me. I will review my model carefully to see what happened.