Файл “Functions.H”
#include <iostream>
#include <math.h>
#include <stdio.h>
#include <vector>
#include <string>
#include <fstream>
#include <windows.h>
#pragma once
#include "Functions.h"
#define _USE_MATH_DEFINES // for math.h functions
#define N 20000
#define int16 int_least16_t
using namespace std;
void AppendToTime(int16 n, double dt, float tn, vector<float>& t); // Declaration array of time
void U_in(int16 n, vector<float>& t, vector<float>& Uvx); // Declaration array of input voltage
void U_out(int16 n, vector<float>& Uvx, vector<float>& Uvix); // Declaration array of output voltage
void PrintTable(int16 n, vector<float>& t, vector<float>& Uvx, vector<float>& Uvix); //Declaration tableprint function
void Title(void); //Declaration function to print title on the screen
void VectorToFile(vector<float> vector_file, string name, int n); //Declaration function to write vector values to file
void findParam2(vector<float>& t, vector<float>& Uvx, vector<float>& Uvix, double dt, float tn);
void findParam(vector<float>& t, vector<float>& Uvx, vector<float>& Uvix, double dt, float tn);
double ImpulseDuration(vector<float> signal, double dt, int16 n);
void BuildGraph(); //Build a graph with wxMaxima by written files
Файл “Zast.txt”
Организация проекта
Скриншоты работы программы
Примеры записанных в файл данных
Файл “TimeArray.txt”
10
11.1667
12.3333
13.5
14.6667
15.8333
17
18.1667
19.3333
20.5
21.6667
22.8333
24
25.1667
26.3333
27.5
28.6667
29.8333
31
32.1667
33.3333
34.5
35.6667
36.8333
38
39.1667
40.3333
41.5
42.6667
43.8333
45
46.1667
47.3333
48.5
49.6667
50.8333
52
53.1667
54.3333
55.5
56.6667
57.8333
59
60.1667
61.3333
62.5
63.6667
64.8333
66
67.1667
68.3333
69.5
70.6667
71.8333
73
74.1667
75.3333
76.5
77.6667
78.8333
Файл “Uvx_Array.txt”
0
0
0
0
0
0
0
0
0
0.625
2.08333
3.54166
5
6.45833
7.91667
9.375
10.8333
12.2917
13.75
15.2083
16.6667
18.125
19.5833
21.0417
22.5
23.9583
25.4167
26.875
28.3333
29.7917
31.25
32.7083
34.1667
35.625
37.0833
38.5417
40
41.4583
42.9167
44.375
45.8333
47.2917
48.75
50
50
50
50
50
50
50
50
50
46.6667
40.8334
35
29.1667
23.3334
17.5
11.6667
5.83336
Файл “Uvix_Array.txt”
10
10
10
10
10
10
10
10
10
10.3125
11.0417
11.7708
12.5
13.2292
13.9583
14.6875
37.0833
40.7292
44.375
48.0208
51.6667
55.3125
58.9583
62.6042
66.25
69.8958
73.5417
77.1875
80.8333
84.4792
75.625
76.3542
77.0833
77.8125
78.5417
79.2708
80
80.7292
81.4583
82.1875
82.9167
83.6458
84.375
85
85
85
85
85
85
85
85
85
83.3333
80.4167
77.5
82.9167
68.3334
53.75
39.1667
12.9167
Примеры построения графика по записанным файлам с помощью wxMaxima