simplify old posts' tags and categories
some blog contents are alse modified
This commit is contained in:
+3
-3
@@ -66,8 +66,8 @@ creative_commons:
|
||||
license: by-nc-sa
|
||||
# Available values: big | small
|
||||
size: small
|
||||
sidebar: true
|
||||
post: false
|
||||
sidebar: false
|
||||
post: true
|
||||
# You can set a language value if you prefer a translated version of CC license, e.g. deed.zh
|
||||
# CC licenses are available in 39 languages, you can find the specific and correct abbreviation you need on https://creativecommons.org
|
||||
language: deed.zh
|
||||
@@ -402,7 +402,7 @@ bookmark:
|
||||
color: "#222"
|
||||
# If auto, save the reading progress when closing the page or clicking the bookmark-icon.
|
||||
# If manual, only save it by clicking the bookmark-icon.
|
||||
save: auto
|
||||
save: manual
|
||||
|
||||
# `Follow me on GitHub` banner in the top-right corner.
|
||||
github_banner:
|
||||
|
||||
+15
@@ -110,6 +110,9 @@ deploy:
|
||||
- type: git
|
||||
repo: [email protected]:/home/josh/documents/josh-blog-deploy.git
|
||||
branch: master
|
||||
- type: git
|
||||
repo: [email protected]:/home/josh/documents/josh-blog.git
|
||||
branch: master
|
||||
- type: git
|
||||
repo: [email protected]:josh-gao/josh-blog/josh-blog.git
|
||||
branch: master
|
||||
@@ -193,3 +196,15 @@ neat_js:
|
||||
- '**/jquery.fancybox.pack.js'
|
||||
- '**/index.js'
|
||||
- '**/fireworks.js'
|
||||
|
||||
related_posts:
|
||||
enabled: true
|
||||
filter_threshold: 0.1
|
||||
related_count: 5
|
||||
weight:
|
||||
title: 0.1
|
||||
description: 0.05
|
||||
keywords: 0.01
|
||||
tags: 0.005
|
||||
categories: 0.005
|
||||
text: 1
|
||||
Generated
+89
@@ -21,6 +21,7 @@
|
||||
"hexo-helper-live2d": "^3.1.1",
|
||||
"hexo-neat": "^1.0.9",
|
||||
"hexo-related-popular-posts": "^5.0.1",
|
||||
"hexo-related-posts": "^1.5.1",
|
||||
"hexo-renderer-ejs": "^2.0.0",
|
||||
"hexo-renderer-pandoc": "^0.3.1",
|
||||
"hexo-renderer-stylus": "^2.1.0",
|
||||
@@ -96,6 +97,15 @@
|
||||
"node": ">=0.4.0"
|
||||
}
|
||||
},
|
||||
"node_modules/afinn-165": {
|
||||
"version": "1.0.4",
|
||||
"resolved": "https://registry.npmjs.org/afinn-165/-/afinn-165-1.0.4.tgz",
|
||||
"integrity": "sha512-7+Wlx3BImrK0HiG6y3lU4xX7SpBPSSu8T9iguPMlaueRFxjbYwAQrp9lqZUuFikqKbd/en8lVREILvP2J80uJA==",
|
||||
"funding": {
|
||||
"type": "github",
|
||||
"url": "https://github.com/sponsors/wooorm"
|
||||
}
|
||||
},
|
||||
"node_modules/agent-base": {
|
||||
"version": "6.0.2",
|
||||
"resolved": "https://registry.npmmirror.com/agent-base/-/agent-base-6.0.2.tgz",
|
||||
@@ -223,6 +233,17 @@
|
||||
"node": ">= 8"
|
||||
}
|
||||
},
|
||||
"node_modules/apparatus": {
|
||||
"version": "0.0.10",
|
||||
"resolved": "https://registry.npmjs.org/apparatus/-/apparatus-0.0.10.tgz",
|
||||
"integrity": "sha512-KLy/ugo33KZA7nugtQ7O0E1c8kQ52N3IvD/XgIh4w/Nr28ypfkwDfA67F1ev4N1m5D+BOk1+b2dEJDfpj/VvZg==",
|
||||
"dependencies": {
|
||||
"sylvester": ">= 0.0.8"
|
||||
},
|
||||
"engines": {
|
||||
"node": ">=0.2.6"
|
||||
}
|
||||
},
|
||||
"node_modules/aproba": {
|
||||
"version": "1.2.0",
|
||||
"resolved": "https://registry.npmmirror.com/aproba/-/aproba-1.2.0.tgz",
|
||||
@@ -4433,6 +4454,18 @@
|
||||
"node": ">=0.10.0"
|
||||
}
|
||||
},
|
||||
"node_modules/hexo-related-posts": {
|
||||
"version": "1.5.1",
|
||||
"resolved": "https://registry.npmjs.org/hexo-related-posts/-/hexo-related-posts-1.5.1.tgz",
|
||||
"integrity": "sha512-KeNGQXcfsDKGyP66wiUVlcqguMyBn0n9tsFE5CftxhD9jiOrCmsqCibY1Aq8w/9f92+uxl+NlNkFhkrLezRFVg==",
|
||||
"dependencies": {
|
||||
"natural": "^2.1.5"
|
||||
},
|
||||
"peerDependencies": {
|
||||
"chalk": "^4.1.0",
|
||||
"hexo": "^4.2.0 || ^5.2.0 || ^6.3.0"
|
||||
}
|
||||
},
|
||||
"node_modules/hexo-renderer-ejs": {
|
||||
"version": "2.0.0",
|
||||
"resolved": "https://registry.npmmirror.com/hexo-renderer-ejs/-/hexo-renderer-ejs-2.0.0.tgz",
|
||||
@@ -5909,6 +5942,17 @@
|
||||
"resolved": "https://registry.npmmirror.com/json-schema-traverse/-/json-schema-traverse-0.4.1.tgz",
|
||||
"integrity": "sha512-xbbCH5dCYU5T8LcEhhuh7HJ88HXuW3qsI3Y0zOZFKfZEHcpWiHU/Jxzk629Brsab/mMiHQti9wMP+845RPe3Vg=="
|
||||
},
|
||||
"node_modules/json-stable-stringify": {
|
||||
"version": "1.0.2",
|
||||
"resolved": "https://registry.npmjs.org/json-stable-stringify/-/json-stable-stringify-1.0.2.tgz",
|
||||
"integrity": "sha512-eunSSaEnxV12z+Z73y/j5N37/In40GK4GmsSy+tEHJMxknvqnA7/djeYtAgW0GsWHUfg+847WJjKaEylk2y09g==",
|
||||
"dependencies": {
|
||||
"jsonify": "^0.0.1"
|
||||
},
|
||||
"funding": {
|
||||
"url": "https://github.com/sponsors/ljharb"
|
||||
}
|
||||
},
|
||||
"node_modules/json-stringify-safe": {
|
||||
"version": "5.0.1",
|
||||
"resolved": "https://registry.npmmirror.com/json-stringify-safe/-/json-stringify-safe-5.0.1.tgz",
|
||||
@@ -5925,6 +5969,14 @@
|
||||
"node": ">=6"
|
||||
}
|
||||
},
|
||||
"node_modules/jsonify": {
|
||||
"version": "0.0.1",
|
||||
"resolved": "https://registry.npmjs.org/jsonify/-/jsonify-0.0.1.tgz",
|
||||
"integrity": "sha512-2/Ki0GcmuqSrgFyelQq9M05y7PS0mEwuIzrf3f1fPqkVDVRvZrPZtVSMHxdgo8Aq0sxAOb/cr2aqqA3LeWHVPg==",
|
||||
"funding": {
|
||||
"url": "https://github.com/sponsors/ljharb"
|
||||
}
|
||||
},
|
||||
"node_modules/jsonparse": {
|
||||
"version": "1.3.1",
|
||||
"resolved": "https://registry.npmmirror.com/jsonparse/-/jsonparse-1.3.1.tgz",
|
||||
@@ -6782,6 +6834,22 @@
|
||||
"node": ">=0.10.0"
|
||||
}
|
||||
},
|
||||
"node_modules/natural": {
|
||||
"version": "2.4.5",
|
||||
"resolved": "https://registry.npmjs.org/natural/-/natural-2.4.5.tgz",
|
||||
"integrity": "sha512-fxQou4ubo6Rzf7XL0jjwtC2vHm6Sdicu7ztcE0k1ODZs+d1UzcKF1Hu2IwE2y7OgzU3Sa9o8obw7rnyNrjsd1A==",
|
||||
"dependencies": {
|
||||
"afinn-165": "^1.0.2",
|
||||
"apparatus": "^0.0.10",
|
||||
"json-stable-stringify": "^1.0.1",
|
||||
"sylvester": "^0.0.12",
|
||||
"underscore": "^1.9.1",
|
||||
"wordnet-db": "^3.1.11"
|
||||
},
|
||||
"engines": {
|
||||
"node": ">=0.4.10"
|
||||
}
|
||||
},
|
||||
"node_modules/ncp": {
|
||||
"version": "2.0.0",
|
||||
"resolved": "https://registry.npmmirror.com/ncp/-/ncp-2.0.0.tgz",
|
||||
@@ -9206,6 +9274,14 @@
|
||||
"node": ">= 0.4"
|
||||
}
|
||||
},
|
||||
"node_modules/sylvester": {
|
||||
"version": "0.0.12",
|
||||
"resolved": "https://registry.npmjs.org/sylvester/-/sylvester-0.0.12.tgz",
|
||||
"integrity": "sha512-SzRP5LQ6Ts2G5NyAa/jg16s8e3R7rfdFjizy1zeoecYWw+nGL+YA1xZvW/+iJmidBGSdLkuvdwTYEyJEb+EiUw==",
|
||||
"engines": {
|
||||
"node": ">=0.2.6"
|
||||
}
|
||||
},
|
||||
"node_modules/symbol-tree": {
|
||||
"version": "3.2.4",
|
||||
"resolved": "https://registry.npmmirror.com/symbol-tree/-/symbol-tree-3.2.4.tgz",
|
||||
@@ -9519,6 +9595,11 @@
|
||||
"node": ">=0.8.0"
|
||||
}
|
||||
},
|
||||
"node_modules/underscore": {
|
||||
"version": "1.13.6",
|
||||
"resolved": "https://registry.npmjs.org/underscore/-/underscore-1.13.6.tgz",
|
||||
"integrity": "sha512-+A5Sja4HP1M08MaXya7p5LvjuM7K6q/2EaC0+iovj/wOcMsTzMvDFbasi/oSapiwOlt252IqsKqPjCl7huKS0A=="
|
||||
},
|
||||
"node_modules/union-value": {
|
||||
"version": "1.0.1",
|
||||
"resolved": "https://registry.npmmirror.com/union-value/-/union-value-1.0.1.tgz",
|
||||
@@ -9954,6 +10035,14 @@
|
||||
"node": ">=0.10.0"
|
||||
}
|
||||
},
|
||||
"node_modules/wordnet-db": {
|
||||
"version": "3.1.14",
|
||||
"resolved": "https://registry.npmjs.org/wordnet-db/-/wordnet-db-3.1.14.tgz",
|
||||
"integrity": "sha512-zVyFsvE+mq9MCmwXUWHIcpfbrHHClZWZiVOzKSxNJruIcFn2RbY55zkhiAMMxM8zCVSmtNiViq8FsAZSFpMYag==",
|
||||
"engines": {
|
||||
"node": ">=0.6.0"
|
||||
}
|
||||
},
|
||||
"node_modules/wrappy": {
|
||||
"version": "1.0.2",
|
||||
"resolved": "https://registry.npmmirror.com/wrappy/-/wrappy-1.0.2.tgz",
|
||||
|
||||
@@ -25,6 +25,7 @@
|
||||
"hexo-helper-live2d": "^3.1.1",
|
||||
"hexo-neat": "^1.0.9",
|
||||
"hexo-related-popular-posts": "^5.0.1",
|
||||
"hexo-related-posts": "^1.5.1",
|
||||
"hexo-renderer-ejs": "^2.0.0",
|
||||
"hexo-renderer-pandoc": "^0.3.1",
|
||||
"hexo-renderer-stylus": "^2.1.0",
|
||||
|
||||
@@ -3,19 +3,18 @@ title: MATLAB 函数 —— rcosdesign
|
||||
tags:
|
||||
- MATLAB
|
||||
- 翻译
|
||||
- 成型滤波器
|
||||
- 成形滤波器
|
||||
- 滤波器
|
||||
categories:
|
||||
- - MATLAB
|
||||
- - 翻译
|
||||
- 帮助文档
|
||||
- [MATLAB, 函数用法]
|
||||
mathjax: true
|
||||
copyright: true
|
||||
comments: true
|
||||
abbrlink: 5c45edfe
|
||||
date: 2020-11-25 22:32:42
|
||||
---
|
||||
|
||||
`rcosdesign`:升余弦 FIR 脉冲成型滤波器设计
|
||||
`rcosdesign`:升余弦 FIR 脉冲成形滤波器设计
|
||||
|
||||
# 语法
|
||||
|
||||
@@ -32,18 +31,18 @@ date: 2020-11-25 22:32:42
|
||||
|
||||
# 示例
|
||||
|
||||
## 设计根升余弦滤波器<span id="Examples-01"></span>
|
||||
## 设计根升余弦滤波器<a name="Examples-01"></a>
|
||||
|
||||
将滚降系数设为 `0.25`,波器的符号数设为 `6`,每个符号 `4` 个采样点。验证 `sqrt` 是 `shape` 参数的默认值。
|
||||
|
||||
```m
|
||||
``` matlab
|
||||
h = rcosdesign(0.25,6,4);
|
||||
mx = max(abs(h-rcosdesign(0.25,6,4,'sqrt')))
|
||||
```
|
||||
|
||||
> <font face="Consolas">mx = 0</font><br>
|
||||
|
||||
```m
|
||||
``` matlab
|
||||
fvtool(h,'Analysis','impulse')
|
||||
```
|
||||
|
||||
@@ -51,13 +50,13 @@ fvtool(h,'Analysis','impulse')
|
||||
<img src="https://josh-blog-1257563604.cos.ap-beijing.myqcloud.com/img/2020-11-25-matlab-rcosdesign/2020-11-25-matlab-rcosdesign-010-DesignASquareRootRaisedCosineFilterExample-01.png?imageMogr2/thumbnail/!100p|watermark/2/text/QEpvc2ggR2Fv/fontsize/15/dissolve/60/gravity/southeast/dx/5/dy/5"/>
|
||||
</div>
|
||||
|
||||
## 升余弦和根升余弦滤波器的脉冲响应<span id="Examples-02"></span>
|
||||
## 升余弦和根升余弦滤波器的脉冲响应<a name="Examples-02"></a>
|
||||
|
||||
将升余弦滤波器与根升余弦滤波器进行比较。一个理想的(无限长)升余弦脉冲成型滤波器等效于两个级联的理想的根升余弦滤波器。因此,FIR 升余弦滤波器的脉冲响应应类似于与其自身卷积的根升余弦滤波器的脉冲响应。
|
||||
将升余弦滤波器与根升余弦滤波器进行比较。一个理想的(无限长)升余弦脉冲成形滤波器等效于两个级联的理想的根升余弦滤波器。因此,FIR 升余弦滤波器的脉冲响应应类似于与其自身卷积的根升余弦滤波器的脉冲响应。
|
||||
|
||||
设计一个衰减为 `0.25` 的升余弦滤波器。指定滤波器有 `4` 个符号,每个符号 `3` 个采样点。
|
||||
|
||||
```m
|
||||
``` matlab
|
||||
rf = 0.25;
|
||||
span = 4;
|
||||
sps = 3;
|
||||
@@ -72,7 +71,7 @@ fvtool(h1,'impulse')
|
||||
|
||||
**升余弦滤波器在 `sps` 的整数倍处具有零值点**。因此,它满足无码间串扰(ISI)的 Nyquist 准则。但是,根升余弦滤波器没有这样的特性:
|
||||
|
||||
```m
|
||||
``` matlab
|
||||
h2 = rcosdesign(rf,span,sps,'sqrt');
|
||||
fvtool(h2,'impulse')
|
||||
```
|
||||
@@ -83,7 +82,7 @@ fvtool(h2,'impulse')
|
||||
|
||||
将根升余弦滤波器与自身进行卷积。在最大值处截断脉冲响应,使其长度与 `h1` 相同。使用最大值将响应归一化。然后,将卷积后的根升余弦滤波器与升余弦滤波器进行比较。
|
||||
|
||||
```m
|
||||
``` matlab
|
||||
h3 = conv(h2,h2);
|
||||
p2 = ceil(length(h3)/2);
|
||||
m2 = ceil(p2-length(h1)/2);
|
||||
@@ -102,13 +101,13 @@ legend('h1','h2 * h2')
|
||||
|
||||
卷积响应的长度是有限的,因此根升余弦滤波器与自身进行卷积得到的结果会与升余弦滤波器不一致。增加 `span` 可以在响应之间获得更紧密的一致性,并更好地符合 Nyquist 准则。
|
||||
|
||||
## 将信号通过升余弦滤波器<span id="Examples-03"></span>
|
||||
## 将信号通过升余弦滤波器<a name="Examples-03"></a>
|
||||
|
||||
本例说明如何将信号通过根升余弦滤波器。
|
||||
|
||||
指定滤波器参数。
|
||||
|
||||
```m
|
||||
``` matlab
|
||||
rolloff = 0.25; % 滚降因子
|
||||
span = 6; % 滤波器宽度(符号数)
|
||||
sps = 4; % 每个符号的样本数
|
||||
@@ -116,31 +115,31 @@ sps = 4; % 每个符号的样本数
|
||||
|
||||
生成根升余弦滤波器的系数。
|
||||
|
||||
```m
|
||||
``` matlab
|
||||
b = rcosdesign(rolloff, span, sps);
|
||||
```
|
||||
|
||||
生成双极性数据向量。
|
||||
|
||||
```m
|
||||
``` matlab
|
||||
d = 2*randi([0 1], 100, 1) - 1;
|
||||
```
|
||||
|
||||
上采样并对数据进行滤波以实现脉冲成型。
|
||||
上采样并对数据进行滤波以实现脉冲成形。
|
||||
|
||||
```m
|
||||
``` matlab
|
||||
x = upfirdn(d, b, sps);
|
||||
```
|
||||
|
||||
添加噪声。
|
||||
|
||||
```m
|
||||
``` matlab
|
||||
r = x + randn(size(x))*0.01;
|
||||
```
|
||||
|
||||
对接收到的信号进行滤波和下采样以进行匹配滤波。
|
||||
|
||||
```m
|
||||
``` matlab
|
||||
y = upfirdn(r, b, 1, sps);
|
||||
```
|
||||
|
||||
@@ -196,6 +195,10 @@ y = upfirdn(r, b, 1, sps);
|
||||
>>
|
||||
>> 所有输入必须为常数。 如果表达式或变量的值不变,则也允许使用。
|
||||
|
||||
# 版本历史
|
||||
|
||||
在 R2013b 中推出
|
||||
|
||||
# 另请参阅
|
||||
|
||||
[`gaussdesign`](https://ww2.mathworks.cn/help/signal/ref/gaussdesign.html)
|
||||
@@ -204,10 +207,4 @@ y = upfirdn(r, b, 1, sps);
|
||||
|
||||
[用 RRC 滤波器进行插值和抽取](https://ww2.mathworks.cn/help/comm/ug/interpolate-and-decimate-using-rrc-filter.html)(Communications Toolbox)
|
||||
|
||||
----
|
||||
|
||||
在 R2013b 中推出
|
||||
|
||||
----
|
||||
|
||||
原文参考:[https://ww2.mathworks.cn/help/signal/ref/rcosdesign.html](https://ww2.mathworks.cn/help/signal/ref/rcosdesign.html)
|
||||
> 原文参考:[https://ww2.mathworks.cn/help/signal/ref/rcosdesign.html](https://ww2.mathworks.cn/help/signal/ref/rcosdesign.html)
|
||||
|
||||
@@ -3,19 +3,18 @@ title: MATLAB 函数 —— gaussdesign
|
||||
tags:
|
||||
- MATLAB
|
||||
- 翻译
|
||||
- 成型滤波器
|
||||
- 成形滤波器
|
||||
- 滤波器
|
||||
categories:
|
||||
- - MATLAB
|
||||
- - 翻译
|
||||
- 帮助文档
|
||||
- [MATLAB, 函数用法]
|
||||
mathjax: true
|
||||
copyright: true
|
||||
comments: true
|
||||
abbrlink: a2967b00
|
||||
date: 2020-11-26 15:56:26
|
||||
---
|
||||
|
||||
`gaussdesign`:高斯 FIR 脉冲成型滤波器设计
|
||||
`gaussdesign`:高斯 FIR 脉冲成形滤波器设计
|
||||
|
||||
# 语法
|
||||
|
||||
@@ -25,15 +24,15 @@ date: 2020-11-26 15:56:26
|
||||
|
||||
# 说明
|
||||
|
||||
`h = gaussdesign(bt,span,sps)` 设计一个低通 FIR 高斯脉冲成型滤波器,并返回滤波器系数向量 `h`。滤波器有 `span` 个符号,每个符号包含 `sps` 个样本。滤波器的阶次,也即 `sps * span` 必须是偶数。[举例](#Examples-01)
|
||||
`h = gaussdesign(bt,span,sps)` 设计一个低通 FIR 高斯脉冲成形滤波器,并返回滤波器系数向量 `h`。滤波器有 `span` 个符号,每个符号包含 `sps` 个样本。滤波器的阶次,也即 `sps * span` 必须是偶数。[举例](#Examples-01)
|
||||
|
||||
# 示例
|
||||
|
||||
## GSM GMSK 数字蜂窝通信系统的高斯滤波器<span id="Examples-01"></span>
|
||||
## GSM GMSK 数字蜂窝通信系统的高斯滤波器<a name="Examples-01"></a>
|
||||
|
||||
指定用于传输比特位的调制是高斯最小频移键控(GMSK)脉冲。此脉冲的 3-dB 带宽等于比特率的 `0.3` 倍,滤波器的符号数为 `4`,每个符号 `8` 个采样点。
|
||||
|
||||
```m
|
||||
``` matlab
|
||||
bt = 0.3;
|
||||
span = 4;
|
||||
sps = 8;
|
||||
@@ -69,7 +68,7 @@ fvtool(h,'impulse')
|
||||
|
||||
## `h` - FIR 滤波器系数
|
||||
|
||||
高斯脉冲成型滤波器的 FIR 系数,以**行向量**的形式返回。系数已被归一化,因此标称通带增益始终为 1。
|
||||
高斯脉冲成形滤波器的 FIR 系数,以**行向量**的形式返回。系数已被归一化,因此标称通带增益始终为 1。
|
||||
|
||||
**数据类型**:`double` | `single`
|
||||
|
||||
@@ -79,14 +78,12 @@ fvtool(h,'impulse')
|
||||
|
||||
[2] Rappaport, Theodore S. *Wireless Communications: Principles and Practice.* 2nd Ed. Upper Saddle River, NJ: Prentice Hall, 2002.
|
||||
|
||||
# 版本历史
|
||||
|
||||
在 R2013b 中推出
|
||||
|
||||
# 另请参阅
|
||||
|
||||
[`rcosdesign`](https://ww2.mathworks.cn/help/signal/ref/rcosdesign.html)
|
||||
|
||||
---
|
||||
|
||||
在 R2013b 中推出
|
||||
|
||||
---
|
||||
|
||||
原文参考:[https://ww2.mathworks.cn/help/signal/ref/gaussdesign.html](https://ww2.mathworks.cn/help/signal/ref/gaussdesign.html)
|
||||
@@ -5,14 +5,14 @@ tags:
|
||||
- 翻译
|
||||
- 上采样
|
||||
categories:
|
||||
- - MATLAB
|
||||
- - 翻译
|
||||
- 帮助文档
|
||||
- [MATLAB, 函数用法]
|
||||
mathjax: true
|
||||
copyright: true
|
||||
comments: true
|
||||
abbrlink: 3a606c9c
|
||||
date: 2020-11-26 22:23:39
|
||||
---
|
||||
|
||||
`upsample`:将采样率提高整数倍
|
||||
|
||||
# 语法
|
||||
@@ -30,16 +30,16 @@ date: 2020-11-26 22:23:39
|
||||
|
||||
# 示例
|
||||
|
||||
## 提高采样率<span id="Examples-01"></span>
|
||||
## 提高采样率<a name="Examples-01"></a>
|
||||
|
||||
将序列的采样率提高 `3` 倍。
|
||||
|
||||
```m
|
||||
``` matlab 输入
|
||||
x = [1 2 3 4];
|
||||
y = upsample(x,3)
|
||||
```
|
||||
|
||||
```no
|
||||
``` plain 输出
|
||||
y = 1×12
|
||||
|
||||
1 0 0 2 0 0 3 0 0 4 0 0
|
||||
@@ -47,12 +47,12 @@ y = 1×12
|
||||
|
||||
将序列的采样率增加 `3` 倍,并将相位偏移增加 `2`。
|
||||
|
||||
```m
|
||||
``` matlab 输入
|
||||
x = [1 2 3 4];
|
||||
y = upsample(x,3,2)
|
||||
```
|
||||
|
||||
```no
|
||||
``` plain 输出
|
||||
y = 1×12
|
||||
|
||||
0 0 1 0 0 2 0 0 3 0 0 4 0
|
||||
@@ -60,14 +60,14 @@ y = 1×12
|
||||
|
||||
将矩阵的采样率提高3倍。
|
||||
|
||||
```m
|
||||
``` matlab 输入
|
||||
x = [1 2;
|
||||
3 4;
|
||||
5 6];
|
||||
y = upsample(x,3)
|
||||
```
|
||||
|
||||
```no
|
||||
``` plain 输出
|
||||
y = 9×2
|
||||
|
||||
1 2
|
||||
@@ -115,12 +115,12 @@ y = 9×2
|
||||
|
||||
> 使用 MATLAB® Coder™ 生成 C 代码和 C++ 代码。
|
||||
|
||||
# 版本历史
|
||||
|
||||
在 R2006a 之前推出
|
||||
|
||||
# 另请参阅
|
||||
|
||||
[`decimate`](https://ww2.mathworks.cn/help/signal/ref/decimate.html) | [`downsample`](https://ww2.mathworks.cn/help/signal/ref/downsample.html) | [`interp`](https://ww2.mathworks.cn/help/signal/ref/interp.html) | [`interp1`](https://ww2.mathworks.cn/help/matlab/ref/interp1.html) | [`resample`](https://ww2.mathworks.cn/help/signal/ref/resample.html) | [`spline`](https://ww2.mathworks.cn/help/matlab/ref/spline.html) | [`upfirdn`](https://ww2.mathworks.cn/help/signal/ref/upfirdn.html)
|
||||
|
||||
--------------------------------------------------------------------------------
|
||||
在 R2006a 之前推出
|
||||
|
||||
--------------------------------------------------------------------------------
|
||||
原文参考:[https://ww2.mathworks.cn/help/signal/ref/upsample.html](https://ww2.mathworks.cn/help/signal/ref/upsample.html)
|
||||
> 原文参考:[https://ww2.mathworks.cn/help/signal/ref/upsample.html](https://ww2.mathworks.cn/help/signal/ref/upsample.html)
|
||||
|
||||
@@ -5,8 +5,10 @@ tags:
|
||||
- Hexo
|
||||
- Next
|
||||
categories:
|
||||
- [Blog, Hexo, Next]
|
||||
- [Blog, Hexo]
|
||||
abbrlink: e96c9b26
|
||||
copyright: true
|
||||
comments: true
|
||||
date: 2020-11-27 11:15:21
|
||||
---
|
||||
|
||||
|
||||
@@ -9,12 +9,10 @@ tags:
|
||||
- RTL
|
||||
- 寄存器传输级
|
||||
categories:
|
||||
- [Verilog, Verilog 简介]
|
||||
- [Josh 的学习笔记, Verilog]
|
||||
mathjax: true
|
||||
comments: true
|
||||
copyright: true
|
||||
sticky: false
|
||||
toc:
|
||||
enable: true
|
||||
number: false
|
||||
|
||||
@@ -5,13 +5,11 @@ tags:
|
||||
- 翻译
|
||||
- 高斯白噪声
|
||||
categories:
|
||||
- - MATLAB
|
||||
- - 翻译
|
||||
- 帮助文档
|
||||
- - 信号处理
|
||||
- 噪声
|
||||
- [MATLAB, 函数用法]
|
||||
- [信号处理, 噪声]
|
||||
mathjax: true
|
||||
copyright: true
|
||||
comments: true
|
||||
abbrlink: 2f6db45b
|
||||
date: 2020-11-27 01:15:12
|
||||
---
|
||||
@@ -49,14 +47,14 @@ date: 2020-11-27 01:15:12
|
||||
|
||||
创建一个锯齿波。
|
||||
|
||||
```m
|
||||
``` matlab
|
||||
t = (0:0.1:10)';
|
||||
x = sawtooth(t);
|
||||
```
|
||||
|
||||
添加高斯白噪声并绘制结果。
|
||||
|
||||
```m
|
||||
``` matlab
|
||||
y = awgn(x,10,'measured');
|
||||
plot(t,[x y])
|
||||
legend('Original Signal','Signal with AWGN')
|
||||
@@ -72,32 +70,32 @@ legend('Original Signal','Signal with AWGN')
|
||||
|
||||
根据电话线调制解调器的 V.29 标准创建一个 16-QAM 星座。
|
||||
|
||||
```m
|
||||
``` matlab
|
||||
c = [-5 -5i 5 5i -3 -3-3i -3i 3-3i 3 3+3i 3i -3+3i -1 -1i 1 1i];
|
||||
M = length(c);
|
||||
```
|
||||
|
||||
生成随机符号。
|
||||
|
||||
```m
|
||||
``` matlab
|
||||
data = randi([0 M-1],2000,1);
|
||||
```
|
||||
|
||||
使用 `genqammod` 函数调制数据。由于星座图不是矩形,因此必须进行常规 QAM 调制。
|
||||
|
||||
```m
|
||||
``` matlab
|
||||
modData = genqammod(data,c);
|
||||
```
|
||||
|
||||
使信号通过具有 20 dB 信噪比(SNR)的 AWGN 信道。
|
||||
|
||||
```m
|
||||
``` matlab
|
||||
rxSig = awgn(modData,20,'measured');
|
||||
```
|
||||
|
||||
显示接收信号的星座图和参考星座图。
|
||||
|
||||
```m
|
||||
``` matlab
|
||||
h = scatterplot(rxSig);
|
||||
hold on
|
||||
scatterplot(c,[],[],'r*',h)
|
||||
@@ -111,25 +109,25 @@ hold off
|
||||
|
||||
使用 `genqamdemod` 函数解调接收到的信号。计算误符号数和误符号率。
|
||||
|
||||
```m
|
||||
``` matlab 输入
|
||||
demodData = genqamdemod(rxSig,c);
|
||||
[numErrors,ser] = symerr(data,demodData)
|
||||
```
|
||||
|
||||
```no
|
||||
``` plain 输出
|
||||
numErrors = 1
|
||||
ser = 5.0000e-04
|
||||
```
|
||||
|
||||
使用具有 10 dB SNR 的 AWGN 信道重复传输和解调过程。计算降低 SNR 后的误符号率。不出所料,当 SNR 降低时,性能会下降。
|
||||
|
||||
```m
|
||||
``` matlab 输入
|
||||
rxSig = awgn(modData,10,'measured');
|
||||
demodData = genqamdemod(rxSig,c);
|
||||
[numErrors,ser] = symerr(data,demodData)
|
||||
```
|
||||
|
||||
```no
|
||||
``` plain 输出
|
||||
numErrors = 462
|
||||
ser = 0.2310
|
||||
```
|
||||
@@ -140,7 +138,7 @@ ser = 0.2310
|
||||
|
||||
将 X 的功率指定为 0 dBW,添加噪声以产生 10 dB 的 SNR,并利用本地随机流。
|
||||
|
||||
```m
|
||||
``` matlab 输入
|
||||
S = RandStream('mt19937ar','Seed',5489);
|
||||
sigin = sqrt(2)*sin(0:pi/8:6*pi);
|
||||
sigout1 = awgn(sigin,10,0,S);
|
||||
@@ -148,25 +146,25 @@ sigout1 = awgn(sigin,10,0,S);
|
||||
|
||||
将 AWGN 添加到 `sigin`。 使用 [`isequal`](https://ww2.mathworks.cn/help/matlab/ref/isequal.html) 比较 `sigout1` 和 `sigout2`。 当不重置随机流时,输出不相等。
|
||||
|
||||
```m
|
||||
``` matlab 输入
|
||||
sigout2 = awgn(sigin,10,0,S);
|
||||
isequal(sigout1,sigout2)
|
||||
```
|
||||
|
||||
```no
|
||||
``` plain 输出
|
||||
ans = logical
|
||||
0
|
||||
```
|
||||
|
||||
重置随机流对象,将对象置为初始状态,然后再将 AWGN 添加到 `sigout1`。将 AWGN 添加到 `sigin` 并将 `sigout1` 与 `sigout3` 比较。 重置随机流后,输出相等。
|
||||
|
||||
```m
|
||||
``` matlab 输入
|
||||
reset(S);
|
||||
sigout3 = awgn(sigin,10,0,S);
|
||||
isequal(sigout1,sigout3)
|
||||
```
|
||||
|
||||
```no
|
||||
``` plain 输出
|
||||
ans = logical
|
||||
1
|
||||
```
|
||||
@@ -260,6 +258,10 @@ ans = logical
|
||||
>>
|
||||
>> 支持代码生成,但包括 [`RandStream`](https://ww2.mathworks.cn/help/matlab/ref/randstream.html) 对象的语法除外。
|
||||
|
||||
# 版本历史
|
||||
|
||||
在 R2006a 之前推出
|
||||
|
||||
# 另请参阅
|
||||
|
||||
## 函数
|
||||
@@ -274,8 +276,4 @@ ans = logical
|
||||
|
||||
[AWGN Channel Noise Level](https://ww2.mathworks.cn/help/comm/ug/awgn-channel.html#a1071501088)
|
||||
|
||||
--------------------------------------------------------------------------------
|
||||
在 R2006a 之前推出
|
||||
|
||||
--------------------------------------------------------------------------------
|
||||
原文参考:[https://ww2.mathworks.cn/help/comm/ref/awgn.html](https://ww2.mathworks.cn/help/comm/ref/awgn.html)
|
||||
@@ -8,7 +8,6 @@ tags:
|
||||
- 自底向上
|
||||
- Verilog 语法
|
||||
categories:
|
||||
- [Verilog, Verilog 语法]
|
||||
- [Josh 的学习笔记, Verilog]
|
||||
mathjax: true
|
||||
comments: true
|
||||
|
||||
@@ -8,7 +8,6 @@ tags:
|
||||
- 设计层次
|
||||
- Verilog 语法
|
||||
categories:
|
||||
- [Verilog, Verilog 设计]
|
||||
- [Josh 的学习笔记, Verilog]
|
||||
mathjax: true
|
||||
comments: true
|
||||
|
||||
@@ -21,7 +21,6 @@ tags:
|
||||
- 异步复位
|
||||
- 条件语句
|
||||
categories:
|
||||
- [Verilog]
|
||||
- [Josh 的学习笔记, Verilog]
|
||||
abbrlink: ecb88422
|
||||
date: 2020-12-02 01:05:32
|
||||
|
||||
@@ -19,9 +19,7 @@ tags:
|
||||
- 速度
|
||||
- 面积
|
||||
categories:
|
||||
- - Verilog
|
||||
- - Josh 的学习笔记
|
||||
- Verilog
|
||||
- [Josh 的学习笔记, Verilog]
|
||||
abbrlink: 53b8b42e
|
||||
date: 2020-12-05 00:46:00
|
||||
---
|
||||
|
||||
@@ -2,7 +2,7 @@
|
||||
title: 'Josh''s Notes: SystemVerilog 验证 (Part 1 — 验证导论)'
|
||||
mathjax: true
|
||||
comments: true
|
||||
copyright: false
|
||||
copyright: true
|
||||
sticky: false
|
||||
toc:
|
||||
enable: true
|
||||
|
||||
@@ -2,7 +2,7 @@
|
||||
title: 'Josh''s Notes: SystemVerilog 验证 (Part 2 — 数据类型)'
|
||||
mathjax: true
|
||||
comments: true
|
||||
copyright: false
|
||||
copyright: true
|
||||
sticky: false
|
||||
toc:
|
||||
enable: true
|
||||
|
||||
@@ -2,7 +2,7 @@
|
||||
title: 'Josh''s Notes: SystemVerilog 验证 (Part 3 — 过程语句和子程序)'
|
||||
mathjax: true
|
||||
comments: true
|
||||
copyright: false
|
||||
copyright: true
|
||||
sticky: false
|
||||
toc:
|
||||
enable: true
|
||||
|
||||
@@ -4,7 +4,7 @@ tags:
|
||||
- 牛津5000
|
||||
- 英语词汇
|
||||
comments: true
|
||||
copyright: false
|
||||
copyright: true
|
||||
toc:
|
||||
enable: true
|
||||
number: true
|
||||
|
||||
@@ -4,7 +4,7 @@ tags:
|
||||
- 牛津5000
|
||||
- 英语词汇
|
||||
comments: true
|
||||
copyright: false
|
||||
copyright: true
|
||||
toc:
|
||||
enable: true
|
||||
number: true
|
||||
|
||||
Reference in New Issue
Block a user