![]() |
Rosetta
2016.32
|
some useful functions for vector1 that I'm tired of rewriting More...
#include <utility/vector1.hh>Namespaces | |
| utility | |
| comment 0 | |
Functions | |
| template<class T > | |
| T | utility::max (vector1< T > const &input) |
| Find the largest value in a vector. More... | |
| template<class T > | |
| T | utility::min (vector1< T > const &input) |
| Find the smallest value in a vector. More... | |
| template<class T > | |
| vector1< T >::Size | utility::arg_max (vector1< T > const &input) |
| find the index of the largest value in a vector More... | |
| template<class T > | |
| vector1< T >::Size | utility::arg_min (vector1< T > const &input) |
| find the index of the smallest value in a vector More... | |
| template<class T > | |
| void | utility::insert_middle (vector1< T > &vect, typename vector1< T >::Size const position, T const new_value, bool expand) |
| template<class T > | |
| void | utility::arg_greatest_several (vector1< T > const &input, vector1< typename vector1< T >::Size > &arg_list) |
| Finds indices of the n largest items in input vector, where n is size of the arg_list vector. The indices are reported in decreasing sorted order by the value of the corresponding position in the input vector. If m is the size of the input vector, then this function is O( m n**2) More... | |
| template<class T > | |
| void | utility::arg_least_several (vector1< T > const &input, vector1< typename vector1< T >::Size > &arg_list) |
| Finds indices of the n smallest items in input vector, where n is size of the arg_list vector. The indices are reported in increasing sorted order by the value of the corresponding position in the input vector. If m is the size of the input vector, then this function is O( m n**2) More... | |
some useful functions for vector1 that I'm tired of rewriting
1.8.7