shape: Moment difference of two point sets

Description Usage Arguments Author(s) See Also Examples

View source: R/shape.R

Description

Evaluates the multipole moment differences of two 3D point sets; designed to study large-scale differences between dark matter and gas in N-body simulations.

Usage

1
shape(x, y)

Arguments

x

n-by-3 matrix containing the first set of points (e.g. dark matter)

y

m-by-3 matrix containing the second set of points (e.g. gas)

Author(s)

Danail Obreschkow

See Also

sphview4

Examples

1
2
3
4
5
# Generate a mock bullet-cluster and output its quadrupole index
x.gas = cooltools::runif3(4e3)
x.cdm = t(cbind(t(cooltools::runif3(5e3))-c(1,0,0),t(cooltools::runif3(5e3))+c(1,0,0)))
cat(sprintf('Quadrupole index = %.2f\n',shape(x.cdm,x.gas)$mu[3]))
sphview(rbind(x.gas,x.cdm), c(rep(1,4e3),rep(2,1e4)))

obreschkow/simstar documentation built on Jan. 29, 2022, 2:16 p.m.