@@ -1628,7 +1628,7 @@ subroutine Grid4DField_GetVel(G4D, Time, Position, Velocity, ErrStat, ErrMsg)
16281628 real (ReKi) :: P(3 , 16 ) ! Point values
16291629 real (ReKi) :: tmp
16301630 integer (IntKi) :: i
1631- character (60 ) :: PtLoc
1631+ character (60 ) :: PtLoc, BoxLL, BoxUR
16321632
16331633 ErrStat = ErrID_None
16341634 ErrMsg = " "
@@ -1665,12 +1665,16 @@ subroutine Grid4DField_GetVel(G4D, Time, Position, Velocity, ErrStat, ErrMsg)
16651665 do i = 1 , 4
16661666 if (Indx_Lo(i) <= 0 ) then
16671667 Indx_Lo(i) = 1
1668- write (PtLoc,' (A1,3(f8.2,A1))' ) ' (' ,Position (1 ),' ,' ,Position (2 ),' ,' ,Position (3 ),' )'
1669- call SetErrStat(ErrID_Fatal, ' Outside the grid bounds: ' // trim (PtLoc), ErrStat, ErrMsg, RoutineName)
1668+ write (PtLoc, ' (A1,3(f8.2,A1))' ) ' (' ,Position (1 ),' ,' ,Position (2 ),' ,' ,Position (3 ),' )'
1669+ write (BoxLL, ' (A1,3(f8.2,A1))' ) ' (' ,G4D% pZero(1 ),' ,' ,G4D% pZero(2 ),' ,' ,G4D% pZero(3 ),' )'
1670+ write (BoxUR, ' (A1,3(f8.2,A1))' ) ' (' ,G4D% pZero(1 )+ (G4D% n(1 )- 1 )* G4D% delta(1 ),' ,' ,G4D% pZero(2 )+ (G4D% n(2 )- 1 )* G4D% delta(2 ),' ,' ,G4D% pZero(3 )+ (G4D% n(3 )- 1 )* G4D% delta(3 ),' )'
1671+ call SetErrStat(ErrID_Fatal, ' Outside the grid bounds: ' // trim (PtLoc)// ' ; box bounds: ' // trim (BoxLL)// ' to ' // trim (BoxUR), ErrStat, ErrMsg, RoutineName)
16701672 return
16711673 elseif (Indx_Lo(i) >= G4D% n(i)) then
1672- write (PtLoc,' (A1,3(f8.2,A1))' ) ' (' ,Position (1 ),' ,' ,Position (2 ),' ,' ,Position (3 ),' )'
1673- call SetErrStat(ErrID_Fatal, ' Outside the grid bounds: ' // trim (PtLoc), ErrStat, ErrMsg, RoutineName)
1674+ write (PtLoc, ' (A1,3(f8.2,A1))' ) ' (' ,Position (1 ),' ,' ,Position (2 ),' ,' ,Position (3 ),' )'
1675+ write (BoxLL, ' (A1,3(f8.2,A1))' ) ' (' ,G4D% pZero(1 ),' ,' ,G4D% pZero(2 ),' ,' ,G4D% pZero(3 ),' )'
1676+ write (BoxUR, ' (A1,3(f8.2,A1))' ) ' (' ,G4D% pZero(1 )+ (G4D% n(1 )- 1 )* G4D% delta(1 ),' ,' ,G4D% pZero(2 )+ (G4D% n(2 )- 1 )* G4D% delta(2 ),' ,' ,G4D% pZero(3 )+ (G4D% n(3 )- 1 )* G4D% delta(3 ),' )'
1677+ call SetErrStat(ErrID_Fatal, ' Outside the grid bounds: ' // trim (PtLoc)// ' ; box bounds: ' // trim (BoxLL)// ' to ' // trim (BoxUR), ErrStat, ErrMsg, RoutineName)
16741678 return
16751679 end if
16761680 Indx_Hi(i) = min (Indx_Lo(i) + 1 , G4D% n(i)) ! make sure it's a valid index
0 commit comments