
"""simple docstring"""
from math import radians as angle_to_radians
from math import sin

# Acceleration Constant on Earth (unit m/s^2)
lowercase		:    Union[str, Any]			=       9.80_665


def      lowerCamelCase_     (						lowerCamelCase_						,					lowerCamelCase_			)  ->      None:


					'''simple docstring'''

					# Ensure valid instance
					if not isinstance(lowerCamelCase_						,					(int, float)			):
										raise TypeError("""Invalid velocity. Should be a positive number."""			)

					if not isinstance(lowerCamelCase_						,					(int, float)			):
										raise TypeError("""Invalid angle. Range is 1-90 degrees."""			)

					# Ensure valid angle
					if angle > 90 or angle < 1:
										raise ValueError("""Invalid angle. Range is 1-90 degrees."""			)

					# Ensure valid velocity
					if init_velocity < 0:
										raise ValueError("""Invalid velocity. Should be a positive number."""			)


def      lowerCamelCase_     (						lowerCamelCase_						,					lowerCamelCase_			)  ->      float:


					'''simple docstring'''
					check_args(lowerCamelCase_						,					lowerCamelCase_			)
					__a:    Any		     =       angle_to_radians(2 * angle			)
					return round(init_velocity**2 * sin(lowerCamelCase_			) / g						,					2			)


def      lowerCamelCase_     (						lowerCamelCase_						,					lowerCamelCase_			)  ->      float:


					'''simple docstring'''
					check_args(lowerCamelCase_						,					lowerCamelCase_			)
					__a:    Any		     =       angle_to_radians(lowerCamelCase_			)
					return round(init_velocity**2 * sin(lowerCamelCase_			) ** 2 / (2 * g)						,					2			)


def      lowerCamelCase_     (						lowerCamelCase_						,					lowerCamelCase_			)  ->      float:


					'''simple docstring'''
					check_args(lowerCamelCase_						,					lowerCamelCase_			)
					__a:    Union[str, Any]		     =       angle_to_radians(lowerCamelCase_			)
					return round(2 * init_velocity * sin(lowerCamelCase_			) / g						,					2			)


def      lowerCamelCase_     (						)  ->      None:


					'''simple docstring'''
					__a     ,					__a:    Optional[Any]		     =       25, 20
					assert horizontal_distance(lowerCamelCase_						,					lowerCamelCase_			) == 40.97
					assert max_height(lowerCamelCase_						,					lowerCamelCase_			) == 3.73
					assert total_time(lowerCamelCase_						,					lowerCamelCase_			) == 1.74


if __name__ == "__main__":
			from doctest import testmod

			testmod()

			# Get input from user
			lowercase		:    str			=       float(input('Initial Velocity: ').strip())

			# Get input from user
			lowercase		:    List[Any]			=       float(input('angle: ').strip())

			# Print results
			print()
			print('Results: ')
			print(F"Horizontal Distance: {horizontal_distance(init_vel, angle)!s} [m]")
			print(F"Maximum Height: {max_height(init_vel, angle)!s} [m]")
			print(F"Total Time: {total_time(init_vel, angle)!s} [s]")


"""simple docstring"""
def      lowerCamelCase_     (						lowerCamelCase_						,					lowerCamelCase_ = 2			)  ->      float:


					'''simple docstring'''
					return round((float(lowerCamelCase_			) * 9 / 5) + 32						,					lowerCamelCase_			)


def      lowerCamelCase_     (						lowerCamelCase_						,					lowerCamelCase_ = 2			)  ->      float:


					'''simple docstring'''
					return round(float(lowerCamelCase_			) + 273.15						,					lowerCamelCase_			)


def      lowerCamelCase_     (						lowerCamelCase_						,					lowerCamelCase_ = 2			)  ->      float:


					'''simple docstring'''
					return round((float(lowerCamelCase_			) * 9 / 5) + 491.67						,					lowerCamelCase_			)


def      lowerCamelCase_     (						lowerCamelCase_						,					lowerCamelCase_ = 2			)  ->      float:


					'''simple docstring'''
					return round((float(lowerCamelCase_			) - 32) * 5 / 9						,					lowerCamelCase_			)


def      lowerCamelCase_     (						lowerCamelCase_						,					lowerCamelCase_ = 2			)  ->      float:


					'''simple docstring'''
					return round(((float(lowerCamelCase_			) - 32) * 5 / 9) + 273.15						,					lowerCamelCase_			)


def      lowerCamelCase_     (						lowerCamelCase_						,					lowerCamelCase_ = 2			)  ->      float:


					'''simple docstring'''
					return round(float(lowerCamelCase_			) + 459.67						,					lowerCamelCase_			)


def      lowerCamelCase_     (						lowerCamelCase_						,					lowerCamelCase_ = 2			)  ->      float:


					'''simple docstring'''
					return round(float(lowerCamelCase_			) - 273.15						,					lowerCamelCase_			)


def      lowerCamelCase_     (						lowerCamelCase_						,					lowerCamelCase_ = 2			)  ->      float:


					'''simple docstring'''
					return round(((float(lowerCamelCase_			) - 273.15) * 9 / 5) + 32						,					lowerCamelCase_			)


def      lowerCamelCase_     (						lowerCamelCase_						,					lowerCamelCase_ = 2			)  ->      float:


					'''simple docstring'''
					return round((float(lowerCamelCase_			) * 9 / 5)						,					lowerCamelCase_			)


def      lowerCamelCase_     (						lowerCamelCase_						,					lowerCamelCase_ = 2			)  ->      float:


					'''simple docstring'''
					return round((float(lowerCamelCase_			) - 491.67) * 5 / 9						,					lowerCamelCase_			)


def      lowerCamelCase_     (						lowerCamelCase_						,					lowerCamelCase_ = 2			)  ->      float:


					'''simple docstring'''
					return round(float(lowerCamelCase_			) - 459.67						,					lowerCamelCase_			)


def      lowerCamelCase_     (						lowerCamelCase_						,					lowerCamelCase_ = 2			)  ->      float:


					'''simple docstring'''
					return round((float(lowerCamelCase_			) * 5 / 9)						,					lowerCamelCase_			)


def      lowerCamelCase_     (						lowerCamelCase_						,					lowerCamelCase_ = 2			)  ->      float:


					'''simple docstring'''
					return round((float(lowerCamelCase_			) * 1.25 + 273.15)						,					lowerCamelCase_			)


def      lowerCamelCase_     (						lowerCamelCase_						,					lowerCamelCase_ = 2			)  ->      float:


					'''simple docstring'''
					return round((float(lowerCamelCase_			) * 2.25 + 32)						,					lowerCamelCase_			)


def      lowerCamelCase_     (						lowerCamelCase_						,					lowerCamelCase_ = 2			)  ->      float:


					'''simple docstring'''
					return round((float(lowerCamelCase_			) * 1.25)						,					lowerCamelCase_			)


def      lowerCamelCase_     (						lowerCamelCase_						,					lowerCamelCase_ = 2			)  ->      float:


					'''simple docstring'''
					return round((float(lowerCamelCase_			) * 2.25 + 32 + 459.67)						,					lowerCamelCase_			)


if __name__ == "__main__":
			import doctest

			doctest.testmod()
