Skip to content

Commit

Permalink
Merge pull request OpenFAST#17 from ashesh2512/f/br_fsi_2
Browse files Browse the repository at this point in the history
Adding accessor functions for blade pitch and blade root deformations
  • Loading branch information
gantech authored Feb 24, 2022
2 parents 7b7d1b0 + 4391819 commit 6bdeca2
Show file tree
Hide file tree
Showing 9 changed files with 174 additions and 5 deletions.
19 changes: 18 additions & 1 deletion glue-codes/openfast-cpp/src/OpenFAST.H
Original file line number Diff line number Diff line change
Expand Up @@ -180,6 +180,10 @@ struct turbBRfsiDataType {
std::vector<double> nac_def;
//! Nacelle velocity
std::vector<double> nac_vel;
//! Blade root deformation
std::vector<double> bld_root_def;
//! Blade pitch
std::vector<double> bld_pitch;

//! Tower loads
std::vector<double> twr_ld;
Expand Down Expand Up @@ -481,7 +485,11 @@ class OpenFAST {
//! Get the blade reference positions array 'bldRefPos' of turbine number 'iTurbGlob'
void getBladeRefPositions(double* bldRefPos, int iTurbGlob, int nSize=6);
//! Get the blade deflections array 'bldDefl' of turbine number 'iTurbGlob' at time step 't'
void getBladeDisplacements(double* bldDefl, double* bldVel, int iTurbGlob, fast::timeStep t = fast::STATE_NP1, int nSize=6);
void getBladeDisplacements(double* bldDefl, double* bldVel, int iTurbGlob, fast::timeStep t = fast::STATE_NP1, int nSize=6);
//! Get the blade root deflections array 'bldRootDefl' of turbine number 'iTurbGlob' at time step 't'
void getBladeRootDisplacements(double* bldRootDefl, int iTurbGlob, fast::timeStep t = fast::STATE_NP1, int nSize=6);
//! Get the blade pitch 'bldPitch' of turbine number 'iTurbGlob'
void getBladePitch(double* bldPitch, int iTurbGlob, int nSize);
//! Get the tower reference positions array 'twrRefPos' of turbine number 'iTurbGlob'
void getTowerRefPositions(double* twrRefPos, int iTurbGlob, int nSize=6);
//! Get the tower deflections array 'twrDefl' of turbine number 'iTurbGlob' at time step 't'
Expand Down Expand Up @@ -605,6 +613,15 @@ class OpenFAST {
{
getBladeDisplacements(bldDefl.data(), bldVel.data(), iTurbGlob, t, bldDefl.size());
}
void getBladeRootDisplacements(std::vector<double> & bldRootDefl, int iTurbGlob, fast::timeStep t = fast::STATE_NP1)
{
getBladeRootDisplacements(bldRootDefl.data(), iTurbGlob, t, bldRootDefl.size());
}
inline
void getBladePitch(std::vector<double> & bldPitch, int iTurbGlob)
{
getBladePitch(bldPitch.data(), iTurbGlob, bldPitch.size());
}
inline
void getTowerRefPositions(std::vector<double> & twrRefPos, int iTurbGlob)
{
Expand Down
48 changes: 47 additions & 1 deletion glue-codes/openfast-cpp/src/OpenFAST.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -891,7 +891,12 @@ void fast::OpenFAST::set_state_from_state(fast::timeStep fromState, fast::timeSt
brFSIData[iTurb][toState].nac_ref_pos[j] = brFSIData[iTurb][fromState].nac_ref_pos[j];
brFSIData[iTurb][toState].nac_def[j] = brFSIData[iTurb][fromState].nac_def[j];
brFSIData[iTurb][toState].nac_vel[j] = brFSIData[iTurb][fromState].nac_vel[j];

}
for (int j=0; j < numBlades; j++) {
for (int k=0; k < 6; k++) {
brFSIData[iTurb][toState].bld_root_def[j] = brFSIData[iTurb][fromState].bld_root_def[j];
}
brFSIData[iTurb][toState].bld_pitch[j] = brFSIData[iTurb][fromState].bld_pitch[j];
}
}
}
Expand Down Expand Up @@ -1003,6 +1008,15 @@ void fast::OpenFAST::predict_states() {
}
}

int nTotBlades = turbineData[iTurb].numBlades;
for (int j=0; j < nTotBlades; j++) {
brFSIData[iTurb][fast::STATE_NP1].bld_pitch[j] = brFSIData[iTurb][fast::STATE_NM2].bld_pitch[j] + 3.0*(brFSIData[iTurb][fast::STATE_N].bld_pitch[j] - brFSIData[iTurb][fast::STATE_NM1].bld_pitch[j]);
extrapRotation(&brFSIData[iTurb][fast::STATE_NM2].bld_root_def[j*6+3], &brFSIData[iTurb][fast::STATE_NM1].bld_root_def[j*6+3], &brFSIData[iTurb][fast::STATE_N].bld_root_def[j*6+3], &brFSIData[iTurb][fast::STATE_NP1].bld_root_def[j*6+3]);
for (int k=0; k < 3; k++) {
brFSIData[iTurb][fast::STATE_NP1].bld_root_def[j*6+k] = brFSIData[iTurb][fast::STATE_NM2].bld_root_def[j*6+k] + 3.0*(brFSIData[iTurb][fast::STATE_N].bld_root_def[j*6+k] - brFSIData[iTurb][fast::STATE_NM1].bld_root_def[j*6+k]);
}
}

int nPtsTwr = turbineData[iTurb].nBRfsiPtsTwr;
for (int j=0; j < nPtsTwr; j++) {
extrapRotation(&brFSIData[iTurb][fast::STATE_NM2].twr_def[j*6+3],&brFSIData[iTurb][fast::STATE_NM1].twr_def[j*6+3],&brFSIData[iTurb][fast::STATE_N].twr_def[j*6+3], &brFSIData[iTurb][fast::STATE_NP1].twr_def[j*6+3]);
Expand Down Expand Up @@ -2004,6 +2018,9 @@ void fast::OpenFAST::allocateMemory_postInit(int iTurbLoc) {
brFSIData[iTurbLoc][k].nac_ref_pos.resize(6);
brFSIData[iTurbLoc][k].nac_def.resize(6);
brFSIData[iTurbLoc][k].nac_vel.resize(6);
brFSIData[iTurbLoc][k].hub_ref_pos.resize(6);
brFSIData[iTurbLoc][k].bld_pitch.resize(turbineData[iTurbLoc].numBlades);
brFSIData[iTurbLoc][k].bld_root_def.resize(6*turbineData[iTurbLoc].numBlades);
}
}

Expand Down Expand Up @@ -2268,6 +2285,11 @@ void fast::OpenFAST::get_data_from_openfast(timeStep t) {
}
iRunTot++;
}
for (int k=0; k < 3; k++) {
brFSIData[iTurb][t].bld_root_def[i*6+k] = extld_i_f_FAST[iTurb].bldRootDef[i*12+k];
brFSIData[iTurb][t].bld_root_def[i*6+3+k] = extld_i_f_FAST[iTurb].bldRootDef[i*12+6+k];
}
brFSIData[iTurb][t].bld_pitch[i] = extld_i_f_FAST[iTurb].bldPitch[i];
}

