Skip to content

Commit

Permalink
Merge pull request #19 from andrew-platt/f/InflowWind_FF
Browse files Browse the repository at this point in the history
merge of dev changes to InflowWind
  • Loading branch information
bjonkman authored Nov 30, 2020
2 parents 20b3cfb + 2b476a8 commit 9bfa548
Show file tree
Hide file tree
Showing 106 changed files with 11,151 additions and 4,910 deletions.
18 changes: 18 additions & 0 deletions .github/actions/cmake-config/action.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,18 @@
name: 'Configure CMake'
description: 'Configure the CMake project'
author: 'Rafael Mudafort https://github.com/rafmudaf'

inputs:
build-type:
description: 'Set the CMake build type: Release (-O3); RelWithDebInfo (-O2 -g); Debug (-g)'
default: 'Release'
additional-flags:
description: 'Additional flags to pass directly to the CMake command'
default: ''

runs:
using: 'composite'
steps:
- run: cmake .. -DCMAKE_BUILD_TYPE=${{ inputs.build-type }} ${{ inputs.additional-flags }}
working-directory: "/openfast/build"
shell: bash
24 changes: 0 additions & 24 deletions .github/actions/compile-and-test/Dockerfile

This file was deleted.

10 changes: 0 additions & 10 deletions .github/actions/compile-and-test/action.yml

This file was deleted.

69 changes: 0 additions & 69 deletions .github/actions/compile-and-test/entrypoint.sh

This file was deleted.

15 changes: 15 additions & 0 deletions .github/actions/compile/action.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,15 @@
name: 'Compile OpenFAST'
description: 'Compile part or all of OpenFAST'
author: 'Rafael Mudafort https://github.com/rafmudaf'

inputs:
build-target:
description: 'Which targets to compile'
default: 'install'

runs:
using: 'composite'
steps:
- run: make -j4 ${{ inputs.build-target }}
working-directory: "/openfast/build"
shell: bash
22 changes: 22 additions & 0 deletions .github/actions/git-update/action.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,22 @@
name: 'Update the existin OpenFAST project in the Docker image'
description: 'Workaround to avoid recompiling every component since the Docker image has the latest "dev" branch precompiled.'
author: 'Rafael Mudafort https://github.com/rafmudaf'

inputs:
repository:
description: 'The GitHub repository that is taking action.'
required: true
ref:
description: 'The branch or tag ref that triggered the action.'
required: true

runs:
using: 'composite'
steps:
- run: |
git config --global user.email "openfast@github_actions.ci"
git config --global user.name "OpenFAST Continuous Integration"
git pull --no-verify https://github.com/${{ inputs.repository }} ${{ inputs.ref }}
git submodule update
working-directory: "/openfast/"
shell: bash
21 changes: 21 additions & 0 deletions .github/actions/tests-gluecode-openfast/action.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,21 @@
name: 'OpenFAST glue code tests'
description: 'Run tests focused on the OpenFAST glue code'
author: 'Rafael Mudafort https://github.com/rafmudaf'
runs:
using: 'composite'
steps:
- run: |
ctest -VV -L linear -E Ideal
ctest -VV -j8 -I 1,1,1,2,3,4,5,6,7,8,10,11,12,13,14,15,17,18,21,22,23,24,25,26,27,28,29
working-directory: "/openfast/build"
shell: bash
# OpenFAST linearization tests
# Dont run these in parallel, copying the case files can fail in a race condition
# Exclude the Ideal_Beam test cases
# - They fail consistently in the Docker container when run on GitHub,
# but pass everywhere else including running the same Docker image locally

