Skip to content

Commit a614830

Browse files
authored
Merge pull request #206 from Infarh/dev
v0.0.14.2 - Обновление версий пакетов
2 parents 46c16e6 + 7848708 commit a614830

16 files changed

Lines changed: 232 additions & 214 deletions

.github/copilot-instructions.md

Lines changed: 15 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,15 @@
1+
Всегда отвечай мне используя русский язык.
2+
Всегда пиши комментарии в коде на русском языке.
3+
Комментарии к классам, структурам делегатам и перечислениям, а также к их членам всегда пиши в системном виде.
4+
При написании комментариев (ели они короткие) в коде предпочитай размещение комментария в конце той же строке, что и сам комментируемый код.
5+
Старайся избегать тривиальных комментариев.
6+
При герерации кода старайся минимизировать количество фигурных скобок.
7+
При генерации кода используй самые современные виды синтаксических конструкций языка.
8+
Всегда старайся минимизировтаь размер кода если не запрошено иное.
9+
Используй стиль именования локальных переменных snake_case.
10+
Используй стиль именования входных переменных методов PascalCase.
11+
Используй стиль именования полей классов _PascalCase для нестатических переменных и __PascalCase для статических переменных.
12+
Ппредпочитай английский язык при именовании переменных, методов, классов и прочих сущностей.
13+
При инициализации массивов, списков и словарей используй выражения инициализации массивов.
14+
При объявлении переменных предпочитай использовать ключевое слово var.
15+
При написании системных комментариев старайся писать их компактно в одну строку, если длина текста небольшая.

MathCore.DSP.sln

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -23,6 +23,11 @@ Project("{9A19103F-16F7-4668-BE54-9A1E7A4F7556}") = "WpfTest", "Tests\WpfTest\Wp
2323
EndProject
2424
Project("{9A19103F-16F7-4668-BE54-9A1E7A4F7556}") = "Benchmarks", "Tests\Benchmarks\Benchmarks.csproj", "{6E552E38-1B68-4DBD-9DAB-03FF2A0A4F06}"
2525
EndProject
26+
Project("{2150E333-8FDC-42A3-9474-1A3956D46DE8}") = ".Service", ".Service", "{2507A7F8-E9DD-CD81-FF78-9340A71A364C}"
27+
ProjectSection(SolutionItems) = preProject
28+
.github\copilot-instructions.md = .github\copilot-instructions.md
29+
EndProjectSection
30+
EndProject
2631
Global
2732
GlobalSection(SolutionConfigurationPlatforms) = preSolution
2833
Debug|Any CPU = Debug|Any CPU

MathCore.DSP.sln.DotSettings

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -8,6 +8,7 @@
88
<s:String x:Key="/Default/CodeStyle/Naming/CSharpNaming/Abbreviations/=FT/@EntryIndexedValue">FT</s:String>
99
<s:String x:Key="/Default/CodeStyle/Naming/CSharpNaming/Abbreviations/=II/@EntryIndexedValue">II</s:String>
1010
<s:String x:Key="/Default/CodeStyle/Naming/CSharpNaming/Abbreviations/=PNG/@EntryIndexedValue">PNG</s:String>
11+
<s:String x:Key="/Default/CodeStyle/Naming/CSharpNaming/Abbreviations/=RC/@EntryIndexedValue">RC</s:String>
1112
<s:Boolean x:Key="/Default/UserDictionary/Words/=ALGLIB/@EntryIndexedValue">True</s:Boolean>
1213
<s:Boolean x:Key="/Default/UserDictionary/Words/=arcch/@EntryIndexedValue">True</s:Boolean>
1314
<s:Boolean x:Key="/Default/UserDictionary/Words/=arcsh/@EntryIndexedValue">True</s:Boolean>
Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,5 @@
11
namespace MathCore.DSP.Filters.Builders;
22

3+
/// <summary>Построитель полосно-пропускающего фильтра</summary>
4+
/// <param name="dt">Период дискретизации</param>
35
public readonly record struct BandPassBuilder(double dt);
Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,5 @@
11
namespace MathCore.DSP.Filters.Builders;
22

