Advertisement
Guest User

Untitled

a guest
Mar 22nd, 2018
71
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.46 KB | None | 0 0
  1. # Nome do aluno:João Pedro Fonseca do Amaral
  2. # Matrícula:96894
  3. # Data:22/03/2018
  4. # (calcula equações)
  5.  
  6. import math
  7.  
  8. g = 9.80665
  9.  
  10. v0= float(input("Type the value of v0 (km/h):"))
  11. theta= float(input("Type the value of theta (degrees):"))
  12.  
  13. v0= v0/ 3.6
  14. theta= math.radians(theta)
  15.  
  16. Xmax= ((v0**2)*(math.sin(2*theta)))/g
  17. print('Maximum range = %0.3f' % Xmax, 'meters')
  18.  
  19. Ymax= ((v0)*(math.sin(theta)))**2/(2*g)
  20. print('Maximum height = %0.3f' % Ymax, 'meters')
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement