Skip to content

Commit

Permalink
Read damping from beamdyn input files (#349)
Browse files Browse the repository at this point in the history
* Set types on wrap functions

* Update IEA-15 inputs

* Update installation instructions -- draft

* Change to new AF Coords

* Fix IEA15 airfoils again

* Try latest setup_fortran action

* Add UAStart/End location writing

* Try intel-classic compiler

* Add developer docs about api changes

* Try macos-latest in CI

* Add support for reading daming from beamdyn blade files (#328)

---------

Co-authored-by: dzalkind <dzalkind@nrel.gov>
Co-authored-by: dzalkind <65573423+dzalkind@users.noreply.github.com>
  • Loading branch information
3 people committed Jun 14, 2024
1 parent 721164e commit f52bc4b
Show file tree
Hide file tree
Showing 2 changed files with 17 additions and 5 deletions.
2 changes: 1 addition & 1 deletion Examples/Test_Cases/BAR_10/BAR_10.fst
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@ True Echo - Echo input data to <RootName>.ech (flag)
99999.0 DT_UJac - Time between calls to get Jacobians (s)
1000000.0 UJacSclFact - Scaling factor used in Jacobians (-)
---------------------- FEATURE SWITCHES AND FLAGS ------------------------------
1 CompElast - Compute structural dynamics (switch) {1=ElastoDyn; 2=ElastoDyn + BeamDyn for blades}
2 CompElast - Compute structural dynamics (switch) {1=ElastoDyn; 2=ElastoDyn + BeamDyn for blades}
1 CompInflow - Compute inflow wind velocities (switch) {0=still air; 1=InflowWind; 2=external from OpenFOAM}
2 CompAero - Compute aerodynamic loads (switch) {0=None; 1=AeroDyn v14; 2=AeroDyn v15}
1 CompServo - Compute control and electrical-drive dynamics (switch) {0=None; 1=ServoDyn}
Expand Down
20 changes: 16 additions & 4 deletions rosco/toolbox/turbine.py
Original file line number Diff line number Diff line change
Expand Up @@ -171,10 +171,18 @@ def load_from_fast(

# file
ed_file = os.path.join(fast.FAST_directory, fast.fst_vt['Fst']['EDFile'])

fast.read_ElastoDyn(ed_file)
ed_blade_file = os.path.join(os.path.dirname(ed_file), fast.fst_vt['ElastoDyn']['BldFile1'])
fast.read_ElastoDynBlade(ed_blade_file)

if fast.fst_vt['Fst']['CompElast'] ==1:
fast.read_ElastoDynBlade(ed_blade_file)
elif fast.fst_vt['Fst']['CompElast'] ==2:
bd_file = os.path.join(fast.FAST_directory, fast.fst_vt['Fst']['BDBldFile(1)'])
fast.read_BeamDyn(bd_file)
bd_blade_file = os.path.join(os.path.dirname(bd_file), fast.fst_vt['BeamDyn']['BldFile'])
fast.read_BeamDynBlade(bd_blade_file)
else:
Warning('No ElastoDyn or BeamDyn files were provided')

fast.read_AeroDyn15()

Expand Down Expand Up @@ -588,8 +596,12 @@ def load_blade_info(self):
self.span = r
self.chord = chord
self.twist = theta
self.bld_flapwise_damp = self.fast.fst_vt['ElastoDynBlade']['BldFlDmp1']/100


if self.fast.fst_vt['Fst']['CompElast'] ==1:
self.bld_flapwise_damp = self.fast.fst_vt['ElastoDynBlade']['BldFlDmp1']/100
elif self.fast.fst_vt['Fst']['CompElast'] ==2:
self.bld_flapwise_damp = self.fast.fst_vt['BeamDynBlade']['mu5']

class RotorPerformance():
'''
Class RotorPerformance used to find details from rotor performance
Expand Down

0 comments on commit f52bc4b

Please sign in to comment.