libCommon Module

Utility procedures and those to compute induced velocity of rotors



Variables

Type Visibility Attributes Name Initial
type(rotor_class), public, allocatable, dimension(:) :: rotor
integer, public :: nt

No. of timesteps

integer, public :: nr

No. of rotors

real(kind=dp), public :: dt

Timestep size

integer, public :: iterStart
real(kind=dp), public :: t

Time

real(kind=dp), public :: density

Density

real(kind=dp), public :: velSound

Velocity of sound to compute Mach

real(kind=dp), public :: kinematicVisc

Kinematic viscosity

character(len=5), public :: timestamp
character(len=2), public :: rotorChar
character(len=10), public :: rotorFile
character(len=10), public :: currentTime
logical, public :: fileExists
real(kind=dp), public :: subIterResidual
real(kind=dp), public :: flipSign

Sign for mirroring image rotor (1 or -1 when imagePlane == 3)

integer, public :: i
integer, public :: is
integer, public :: ic
integer, public :: row
integer, public :: iter
integer, public :: ir
integer, public :: jr
integer, public :: ib
integer, public :: rowErase
integer, public :: hdf5Nt
type(switches_class), public :: switches
real(kind=dp), public, allocatable, dimension(:, :) :: probe
real(kind=dp), public, allocatable, dimension(:, :) :: probeVel
integer(kind=HID_T), public :: hdf5_file_id
integer(kind=HID_T), public :: hdf5_results_file_id

Functions

public function vind_onNwake_byRotor(rotor, Nwake, optionalChar) result(vindArray)

Compute induced velocity by rotor (wing + wake) on Nwake corner points

Arguments

Type IntentOptional Attributes Name
type(rotor_class), intent(in) :: rotor

Rotor

type(Nwake_class), intent(in), dimension(:, :) :: Nwake

Near wake

character(len=1), optional :: optionalChar

If 'P' is specified, predicted wake of rotor is used

Return Value real(kind=dp), dimension(3, size(Nwake, 1), size(Nwake, 2) + 1)

public function vind_onFwake_byRotor(rotor, Fwake, optionalChar) result(vindArray)

Compute induced velocity by rotor (wing + wake) on Fwake corner points

Arguments

Type IntentOptional Attributes Name
type(rotor_class), intent(in) :: rotor

Rotor

type(Fwake_class), intent(in), dimension(:) :: Fwake

Far wake

character(len=1), optional :: optionalChar

If 'P' is specified, predicted wake of rotor is used

Return Value real(kind=dp), dimension(3, size(Fwake, 1))

public function vel_order2_Nwake(v_wake_n, v_wake_np1)

Calculate 2nd order accurate induced velocity on near wake

Arguments

Type IntentOptional Attributes Name
real(kind=dp), intent(in), dimension(:, :, :) :: v_wake_n

Induced velocity on wake at timestep n

real(kind=dp), intent(in), dimension(:, :, :) :: v_wake_np1

Induced velocity on wake at timestep n+1

Return Value real(kind=dp), dimension(3, size(v_wake_n, 2), size(v_wake_n, 3))

public function vel_order2_Fwake(v_wake_n, v_wake_np1)

Calculate 2nd order accurate induced velocity on far wake

Arguments

Type IntentOptional Attributes Name
real(kind=dp), intent(in), dimension(:, :) :: v_wake_n

Induced velocity on wake at timestep n

real(kind=dp), intent(in), dimension(:, :) :: v_wake_np1

Induced velocity on wake at timestep n+1

Return Value real(kind=dp), dimension(3, size(v_wake_n, 2))


Subroutines

public subroutine readConfig(filename, outputFilename)

Read config.nml input file (in namelist format)

Arguments

Type IntentOptional Attributes Name
character(len=*), intent(in) :: filename
character(len=*), intent(in), optional :: outputFilename

public subroutine print_status(statusMessage)

Prints status message (or SUCCESS if left blank)

Arguments

Type IntentOptional Attributes Name
character(len=*), optional :: statusMessage