Description Usage Arguments Examples

View source: R/diffraction.line.R

Return a diffraction line to be added to a plot, given a vector of in-plane wavenumbers (k)

1 | ```
diffraction.line(k, kgx, kgv, m, n, phi = 0, alpha = pi/2)
``` |

`k` |
in-plane wavenumbers. |

`kgx` |
the grating vector of the (phi=0) periodicity (2*pi/pitch) |

`kgv` |
the grating vector of the out-of-plane periodicity (2*pi/pitch) |

`m` |
in-plane scattering integer |

`n` |
out-of-plane scattering integer |

`phi` |
azimuthal angle away from kgx (phi=0 along kgx) in radians |

`alpha` |
angle between the two grating vectors in radians |

1 2 3 4 5 6 7 8 9 10 11 | ```
##---- Should be DIRECTLY executable !! ----
##-- ==> Define data, use random,
##-- or do help(data=index) for the standard data sets.
## The function is currently defined as
function (k, kgx, kgv, m, n, phi = 0, alpha = pi/2)
{
return(data.frame(k = k, omega = 3e+08 * (sqrt(((k * cos(phi) +
m * kgx - n * kgv * cos(alpha))^2) + ((k * sin(phi) -
n * kgv * sin(alpha))^2)))))
}
``` |

Embedding an R snippet on your website

Add the following code to your website.

For more information on customizing the embed code, read Embedding Snippets.