# Subset of OpenFAST regression tests; do not run
# - 9, 16 because they're very sensitive
# - 19, 20 because they're too long
9 changes: 9 additions & 0 deletions .github/actions/tests-module-aerodyn/action.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,9 @@
name: 'AeroDyn module tests'
description: 'Run tests specific to the AeroDyn module'
author: 'Rafael Mudafort https://github.com/rafmudaf'
runs:
using: "composite"
steps:
- run: ctest -VV -R fvw_utest
working-directory: "/openfast/build"
shell: bash
11 changes: 11 additions & 0 deletions .github/actions/tests-module-beamdyn/action.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,11 @@
name: 'BeamDyn module tests'
description: 'Run tests specific to the BeamDyn module'
author: 'Rafael Mudafort https://github.com/rafmudaf'
runs:
using: "composite"
steps:
- run: |
ctest -VV -j7 -R bd_
ctest -VV -R beamdyn_utest
working-directory: "/openfast/build"
shell: bash
9 changes: 9 additions & 0 deletions .github/actions/tests-module-hydrodyn/action.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,9 @@
name: 'HydroDyn module tests'
description: 'Run tests specific to the HydroDyn module'
author: 'Rafael Mudafort https://github.com/rafmudaf'
runs:
using: "composite"
steps:
- run: ctest -VV -j7 -hd_
working-directory: "/openfast/build"
shell: bash
9 changes: 9 additions & 0 deletions .github/actions/tests-module-inflowwind/action.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,9 @@
name: 'InflowWind module tests'
description: 'Run tests specific to the InflowWind module'
author: 'Rafael Mudafort https://github.com/rafmudaf'
runs:
using: "composite"
steps:
- run: ctest -VV -R inflowwind_utest
working-directory: "/openfast/build"
shell: bash
9 changes: 9 additions & 0 deletions .github/actions/tests-module-nwtclibrary/action.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,9 @@
name: 'NWTC Library module tests'
description: 'Run tests specific to the NWTC Library module'
author: 'Rafael Mudafort https://github.com/rafmudaf'
runs:
using: "composite"
steps:
- run: ctest -VV -R nwtc_library_utest
working-directory: "/openfast/build"
shell: bash
81 changes: 81 additions & 0 deletions .github/workflows/automated-dev-tests.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,81 @@

name: 'Development Pipeline'

on:
push:

pull_request:
types: [opened, synchronize] #labeled, assigned]

# runs-on: ${{ matrix.os }}
# strategy:
# matrix:
# os: [macOS-10.14, ubuntu-18.04]

jobs:
build-and-test:

# Do not run if:
# - Branch name contains "docs/"
if: "!contains(github.ref, 'docs/')"

runs-on: ubuntu-latest
container:
image: rafmudaf/openfast-ubuntu:dev
steps:
- name: Checkout
uses: actions/checkout@main
with:
submodules: recursive
- name: Git Update
uses: ./.github/actions/git-update
with:
repository: $GITHUB_REPOSITORY
ref: $GITHUB_REF

- name: Configure CMake
uses: ./.github/actions/cmake-config
with:
build-type: RelWithDebInfo
additional-flags: -DBUILD_TESTING=ON -DCTEST_PLOT_ERRORS=ON

- name: Compile Unit Tests
uses: ./.github/actions/compile
with:
build-target: 'unit_tests'
- name: Compile Drivers
uses: ./.github/actions/compile
with:
build-target: 'beamdyn_driver hydrodyn_driver'
- name: Compile OpenFAST
# if: contains(github.event.head_commit.message, 'Action - Test All') || contains(github.event.pull_request.labels.*.name, 'Action - Test All')
uses: ./.github/actions/compile
with:
build-target: 'install'

- name: 'Run NWTC Library tests'
uses: ./.github/actions/tests-module-nwtclibrary
- name: 'Run AeroDyn tests'
uses: ./.github/actions/tests-module-aerodyn
- name: 'Run BeamDyn tests'
uses: ./.github/actions/tests-module-beamdyn
- name: 'Run InflowWind tests'
uses: ./.github/actions/tests-module-inflowwind
- name: 'Run OpenFAST tests'
# if: contains(github.event.head_commit.message, 'Action - Test All') || contains(github.event.pull_request.labels.*.name, 'Action - Test All')
uses: ./.github/actions/tests-gluecode-openfast

- name: 'If failure, post test files'
uses: actions/upload-artifact@v2
if: failure()
with:
name: test-results
path: |
build/reg_tests/modules
build/reg_tests/glue-codes/openfast
!build/reg_tests/glue-codes/openfast/5MW_Baseline
!build/reg_tests/glue-codes/openfast/AOC
!build/reg_tests/glue-codes/openfast/AWT27
!build/reg_tests/glue-codes/openfast/SWRT
!build/reg_tests/glue-codes/openfast/UAE_VI
!build/reg_tests/glue-codes/openfast/WP_Baseline
22 changes: 0 additions & 22 deletions .github/workflows/continuous-integration-workflow.yml

