Class: EngineeringCalculator::GasDynamicsCalculator

Inherits:
Object
  • Object
show all
Defined in:
lib/engineering_calculator/calculator/gas_dynamics_calculator.rb

Constant Summary collapse

@@functions =
['fanno',
'isentropic',
'normal_shock',
'oblique', 
'prandtl_compression', 
'prandtl_expansion', 
'rayleigh']

Class Method Summary collapse

Class Method Details

.function(fun) ⇒ Object



17
18
19
20
21
22
23
# File 'lib/engineering_calculator/calculator/gas_dynamics_calculator.rb', line 17

def self.function(fun)
  if @@functions.include?(fun)
    perform(fun)
  else
    display_functions
  end
end

.functionsObject



13
14
15
# File 'lib/engineering_calculator/calculator/gas_dynamics_calculator.rb', line 13

def self.functions
  display_functions
end