2 Copyright (C) 2009-2015 Paul Brossier <piem@aubio.org>
4 This file is part of aubio.
6 aubio is free software: you can redistribute it and/or modify
7 it under the terms of the GNU General Public License as published by
8 the Free Software Foundation, either version 3 of the License, or
9 (at your option) any later version.
11 aubio is distributed in the hope that it will be useful,
12 but WITHOUT ANY WARRANTY; without even the implied warranty of
13 MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
14 GNU General Public License for more details.
16 You should have received a copy of the GNU General Public License
17 along with aubio. If not, see <http://www.gnu.org/licenses/>.
23 Utility functions for ::fvec_t
27 #ifndef AUBIO_VECUTILS_H
28 #define AUBIO_VECUTILS_H
34 /** compute \f$e^x\f$ of each vector elements
36 \param s vector to modify
39 void fvec_exp (fvec_t *s);
41 /** compute \f$cos(x)\f$ of each vector elements
43 \param s vector to modify
46 void fvec_cos (fvec_t *s);
48 /** compute \f$sin(x)\f$ of each vector elements
50 \param s vector to modify
53 void fvec_sin (fvec_t *s);
55 /** compute the \f$abs(x)\f$ of each vector elements
57 \param s vector to modify
60 void fvec_abs (fvec_t *s);
62 /** compute the \f$sqrt(x)\f$ of each vector elements
64 \param s vector to modify
67 void fvec_sqrt (fvec_t *s);
69 /** compute the \f$log10(x)\f$ of each vector elements
71 \param s vector to modify
74 void fvec_log10 (fvec_t *s);
76 /** compute the \f$log(x)\f$ of each vector elements
78 \param s vector to modify
81 void fvec_log (fvec_t *s);
83 /** compute the \f$floor(x)\f$ of each vector elements
85 \param s vector to modify
88 void fvec_floor (fvec_t *s);
90 /** compute the \f$ceil(x)\f$ of each vector elements
92 \param s vector to modify
95 void fvec_ceil (fvec_t *s);
97 /** compute the \f$round(x)\f$ of each vector elements
99 \param s vector to modify
102 void fvec_round (fvec_t *s);
104 /** raise each vector elements to the power pow
106 \param s vector to modify
107 \param pow power to raise to
110 void fvec_pow (fvec_t *s, smpl_t pow);
116 #endif /* AUBIO_VECUTILS_H */