Description Usage Arguments Value References See Also Examples
View source: R/rank_one_tensor.R
This function applies the operator given as a rank-one tensor defines rank one operator defined as: "(g1 'otimes' g2)(f) = <f,g2>g1"
1 | rank_one_tensor(g1, g2, f)
|
g1 |
The function |
g2 |
The function |
f |
The discretized function |
Vector of the same size as f
representing the discretized function - the result of the application "(g1 'otimes' g2)(f)".
Rubin, Panaretos. Simulation of stationary functional time series with given spectral density. arXiv, 2020
kernel_operator
, filter_simulate
1 2 3 4 5 6 7 8 9 10 11 12 | # define kernel
g1 <- function(x){ exp(x^2) }
g2 <- function(x){ sin(x) }
# discretize sinus function
grid <- seq(0,1, length.out = 101)
f <- sin(grid)
# apply onto function
plot(f, type="l", col="blue", ylim=c(-0.5,1))
lines( rank_one_tensor(g1,g2,f), col="red" )
legend("topleft",c("f","<f,g2>g1"), col=c("blue","red"), lty=1)
|
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.