kopia lustrzana https://github.com/Dsplib/libdspl-2.0
fixed VS projects
rodzic
b4cb9914ed
commit
c7fef21597
|
@ -1,4 +1,4 @@
|
|||
# Doxyfile 1.8.13
|
||||
# Doxyfile 1.8.14
|
||||
|
||||
# This file describes the settings to be used by the documentation system
|
||||
# doxygen (www.doxygen.org) for a project.
|
||||
|
@ -20,8 +20,8 @@
|
|||
# This tag specifies the encoding used for all characters in the config file
|
||||
# that follow. The default is UTF-8 which is also the encoding used for all text
|
||||
# before the first occurrence of this tag. Doxygen uses libiconv (or the iconv
|
||||
# built into libc) for the transcoding. See http://www.gnu.org/software/libiconv
|
||||
# for the list of possible encodings.
|
||||
# built into libc) for the transcoding. See
|
||||
# https://www.gnu.org/software/libiconv/ for the list of possible encodings.
|
||||
# The default value is: UTF-8.
|
||||
|
||||
DOXYFILE_ENCODING = UTF-8
|
||||
|
@ -226,7 +226,7 @@ SEPARATE_MEMBER_PAGES = NO
|
|||
# uses this value to replace tabs by spaces in code fragments.
|
||||
# Minimum value: 1, maximum value: 16, default value: 4.
|
||||
|
||||
TAB_SIZE = 4
|
||||
TAB_SIZE = 8
|
||||
|
||||
# This tag can be used to specify a number of aliases that act as commands in
|
||||
# the documentation. An alias has the form:
|
||||
|
@ -337,7 +337,7 @@ BUILTIN_STL_SUPPORT = NO
|
|||
CPP_CLI_SUPPORT = NO
|
||||
|
||||
# Set the SIP_SUPPORT tag to YES if your project consists of sip (see:
|
||||
# http://www.riverbankcomputing.co.uk/software/sip/intro) sources only. Doxygen
|
||||
# https://www.riverbankcomputing.com/software/sip/intro) sources only. Doxygen
|
||||
# will parse them like normal C++ but will assume all classes use public instead
|
||||
# of private inheritance when no explicit protection keyword is present.
|
||||
# The default value is: NO.
|
||||
|
@ -708,7 +708,7 @@ LAYOUT_FILE =
|
|||
# The CITE_BIB_FILES tag can be used to specify one or more bib files containing
|
||||
# the reference definitions. This must be a list of .bib files. The .bib
|
||||
# extension is automatically appended if omitted. This requires the bibtex tool
|
||||
# to be installed. See also http://en.wikipedia.org/wiki/BibTeX for more info.
|
||||
# to be installed. See also https://en.wikipedia.org/wiki/BibTeX for more info.
|
||||
# For LaTeX the style of the bibliography can be controlled using
|
||||
# LATEX_BIB_STYLE. To use this feature you need bibtex and perl available in the
|
||||
# search path. See also \cite for info how to create references.
|
||||
|
@ -801,7 +801,7 @@ INPUT = ru \
|
|||
# This tag can be used to specify the character encoding of the source files
|
||||
# that doxygen parses. Internally doxygen uses the UTF-8 encoding. Doxygen uses
|
||||
# libiconv (or the iconv built into libc) for the transcoding. See the libiconv
|
||||
# documentation (see: http://www.gnu.org/software/libiconv) for the list of
|
||||
# documentation (see: https://www.gnu.org/software/libiconv/) for the list of
|
||||
# possible encodings.
|
||||
# The default value is: UTF-8.
|
||||
|
||||
|
@ -1005,7 +1005,7 @@ USE_MDFILE_AS_MAINPAGE =
|
|||
# also VERBATIM_HEADERS is set to NO.
|
||||
# The default value is: NO.
|
||||
|
||||
SOURCE_BROWSER = NO
|
||||
SOURCE_BROWSER = YES
|
||||
|
||||
# Setting the INLINE_SOURCES tag to YES will include the body of functions,
|
||||
# classes and enums directly into the documentation.
|
||||
|
@ -1024,7 +1024,7 @@ STRIP_CODE_COMMENTS = YES
|
|||
# function all documented functions referencing it will be listed.
|
||||
# The default value is: NO.
|
||||
|
||||
REFERENCED_BY_RELATION = NO
|
||||
REFERENCED_BY_RELATION = YES
|
||||
|
||||
# If the REFERENCES_RELATION tag is set to YES then for each documented function
|
||||
# all documented entities called/used by that function will be listed.
|
||||
|
@ -1053,7 +1053,7 @@ SOURCE_TOOLTIPS = YES
|
|||
# If the USE_HTAGS tag is set to YES then the references to source code will
|
||||
# point to the HTML generated by the htags(1) tool instead of doxygen built-in
|
||||
# source browser. The htags tool is part of GNU's global source tagging system
|
||||
# (see http://www.gnu.org/software/global/global.html). You will need version
|
||||
# (see https://www.gnu.org/software/global/global.html). You will need version
|
||||
# 4.8.6 or higher.
|
||||
#
|
||||
# To use it do the following:
|
||||
|
@ -1099,6 +1099,17 @@ CLANG_ASSISTED_PARSING = NO
|
|||
|
||||
CLANG_OPTIONS =
|
||||
|
||||
# If clang assisted parsing is enabled you can provide the clang parser with the
|
||||
# path to the compilation database (see:
|
||||
# http://clang.llvm.org/docs/HowToSetupToolingForLLVM.html) used when the files
|
||||
# were built. This is equivalent to specifying the "-p" option to a clang tool,
|
||||
# such as clang-check. These options will then be pased to the parser.
|
||||
# Note: The availability of this option depends on whether or not doxygen was
|
||||
# generated with the -Duse-libclang=ON option for CMake.
|
||||
# The default value is: 0.
|
||||
|
||||
CLANG_COMPILATION_DATABASE_PATH= 0
|
||||
|
||||
#---------------------------------------------------------------------------
|
||||
# Configuration options related to the alphabetical class index
|
||||
#---------------------------------------------------------------------------
|
||||
|
@ -1217,7 +1228,7 @@ HTML_EXTRA_FILES =
|
|||
# The HTML_COLORSTYLE_HUE tag controls the color of the HTML output. Doxygen
|
||||
# will adjust the colors in the style sheet and background images according to
|
||||
# this color. Hue is specified as an angle on a colorwheel, see
|
||||
# http://en.wikipedia.org/wiki/Hue for more information. For instance the value
|
||||
# https://en.wikipedia.org/wiki/Hue for more information. For instance the value
|
||||
# 0 represents red, 60 is yellow, 120 is green, 180 is cyan, 240 is blue, 300
|
||||
# purple, and 360 is red again.
|
||||
# Minimum value: 0, maximum value: 359, default value: 220.
|
||||
|
@ -1253,6 +1264,17 @@ HTML_COLORSTYLE_GAMMA = 80
|
|||
|
||||
HTML_TIMESTAMP = YES
|
||||
|
||||
# If the HTML_DYNAMIC_MENUS tag is set to YES then the generated HTML
|
||||
# documentation will contain a main index with vertical navigation menus that
|
||||
# are dynamically created via Javascript. If disabled, the navigation index will
|
||||
# consists of multiple levels of tabs that are statically embedded in every HTML
|
||||
# page. Disable this option to support browsers that do not have Javascript,
|
||||
# like the Qt help browser.
|
||||
# The default value is: YES.
|
||||
# This tag requires that the tag GENERATE_HTML is set to YES.
|
||||
|
||||
HTML_DYNAMIC_MENUS = YES
|
||||
|
||||
# If the HTML_DYNAMIC_SECTIONS tag is set to YES then the generated HTML
|
||||
# documentation will contain sections that can be hidden and shown after the
|
||||
# page has loaded.
|
||||
|
@ -1276,12 +1298,12 @@ HTML_INDEX_NUM_ENTRIES = 100
|
|||
|
||||
# If the GENERATE_DOCSET tag is set to YES, additional index files will be
|
||||
# generated that can be used as input for Apple's Xcode 3 integrated development
|
||||
# environment (see: http://developer.apple.com/tools/xcode/), introduced with
|
||||
# environment (see: https://developer.apple.com/tools/xcode/), introduced with
|
||||
# OSX 10.5 (Leopard). To create a documentation set, doxygen will generate a
|
||||
# Makefile in the HTML output directory. Running make will produce the docset in
|
||||
# that directory and running make install will install the docset in
|
||||
# ~/Library/Developer/Shared/Documentation/DocSets so that Xcode will find it at
|
||||
# startup. See http://developer.apple.com/tools/creatingdocsetswithdoxygen.html
|
||||
# startup. See https://developer.apple.com/tools/creatingdocsetswithdoxygen.html
|
||||
# for more information.
|
||||
# The default value is: NO.
|
||||
# This tag requires that the tag GENERATE_HTML is set to YES.
|
||||
|
@ -1397,7 +1419,7 @@ QCH_FILE =
|
|||
|
||||
# The QHP_NAMESPACE tag specifies the namespace to use when generating Qt Help
|
||||
# Project output. For more information please see Qt Help Project / Namespace
|
||||
# (see: http://qt-project.org/doc/qt-4.8/qthelpproject.html#namespace).
|
||||
# (see: http://doc.qt.io/qt-4.8/qthelpproject.html#namespace).
|
||||
# The default value is: org.doxygen.Project.
|
||||
# This tag requires that the tag GENERATE_QHP is set to YES.
|
||||
|
||||
|
@ -1405,8 +1427,7 @@ QHP_NAMESPACE = org.doxygen.Project
|
|||
|
||||
# The QHP_VIRTUAL_FOLDER tag specifies the namespace to use when generating Qt
|
||||
# Help Project output. For more information please see Qt Help Project / Virtual
|
||||
# Folders (see: http://qt-project.org/doc/qt-4.8/qthelpproject.html#virtual-
|
||||
# folders).
|
||||
# Folders (see: http://doc.qt.io/qt-4.8/qthelpproject.html#virtual-folders).
|
||||
# The default value is: doc.
|
||||
# This tag requires that the tag GENERATE_QHP is set to YES.
|
||||
|
||||
|
@ -1414,23 +1435,21 @@ QHP_VIRTUAL_FOLDER = doc
|
|||
|
||||
# If the QHP_CUST_FILTER_NAME tag is set, it specifies the name of a custom
|
||||
# filter to add. For more information please see Qt Help Project / Custom
|
||||
# Filters (see: http://qt-project.org/doc/qt-4.8/qthelpproject.html#custom-
|
||||
# filters).
|
||||
# Filters (see: http://doc.qt.io/qt-4.8/qthelpproject.html#custom-filters).
|
||||
# This tag requires that the tag GENERATE_QHP is set to YES.
|
||||
|
||||
QHP_CUST_FILTER_NAME =
|
||||
|
||||
# The QHP_CUST_FILTER_ATTRS tag specifies the list of the attributes of the
|
||||
# custom filter to add. For more information please see Qt Help Project / Custom
|
||||
# Filters (see: http://qt-project.org/doc/qt-4.8/qthelpproject.html#custom-
|
||||
# filters).
|
||||
# Filters (see: http://doc.qt.io/qt-4.8/qthelpproject.html#custom-filters).
|
||||
# This tag requires that the tag GENERATE_QHP is set to YES.
|
||||
|
||||
QHP_CUST_FILTER_ATTRS =
|
||||
|
||||
# The QHP_SECT_FILTER_ATTRS tag specifies the list of the attributes this
|
||||
# project's filter section matches. Qt Help Project / Filter Attributes (see:
|
||||
# http://qt-project.org/doc/qt-4.8/qthelpproject.html#filter-attributes).
|
||||
# http://doc.qt.io/qt-4.8/qthelpproject.html#filter-attributes).
|
||||
# This tag requires that the tag GENERATE_QHP is set to YES.
|
||||
|
||||
QHP_SECT_FILTER_ATTRS =
|
||||
|
@ -1523,7 +1542,7 @@ EXT_LINKS_IN_WINDOW = NO
|
|||
|
||||
FORMULA_FONTSIZE = 14
|
||||
|
||||
# Use the FORMULA_TRANPARENT tag to determine whether or not the images
|
||||
# Use the FORMULA_TRANSPARENT tag to determine whether or not the images
|
||||
# generated for formulas are transparent PNGs. Transparent PNGs are not
|
||||
# supported properly for IE 6.0, but are supported on all modern browsers.
|
||||
#
|
||||
|
@ -1535,7 +1554,7 @@ FORMULA_FONTSIZE = 14
|
|||
FORMULA_TRANSPARENT = YES
|
||||
|
||||
# Enable the USE_MATHJAX option to render LaTeX formulas using MathJax (see
|
||||
# http://www.mathjax.org) which uses client side Javascript for the rendering
|
||||
# https://www.mathjax.org) which uses client side Javascript for the rendering
|
||||
# instead of using pre-rendered bitmaps. Use this if you do not have LaTeX
|
||||
# installed or if you want to formulas look prettier in the HTML output. When
|
||||
# enabled you may also need to install MathJax separately and configure the path
|
||||
|
@ -1562,7 +1581,7 @@ MATHJAX_FORMAT = HTML-CSS
|
|||
# MATHJAX_RELPATH should be ../mathjax. The default value points to the MathJax
|
||||
# Content Delivery Network so you can quickly see the result without installing
|
||||
# MathJax. However, it is strongly recommended to install a local copy of
|
||||
# MathJax from http://www.mathjax.org before deployment.
|
||||
# MathJax from https://www.mathjax.org before deployment.
|
||||
# The default value is: http://cdn.mathjax.org/mathjax/latest.
|
||||
# This tag requires that the tag USE_MATHJAX is set to YES.
|
||||
|
||||
|
@ -1624,7 +1643,7 @@ SERVER_BASED_SEARCH = NO
|
|||
#
|
||||
# Doxygen ships with an example indexer (doxyindexer) and search engine
|
||||
# (doxysearch.cgi) which are based on the open source search engine library
|
||||
# Xapian (see: http://xapian.org/).
|
||||
# Xapian (see: https://xapian.org/).
|
||||
#
|
||||
# See the section "External Indexing and Searching" for details.
|
||||
# The default value is: NO.
|
||||
|
@ -1637,7 +1656,7 @@ EXTERNAL_SEARCH = NO
|
|||
#
|
||||
# Doxygen ships with an example indexer (doxyindexer) and search engine
|
||||
# (doxysearch.cgi) which are based on the open source search engine library
|
||||
# Xapian (see: http://xapian.org/). See the section "External Indexing and
|
||||
# Xapian (see: https://xapian.org/). See the section "External Indexing and
|
||||
# Searching" for details.
|
||||
# This tag requires that the tag SEARCHENGINE is set to YES.
|
||||
|
||||
|
@ -1824,7 +1843,7 @@ LATEX_SOURCE_CODE = NO
|
|||
|
||||
# The LATEX_BIB_STYLE tag can be used to specify the style to use for the
|
||||
# bibliography, e.g. plainnat, or ieeetr. See
|
||||
# http://en.wikipedia.org/wiki/BibTeX and \cite for more info.
|
||||
# https://en.wikipedia.org/wiki/BibTeX and \cite for more info.
|
||||
# The default value is: plain.
|
||||
# This tag requires that the tag GENERATE_LATEX is set to YES.
|
||||
|
||||
|
@ -2007,9 +2026,9 @@ DOCBOOK_PROGRAMLISTING = NO
|
|||
#---------------------------------------------------------------------------
|
||||
|
||||
# If the GENERATE_AUTOGEN_DEF tag is set to YES, doxygen will generate an
|
||||
# AutoGen Definitions (see http://autogen.sf.net) file that captures the
|
||||
# structure of the code including all documentation. Note that this feature is
|
||||
# still experimental and incomplete at the moment.
|
||||
# AutoGen Definitions (see http://autogen.sourceforge.net/) file that captures
|
||||
# the structure of the code including all documentation. Note that this feature
|
||||
# is still experimental and incomplete at the moment.
|
||||
# The default value is: NO.
|
||||
|
||||
GENERATE_AUTOGEN_DEF = NO
|
||||
|
@ -2224,7 +2243,7 @@ HIDE_UNDOC_RELATIONS = NO
|
|||
# http://www.graphviz.org/), a graph visualization toolkit from AT&T and Lucent
|
||||
# Bell Labs. The other options in this section have no effect if this option is
|
||||
# set to NO
|
||||
# The default value is: YES.
|
||||
# The default value is: NO.
|
||||
|
||||
HAVE_DOT = NO
|
||||
|
||||
|
@ -2380,9 +2399,7 @@ DIRECTORY_GRAPH = YES
|
|||
# Note: If you choose svg you need to set HTML_FILE_EXTENSION to xhtml in order
|
||||
# to make the SVG files visible in IE 9+ (other browsers do not have this
|
||||
# requirement).
|
||||
# Possible values are: png, png:cairo, png:cairo:cairo, png:cairo:gd, png:gd,
|
||||
# png:gd:gd, jpg, jpg:cairo, jpg:cairo:gd, jpg:gd, jpg:gd:gd, gif, gif:cairo,
|
||||
# gif:cairo:gd, gif:gd, gif:gd:gd, svg, png:gd, png:gd:gd, png:cairo,
|
||||
# Possible values are: png, jpg, gif, svg, png:gd, png:gd:gd, png:cairo,
|
||||
# png:cairo:gd, png:cairo:cairo, png:cairo:gdiplus, png:gdiplus and
|
||||
# png:gdiplus:gdiplus.
|
||||
# The default value is: png.
|
||||
|
|
Plik binarny nie jest wyświetlany.
Po Szerokość: | Wysokość: | Rozmiar: 60 KiB |
Plik binarny nie jest wyświetlany.
Po Szerokość: | Wysokość: | Rozmiar: 63 KiB |
Plik binarny nie jest wyświetlany.
Po Szerokość: | Wysokość: | Rozmiar: 34 KiB |
Plik binarny nie jest wyświetlany.
Po Szerokość: | Wysokość: | Rozmiar: 44 KiB |
Plik binarny nie jest wyświetlany.
Po Szerokość: | Wysokość: | Rozmiar: 70 KiB |
|
@ -147,14 +147,8 @@ butter_ap_test_tau.txt ГВЗ фильтра
|
|||
Кроме того программа GNUPLOT произведет построение следующих графиков
|
||||
по сохраненным в файлах данным:
|
||||
|
||||
АЧХ фильтра: `butter_ap_test_mag.png`
|
||||
\image html butter_ap_test_mag.png
|
||||
\image html butter_ap_test.png
|
||||
|
||||
ФЧХ фильтра: `butter_ap_test_phi.png`
|
||||
\image html butter_ap_test_phi.png
|
||||
|
||||
ГВЗ фильтра: `butter_ap_test_tau.png`
|
||||
\image html butter_ap_test_tau.png
|
||||
|
||||
\return
|
||||
`RES_OK` Параметры фильтра рассчитаны успешно.<BR>
|
||||
|
|
|
@ -182,14 +182,7 @@ cheby1_ap_test_tau.txt ГВЗ фильтра
|
|||
Кроме того программа GNUPLOT произведет построение следующих графиков
|
||||
по сохраненным в файлах данным:
|
||||
|
||||
АЧХ фильтра: `cheby1_ap_test_mag.png`
|
||||
\image html cheby1_ap_test_mag.png
|
||||
|
||||
ФЧХ фильтра: `cheby1_ap_test_phi.png`
|
||||
\image html cheby1_ap_test_phi.png
|
||||
|
||||
ГВЗ фильтра: `butter_ap_test_tau.png`
|
||||
\image html cheby1_ap_test_tau.png
|
||||
\image html cheby1_ap_test.png
|
||||
|
||||
|
||||
Скрипт GNUPLOT для построения графиков из текстовых файлов:
|
||||
|
|
|
@ -38,7 +38,7 @@ int DSPL_API concat(void* a, size_t na, void *b, size_t nb, void* c)
|
|||
if(c != a)
|
||||
memcpy(c, a, na);
|
||||
|
||||
memcpy(c+na, b, nb);
|
||||
memcpy((char*)c+na, b, nb);
|
||||
return RES_OK;
|
||||
}
|
||||
|
||||
|
|
|
@ -174,7 +174,7 @@ int fft_bit_reverse(complex_t* x, complex_t* y, int n, int p2)
|
|||
|
||||
unsigned int v, c;
|
||||
|
||||
for(v = 0; v < n; v++)
|
||||
for(v = 0; v < (unsigned int)n; v++)
|
||||
{
|
||||
c = (unsigned int)
|
||||
((rb_table[ v & 0xff] << 24) |
|
||||
|
|
|
@ -31,8 +31,8 @@ Print DSPL info
|
|||
void DSPL_API dspl_info()
|
||||
{
|
||||
printf("\n\n D S P L - 2.0\n");
|
||||
printf(" version 2.18.6.14\n");
|
||||
printf("\n Сopyright (C) 2015-2018\n");
|
||||
printf(" version 2.18.10.05\n");
|
||||
printf("\n Copyright (C) 2015-2018\n");
|
||||
printf(" Sergey Bakhurin www.dsplib.org\n\n");
|
||||
}
|
||||
|
||||
|
|
|
@ -65,7 +65,7 @@ int DSPL_API farrow_lagrange(double *s, int n, double p, double q, double frd, d
|
|||
k = 0;
|
||||
while(k < (*ny))
|
||||
{
|
||||
ind = floor(t)+1;
|
||||
ind = (int)floor(t)+1;
|
||||
x = t - (double)ind;
|
||||
ind-=2;
|
||||
if(ind < 0)
|
||||
|
@ -144,7 +144,7 @@ int DSPL_API farrow_spline(double *s, int n, double p, double q, double frd, dou
|
|||
k = 0;
|
||||
while(k < (*ny))
|
||||
{
|
||||
ind = floor(t)+1;
|
||||
ind = (int)floor(t)+1;
|
||||
x = t - (double)ind;
|
||||
ind-=2;
|
||||
if(ind < 0)
|
||||
|
|
|
@ -35,7 +35,7 @@ Rectangle pulse signal
|
|||
int DSPL_API signal_pimp(double* t, size_t n, double amp,
|
||||
double tau, double dt, double period, double* y)
|
||||
{
|
||||
int k;
|
||||
size_t k;
|
||||
double ll, lr, p2, tp;
|
||||
|
||||
if(!t || !y)
|
||||
|
@ -65,7 +65,7 @@ Saw periodic signal
|
|||
int DSPL_API signal_saw(double* t, size_t n, double amp,
|
||||
double dt, double period, double* y)
|
||||
{
|
||||
int k;
|
||||
size_t k;
|
||||
double p2, tp;
|
||||
|
||||
if(!t || !y)
|
||||
|
|
|
@ -3,12 +3,9 @@ Microsoft Visual Studio Solution File, Format Version 12.00
|
|||
# Visual Studio 15
|
||||
VisualStudioVersion = 15.0.27703.2042
|
||||
MinimumVisualStudioVersion = 10.0.40219.1
|
||||
Project("{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}") = "libdspl-2.0", "libdspl-2.0.vcxproj", "{B7A08A03-C9D7-49C8-89C5-15B0EB872A2E}"
|
||||
EndProject
|
||||
Project("{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}") = "test", "test.vcxproj", "{281E42D9-1F9F-4A4B-852D-AAD12291EBF1}"
|
||||
ProjectSection(ProjectDependencies) = postProject
|
||||
{B7A08A03-C9D7-49C8-89C5-15B0EB872A2E} = {B7A08A03-C9D7-49C8-89C5-15B0EB872A2E}
|
||||
EndProjectSection
|
||||
EndProject
|
||||
Project("{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}") = "libdspl-2.0", "libdspl-2.0.vcxproj", "{B7A08A03-C9D7-49C8-89C5-15B0EB872A2E}"
|
||||
EndProject
|
||||
Global
|
||||
GlobalSection(SolutionConfigurationPlatforms) = preSolution
|
||||
|
@ -18,14 +15,6 @@ Global
|
|||
Release|x86 = Release|x86
|
||||
EndGlobalSection
|
||||
GlobalSection(ProjectConfigurationPlatforms) = postSolution
|
||||
{B7A08A03-C9D7-49C8-89C5-15B0EB872A2E}.Debug|x64.ActiveCfg = Debug|x64
|
||||
{B7A08A03-C9D7-49C8-89C5-15B0EB872A2E}.Debug|x64.Build.0 = Debug|x64
|
||||
{B7A08A03-C9D7-49C8-89C5-15B0EB872A2E}.Debug|x86.ActiveCfg = Debug|Win32
|
||||
{B7A08A03-C9D7-49C8-89C5-15B0EB872A2E}.Debug|x86.Build.0 = Debug|Win32
|
||||
{B7A08A03-C9D7-49C8-89C5-15B0EB872A2E}.Release|x64.ActiveCfg = Release|x64
|
||||
{B7A08A03-C9D7-49C8-89C5-15B0EB872A2E}.Release|x64.Build.0 = Release|x64
|
||||
{B7A08A03-C9D7-49C8-89C5-15B0EB872A2E}.Release|x86.ActiveCfg = Release|Win32
|
||||
{B7A08A03-C9D7-49C8-89C5-15B0EB872A2E}.Release|x86.Build.0 = Release|Win32
|
||||
{281E42D9-1F9F-4A4B-852D-AAD12291EBF1}.Debug|x64.ActiveCfg = Debug|x64
|
||||
{281E42D9-1F9F-4A4B-852D-AAD12291EBF1}.Debug|x64.Build.0 = Debug|x64
|
||||
{281E42D9-1F9F-4A4B-852D-AAD12291EBF1}.Debug|x86.ActiveCfg = Debug|Win32
|
||||
|
@ -34,6 +23,14 @@ Global
|
|||
{281E42D9-1F9F-4A4B-852D-AAD12291EBF1}.Release|x64.Build.0 = Release|x64
|
||||
{281E42D9-1F9F-4A4B-852D-AAD12291EBF1}.Release|x86.ActiveCfg = Release|Win32
|
||||
{281E42D9-1F9F-4A4B-852D-AAD12291EBF1}.Release|x86.Build.0 = Release|Win32
|
||||
{B7A08A03-C9D7-49C8-89C5-15B0EB872A2E}.Debug|x64.ActiveCfg = Debug|x64
|
||||
{B7A08A03-C9D7-49C8-89C5-15B0EB872A2E}.Debug|x64.Build.0 = Debug|x64
|
||||
{B7A08A03-C9D7-49C8-89C5-15B0EB872A2E}.Debug|x86.ActiveCfg = Debug|Win32
|
||||
{B7A08A03-C9D7-49C8-89C5-15B0EB872A2E}.Debug|x86.Build.0 = Debug|Win32
|
||||
{B7A08A03-C9D7-49C8-89C5-15B0EB872A2E}.Release|x64.ActiveCfg = Release|x64
|
||||
{B7A08A03-C9D7-49C8-89C5-15B0EB872A2E}.Release|x64.Build.0 = Release|x64
|
||||
{B7A08A03-C9D7-49C8-89C5-15B0EB872A2E}.Release|x86.ActiveCfg = Release|Win32
|
||||
{B7A08A03-C9D7-49C8-89C5-15B0EB872A2E}.Release|x86.Build.0 = Release|Win32
|
||||
EndGlobalSection
|
||||
GlobalSection(SolutionProperties) = preSolution
|
||||
HideSolutionNode = FALSE
|
||||
|
|
|
@ -99,19 +99,27 @@
|
|||
<PropertyGroup Label="UserMacros" />
|
||||
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Debug|Win32'">
|
||||
<LinkIncremental>true</LinkIncremental>
|
||||
<OutDir>$(SolutionDir)$(Configuration)\../../../test/bin</OutDir>
|
||||
<OutDir>..\..\test\bin\</OutDir>
|
||||
<TargetName>libdspl</TargetName>
|
||||
<IntDir>$(Configuration)\dll\</IntDir>
|
||||
</PropertyGroup>
|
||||
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Debug|x64'">
|
||||
<LinkIncremental>true</LinkIncremental>
|
||||
<OutDir>$(SolutionDir)$(Configuration)\../../../test/bin</OutDir>
|
||||
<OutDir>..\..\test\bin\</OutDir>
|
||||
<TargetName>libdspl</TargetName>
|
||||
<IntDir>$(Configuration)\dll\</IntDir>
|
||||
</PropertyGroup>
|
||||
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Release|Win32'">
|
||||
<LinkIncremental>false</LinkIncremental>
|
||||
<OutDir>$(SolutionDir)$(Configuration)\../../../test/bin</OutDir>
|
||||
<OutDir>..\..\test\bin\</OutDir>
|
||||
<TargetName>libdspl</TargetName>
|
||||
<IntDir>$(Configuration)\dll\</IntDir>
|
||||
</PropertyGroup>
|
||||
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Release|x64'">
|
||||
<LinkIncremental>false</LinkIncremental>
|
||||
<OutDir>$(SolutionDir)$(Configuration)\../../../test/bin</OutDir>
|
||||
<OutDir>..\..\test\bin\</OutDir>
|
||||
<TargetName>libdspl</TargetName>
|
||||
<IntDir>$(Configuration)\dll\</IntDir>
|
||||
</PropertyGroup>
|
||||
<ItemDefinitionGroup Condition="'$(Configuration)|$(Platform)'=='Debug|Win32'">
|
||||
<ClCompile>
|
||||
|
@ -130,7 +138,7 @@
|
|||
<Link>
|
||||
<SubSystem>Windows</SubSystem>
|
||||
<GenerateDebugInformation>true</GenerateDebugInformation>
|
||||
<OutputFile>$(OutDir)libdspl.dll</OutputFile>
|
||||
<OutputFile>../../test/bin/libdspl.dll</OutputFile>
|
||||
</Link>
|
||||
</ItemDefinitionGroup>
|
||||
<ItemDefinitionGroup Condition="'$(Configuration)|$(Platform)'=='Debug|x64'">
|
||||
|
@ -150,7 +158,7 @@
|
|||
<Link>
|
||||
<SubSystem>Windows</SubSystem>
|
||||
<GenerateDebugInformation>true</GenerateDebugInformation>
|
||||
<OutputFile>$(OutDir)libdspl.dll</OutputFile>
|
||||
<OutputFile>../../test/bin/libdspl.dll</OutputFile>
|
||||
</Link>
|
||||
</ItemDefinitionGroup>
|
||||
<ItemDefinitionGroup Condition="'$(Configuration)|$(Platform)'=='Release|Win32'">
|
||||
|
@ -172,7 +180,7 @@
|
|||
<EnableCOMDATFolding>true</EnableCOMDATFolding>
|
||||
<OptimizeReferences>true</OptimizeReferences>
|
||||
<GenerateDebugInformation>true</GenerateDebugInformation>
|
||||
<OutputFile>$(OutDir)libdspl.dll</OutputFile>
|
||||
<OutputFile>../../test/bin/libdspl.dll</OutputFile>
|
||||
</Link>
|
||||
</ItemDefinitionGroup>
|
||||
<ItemDefinitionGroup Condition="'$(Configuration)|$(Platform)'=='Release|x64'">
|
||||
|
@ -194,7 +202,7 @@
|
|||
<EnableCOMDATFolding>true</EnableCOMDATFolding>
|
||||
<OptimizeReferences>true</OptimizeReferences>
|
||||
<GenerateDebugInformation>true</GenerateDebugInformation>
|
||||
<OutputFile>$(OutDir)libdspl.dll</OutputFile>
|
||||
<OutputFile>../../test/bin/libdspl.dll</OutputFile>
|
||||
</Link>
|
||||
</ItemDefinitionGroup>
|
||||
<Import Project="$(VCTargetsPath)\Microsoft.Cpp.targets" />
|
||||
|
|
|
@ -70,16 +70,20 @@
|
|||
</ImportGroup>
|
||||
<PropertyGroup Label="UserMacros" />
|
||||
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Debug|Win32'">
|
||||
<OutDir>$(SolutionDir)$(Configuration)\../../../test/bin</OutDir>
|
||||
<OutDir>..\..\test\bin\</OutDir>
|
||||
<IntDir>$(Configuration)\test\</IntDir>
|
||||
</PropertyGroup>
|
||||
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Release|Win32'">
|
||||
<OutDir>$(SolutionDir)$(Configuration)\../../../test/bin</OutDir>
|
||||
<OutDir>..\..\test\bin\</OutDir>
|
||||
<IntDir>$(Configuration)\test\</IntDir>
|
||||
</PropertyGroup>
|
||||
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Debug|x64'">
|
||||
<OutDir>$(SolutionDir)$(Configuration)\../../../test/bin</OutDir>
|
||||
<OutDir>..\..\test\bin\</OutDir>
|
||||
<IntDir>$(Configuration)\test\</IntDir>
|
||||
</PropertyGroup>
|
||||
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Release|x64'">
|
||||
<OutDir>$(SolutionDir)$(Configuration)\../../../test/bin</OutDir>
|
||||
<OutDir>..\..\test\bin\</OutDir>
|
||||
<IntDir>$(Configuration)\test\</IntDir>
|
||||
</PropertyGroup>
|
||||
<ItemDefinitionGroup Condition="'$(Configuration)|$(Platform)'=='Release|x64'">
|
||||
<ClCompile>
|
||||
|
|
|
@ -1,3 +1,8 @@
|
|||
*.exe
|
||||
*.so
|
||||
*.dll
|
||||
*.exp
|
||||
*.ipdb
|
||||
*.pdb
|
||||
*.iobj
|
||||
*.lib
|
||||
|
|
|
@ -3,37 +3,37 @@ unset key
|
|||
set grid
|
||||
set xlabel "frequency, rad/s"
|
||||
|
||||
set lmargin at screen 0.10
|
||||
set terminal wxt size 920, 260 enhanced font 'Verdana,8'
|
||||
|
||||
|
||||
set terminal wxt 0 size 460,320 enhanced font 'Verdana,8'
|
||||
|
||||
set ylabel "Butterworth filter magnitude, dB"
|
||||
set multiplot layout 1,3 rowsfirst
|
||||
set ylabel "Magnitude, dB"
|
||||
set yrange [-100:5]
|
||||
plot 'dat/butter_ap_test_mag.txt' with lines
|
||||
|
||||
|
||||
set terminal pngcairo size 560,420 enhanced font 'Verdana,8'
|
||||
set output 'img/butter_ap_test_mag.png'
|
||||
replot
|
||||
|
||||
|
||||
set terminal wxt 0 size 460,320 enhanced font 'Verdana,8'
|
||||
set ylabel "Butterworth filter phase response, rad"
|
||||
set ylabel "Phase response, rad"
|
||||
unset yrange
|
||||
plot 'dat/butter_ap_test_phi.txt' with lines
|
||||
|
||||
set terminal pngcairo size 560,420 enhanced font 'Verdana,8'
|
||||
set output 'img/butter_ap_test_phi.png'
|
||||
replot
|
||||
|
||||
|
||||
|
||||
set terminal wxt 0 size 460,320 enhanced font 'Verdana,8'
|
||||
set ylabel "Butterworth filter groupdelay, sec"
|
||||
set ylabel "Groupdelay, sec"
|
||||
unset yrange
|
||||
plot 'dat/butter_ap_test_tau.txt' with lines
|
||||
|
||||
set terminal pngcairo size 560,420 enhanced font 'Verdana,8'
|
||||
set output 'img/butter_ap_test_tau.png'
|
||||
replot
|
||||
unset multiplot
|
||||
|
||||
set terminal pngcairo size 920, 260 enhanced font 'Verdana,8'
|
||||
set output 'img/butter_ap_test.png'
|
||||
|
||||
set multiplot layout 1,3 rowsfirst
|
||||
set ylabel "Magnitude, dB"
|
||||
set yrange [-100:5]
|
||||
plot 'dat/butter_ap_test_mag.txt' with lines
|
||||
|
||||
set ylabel "Phase response, rad"
|
||||
unset yrange
|
||||
plot 'dat/butter_ap_test_phi.txt' with lines
|
||||
|
||||
set ylabel "Groupdelay, sec"
|
||||
unset yrange
|
||||
plot 'dat/butter_ap_test_tau.txt' with lines
|
||||
|
||||
unset multiplot
|
|
@ -3,40 +3,37 @@ unset key
|
|||
set grid
|
||||
set xlabel "frequency, rad/s"
|
||||
|
||||
set lmargin at screen 0.10
|
||||
set terminal wxt size 920, 260 enhanced font 'Verdana,8'
|
||||
|
||||
set terminal wxt 0 size 460,320 enhanced font 'Verdana,8' position 0,0
|
||||
|
||||
set ylabel "Chebyshev type 1 filter magnitude, dB"
|
||||
set multiplot layout 1,3 rowsfirst
|
||||
set ylabel "Magnitude, dB"
|
||||
set yrange [-100:5]
|
||||
plot 'dat/cheby1_ap_test_mag.txt' with lines
|
||||
|
||||
set terminal pngcairo size 560,420 enhanced font 'Verdana,8'
|
||||
set output 'img/cheby1_ap_test_mag.png'
|
||||
replot
|
||||
|
||||
|
||||
|
||||
|
||||
set terminal wxt 1 size 460,320 enhanced font 'Verdana,8' position 460, 0
|
||||
set ylabel "Chebyshev type 1 filter phase response, rad"
|
||||
set ylabel "Phase response, rad"
|
||||
unset yrange
|
||||
plot 'dat/cheby1_ap_test_phi.txt' with lines
|
||||
|
||||
set terminal pngcairo size 560,420 enhanced font 'Verdana,8'
|
||||
set output 'img/cheby1_ap_test_phi.png'
|
||||
replot
|
||||
|
||||
|
||||
|
||||
|
||||
set terminal wxt 2 size 460,320 enhanced font 'Verdana,8' position 920, 0
|
||||
set ylabel "Chebyshev type 1 filter groupdelay, sec"
|
||||
set ylabel "Groupdelay, sec"
|
||||
unset yrange
|
||||
plot 'dat/cheby1_ap_test_tau.txt' with lines
|
||||
|
||||
unset multiplot
|
||||
|
||||
set terminal pngcairo size 560,420 enhanced font 'Verdana,8'
|
||||
set output 'img/cheby1_ap_test_tau.png'
|
||||
replot
|
||||
set terminal pngcairo size 920, 260 enhanced font 'Verdana,8'
|
||||
set output 'img/cheby1_ap_test.png'
|
||||
|
||||
set multiplot layout 1,3 rowsfirst
|
||||
set ylabel "Magnitude, dB"
|
||||
set yrange [-100:5]
|
||||
plot 'dat/cheby1_ap_test_mag.txt' with lines
|
||||
|
||||
set ylabel "Phase response, rad"
|
||||
unset yrange
|
||||
plot 'dat/cheby1_ap_test_phi.txt' with lines
|
||||
|
||||
set ylabel "Groupdelay, sec"
|
||||
unset yrange
|
||||
plot 'dat/cheby1_ap_test_tau.txt' with lines
|
||||
|
||||
unset multiplot
|
||||
|
|
|
@ -1,5 +1,3 @@
|
|||
### Start multiplot (2x2 layout)
|
||||
|
||||
set terminal wxt 0 size 800,640 enhanced font 'Verdana,8' position 0,0
|
||||
unset key
|
||||
set multiplot layout 4,2 rowsfirst
|
||||
|
|
|
@ -11,7 +11,8 @@ int main()
|
|||
dspl_info(); // Print DSPL information
|
||||
|
||||
dspl_free(handle); // free dspl handle
|
||||
return 0;
|
||||
getch();
|
||||
return 0;
|
||||
}
|
||||
|
||||
|
||||
|
|
|
@ -3,126 +3,43 @@
|
|||
#include <math.h>
|
||||
#include "dspl.h"
|
||||
|
||||
#define N 8000
|
||||
|
||||
|
||||
|
||||
void r2hdb(double* r, double* h, double* hdb, double ep2, int n)
|
||||
{
|
||||
int k;
|
||||
for(k = 0; k < n; k++)
|
||||
{
|
||||
r[k] *= r[k];
|
||||
h[k] = 1.0/(1.0 + ep2 * r[k]);
|
||||
hdb[k] = 10.0*log10(h[k]);
|
||||
}
|
||||
}
|
||||
|
||||
#define N 1000
|
||||
|
||||
int main(int argc, char* argv[])
|
||||
{
|
||||
double w[N]; // время (сек)
|
||||
double r[N]; // входной сигнал
|
||||
double h[N], hdb[N];
|
||||
double ep2, Rp, Rs, es2, m;
|
||||
int ord, k;
|
||||
|
||||
void* handle; // DSPL handle
|
||||
handle = dspl_load(); // Load DSPL function
|
||||
|
||||
// заполняю массив частот в логарифмическом формате от 0.01 до 100
|
||||
logspace(-2, 2, N, DSPL_PERIODIC, w);
|
||||
|
||||
|
||||
ord = 4; // порядок фильтра
|
||||
Rp = 0.3; // Неравномерность в полосе пропускания (дБ)
|
||||
Rs = 15.0; // Уровень подавления в полосе заграждения (дБ)
|
||||
|
||||
// Параметры ep^2 и es^2
|
||||
ep2 = pow(10.0, Rp*0.1) - 1.0;
|
||||
es2 = pow(10.0, Rs*0.1) - 1.0;
|
||||
|
||||
// вывод на печать параметров ep^2 и es^2
|
||||
printf("ep^2 = %.4f\n", ep2);
|
||||
printf("es^2 = %.4f\n", es2);
|
||||
|
||||
|
||||
|
||||
|
||||
//**********************************************************************
|
||||
// Расчет F_N^2(w) и |H(jw)|^2 фильтра Баттерворта
|
||||
//**********************************************************************
|
||||
for(k = 0; k < N; k++)
|
||||
{
|
||||
r[k] = pow(w[k], (double)(ord));
|
||||
}
|
||||
r2hdb(r, h, hdb, ep2, N);
|
||||
|
||||
// сохранение в файлы результатов расчета фильтра Баттерворта
|
||||
writetxt(w, r, N, "dat/butter_r.txt");
|
||||
writetxt(w, h, N, "dat/butter_h.txt");
|
||||
writetxt(w, hdb, N, "dat/butter_hdb.txt");
|
||||
|
||||
|
||||
double w[N], r[N], h[N];
|
||||
double ep2, Gp2;
|
||||
int ord, k;
|
||||
void* handle;
|
||||
handle = dspl_load();
|
||||
if(!handle)
|
||||
{
|
||||
printf("cannot to load libdspl!\n");
|
||||
return 0;
|
||||
}
|
||||
|
||||
|
||||
|
||||
|
||||
//**********************************************************************
|
||||
// Расчет F_N^2(w) и |H(jw)|^2 фильтра Чебышева 1-го рода
|
||||
//**********************************************************************
|
||||
cheby_poly1(w, N, ord, r);
|
||||
r2hdb(r, h, hdb, ep2, N);
|
||||
// сохранение в файлы результатов расчета фильтра Чебышева 1-го рода
|
||||
writetxt(w, r, N, "dat/cheby1_r.txt");
|
||||
writetxt(w, h, N, "dat/cheby1_h.txt");
|
||||
writetxt(w, hdb, N, "dat/cheby1_hdb.txt");
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
//**********************************************************************
|
||||
// Расчет F_N^2(w) и |H(jw)|^2 фильтра Чебышева 2-го рода
|
||||
//**********************************************************************
|
||||
for(k = 0; k < N; k++)
|
||||
{
|
||||
w[k] = 1.0 / w[k];
|
||||
}
|
||||
cheby_poly1(w, N, ord, r);
|
||||
for(k = 0; k < N; k++)
|
||||
{
|
||||
r[k] =1.0 / (r[k] *r[k]);
|
||||
h[k] = 1.0/(1.0 + es2*r[k]);
|
||||
hdb[k] = 10.0*log10(h[k]);
|
||||
}
|
||||
logspace(-2, 2, N, DSPL_PERIODIC, w);
|
||||
// сохранение в файлы результатов расчета фильтра Чебышева 1-го рода
|
||||
writetxt(w, r, N, "dat/cheby2_r.txt");
|
||||
writetxt(w, h, N, "dat/cheby2_h.txt");
|
||||
writetxt(w, hdb, N, "dat/cheby2_hdb.txt");
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
//**********************************************************************
|
||||
// Расчет F_N^2(w) и |H(jw)|^2 эллиптического фильтра
|
||||
//**********************************************************************
|
||||
ellip_modulareq(Rp, Rs, ord, &m); // пересчет эллиптического модуля
|
||||
printf("modular m = %.3f\n", m); // вывод на печать
|
||||
// расчет эллиптической рациональной функции
|
||||
ellip_rat(w, N, ord, m, r);
|
||||
r2hdb(r, h, hdb, ep2, N);
|
||||
// сохранение в файлы результатов расчета эллиптического фильтра
|
||||
writetxt(w, r, N, "dat/ellip_r.txt");
|
||||
writetxt(w, h, N, "dat/ellip_h.txt");
|
||||
writetxt(w, hdb, N, "dat/ellip_hdb.txt");
|
||||
linspace(0, 2.5, N, DSPL_PERIODIC, w);
|
||||
|
||||
|
||||
|
||||
dspl_free(handle); // free dspl handle
|
||||
return 0;
|
||||
ord = 4;
|
||||
Gp2 = 0.9;
|
||||
ep2 = 1.0 / Gp2 -1;
|
||||
|
||||
for(k = 0; k < N; k++)
|
||||
{
|
||||
r[k] = pow(w[k], (double)(ord));
|
||||
r[k] *= r[k];
|
||||
h[k] = 6.0/(1.0 + ep2*r[k]);
|
||||
|
||||
w[k] *= 4;
|
||||
}
|
||||
|
||||
writetxt(w, h, N, "dat/butter_approx.txt");
|
||||
|
||||
|
||||
// remember to free the resource
|
||||
dspl_free(handle);
|
||||
|
||||
return 0;
|
||||
}
|
||||
|
||||
|
||||
|
||||
|
|
|
@ -0,0 +1,81 @@
|
|||
#include <stdio.h>
|
||||
#include <string.h>
|
||||
#include "common.h"
|
||||
#include "dspl.h"
|
||||
#include "plot.h"
|
||||
|
||||
#define N 1000
|
||||
#define T 4.0
|
||||
#define A 2.0
|
||||
#define M 41
|
||||
|
||||
int main(int argc, char* argv[])
|
||||
{
|
||||
|
||||
double t[N]; // время (сек)
|
||||
double s[N]; // входной сигнал
|
||||
complex_t S[M]; // комплексный спектр периодического сигнала
|
||||
double Smag[M]; // амплитудный спектр периодического сигнала
|
||||
double w[M]; // частота (рад/c) дискретного спектра
|
||||
double wc[N]; // частота (рад/с) огибающей спектра
|
||||
double Sc[N]; // огибающая спектра
|
||||
double tau; // длительность импульса
|
||||
|
||||
// скважность
|
||||
double Q[3] = {5.0, 2.0, 1.25};
|
||||
|
||||
int q, m, n;
|
||||
char fname[64];
|
||||
|
||||
|
||||
for(q = 0; q < 3; q++)
|
||||
{
|
||||
tau = T/Q[q];
|
||||
|
||||
// заполнение массива временных отсчетов
|
||||
// на 4-x периодах повторения сигнала
|
||||
// для отображения на осциллограмме
|
||||
linspace(-T*2.0, T*2.0, N, DSPL_PERIODIC, t);
|
||||
|
||||
// 4 периода повторения п-импульса скважности Q[q]
|
||||
signal_pimp(t, N, A, tau, 0.0, T, s);
|
||||
|
||||
// сохранение в текстовый файл
|
||||
sprintf(fname, "dat/pimp_time_%.2lf.csv", Q[q]);
|
||||
writetxt(t, s, N, fname);
|
||||
|
||||
|
||||
// заполнение массива временных отсчетов
|
||||
// на одном периоде повторения сигнала
|
||||
linspace(-T/2.0, T/2.0, N, DSPL_PERIODIC, t);
|
||||
|
||||
// один период повторения п-импульса скважности Q[q]
|
||||
signal_pimp(t, N, A, tau, 0.0, T, s);
|
||||
|
||||
// разложение в ряд Фурье
|
||||
fourier_series_dec(t, s, N, T, M, w, S);
|
||||
|
||||
// Рассчет амплитудного спектра
|
||||
for(m = 0; m < M; m++)
|
||||
{
|
||||
printf("S[%d] = %f %f\n", m, RE(S[m]), IM(S[m]));
|
||||
Smag[m] = ABS(S[m]);
|
||||
}
|
||||
// Сохранение в файл амплитудного спетра для скважности Q[q]
|
||||
sprintf(fname, "dat/pimp_freq_discrete_%.2lf.csv", Q[q]);
|
||||
writetxt(w, Smag, M, fname);
|
||||
|
||||
// Вектор частот непрерывной огибаюхей вида sin(w/2*tau) / (w/2*T)
|
||||
linspace(w[0], w[M-1], N, DSPL_SYMMETRIC, wc);
|
||||
|
||||
// Расчет огибающей
|
||||
for(n = 0; n < N; n++)
|
||||
Sc[n] = (wc[n] == 0.0) ? A/Q[q] : fabs( A * sin(0.5*wc[n]*tau) / (0.5*wc[n] * T));
|
||||
|
||||
// сохранение огибающей в файл для скважности Q[q]
|
||||
sprintf(fname, "dat/pimp_freq_cont_%.2lf.csv", Q[q]);
|
||||
writetxt(wc, Sc, N, fname);
|
||||
}
|
||||
|
||||
return 0;
|
||||
}
|
Ładowanie…
Reference in New Issue