pendulum {geostats} | R Documentation |
3-magnet pendulum experiment
Description
Simulates the 3-magnet pendulum experiment, starting at a specified position with a given start velocity.
Usage
pendulum(
startpos = c(-2, 2),
startvel = c(0, 0),
src = rbind(c(0, 0), c(0.5, sqrt(0.75)), c(1, 0)),
plot = TRUE
)
Arguments
startpos |
2-element vecotor with the initial position |
startvel |
2-element vector with the initial velocity |
src |
|
plot |
logical. If |
Value
the end position of the pendulum
Examples
p <- par(mfrow=c(1,2))
pendulum(startpos=c(2.1,2))
pendulum(startpos=c(1.9,2))
par(p)
[Package geostats version 1.6 Index]