





"""simple docstring"""
from math import asin, atan, cos, radians, sin, sqrt, tan

__A       =		6_3_7_8_1_3_7.0
__A       =		6_3_5_6_7_5_2.3_1_4_2_4_5
__A       =		6_3_7_8_1_3_7



def 					__lowerCamelCase       (							a_					:		str			,       a_					:		Tuple			,       a_					:		List[Any]			,       a_					:		Optional[Any]							)      ->				float:
      __SCREAMING_SNAKE_CASE       :Union[str, Any]		    =  (AXIS_A - AXIS_B) / AXIS_A
      __SCREAMING_SNAKE_CASE       :Dict		    =  atan((1 - flattening) * tan(radians(lowerCamelCase_							)							)							)
      __SCREAMING_SNAKE_CASE       :Any		    =  atan((1 - flattening) * tan(radians(lowerCamelCase_							)							)							)
      __SCREAMING_SNAKE_CASE       :Optional[Any]		    =  radians(lowerCamelCase_							)
      __SCREAMING_SNAKE_CASE       :Tuple		    =  radians(lowerCamelCase_							)
      # Equation
      __SCREAMING_SNAKE_CASE       :Optional[int]		    =  sin((phi_a - phi_a) / 2							)
      __SCREAMING_SNAKE_CASE       :int		    =  sin((lambda_a - lambda_a) / 2							)
      # Square both values
      sin_sq_phi *= sin_sq_phi
      sin_sq_lambda *= sin_sq_lambda
      __SCREAMING_SNAKE_CASE       :Any		    =  sqrt(sin_sq_phi + (cos(lowerCamelCase_							) * cos(lowerCamelCase_							) * sin_sq_lambda)							)
      return 2 * RADIUS * asin(lowerCamelCase_							)


if __name__ == "__main__":
  import doctest

  doctest.testmod()






"""simple docstring"""
import math
import random



def 					__lowerCamelCase       (							a_					:		float			,       a_					:		bool = False							)      ->				float:
      if deriv:
            return value * (1 - value)
      return 1 / (1 + math.exp(-value							))


# Initial Value
lowerCamelCase_       =		0.02



def 					__lowerCamelCase       (							a_					:		int			,       a_					:		int							)      ->				float:
      __SCREAMING_SNAKE_CASE       :Any		    =  float(2 * (random.randint(1			,       1_00							)) - 1							)

      for _ in range(a_							):
            # Forward propagation
            __SCREAMING_SNAKE_CASE       :Any		    =  sigmoid_function(INITIAL_VALUE * weight							)
            # How much did we miss?
            __SCREAMING_SNAKE_CASE       :Tuple		    =  (expected / 1_00) - layer_a
            # Error delta
            __SCREAMING_SNAKE_CASE       :Union[str, Any]		    =  layer_1_error * sigmoid_function(a_			,       a_							)
            # Update weight
            weight += INITIAL_VALUE * layer_1_delta

      return layer_a * 1_00


if __name__ == "__main__":
  import doctest

  doctest.testmod()

  lowerCamelCase_       =		int(input("Expected value: "))
  lowerCamelCase_       =		int(input("Number of propagations: "))
  print(forward_propagation(expected, number_propagations))