Skip to content

Commit

Permalink
typo
Browse files Browse the repository at this point in the history
  • Loading branch information
nikhar-abbas committed Dec 4, 2020
1 parent 92d6410 commit 3afe143
Showing 1 changed file with 4 additions and 4 deletions.
8 changes: 4 additions & 4 deletions ROSCO_toolbox/controller.py
Original file line number Diff line number Diff line change
Expand Up @@ -160,7 +160,7 @@ def tune_controller(self, turbine):

# separate wind speeds by operation regions
v_below_rated = np.linspace(turbine.v_min,turbine.v_rated, num=30) # below rated
v_above_rated = np.linspace(turbine.v_rated,turbine.v_max, num=30)[1:-1] # above rated
v_above_rated = np.linspace(turbine.v_rated,turbine.v_max, num=30)[1:] # above rated
v = np.concatenate((v_below_rated, v_above_rated))

# separate TSRs by operations regions
Expand Down Expand Up @@ -274,7 +274,7 @@ def tune_controller(self, turbine):
self.v = v # Wind speed (m/s)
self.v_below_rated = v_below_rated
self.pitch_op = pitch_op
self.pitch_op_pc = pitch_op[len(v_below_rated):len(v)]
self.pitch_op_pc = pitch_op[len(v_below_rated):]
self.TSR_op = TSR_op
self.A = A
self.B_beta = B_beta
Expand Down Expand Up @@ -495,9 +495,9 @@ def peak_shaving(self,controller, turbine):
def min_pitch_saturation(self, controller, turbine):

# Find TSR associated with minimum rotor speed
TSR_at_minspeed = (controller.pc_minspd/turbine.Ng) * turbine.rotor_radius / controller.v_below_rated
TSR_at_minspeed = (controller.vs_minspd/turbine.Ng) * turbine.rotor_radius / controller.v_below_rated
for i in range(len(TSR_at_minspeed)):
if TSR_at_minspeed[i] > controller.TSR_op[i]:
if TSR_at_minspeed[i] > turbine.Cp.TSR_opt:
controller.TSR_op[i] = TSR_at_minspeed[i]

# Initialize some arrays
Expand Down

0 comments on commit 3afe143

Please sign in to comment.