Excercises_GeorgMandl/BSP_1_A/bsp_1_a.h

31 lines
1,003 B
C++

#ifndef BSP_1_A_H_INCLUDED
#define BSP_1_A_H_INCLUDED
#include<vector>
/** \brief Funktion zur Berechnung des arithmetischen, geometrischen und harmonischen Mittels aus 3 Zahlen
*
* \param[in,out] x erste Zahl
* \param[in,out] y zweite Zahl
* \param[in,out] z dritte Zahl
* \param[in,out] a arithmetisches Mittel
* \param[in,out] g geometrisches Mittel
* \param[in,out] h harmonisches Mittel
* \return
*
*/
void mean(long long int x, long long int y, long long int z, float &a, float &g, float &h);
/** \brief Funktion zur Berechnung des arithmetischen, geometrischen und harmonischen Mittels aus den Eintraegen eines gegebenen Vektors
*
* \param[in,out] x Vektor mit Eintraegen
* \param[in,out] a arithmetisches Mittel
* \param[in,out] g geometrisches Mittel
* \param[in,out] h harmonisches Mittel
* \return
*
*/
void meanvec(std::vector<float> x, float &a, float &g, float &h);
#endif // BSP_1_A_H_INCLUDED