ssa
97 строк · 2.7 Кб
1package periodogram_test2
3// Входные данные для длины окна = 32
4func Data32(N int) ([]float64, []float64, []float64) {5
6// Окно Блэкмана-Харриса7w32 := make([]float64, N)8w32[0] = 0.02342000000000009w32[1] = 0.020079620856794910w32[2] = 0.011998651606123511w32[3] = 0.0045385633721817112w32[4] = 0.0052178226101618613w32[5] = 0.021949523519208814w32[6] = 0.061198547824683015w32[7] = 0.12647458598788116w32[8] = 0.21747000000000017w32[9] = 0.32997401330573018w32[10] = 0.45650136008324619w32[11] = 0.58741944583171120w32[12] = 0.71228217738983821w32[13] = 0.82109246727689822w32[14] = 0.90530144048594723w32[15] = 0.95847177984959424w32[16] = 0.97664000000000025w32[17] = 0.95847177984959426w32[18] = 0.90530144048594727w32[19] = 0.82109246727689828w32[20] = 0.71228217738983829w32[21] = 0.58741944583171230w32[22] = 0.45650136008324731w32[23] = 0.32997401330573032w32[24] = 0.21747000000000033w32[25] = 0.12647458598788134w32[26] = 0.061198547824683035w32[27] = 0.021949523519208936w32[28] = 0.0052178226101619037w32[29] = 0.0045385633721816838w32[30] = 0.011998651606123439w32[31] = 0.020079620856794940
41// Входной сигнал42x32 := make([]float64, N)43x32[0] = 1.0975404049994144x32[1] = 0.80464718618595745x32[2] = 0.097540404999409646x32[3] = -0.60956637618713847x32[4] = -0.90245959500059148x32[5] = -0.60956637618713849x32[6] = 0.097540404999409350x32[7] = 0.80464718618595751x32[8] = 1.0975404049994152x32[9] = 0.80464718618595753x32[10] = 0.097540404999409854x32[11] = -0.60956637618713755x32[12] = -0.90245959500059156x32[13] = -0.60956637618713857x32[14] = 0.097540404999409158x32[15] = 0.80464718618595659x32[16] = 1.0975404049994160x32[17] = 0.80464718618595761x32[18] = 0.097540404999410162x32[19] = -0.60956637618713763x32[20] = -0.90245959500059164x32[21] = -0.60956637618713865x32[22] = 0.097540404999407166x32[23] = 0.80464718618595667x32[24] = 1.0975404049994168x32[25] = 0.80464718618595769x32[26] = 0.097540404999408570x32[27] = -0.60956637618713771x32[28] = -0.90245959500059172x32[29] = -0.60956637618713873x32[30] = 0.097540404999406874x32[31] = 0.80464718618595675
76// Результат выполнения77rez32 := make([]float64, N/2+1)78rez32[0] = 0.19707918466885979rez32[1] = 0.16720774742780380rez32[2] = 0.11941495430565981rez32[3] = 0.57283211778747282rez32[4] = 1.2704743964581083rez32[5] = 0.58840691345567084rez32[6] = 0.049258760435640585rez32[7] = 0.00033667261480094086rez32[8] = 1.71105942505116e-3287rez32[9] = 2.50134060820484e-3288rez32[10] = 1.26250044383115e-3289rez32[11] = 1.52094171115659e-3290rez32[12] = 2.20536548117705e-3191rez32[13] = 2.30042433812434e-3192rez32[14] = 7.80670862679593e-3293rez32[15] = 1.50014758619937e-3294rez32[16] = 4.65788399041705e-3295
96return x32, w32, rez3297}
98