Description Usage Arguments Details Value References Examples
The function generates uni-dimensional chebyshev nodes.
1 | chebnodegen(n, a, b)
|
n |
A number of nodes |
a |
The lower bound of inverval [a,b] |
b |
The upper bound of interval [a,b] |
A polynomial approximant s_{i} over a bounded interval [a,b] is constructed by:
s_{i} = \frac{b+a}{2} + \frac{b-a}{2}cos (\frac{n - i + 0.5 }{n} π ) for i = 1,2,\cdots,n.
More detail explanation can be refered from Miranda and Fackler (2002, p.119).
An array n Chebyshev nodes
Miranda, Mario J. and Paul L. Fackler. (2002) Applied Computational Economics and Finance. Cambridge: The MIT Press.
1 2 3 4 | ## 10 Chebyshev nodes in [-1,1]
chebnodegen(10,-1,1)
## 5 Chebyshev nodes in [1,5]
chebnodegen(5,1,5)
|
[1] -0.9876883 -0.8910065 -0.7071068 -0.4539905 -0.1564345 0.1564345
[7] 0.4539905 0.7071068 0.8910065 0.9876883
[1] 1.097887 1.824429 3.000000 4.175571 4.902113
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.