Skip to content

Commit

Permalink
Adding freedecay dlc
Browse files Browse the repository at this point in the history
  • Loading branch information
abhineet-gupta committed Jan 14, 2025
1 parent c2559f8 commit 4113183
Show file tree
Hide file tree
Showing 2 changed files with 38 additions and 2 deletions.
36 changes: 36 additions & 0 deletions weis/dlc_driver/dlc_generator.py
Original file line number Diff line number Diff line change
Expand Up @@ -30,6 +30,13 @@
'pitch_initial': [("ElastoDyn","BlPitch1"),("ElastoDyn","BlPitch2"),("ElastoDyn","BlPitch3")],
'azimuth_init': ("ElastoDyn","Azimuth"),
'yaw_misalign': ("ElastoDyn","NacYaw"),

'PtfmSurge': ("ElastoDyn","PtfmSurge"),
'PtfmSway': ("ElastoDyn","PtfmSway"),
'PtfmHeave': ("ElastoDyn","PtfmHeave"),
'PtfmRoll': ("ElastoDyn","PtfmRoll"),
'PtfmPitch': ("ElastoDyn","PtfmPitch"),
'PtfmYaw': ("ElastoDyn","PtfmYaw"),

'wave_height': ("HydroDyn","WaveHs"),
'wave_period': ("HydroDyn","WaveTp"),
Expand Down Expand Up @@ -1239,6 +1246,35 @@ def generate_7p2(self, dlc_options):
# This function does the rest and generates the individual cases for each DLC
self.generate_cases(generic_case_inputs,dlc_options)

def generate_freedecay(self,dlc_options):
# Describe the new design load case

# Get default options
dlc_options.update(self.default_options)

# Set DLC Specific options:
# These three are required
dlc_options['label'] = 'freedecay'
dlc_options['sea_state'] = 'normal'
dlc_options['IEC_WindType'] = 'NTM'

# Set dlc-specific options, like yaw_misalign, initial azimuth
if 'yaw_misalign' in dlc_options:
dlc_options['yaw_misalign'] = dlc_options['yaw_misalign']
else: # default
dlc_options['yaw_misalign'] = [0]

# DLC-specific: define groups
# Groups are dependent variables, the cases are a cross product of the independent groups
# The options in each group should have the same length
generic_case_inputs = []
generic_case_inputs.append(['total_time','transient_time','wake_mod','wave_model','PtfmRoll','PtfmPitch','PtfmYaw']) # group 0, (usually constants) turbine variables, DT, aero_modeling
generic_case_inputs.append(['wind_speed','wave_height','wave_period', 'wind_seed', 'wave_seed']) # group 1, initial conditions will be added here, define some method that maps wind speed to ICs and add those variables to this group
generic_case_inputs.append(['yaw_misalign']) # group 2

# This function does the rest and generates the individual cases for each DLC
self.generate_cases(generic_case_inputs,dlc_options)

def generate_new_dlc(self,dlc_options):
# Describe the new design load case

Expand Down
4 changes: 2 additions & 2 deletions weis/inputs/modeling_schema.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -3053,7 +3053,7 @@ properties:
DLC:
type: string
default: '1.1'
enum: ['1.1', '1.2', '1.3', '1.4', '1.5', '1.6', '2.1', '2.3', '3.1', '3.2', '3.3', '5.1', '6.1', '6.2', '6.3', '6.4', '6.5', '7.1', '7.2', '12.1', 'Custom','AEP']
enum: ['1.1', '1.2', '1.3', '1.4', '1.5', '1.6', '2.1', '2.3', '3.1', '3.2', '3.3', '5.1', '6.1', '6.2', '6.3', '6.4', '6.5', '7.1', '7.2', '12.1', 'Custom','AEP','freedecay']
description: IEC design load case to run. The DLCs currently supported are 1.1, 1.2, 1.3, 1.4, 1.5, 1.6, 5.1, 6.1, 6.3, and 6.4
wind_speed:
type: array
Expand Down Expand Up @@ -3186,7 +3186,7 @@ properties:
IEC_WindType:
type: string
default: NTM
enum: ['NTM', '1ETM', '2ETM', '3ETM', '1EWM1', '2EWM1', '3EWM1', '1EWM50', '2EWM50', '3EWM50', 'ECD', 'EDC', 'EOG','EWS']
enum: ['NTM', '1ETM', '2ETM', '3ETM', '1EWM1', '2EWM1', '3EWM1', '1EWM50', '2EWM50', '3EWM50', 'ECD', 'EDC', 'EOG','EWS','Custom']
description: IEC turbulence type ('NTM'=normal, 'xETM'=extreme turbulence, 'xEWM1'=extreme 1-year wind, 'xEWM50'=extreme 50-year wind, where x=wind turbine class 1, 2, or 3), 'ECD'=extreme coherent gust with direction change, 'EDC'=extreme direction change, 'EOG'=extreme operating gust. Normally the user does not need to define this entry, 'EWS'='extreme wind shear'
analysis_time:
type: number
Expand Down

0 comments on commit 4113183

Please sign in to comment.