Model random motion until a target is reached. Compute expected times with robust parameter checks. Run Monte Carlo trials and download clean summary files.
First passage time (FPT) is the time required for a stochastic trajectory to reach a boundary or target for the first time. For diffusion with coefficient D, the mean FPT follows the backward equation:
Sample input sets and expected analytic outputs (using consistent units).
| Case | Model | D | Geometry | Analytic / characteristic time |
|---|---|---|---|---|
| 1 | Absorb at 0 and L | 0.50 | L = 2.0, x0 = 0.5 | x0(L-x0)/D = 1.5000 |
| 2 | Reflect at 0, absorb at L | 0.25 | L = 3.0, x0 = 1.0 | (L^2-x0^2)/(2D) = 16.0000 |
| 3 | Ball exit time | 1.00 | a = 5.0, r0 = 2.0, d = 3 | (a^2-r0^2)/(2dD) = 3.5000 |
| 4 | Unbounded target | 0.10 | L = 4.0, x0 = 1.0 | tau=(L-x0)^2/(2D)=45.0000 |
First passage time (FPT) is the random time needed for a fluctuating quantity to reach a target for the first time. In diffusion problems, it answers “how long until a particle hits a boundary?” rather than “where is it after time t”. FPT statistics control reaction rates, transport delays, and failure probabilities in many physical systems.
For a diffusing particle, trajectories wander with typical displacement scaling as sqrt(2Dt). Boundaries turn this wandering into an event: absorption corresponds to capture, escape, or detection. Reflecting walls enforce confinement without capture, changing the time distribution and lowering long delays.
This calculator includes bounded 1D intervals and an absorbing d-dimensional ball. With absorbing boundaries at both ends of an interval, the particle is removed once it touches either edge. With reflection at one end and absorption at the other, the motion “bounces” and is eventually captured.
Mean FPT values come from solving the backward equation D∇²T = −1 with the selected boundary conditions. In a 1D interval with absorption at 0 and L, the mean is x0(L−x0)/D. For a reflecting 0 and absorbing L setup, the mean becomes (L²−x0²)/(2D). For a dD ball, the mean exit time is (a²−r0²)/(2dD).
These formulas show clear scaling: doubling a length scale multiplies times by roughly four, while doubling D halves times. Sensitivity is strongest near boundaries because x0 close to an absorbing edge produces short expected times. Using consistent units for length and D is essential for interpretable outputs.
The simulation option uses Euler stepping with Gaussian increments of variance 2Ddt. Smaller dt improves boundary resolution but increases steps, so run-time rises. The tool reports hit rate, mean, spread, and percentiles, helping you compare analytic predictions with sampling.
Use the analytic mean as a baseline and the simulated percentiles to communicate variability. A high standard deviation relative to the mean indicates a broad distribution with occasional long trajectories. Exported CSV summaries are convenient for lab notes, while the print view is suited for quick PDF records.
FPT models appear in diffusion-limited reactions, charge transport, neuron firing thresholds, microfluidic escape, and reliability problems where a variable crosses a failure level. Unbounded targets can have divergent means, so the calculator labels such cases and provides a characteristic scale. For rigorous studies, refine dt, increase trials, and verify convergence against known benchmarks.
The mean is the average over many trials, while a percentile (like p90) is a threshold time that 90% of hits occur below. Percentiles describe spread and skew better than a single average.
In some unbounded diffusion settings, the true mean first passage time can diverge even though hits occur. The tool reports a typical scale based on (L−x0)²/(2D) and labels it clearly.
Choose dt small enough that trajectories do not “jump” across boundaries too coarsely. If results change noticeably when halving dt, dt is too large. Smaller dt increases computation, so balance accuracy and speed.
Hit rate is the fraction of simulated trials that reached the target before the max-step limit. Low hit rate suggests the max steps are too small, dt is too small for the limit, or the domain is effectively unbounded.
Differences arise from finite sampling, time-step discretization, and timeouts. Increase N, reduce dt, and raise max steps to improve agreement. Analytic means apply to ideal continuous diffusion with the stated boundaries.
Any consistent unit system works. If length is in meters and time in seconds, use D in m^2/s. If you switch to centimeters, convert D accordingly to keep the output time meaningful.
The analytic mean is exact for diffusion in a ball with absorbing boundary. The simulation uses full d-dimensional Brownian steps and checks radius crossing, which is a standard approximation. Convergence improves with smaller dt and more trials.
Important Note: All the Calculators listed in this site are for educational purpose only and we do not guarentee the accuracy of results. Please do consult with other sources as well.