Debian Codegraph @

LPC/LPC.h

raw symbols SCIP
1 #cxx . . $ `<file>/LPC/LPC.h`/ifndef _LPC_h_
2 #define _LPC_h_cxx . . $ `LPC/LPC.h:2:9`!
3 /* LPC.h
4 *
5 * Copyright (C) 1994-2020,2025 David Weenink
6 *
7 * This code is free software; you can redistribute it and/or modify
8 * it under the terms of the GNU General Public License as published by
9 * the Free Software Foundation; either version 2 of the License, or (at
10 * your option) any later version.
11 *
12 * This code is distributed in the hope that it will be useful, but
13 * WITHOUT ANY WARRANTY; without even the implied warranty of
14 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
15 * General Public License for more details.
16 *
17 * You should have received a copy of the GNU General Public License
18 * along with this work. If not, see <http://www.gnu.org/licenses/>.
19 */
20
21 #include "Matrix.h"cxx . . $ `<file>/fon/Matrix.h`/
22 #include "Graphics.h"cxx . . $ `<file>/sys/Graphics.h`/
23 #include "LPC_enums.h"cxx . . $ `<file>/LPC/LPC_enums.h`/
24
25 #include "LPC_def.h"cxx . . $ `<file>/LPC/LPC_def.h`/
26
27 /*
28 From Sampled:
29 xmin, xmax : range of time (s)
30 x1 : position of first frame (s)
31 dx : step size (s)
32 nx : number of frames
33 */
34
35 void LPC_initcxx . . $ LPC_init(879d622f7b1d3bbd). (LPCcxx . . $ LPC# me, double tmin, double tmax, integercxx . . $ integer# nt, double dt, double t1, integercxx . . $ integer# predictionOrder, double samplingPeriod);
36
37 autoLPCcxx . . $ autoLPC# LPC_createcxx . . $ LPC_create(dee197ba90f07c69). (double tmin, double tmax, integercxx . . $ integer# nt, double dt, double t1, integercxx . . $ integer# predictionOrder, double samplingPeriod);
38 /* Basic structure */
39
40 autoLPCcxx . . $ autoLPC# LPC_createCompletelyInitializedcxx . . $ LPC_createCompletelyInitialized(dee197ba90f07c69). (double tmin, double tmax, integercxx . . $ integer# nt, double dt, double t1, integercxx . . $ integer# predictionOrder, double samplingPeriod);
41 /* With all frames initialised */
42
43 void LPC_drawGaincxx . . $ LPC_drawGain(270151b8dc73f79f). (LPCcxx . . $ LPC# me, Graphicscxx . . $ Graphics# g, double t1, double t2, double gmin, double gmax, bool garnish);
44
45 void LPC_drawPolescxx . . $ LPC_drawPoles(c2507fe6286f2d06). (LPCcxx . . $ LPC# me, Graphicscxx . . $ Graphics# g, double time, bool garnish);
46
47 autoMatrixcxx . . $ autoMatrix# LPC_downto_Matrix_lpccxx . . $ LPC_downto_Matrix_lpc(183bbe624f631675). (LPCcxx . . $ LPC# me);
48
49 autoMatrixcxx . . $ autoMatrix# LPC_downto_Matrix_rccxx . . $ LPC_downto_Matrix_rc(183bbe624f631675). (LPCcxx . . $ LPC# me);
50
51 autoMatrixcxx . . $ autoMatrix# LPC_downto_Matrix_areacxx . . $ LPC_downto_Matrix_area(183bbe624f631675). (LPCcxx . . $ LPC# me);
52
53 static inline autoVECcxx . . $ autoVEC# LPC_listAllGainscxx . . $ LPC_listAllGains(a9c8e8094b1b3661). (LPCcxx . . $ LPC# me) {
54 autoVECcxx . . $ autoVEC# result = raw_VECcxx . . $ raw_VEC(e4395f764b859b1e). (mycxx . . $ `melder/melder.h:44:9`! nxcxx . . $ structSampled#nx.);
55 for (integercxx . . $ integer# iframe = 1; iframe <= mycxx . . $ `melder/melder.h:44:9`! nxcxx . . $ structSampled#nx.; iframe ++)
56 result [cxx . . $ autovector#`operator[]`(8a4599b8835d1ce1).iframe] = mycxx . . $ `melder/melder.h:44:9`! d_framescxx . . $ structLPC#d_frames. [cxx . . $ autovector#`operator[]`(8a4599b8835d1ce1).iframe]. gaincxx . . $ structLPC_Frame#gain.;
57 return resultcxx . . $ autovector#autovector(d33c649a3aceae2f).;
58 }
59
60 static inline autoVECcxx . . $ autoVEC# LPC_listCoefficientsInFramecxx . . $ LPC_listCoefficientsInFrame(a7a70102aa1da0af). (LPCcxx . . $ LPC# me, integercxx . . $ integer# frameNumber) {
61 mycxx . . $ `melder/melder.h:44:9`! checkIndexcxx . . $ structSampled#checkIndex(1624ee8275b10bda). (frameNumber);
62 autoVECcxx . . $ autoVEC# result = copy_VECcxx . . $ copy_VEC(d4415e68b25283a8). (mycxx . . $ constvectorview#constvectorview(eac9d6ec4c4bfecd). d_framescxx . . $ structLPC#d_frames. [cxx . . $ autovector#`operator[]`(8a4599b8835d1ce1).frameNumber]. acxx . . $ structLPC_Frame#a..getcxx . . $ autovector#get(e8d1da7fe68a6585).());
63 return resultcxx . . $ autovector#autovector(d33c649a3aceae2f).;
64 }
65
66 static inline autoMATcxx . . $ autoMAT# LPC_listAllCoefficientscxx . . $ LPC_listAllCoefficients(337ddec100dfae32). (LPCcxx . . $ LPC# me) {
67 autoMATcxx . . $ autoMAT# result = zero_MATcxx . . $ zero_MAT(3d09731056d2b97d). (mycxx . . $ `melder/melder.h:44:9`! maxnCoefficientscxx . . $ structLPC#maxnCoefficients., mycxx . . $ `melder/melder.h:44:9`! nxcxx . . $ structSampled#nx.);
68 for (integercxx . . $ integer# iframe = 1; iframe <= mycxx . . $ `melder/melder.h:44:9`! nxcxx . . $ structSampled#nx.; iframe ++) {
69 LPC_Framecxx . . $ LPC_Frame# f = & mycxx . . $ `melder/melder.h:44:9`! d_framescxx . . $ structLPC#d_frames. [cxx . . $ autovector#`operator[]`(8a4599b8835d1ce1).iframe];
70 result.columncxx . . $ automatrix#column(a8b9553e85c2b1fc). (iframe).partcxx . . $ vectorview#part(fd45ed87dd839590). (1, f -> nCoefficientscxx . . $ structLPC_Frame#nCoefficients.) <<=cxx . . $ `operator<<=`(adea042513329390). fcxx . . $ constvectorview#constvectorview(eac9d6ec4c4bfecd). -> acxx . . $ structLPC_Frame#a..getcxx . . $ autovector#get(e8d1da7fe68a6585).();
71 }
72 return resultcxx . . $ automatrix#automatrix(a69681c49ef9c9eb).;
73 }
74
75 /******************* Frames ************************************************/
76
77 void LPC_Frame_initcxx . . $ LPC_Frame_init(36b24d3ac8bf631d). (LPC_Framecxx . . $ LPC_Frame# me, integercxx . . $ integer# nCoefficients);
78
79 #endif /* _LPC_h_ */