This file was deleted.

5 changes: 5 additions & 0 deletions cmake/OpenfastFortranOptions.cmake
Original file line number Diff line number Diff line change
Expand Up @@ -107,6 +107,11 @@ macro(set_fast_gfortran)
#set(CMAKE_Fortran_FLAGS "${CMAKE_Fortran_FLAGS} -ffree-line-length-none -cpp -fopenmp")
set(CMAKE_Fortran_FLAGS "${CMAKE_Fortran_FLAGS} -ffree-line-length-none -cpp")

# Disable stack reuse within routines: issues seen with gfortran 9.x, but others may also exhibit
# see section 3.16 of https://gcc.gnu.org/onlinedocs/gcc-9.2.0/gcc.pdf
# and https://github.com/OpenFAST/openfast/pull/595
set(CMAKE_Fortran_FLAGS "${CMAKE_Fortran_FLAGS} -fstack-reuse='none'")

# Deal with Double/Single precision
if (DOUBLE_PRECISION)
add_definitions(-DOPENFAST_DOUBLE_PRECISION)
Expand Down
Binary file modified docs/OtherSupporting/OutListParameters.xlsx
Binary file not shown.
Original file line number Diff line number Diff line change
@@ -0,0 +1,11 @@
Example Time-Series Input File for UnsteadyAero Driver


This file has 8 header lines followed by three columns of data:


Time Angle of Attack VRel omega
(s) (deg) (m/s) (rad/s^2)
0.0 0 10 0
0.01 0 10 0
0.02 0 10 0
25 changes: 25 additions & 0 deletions docs/source/user/aerodyn-dynamicStall/examples/UA-driver.inp
Original file line number Diff line number Diff line change
@@ -0,0 +1,25 @@
UnsteadyAero Driver file for Unit NACA. k = 0.077
-------------------------------------------------------------------------------
FALSE Echo - Echo the input file data (flag)
---------------------- ENVIRONMENTAL CONDITIONS -------------------------------
340.29 SpdSound - Speed of sound (m/s)
---------------------- UNSTEADYAERO -------------------------------------------
"05014051_NACA" OutRootName - The name which prefixes all UnsteadyAero generated files (quoted string)
40.36 InflowVel - Inflow velocity (m/s)
1.48 Re - Reynolds number in millions (-)
3 UAMod - Unsteady Aero Model Switch: 2 - Gonzalez’s variant (changes in Cn,Cc,Cm); 3 - Minnema/Pierce variant (changes in Cc and Cm)
TRUE Flookup – Flag to indicate whether a lookup for f’ will be calculated (TRUE) or whether best-fit exponential equations will be used (FALSE); if FALSE S1-S4 must be provided in airfoil input files
------------------- AIRFOIL PROPERTIES ----------------------------------------
"05000051_AD15.dat" AirFoil - Airfoil table
0.55 Chord - Chord length (m)
TRUE UseCm - Use Cm data in airfoil table
------------------- SIMULATION CONTROL ----------------------------------------
1 SimMod - Simulation model [ 1 - use reduced frequency model, 2 - use time series data stored in the TimeInputs file and ignore the remaining parameters ]
3 NCycles - Number of angle-of-attack oscillations (cosine function) over the length of the simulation (-)
720 StepsPerCycle - Number of timesteps per cycle (-)
1.8 Frequency - Frequency for the airfoil oscillations (Hz)
9.685 Amplitude - Amplitude of the oscillations (deg)
15.195 Mean - Cycle mean (deg)
-180 Phase - Initial phase (num steps)
"UA-driver-timeseries.dat" InputsFile - Time series data in an ASCII input file (whitespace-separated data). 8 header lines, followed by column data. First column is time (sec), second column is angle-of-attack (deg), third column is InflowVel (m/s)
"END" of driver input file
Loading

0 comments on commit 9bfa548

Please sign in to comment.