3+
/// <summary>Построитель полосно-задерживающего фильтра</summary>
4+
/// <param name="dt">Период дискретизации</param>
35
public readonly record struct BandStopBuilder(double dt);
Lines changed: 37 additions & 65 deletions
Original file line numberDiff line numberDiff line change
@@ -1,81 +1,53 @@
11
namespace MathCore.DSP.Filters.Builders;
22

3+
/// <summary>Построитель фильтра Батерворта</summary>
34
public readonly ref struct ButterworthBuilder
45
{
6+
/// <summary>Тип пропускания полосы частот</summary>
57
public FrequencyPassType PassType { get; init; }
68

9+
/// <summary>Период дискретизации фильтра</summary>
710
public double dt { get; init; }
811

12+
/// <summary>Частота дискретизации фильтра</summary>
913
public double fd { get => 1 / dt; init => dt = 1 / value; }
1014

15+
/// <summary>Фильтр нижних частот</summary>
1116
public ButterworthBuilder LowPass => this with { PassType = FrequencyPassType.LowPass };
17+
18+
/// <summary>Фильтр верхних частот</summary>
1219
public ButterworthBuilder HighPass => this with { PassType = FrequencyPassType.HighPass };
20+
21+
/// <summary>Полосопропускающий фильтр</summary>
1322
public ButterworthBuilder BandPass => this with { PassType = FrequencyPassType.BandPass };
23+
24+
/// <summary>Полосозадерживающий фильтр</summary>
1425
public ButterworthBuilder BandStop => this with { PassType = FrequencyPassType.BandStop };
1526

16-
private readonly double? _PassFrequency;
17-
private readonly double? _StopFrequency;
18-
private readonly double? _PassHighFrequency;
19-
private readonly double? _StopHighFrequency;
20-
21-
private readonly int? _Order;
22-
23-
private readonly double? _Gp;
24-
private readonly double? _Gs;
25-
private readonly double? _Rp;
26-
private readonly double? _Rs;
27-
28-
public double? PassFrequency
29-
{
30-
get => _PassFrequency;
31-
init => _PassFrequency = value;
32-
}
33-
34-
public double? StopFrequency
35-
{
36-
get => _StopFrequency;
37-
init => _StopFrequency = value;
38-
}
39-
40-
public double? PassHighFrequency
41-
{
42-
get => _PassHighFrequency;
43-
init => _PassHighFrequency = value;
44-
}
45-
46-
public double? StopHighFrequency
47-
{
48-
get => _StopHighFrequency;
49-
init => _StopHighFrequency = value;
50-
}
51-
52-
public int? Order
53-
{
54-
get => _Order;
55-
init => _Order = value;
56-
}
57-
58-
public double? Gp
59-
{
60-
get => _Gp;
61-
init => _Gp = value;
62-
}
63-
64-
public double? Gs
65-
{
66-
get => _Gs;
67-
init => _Gs = value;
68-
}
69-
70-
public double? Rp
71-
{
72-
get => _Rp;
73-
init => _Rp = value;
74-
}
75-
76-
public double? Rs
77-
{
78-
get => _Rs;
79-
init => _Rs = value;
80-
}
27+
/// <summary>Частота пропускания</summary>
28+
public double? PassFrequency { get; init; }
29+
30+
/// <summary>Частота заграждения</summary>
31+
public double? StopFrequency { get; init; }
32+
33+
/// <summary>Верхняя частота пропускания</summary>
34+
public double? PassHighFrequency { get; init; }
35+
36+
/// <summary>Верхняя частота заграждения</summary>
37+
public double? StopHighFrequency { get; init; }
38+
39+
/// <summary>Порядок фильтра</summary>
40+
public int? Order { get; init; }
41+
42+
/// <summary>Коэффициент пропускания</summary>
43+
public double? Gp { get; init; }
44+
45+
/// <summary>Коэффициент заграждения</summary>
46+
public double? Gs { get; init; }
47+
48+
/// <summary>Неравномерность в полосе пропускания</summary>
49+
public double? Rp { get; init; }
50+
51+
/// <summary>Неравномерность в полосе заграждения</summary>
52+
public double? Rs { get; init; }
8153
}
Lines changed: 38 additions & 65 deletions
Original file line numberDiff line numberDiff line change
@@ -1,83 +1,56 @@
11
namespace MathCore.DSP.Filters.Builders;
22

