onstruct a random path for N particles (see Example in python done in class).
The direction is continuous between 0 and 360 °.
There is a probability of movement associated with each quadrant of the circle (see image at the end).
Each particle has its own random probability of movement.
Read these probabilities of a text file.
The grid is closed ([url removed, login to view]).
Example of execution
Python [url removed, login to view] timeSteps minX maxX minY maxY [url removed, login to view]
MinX maxX minY maxY, are the limits of the grid.
[url removed, login to view] contains the 4 probabilities (4 quadrants) for each particle
0.25 0.25 0.25 0.25 mu1 sigma1
0.10 0.10 0.40 0.40 mu2 sigma2
This means that there are 2 particles (as many lines as the file contains):
The first particle has the following probabilities associated:
Quadrant 1: 0.25
Quadrant 2: 0.25
Quadrant 3: 0.25
Quadrant 4: 0.25
The second particle has the following probabilities associated:
Quadrant 1: 0.10
Quadrant 2: 0.10
Quadrant 3: 0.40
Quadrant 4: 0.40
Once the address is chosen, the size of the particle's pitch must be generated.
The size of the pitch follows a normal distribution with mean mu and sigma deviation, each particle has a value for the mean and deviation assigned in the txt file (see above).
Particle 1: mu1 sigma1
Particle 2: mu2 sigma2.
Mu and sigma are real values.
Contemplate any additional parameters that may be necessary.
NOTE: Remember that the grating where the particles move is a torus.