Skip to content

Commit

Permalink
notation: W(x), not w(x)
Browse files Browse the repository at this point in the history
  • Loading branch information
stevengj committed Jul 25, 2023
1 parent 7565a9c commit a1c5077
Show file tree
Hide file tree
Showing 2 changed files with 8 additions and 8 deletions.
4 changes: 2 additions & 2 deletions docs/src/api.md
Original file line number Diff line number Diff line change
Expand Up @@ -27,7 +27,7 @@ QuadGK.gauss(::Type{<:AbstractFloat}, ::Integer)
QuadGK.kronrod(::Type{<:AbstractFloat}, ::Integer)
```

More generally, to compute rules for $\int_a^b w(x) f(x) dx$ (weighted integrals, as described in [Gaussian quadrature and arbitrary weight functions](@ref)), use the following methods if you know the [Jacobi matrix](https://en.wikipedia.org/wiki/Jacobi_operator) for the orthogonal
More generally, to compute rules for $\int_a^b W(x) f(x) dx$ (weighted integrals, as described in [Gaussian quadrature and arbitrary weight functions](@ref)), use the following methods if you know the [Jacobi matrix](https://en.wikipedia.org/wiki/Jacobi_operator) for the orthogonal
polynomials associated with your weight function:

```@docs
Expand All @@ -36,7 +36,7 @@ QuadGK.kronrod(::AbstractMatrix{<:Real}, ::Integer, ::Real)
QuadGK.HollowSymTridiagonal
```

Most generally, if you know only the weight function $w(x)$ and the interval $(a,b)$, you
Most generally, if you know only the weight function $W(x)$ and the interval $(a,b)$, you
can construct Gauss and Gauss–Kronrod rules completely numerically using:

```@docs
Expand Down
12 changes: 6 additions & 6 deletions docs/src/gauss-kronrod.md
Original file line number Diff line number Diff line change
Expand Up @@ -228,16 +228,16 @@ julia> setprecision(50, base=10); x, w, gw = kronrod(BigFloat, 5); x
More generally, one can compute quadrature rules for a **weighted** integral:

```math
\int_a^b w(x) f(x) dx \approx \sum_{i=1}^n w_i f(x_i)
\int_a^b W(x) f(x) dx \approx \sum_{i=1}^n w_i f(x_i)
```
where the effect of **weight function** $w(x)$ (usually required to be $≥ 0$ in ``(a,b)``) is
where the effect of **weight function** $W(x)$ (usually required to be $≥ 0$ in ``(a,b)``) is
included in the quadrature weights $w_i$ and points $x_i$. The main motivation
for weighted quadrature rules is to handle *poorly behaved* integrands — singular, discontinuous, highly oscillatory, and so on — where the "bad" behavior is *known*
and can be *factored out* into $w(x)$. By designing a quadrature rule with $w(x)$
and can be *factored out* into $W(x)$. By designing a quadrature rule with $W(x)$
taken into account, one can obtain fast convergence as long as the remaining
factor $f(x)$ is smooth, regardless of how "bad" $w(x)$ is. Moreover, the rule
can be re-used for many different $f(x)$ as long as $w(x)$ remains the same.
factor $f(x)$ is smooth, regardless of how "bad" $W(x)$ is. Moreover, the rule
can be re-used for many different $f(x)$ as long as $W(x)$ remains the same.

The QuadGK package can compute both Gauss and Gauss–Kronrod quadrature rules
for arbitrary weight functions $w(x)$, to arbitrary precision, as described
for arbitrary weight functions $W(x)$, to arbitrary precision, as described
in the section: [Gaussian quadrature and arbitrary weight functions](@ref).

0 comments on commit a1c5077

Please sign in to comment.