3+
/// <summary>Строитель фильтров Чебышева</summary>
34
public readonly ref struct ChebyshevBuilder
45
{
6+
/// <summary>Тип пропускания полосы частот</summary>
57
public FrequencyPassType PassType { get; init; }
68

9+
/// <summary>Период дискретизации</summary>
710
public double dt { get; init; }
811

12+
/// <summary>Частота дискретизации</summary>
913
public double fd { get => 1 / dt; init => dt = 1 / value; }
1014

15+
/// <summary>Тип фильтра Чебышева</summary>
1116
public ChebyshevType Type { get; init; }
1217

18+
/// <summary>ФНЧ</summary>
1319
public ChebyshevBuilder LowPass => this with { PassType = FrequencyPassType.LowPass };
20+
21+
/// <summary>ФВЧ</summary>
1422
public ChebyshevBuilder HighPass => this with { PassType = FrequencyPassType.HighPass };
23+
24+
/// <summary>ППФ</summary>
1525
public ChebyshevBuilder BandPass => this with { PassType = FrequencyPassType.BandPass };
26+
27+
/// <summary>ПЗФ</summary>
1628
public ChebyshevBuilder BandStop => this with { PassType = FrequencyPassType.BandStop };
1729

18-
private readonly double? _PassFrequency;
19-
private readonly double? _StopFrequency;
20-
private readonly double? _PassHighFrequency;
21-
private readonly double? _StopHighFrequency;
22-
23-
private readonly int? _Order;
24-
25-
private readonly double? _Gp;
26-
private readonly double? _Gs;
27-
private readonly double? _Rp;
28-
private readonly double? _Rs;
29-
30-
public double? PassFrequency
31-
{
32-
get => _PassFrequency;
33-
init => _PassFrequency = value;
34-
}
35-
36-
public double? StopFrequency
37-
{
38-
get => _StopFrequency;
39-
init => _StopFrequency = value;
40-
}
41-
42-
public double? PassHighFrequency
43-
{
44-
get => _PassHighFrequency;
45-
init => _PassHighFrequency = value;
46-
}
47-
48-
public double? StopHighFrequency
49-
{
50-
get => _StopHighFrequency;
51-
init => _StopHighFrequency = value;
52-
}
53-
54-
public int? Order
55-
{
56-
get => _Order;
57-
init => _Order = value;
58-
}
59-
60-
public double? Gp
61-
{
62-
get => _Gp;
63-
init => _Gp = value;
64-
}
65-
66-
public double? Gs
67-
{
68-
get => _Gs;
69-
init => _Gs = value;
70-
}
71-
72-
public double? Rp
73-
{
74-
get => _Rp;
75-
init => _Rp = value;
76-
}
77-
78-
public double? Rs
79-
{
80-
get => _Rs;
81-
init => _Rs = value;
82-
}
30+
/// <summary>Частота пропускания</summary>
31+
public double? PassFrequency { get; init; }
32+
33+
/// <summary>Частота заграждения</summary>
34+
public double? StopFrequency { get; init; }
35+
36+
/// <summary>Верхняя частота пропускания</summary>
37+
public double? PassHighFrequency { get; init; }
38+
39+
/// <summary>Верхняя частота заграждения</summary>
40+
public double? StopHighFrequency { get; init; }
41+
42+
/// <summary>Порядок фильтра</summary>
43+
public int? Order { get; init; }
44+
45+
/// <summary>Коэффициент передачи в полосе пропускания</summary>
46+
public double? Gp { get; init; }
47+
48+
/// <summary>Коэффициент передачи в полосе заграждения</summary>
49+
public double? Gs { get; init; }
50+
51+
/// <summary>Неравномерность в полосе пропускания (дБ)</summary>
52+
public double? Rp { get; init; }
53+
54+
/// <summary>Затухание в полосе заграждения (дБ)</summary>
55+
public double? Rs { get; init; }
8356
}

0 commit comments

Comments
 (0)