Description Usage Arguments Value See Also Examples
Given the details of a rectangular boundary in 1, 2 or 3 dimensions, and a diffusion constant, simulate the brownian trajectories of particles.
1 2 | bbm_simulate(n_particles, D, dim, time_interval = 1, end_time,
init_pos = NULL)
|
n_particles |
A natural number. The number of particles to use in the simulation. |
D |
The diffusivity constant. |
dim |
A vector giving the dimensions of the simulation space. |
time_interval |
The time interval between observations. |
end_time |
The time at which the simulation should end. The last timpoint in the simulation will be before or at this time. |
init_pos |
An n x d matrix giving the initial positions of the |
An object of class bbm_sim
: a tibble with d + 2
columns, where d
is the number of dimensions in the space of the
simulation. One column for time, one for the particle ID number and the
other d
for the positions of the particles in d
-dimensional space.
1 | bbm_simulate(n_particles = 2, D = 1.5, dim = c(3, 5), end_time = 2)
|
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.