from math import radians as angle_to_radians
from math import sin

# Acceleration Constant on Earth (unit m/s^2)
__SCREAMING_SNAKE_CASE						:    Union[str, Any]     = 9.8_06_65
def 					snake_case						(__lowercase					,			__lowercase						)       ->       List[Any]:

						'''simple docstring'''



						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 					snake_case						(__lowercase					,			__lowercase						)       ->       List[str]:

						'''simple docstring'''



						check_args(lowerCamelCase_					,			lowerCamelCase_						)
						_snake_case						:     Tuple				=    angle_to_radians(2 * angle						)
						return round(init_velocity**2 * sin(lowerCamelCase_						) / g					,			2						)
def 					snake_case						(__lowercase					,			__lowercase						)       ->       Optional[int]:

						'''simple docstring'''



						check_args(lowerCamelCase_					,			lowerCamelCase_						)
						_snake_case						:     List[Any]				=    angle_to_radians(lowerCamelCase_						)
						return round(init_velocity**2 * sin(lowerCamelCase_						) ** 2 / (2 * g)					,			2						)
def 					snake_case						(__lowercase					,			__lowercase						)       ->       Optional[Any]:

						'''simple docstring'''



						check_args(lowerCamelCase_					,			lowerCamelCase_						)
						_snake_case						:     Optional[Any]				=    angle_to_radians(lowerCamelCase_						)
						return round(2 * init_velocity * sin(lowerCamelCase_						) / g					,			2						)
def 					snake_case						()       ->       List[Any]:

						'''simple docstring'''



						_snake_case						:     int				=    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
				__SCREAMING_SNAKE_CASE						:    int     = float(input('Initial Velocity: ').strip())

				# Get input from user
				__SCREAMING_SNAKE_CASE						:    int     = 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'''


from typing import TYPE_CHECKING

from ...utils import OptionalDependencyNotAvailable, _LazyModule, is_torch_available


snake_case__     :			Optional[Any]      			=  {'''configuration_nat''': ['''NAT_PRETRAINED_CONFIG_ARCHIVE_MAP''', '''NatConfig''']}


try:
 if not is_torch_available():
  raise OptionalDependencyNotAvailable()
except OptionalDependencyNotAvailable:
 pass
else:
 snake_case__     :			Tuple      			=  [
     '''NAT_PRETRAINED_MODEL_ARCHIVE_LIST''',
     '''NatForImageClassification''',
     '''NatModel''',
     '''NatPreTrainedModel''',
     '''NatBackbone''',
 ]

if TYPE_CHECKING:
 from .configuration_nat import NAT_PRETRAINED_CONFIG_ARCHIVE_MAP, NatConfig

 try:
  if not is_torch_available():
   raise OptionalDependencyNotAvailable()
 except OptionalDependencyNotAvailable:
  pass
 else:
  from .modeling_nat import (
      NAT_PRETRAINED_MODEL_ARCHIVE_LIST,
      NatBackbone,
      NatForImageClassification,
      NatModel,
      NatPreTrainedModel,
  )

else:
 import sys

 snake_case__     :			int      			=  _LazyModule(__name__, globals()['''__file__'''], _import_structure, module_spec=__spec__)






