Advertisement
hiddenGem

Speed of a Relativistic Particle

Aug 6th, 2020
81
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
MatLab 0.36 KB | None | 0 0
  1. %% Speed of a Relativistic Particle
  2. % Determines the average speed of the particles in terms of the speed of
  3. % light
  4.  
  5. % Constants
  6. c = 3.00*10^8
  7.  
  8. % Inputs and Variables
  9. l = input('Particle Tracks\n');
  10. Tau = input('Lifetime of the particle\n');
  11.  
  12. % Outputs and Equations
  13. v = (1/sqrt(1+l^2/(c^2*Tau^2)))*l/Tau;
  14. B = v/c;
  15. pfrintf('The average speed is %.4f\n',B)
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement