Pushing everything again, accidentally deleted my remote repository
This commit is contained in:
commit
1bee3e8e5b
101 changed files with 9428 additions and 0 deletions
42
ex5/ex5_2/mylib.h
Normal file
42
ex5/ex5_2/mylib.h
Normal file
|
|
@ -0,0 +1,42 @@
|
|||
#include <vector>
|
||||
|
||||
/**
|
||||
This function calculates arithmetic mean, geometric mean and harmonic mean of an integer vector.
|
||||
Uses openMP parallelization.
|
||||
@param[in] numbers vector containing integers
|
||||
@param[out] am arithmetic mean
|
||||
@param[out] gm geometric mean
|
||||
@param[out] hm harmonic mean
|
||||
*/
|
||||
void means_omp(const std::vector<size_t> numbers, double &am, double &gm, double &hm);
|
||||
|
||||
|
||||
/**
|
||||
This function calculates the minimum and maximum of a vector.
|
||||
Uses openMP parallelization.
|
||||
@param[in] numbers vector containing integers
|
||||
@param[out] global_min minimum
|
||||
@param[out] global_max maximum
|
||||
*/
|
||||
void minmax_omp(const std::vector<size_t> numbers, size_t &global_min, size_t &global_max);
|
||||
|
||||
|
||||
/**
|
||||
This function calculates arithmetic mean, geometric mean and harmonic mean of an integer vector.
|
||||
Uses C++ parallelization.
|
||||
@param[in] numbers vector containing integers
|
||||
@param[out] am arithmetic mean
|
||||
@param[out] gm geometric mean
|
||||
@param[out] hm harmonic mean
|
||||
*/
|
||||
void means_cpp(const std::vector<size_t> numbers, double &am, double &gm, double &hm);
|
||||
|
||||
|
||||
/**
|
||||
This function calculates the minimum and maximum of a vector.
|
||||
Uses C++ parallelization.
|
||||
@param[in] numbers vector containing integers
|
||||
@param[out] global_min minimum
|
||||
@param[out] global_max maximum
|
||||
*/
|
||||
void minmax_cpp(const std::vector<size_t> numbers, size_t &global_min, size_t &global_max);
|
||||
Loading…
Add table
Add a link
Reference in a new issue