





from math import atan, cos, radians, sin, tan

from .haversine_distance import haversine_distance

_lowercase		:  List[Any]			       =637_8137.0
_lowercase		:  Union[str, Any]			       =635_6752.31_4245
_lowercase		:  Any			       =637_8137


def 		_SCREAMING_SNAKE_CASE     ( lowerCAmelCase__							,lowerCAmelCase__							,lowerCAmelCase__							,lowerCAmelCase__						):
		lowerCamelCase_	:     Union[str, Any] 						=      (AXIS_A - AXIS_B) / AXIS_A
		# Parametric latitudes
		# https://en.wikipedia.org/wiki/Latitude#Parametric_(or_reduced)_latitude
		lowerCamelCase_	:     List[Any] 						=      atan((1 - flattening) * tan(radians(lowerCAmelCase__						)						)						)
		lowerCamelCase_	:     Optional[Any] 						=      atan((1 - flattening) * tan(radians(lowerCAmelCase__						)						)						)

		# Compute central angle between two points
		# using haversine theta. sigma =  haversine_distance / equatorial radius
		lowerCamelCase_	:     str 						=      haversine_distance(lowerCAmelCase__							,lowerCAmelCase__							,lowerCAmelCase__							,lowerCAmelCase__						) / EQUATORIAL_RADIUS

		# Intermediate P and Q values
		lowerCamelCase_	:     Dict 						=      (b_lata + b_lata) / 2
		lowerCamelCase_	:     List[str] 						=      (b_lata - b_lata) / 2

		# Intermediate X value
		# X = (sigma - sin(sigma)) * sin^2Pcos^2Q / cos^2(sigma/2)
		lowerCamelCase_	:     Union[str, Any] 						=      (sin(lowerCAmelCase__						) ** 2) * (cos(lowerCAmelCase__						) ** 2)
		lowerCamelCase_	:     Union[str, Any] 						=      cos(sigma / 2						) ** 2
		lowerCamelCase_	:     Union[str, Any] 						=      (sigma - sin(lowerCAmelCase__						)) * (x_numerator / x_demonimator)

		# Intermediate Y value
		# Y = (sigma + sin(sigma)) * cos^2Psin^2Q / sin^2(sigma/2)
		lowerCamelCase_	:     str 						=      (cos(lowerCAmelCase__						) ** 2) * (sin(lowerCAmelCase__						) ** 2)
		lowerCamelCase_	:     str 						=      sin(sigma / 2						) ** 2
		lowerCamelCase_	:     str 						=      (sigma + sin(lowerCAmelCase__						)) * (y_numerator / y_denominator)

		return EQUATORIAL_RADIUS * (sigma - ((flattening / 2) * (x_value + y_value)))


if __name__ == "__main__":
		import doctest

		doctest.testmod()







def 		_SCREAMING_SNAKE_CASE     ( lowerCAmelCase__=2_81_23						):
		lowerCamelCase_	:     Any 						=      [1] * (limit + 1)

		for i in range(2							,int(limit**0.5						) + 1						):
				sum_divs[i * i] += i
				for k in range(i + 1							,limit // i + 1						):
						sum_divs[k * i] += k + i

		lowerCamelCase_	:     List[str] 						=      set()
		lowerCamelCase_	:     List[str] 						=      0

		for n in range(1							,limit + 1						):
				if sum_divs[n] > n:
						abundants.add(lowerCAmelCase__						)

				if not any((n - a in abundants) for a in abundants						):
						res += n

		return res


if __name__ == "__main__":
		print(solution())