int nPtsTwr = turbineData[iTurb].nBRfsiPtsTwr;
Expand Down Expand Up @@ -2868,6 +2890,30 @@ void fast::OpenFAST::getBladeDisplacements(double* bldDefl, double* bldVel, int

}

void fast::OpenFAST::getBladeRootDisplacements(double* bldRootDefl, int iTurbGlob, fast::timeStep t, int nSize) {

int iTurbLoc = get_localTurbNo(iTurbGlob);
int nBlades = get_numBladesLoc(iTurbLoc);
assert(nSize == 6*nBlades);

int iRunTot = 0;
for (int i=0; i < nBlades; i++) {
for (int k=0; k < 6; k++) {
bldRootDefl[iRunTot] = brFSIData[iTurbLoc][t].bld_root_def[iRunTot];
iRunTot++;
}
}
}

void fast::OpenFAST::getBladePitch(double* bldPitch, int iTurbGlob, int nSize) {

assert(nSize==3);
int iTurbLoc = get_localTurbNo(iTurbGlob);
for (int j=0; j < nSize; j++)
bldPitch[j] = brFSIData[iTurbLoc][fast::STATE_NP1].bld_pitch[j] * 180/M_PI;

}

void fast::OpenFAST::getTowerRefPositions(double* twrRefPos, int iTurbGlob, int nSize) {

assert(nSize==6);
Expand Down
6 changes: 4 additions & 2 deletions modules/extloads/src/ExtLoads.f90
Original file line number Diff line number Diff line change
Expand Up @@ -461,9 +461,8 @@ subroutine Init_u( u, p, InitInp, errStat, errMsg )
call SetErrStat( ErrID_Fatal, 'Error allocating u%BladeMotion array.', ErrStat, ErrMsg, RoutineName )
return
end if

do k=1,p%NumBlds

do k=1,p%NumBlds

call MeshCreate ( BlankMesh = u%BladeRootMotion(k) &
,IOS = COMPONENT_INPUT &
Expand Down Expand Up @@ -626,11 +625,14 @@ subroutine Init_u( u, p, InitInp, errStat, errMsg )
CALL AllocPAry( u%DX_u%bldRloc, p%nTotBldNds, 'bldRloc', ErrStat2, ErrMsg2 ); CALL SetErrStat( ErrStat2, ErrMsg2, ErrStat, ErrMsg, RoutineName )
CALL AllocPAry( u%DX_u%twrdia, p%NumTwrNds, 'twrDia', ErrStat2, ErrMsg2 ); CALL SetErrStat( ErrStat2, ErrMsg2, ErrStat, ErrMsg, RoutineName )
CALL AllocPAry( u%DX_u%twrHloc, p%NumTwrNds, 'twrHloc', ErrStat2, ErrMsg2 ); CALL SetErrStat( ErrStat2, ErrMsg2, ErrStat, ErrMsg, RoutineName )
CALL AllocPAry( u%DX_u%bldPitch, p%NumBlds, 'bldPitch', ErrStat2, ErrMsg2 ); CALL SetErrStat( ErrStat2, ErrMsg2, ErrStat, ErrMsg, RoutineName )

! make sure the C versions are synced with these arrays
u%DX_u%c_obj%bldChord_Len = p%nTotBldNds; u%DX_u%c_obj%bldChord = C_LOC( u%DX_u%bldChord(1) )
u%DX_u%c_obj%bldRloc_Len = p%nTotBldNds; u%DX_u%c_obj%bldRloc = C_LOC( u%DX_u%bldRloc(1) )
u%DX_u%c_obj%twrDia_Len = p%NumTwrNds; u%DX_u%c_obj%twrDia = C_LOC( u%DX_u%twrDia(1) )
u%DX_u%c_obj%twrHloc_Len = p%NumTwrNds; u%DX_u%c_obj%twrHloc = C_LOC( u%DX_u%twrHloc(1) )
u%DX_u%c_obj%bldPitch_Len = p%NumBlds; u%DX_u%c_obj%bldPitch = C_LOC( u%DX_u%bldPitch(1) )

jTot = 1
do k=1,p%NumBlds
Expand Down
1 change: 1 addition & 0 deletions modules/extloads/src/ExtLoadsDX_Registry.txt
Original file line number Diff line number Diff line change
Expand Up @@ -35,6 +35,7 @@ typedef ^ InputType R8Ki bldChord {:} - -
typedef ^ InputType R8Ki bldRloc {:} - - "Radial location along the blade" m
typedef ^ InputType R8Ki twrDia {:} - - "Tower diameter" m
typedef ^ InputType R8Ki twrHloc {:} - - "Height location along the tower" m
typedef ^ InputType R8Ki bldPitch {:} - - "Pitch angle of blade"


# ..... Outputs ...................................................................................................................
Expand Down
99 changes: 99 additions & 0 deletions modules/extloads/src/ExtLoadsDX_Types.f90
Original file line number Diff line number Diff line change
Expand Up @@ -71,6 +71,8 @@ MODULE ExtLoadsDX_Types
INTEGER(C_int) :: twrDia_Len = 0
TYPE(C_ptr) :: twrHloc = C_NULL_PTR
INTEGER(C_int) :: twrHloc_Len = 0
TYPE(C_ptr) :: bldPitch = C_NULL_PTR
INTEGER(C_int) :: bldPitch_Len = 0
END TYPE ExtLdDX_InputType_C
TYPE, PUBLIC :: ExtLdDX_InputType
TYPE( ExtLdDX_InputType_C ) :: C_obj
Expand All @@ -91,6 +93,7 @@ MODULE ExtLoadsDX_Types
REAL(KIND=C_DOUBLE) , DIMENSION(:), POINTER :: bldRloc => NULL() !< Radial location along the blade [m]
REAL(KIND=C_DOUBLE) , DIMENSION(:), POINTER :: twrDia => NULL() !< Tower diameter [m]
REAL(KIND=C_DOUBLE) , DIMENSION(:), POINTER :: twrHloc => NULL() !< Height location along the tower [m]
REAL(KIND=C_DOUBLE) , DIMENSION(:), POINTER :: bldPitch => NULL() !< Pitch angle of blade [-]
END TYPE ExtLdDX_InputType
! =======================
! ========= ExtLdDX_OutputType_C =======
Expand Down Expand Up @@ -377,6 +380,21 @@ SUBROUTINE ExtLdDX_CopyInput( SrcInputData, DstInputData, CtrlCode, ErrStat, Err
DstInputData%c_obj%twrHloc = C_LOC( DstInputData%twrHloc(i1_l) )
END IF
DstInputData%twrHloc = SrcInputData%twrHloc
ENDIF
IF (ASSOCIATED(SrcInputData%bldPitch)) THEN
i1_l = LBOUND(SrcInputData%bldPitch,1)
i1_u = UBOUND(SrcInputData%bldPitch,1)
IF (.NOT. ASSOCIATED(DstInputData%bldPitch)) THEN
ALLOCATE(DstInputData%bldPitch(i1_l:i1_u),STAT=ErrStat2)
IF (ErrStat2 /= 0) THEN
CALL SetErrStat(ErrID_Fatal, 'Error allocating DstInputData%bldPitch.', ErrStat, ErrMsg,RoutineName)
RETURN
END IF
DstInputData%c_obj%bldPitch_Len = SIZE(DstInputData%bldPitch)
IF (DstInputData%c_obj%bldPitch_Len > 0) &
DstInputData%c_obj%bldPitch = C_LOC( DstInputData%bldPitch(i1_l) )
END IF
DstInputData%bldPitch = SrcInputData%bldPitch
ENDIF
END SUBROUTINE ExtLdDX_CopyInput

Expand Down Expand Up @@ -490,6 +508,12 @@ SUBROUTINE ExtLdDX_DestroyInput( InputData, ErrStat, ErrMsg )
InputData%twrHloc => NULL()
InputData%C_obj%twrHloc = C_NULL_PTR
InputData%C_obj%twrHloc_Len = 0
ENDIF
IF (ASSOCIATED(InputData%bldPitch)) THEN
DEALLOCATE(InputData%bldPitch)
InputData%bldPitch => NULL()
InputData%C_obj%bldPitch = C_NULL_PTR
InputData%C_obj%bldPitch_Len = 0
ENDIF
END SUBROUTINE ExtLdDX_DestroyInput

Expand Down Expand Up @@ -613,6 +637,11 @@ SUBROUTINE ExtLdDX_PackInput( ReKiBuf, DbKiBuf, IntKiBuf, Indata, ErrStat, ErrMs
Int_BufSz = Int_BufSz + 2*1 ! twrHloc upper/lower bounds for each dimension
Db_BufSz = Db_BufSz + SIZE(InData%twrHloc) ! twrHloc
END IF
Int_BufSz = Int_BufSz + 1 ! bldPitch allocated yes/no
IF ( ASSOCIATED(InData%bldPitch) ) THEN
Int_BufSz = Int_BufSz + 2*1 ! bldPitch upper/lower bounds for each dimension
Db_BufSz = Db_BufSz + SIZE(InData%bldPitch) ! bldPitch
END IF
IF ( Re_BufSz .GT. 0 ) THEN
ALLOCATE( ReKiBuf( Re_BufSz ), STAT=ErrStat2 )
IF (ErrStat2 /= 0) THEN
Expand Down Expand Up @@ -897,6 +926,21 @@ SUBROUTINE ExtLdDX_PackInput( ReKiBuf, DbKiBuf, IntKiBuf, Indata, ErrStat, ErrMs
Db_Xferred = Db_Xferred + 1
END DO
END IF
IF ( .NOT. ASSOCIATED(InData%bldPitch) ) THEN
IntKiBuf( Int_Xferred ) = 0
Int_Xferred = Int_Xferred + 1
ELSE
IntKiBuf( Int_Xferred ) = 1
Int_Xferred = Int_Xferred + 1
IntKiBuf( Int_Xferred ) = LBOUND(InData%bldPitch,1)
IntKiBuf( Int_Xferred + 1) = UBOUND(InData%bldPitch,1)
Int_Xferred = Int_Xferred + 2

DO i1 = LBOUND(InData%bldPitch,1), UBOUND(InData%bldPitch,1)
DbKiBuf(Db_Xferred) = InData%bldPitch(i1)
Db_Xferred = Db_Xferred + 1
END DO
END IF
END SUBROUTINE ExtLdDX_PackInput

SUBROUTINE ExtLdDX_UnPackInput( ReKiBuf, DbKiBuf, IntKiBuf, Outdata, ErrStat, ErrMsg )
Expand Down Expand Up @@ -1283,6 +1327,27 @@ SUBROUTINE ExtLdDX_UnPackInput( ReKiBuf, DbKiBuf, IntKiBuf, Outdata, ErrStat, Er
Db_Xferred = Db_Xferred + 1
END DO
END IF
IF ( IntKiBuf( Int_Xferred ) == 0 ) THEN ! bldPitch not allocated
Int_Xferred = Int_Xferred + 1
ELSE
Int_Xferred = Int_Xferred + 1
i1_l = IntKiBuf( Int_Xferred )
i1_u = IntKiBuf( Int_Xferred + 1)
Int_Xferred = Int_Xferred + 2
IF (ASSOCIATED(OutData%bldPitch)) DEALLOCATE(OutData%bldPitch)
ALLOCATE(OutData%bldPitch(i1_l:i1_u),STAT=ErrStat2)
IF (ErrStat2 /= 0) THEN
CALL SetErrStat(ErrID_Fatal, 'Error allocating OutData%bldPitch.', ErrStat, ErrMsg,RoutineName)
RETURN
END IF
OutData%c_obj%bldPitch_Len = SIZE(OutData%bldPitch)
IF (OutData%c_obj%bldPitch_Len > 0) &
OutData%c_obj%bldPitch = C_LOC( OutData%bldPitch(i1_l) )
DO i1 = LBOUND(OutData%bldPitch,1), UBOUND(OutData%bldPitch,1)
OutData%bldPitch(i1) = REAL(DbKiBuf(Db_Xferred), C_DOUBLE)
Db_Xferred = Db_Xferred + 1
END DO
END IF
END SUBROUTINE ExtLdDX_UnPackInput

SUBROUTINE ExtLdDX_C2Fary_CopyInput( InputData, ErrStat, ErrMsg, SkipPointers )
Expand Down Expand Up @@ -1453,6 +1518,15 @@ SUBROUTINE ExtLdDX_C2Fary_CopyInput( InputData, ErrStat, ErrMsg, SkipPointers )
CALL C_F_POINTER(InputData%C_obj%twrHloc, InputData%twrHloc, (/InputData%C_obj%twrHloc_Len/))
END IF
END IF

! -- bldPitch Input Data fields
IF ( .NOT. SkipPointers_local ) THEN
IF ( .NOT. C_ASSOCIATED( InputData%C_obj%bldPitch ) ) THEN
NULLIFY( InputData%bldPitch )
ELSE
CALL C_F_POINTER(InputData%C_obj%bldPitch, InputData%bldPitch, (/InputData%C_obj%bldPitch_Len/))
END IF
END IF
END SUBROUTINE ExtLdDX_C2Fary_CopyInput

SUBROUTINE ExtLdDX_F2C_CopyInput( InputData, ErrStat, ErrMsg, SkipPointers )
Expand Down Expand Up @@ -1674,6 +1748,18 @@ SUBROUTINE ExtLdDX_F2C_CopyInput( InputData, ErrStat, ErrMsg, SkipPointers )
InputData%c_obj%twrHloc = C_LOC( InputData%twrHloc( LBOUND(InputData%twrHloc,1) ) )
END IF
END IF

! -- bldPitch Input Data fields
IF ( .NOT. SkipPointers_local ) THEN
IF ( .NOT. ASSOCIATED(InputData%bldPitch)) THEN
InputData%c_obj%bldPitch_Len = 0
InputData%c_obj%bldPitch = C_NULL_PTR
ELSE
InputData%c_obj%bldPitch_Len = SIZE(InputData%bldPitch)
IF (InputData%c_obj%bldPitch_Len > 0) &
InputData%c_obj%bldPitch = C_LOC( InputData%bldPitch( LBOUND(InputData%bldPitch,1) ) )
END IF
END IF
END SUBROUTINE ExtLdDX_F2C_CopyInput

SUBROUTINE ExtLdDX_CopyOutput( SrcOutputData, DstOutputData, CtrlCode, ErrStat, ErrMsg )
Expand Down Expand Up @@ -2183,6 +2269,12 @@ SUBROUTINE ExtLdDX_Input_ExtrapInterp1(u1, u2, tin, u_out, tin_out, ErrStat, Err
b = -(u1%twrHloc(i1) - u2%twrHloc(i1))
u_out%twrHloc(i1) = u1%twrHloc(i1) + b * ScaleFactor
END DO
END IF ! check if allocated
IF (ASSOCIATED(u_out%bldPitch) .AND. ASSOCIATED(u1%bldPitch)) THEN
DO i1 = LBOUND(u_out%bldPitch,1),UBOUND(u_out%bldPitch,1)
b = -(u1%bldPitch(i1) - u2%bldPitch(i1))
u_out%bldPitch(i1) = u1%bldPitch(i1) + b * ScaleFactor
END DO
END IF ! check if allocated
END SUBROUTINE ExtLdDX_Input_ExtrapInterp1

Expand Down Expand Up @@ -2344,6 +2436,13 @@ SUBROUTINE ExtLdDX_Input_ExtrapInterp2(u1, u2, u3, tin, u_out, tin_out, ErrStat,
c = ( (t(2)-t(3))*u1%twrHloc(i1) + t(3)*u2%twrHloc(i1) - t(2)*u3%twrHloc(i1) ) * scaleFactor
u_out%twrHloc(i1) = u1%twrHloc(i1) + b + c * t_out
END DO
END IF ! check if allocated
IF (ASSOCIATED(u_out%bldPitch) .AND. ASSOCIATED(u1%bldPitch)) THEN
DO i1 = LBOUND(u_out%bldPitch,1),UBOUND(u_out%bldPitch,1)
b = (t(3)**2*(u1%bldPitch(i1) - u2%bldPitch(i1)) + t(2)**2*(-u1%bldPitch(i1) + u3%bldPitch(i1)))* scaleFactor
c = ( (t(2)-t(3))*u1%bldPitch(i1) + t(3)*u2%bldPitch(i1) - t(2)*u3%bldPitch(i1) ) * scaleFactor
u_out%bldPitch(i1) = u1%bldPitch(i1) + b + c * t_out
END DO
END IF ! check if allocated
END SUBROUTINE ExtLdDX_Input_ExtrapInterp2

Expand Down
1 change: 1 addition & 0 deletions modules/extloads/src/ExtLoadsDX_Types.h
Original file line number Diff line number Diff line change
Expand Up @@ -39,6 +39,7 @@
double * bldRloc ; int bldRloc_Len ;
double * twrDia ; int twrDia_Len ;
double * twrHloc ; int twrHloc_Len ;
double * bldPitch ; int bldPitch_Len ;
} ExtLdDX_InputType_t ;
typedef struct ExtLdDX_OutputType {
void * object ;
Expand Down
1 change: 0 additions & 1 deletion modules/extloads/src/ExtLoads_Registry.txt
Original file line number Diff line number Diff line change
Expand Up @@ -43,7 +43,6 @@ typedef ^ InitInputType ReKi BldChord {:}{:}
typedef ^ InitInputType ReKi BldRloc {:}{:} - - "Radial location of each node along the blade" m
typedef ^ InitInputType ReKi TwrDia {:} - - "Tower diameter (NumTwrNodes)" m
typedef ^ InitInputType ReKi TwrHloc {:} - - "Height location of each node along the tower" m


# Define outputs from the initialization routine here:
typedef ^ InitOutputType CHARACTER(ChanLen) WriteOutputHdr {:} - - "Names of the output-to-file channels" -
Expand Down
3 changes: 3 additions & 0 deletions modules/openfast-library/src/FAST_Library.f90
Original file line number Diff line number Diff line change
Expand Up @@ -934,6 +934,7 @@ subroutine SetExtLoads_pointers(iTurb, ExtLd_iFromOF, ExtLd_oToOF)
TYPE(ExtLdDX_InputType_C), INTENT(INOUT) :: ExtLd_iFromOF
TYPE(ExtLdDX_OutputType_C),INTENT(INOUT) :: ExtLd_oToOF

ExtLd_iFromOF%bldPitch_Len = Turbine(iTurb)%ExtLd%u%DX_u%c_obj%bldPitch_Len; ExtLd_iFromOF%bldPitch = Turbine(iTurb)%ExtLd%u%DX_u%c_obj%bldPitch
ExtLd_iFromOF%twrHloc_Len = Turbine(iTurb)%ExtLd%u%DX_u%c_obj%twrHloc_Len; ExtLd_iFromOF%twrHloc = Turbine(iTurb)%ExtLd%u%DX_u%c_obj%twrHloc
ExtLd_iFromOF%twrDia_Len = Turbine(iTurb)%ExtLd%u%DX_u%c_obj%twrDia_Len; ExtLd_iFromOF%twrDia = Turbine(iTurb)%ExtLd%u%DX_u%c_obj%twrDia
ExtLd_iFromOF%twrRefPos_Len = Turbine(iTurb)%ExtLd%u%DX_u%c_obj%twrRefPos_Len; ExtLd_iFromOF%twrRefPos = Turbine(iTurb)%ExtLd%u%DX_u%c_obj%twrRefPos
Expand All @@ -946,6 +947,8 @@ subroutine SetExtLoads_pointers(iTurb, ExtLd_iFromOF, ExtLd_oToOF)
ExtLd_iFromOF%nBladeNodes_Len = Turbine(iTurb)%ExtLd%u%DX_u%c_obj%nBladeNodes_Len; ExtLd_iFromOF%nBladeNodes = Turbine(iTurb)%ExtLd%u%DX_u%c_obj%nBladeNodes
ExtLd_iFromOF%nTowerNodes_Len = Turbine(iTurb)%ExtLd%u%DX_u%c_obj%nTowerNodes_Len; ExtLd_iFromOF%nTowerNodes = Turbine(iTurb)%ExtLd%u%DX_u%c_obj%nTowerNodes

ExtLd_iFromOF%bldRootDef_Len = Turbine(iTurb)%ExtLd%u%DX_u%c_obj%bldRootDef_Len; ExtLd_iFromOF%bldRootDef = Turbine(iTurb)%ExtLd%u%DX_u%c_obj%bldRootDef

ExtLd_iFromOF%hubRefPos_Len = Turbine(iTurb)%ExtLd%u%DX_u%c_obj%hubRefPos_Len; ExtLd_iFromOF%hubRefPos = Turbine(iTurb)%ExtLd%u%DX_u%c_obj%hubRefPos
ExtLd_iFromOF%hubDef_Len = Turbine(iTurb)%ExtLd%u%DX_u%c_obj%hubDef_Len; ExtLd_iFromOF%hubDef = Turbine(iTurb)%ExtLd%u%DX_u%c_obj%hubDef

Expand Down
1 change: 1 addition & 0 deletions modules/openfast-library/src/FAST_Solver.f90
Original file line number Diff line number Diff line change
Expand Up @@ -1108,6 +1108,7 @@ SUBROUTINE ExtLd_InputSolve_NoIfW( p_FAST, u_ExtLd, p_ExtLd, y_ED, BD, MeshMapDa
END IF

u_ExtLd%az = y_ED%LSSTipPxa
u_ExtLd%DX_u%bldPitch(:) = y_ED%BlPitch

call ExtLd_ConvertInpDataForExtProg(u_ExtLd, p_ExtLd, ErrStat2, ErrMsg2 )
CALL SetErrStat(ErrStat2,ErrMsg2,ErrStat,ErrMsg,RoutineName)
Expand Down

0 comments on commit 6bdeca2

Please sign in to comment.