Skip to content

Commit 66d75ed

Browse files
authored
Merge pull request #5 from JuliaAlgebra/bl/d17
Cite Dimitrescu's book
2 parents dbb623b + 2ccb598 commit 66d75ed

File tree

4 files changed

+21
-8
lines changed

4 files changed

+21
-8
lines changed

docs/Project.toml

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,6 @@
11
[deps]
22
Documenter = "e30172f5-a6a5-5a46-863b-614d45cd2de4"
33
TrigPolys = "bbdedc48-cb31-4a37-9fe3-b015aecc8dd3"
4+
5+
[compat]
6+
Documenter = "1"

docs/make.jl

Lines changed: 0 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -8,9 +8,6 @@ makedocs(
88
prettyurls = get(ENV, "CI", nothing) == "true"
99
),
1010

11-
# See https://github.com/jump-dev/JuMP.jl/issues/1576
12-
strict = true,
13-
1411
pages = [
1512
"Introduction" => "index.md",
1613
]

docs/src/index.md

Lines changed: 10 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -3,12 +3,18 @@
33
[TrigPolys.jl](https://github.com/yuanchenyang/TrigPolys.jl) is a package for
44
fast manipulation of trigonometric polynomials.
55

6-
7-
A trignometric polynomial is defined on $$x \in [0,2\pi)$$ by
8-
6+
A *Hermitian trigonometric polynomial*
7+
can be viewed as a polynomial `R(z) \\in \\mathbb{C}[z]` [D17, (1.7)]:
98
```math
10-
p(x) = a_0 + \sum_{k=1}^n a_k \cos(kx) + a_{-k} \sin(kx)
9+
R(z) = a_0 + \\frac{1}{2} \\sum_{k=1}^n a_k z^{-k} + a_k^* z^k
1110
```
11+
On the unit circle, this becomes [D17, (1.8)]:
12+
```math
13+
R(\\omega) = a_0 + \\sum_{k=1}^n a_{c,k} \\cos(k\\omega) + a_{s,k} \\sin(k\\omega)
14+
```
15+
where ``a_{c,k}`` is `ac[k]` and ``a_{s,k}`` is `as[k]`.
16+
17+
[D17] Dumitrescu, Bogdan. Positive trigonometric polynomials and signal processing applications. Vol. 103. Berlin: Springer, 2007.
1218

1319
The polynomial $$p(x)$$ can be represented either by $$2n+1$$ coefficients
1420
$$a_k$$ or by evaluations at $$2n+1$$ distinct points in the interval

src/TrigPolys.jl

Lines changed: 8 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -12,7 +12,14 @@ export pad_to, truncate
1212
as::VT # sin coefficients
1313
end
1414
15-
Represents a trigonometric polynomial by its coefficients.
15+
Represents a *Hermitian trigonometric polynomial* by its coefficients.
16+
The vectors `ac` and `as` should have the same length, that we call `n` in this
17+
docstring.
18+
This represent the following function
19+
```julia
20+
R(ω) = a0 + sum(ac[k] * cos(k * ω) + as[k] * sin(k * ω) for k in 1:n)
21+
```
22+
which is a polynomial in the variable `x = cos(ω)`.
1623
"""
1724
struct TrigPoly{T<:AbstractFloat, VT<:AbstractVector{T}}
1825
a0::T # Constant coefficient

0 commit comments

Comments
 (0)