Description Usage Arguments Examples
Sphere field generator using harmonc fx and transformation matrix
1 2 | my.sphere.field(n = 5, k = runif(1), n.mesh = 32, scale.shift = 0.1,
scale.rotation1 = 0.1, scale.rotation2 = 0.1, scale.shear = 0.1)
|
n |
depth of sphere harmonic functions |
k |
simple sphere radius |
n.mesh |
fineness of mesh |
scale.shift |
scale of shift |
scale.rotation1 |
scale of rotation 1 |
scale.rotation2 |
scale of rotation 2 |
scale.shear |
scale of shear |
1 2 3 4 5 6 7 8 9 10 | library(rgl)
library(RFOC)
out <- my.sphere.field()
# ”¼Œa‚ðF‚Å
col1 <- col2 <- rep(0,length(out$v[,1]))
col1[which(out$v[,1]>=0)] <- out$v[,1][which(out$v[,1]>=0)]
col2[which(out$v[,1]<0)] <- -out$v[,1][which(out$v[,1]<0)]
col1 <- col1/max(col1)
col2 <- col2/max(col2)
plot3d(out$mesh$x,col=rgb(1-col1,1-col2,0),size=10)
|
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.