from math import cos, sin







def  __lowerCAmelCase							(						__SCREAMING_SNAKE_CASE    : float					):







    '''simple docstring'''
    __snake_case    :							str             =  float(__SCREAMING_SNAKE_CASE					)
    return [[scaling_factor * int(x == y					) for x in range(2					)] for y in range(2					)]







def  __lowerCAmelCase							(						__SCREAMING_SNAKE_CASE    : float					):







    '''simple docstring'''
    __snake_case       ,      __snake_case    :							List[Any]             =  cos(__SCREAMING_SNAKE_CASE					), sin(__SCREAMING_SNAKE_CASE					)
    return [[c, -s], [s, c]]







def  __lowerCAmelCase							(						__SCREAMING_SNAKE_CASE    : float					):







    '''simple docstring'''
    __snake_case       ,      __snake_case    :							Tuple             =  cos(__SCREAMING_SNAKE_CASE					), sin(__SCREAMING_SNAKE_CASE					)
    __snake_case    :							List[str]             =  c * s
    return [[c * c, cs], [cs, s * s]]







def  __lowerCAmelCase							(						__SCREAMING_SNAKE_CASE    : float					):







    '''simple docstring'''
    __snake_case       ,      __snake_case    :							Tuple             =  cos(__SCREAMING_SNAKE_CASE					), sin(__SCREAMING_SNAKE_CASE					)
    __snake_case    :							Optional[int]             =  c * s
    return [[2 * c - 1, 2 * cs], [2 * cs, 2 * s - 1]]


print(F'''    {scaling(5) = }''')
print(F'''  {rotation(45) = }''')
print(F'''{projection(45) = }''')






print(F'''{reflection(45) = }''')





"""simple docstring"""

import doctest

import projectq
from projectq.ops import H, Measure




def 			lowercase__  (    lowerCAmelCase :    projectq.cengines._main.MainEngine       )       ->					int:






    """simple docstring"""




    UpperCAmelCase  	=    quantum_engine.allocate_qubit()
    H | qubit
    Measure | qubit
    return int(lowerCAmelCase       )


if __name__ == "__main__":
   doctest.testmod()

   # initialises a new quantum backend
   SCREAMING_SNAKE_CASE_			    =  projectq.MainEngine()

   # Generate a list of 10 random numbers
   SCREAMING_SNAKE_CASE_			    =  [get_random_number(quantum_engine) for _ in range(10)]

   # Flushes the quantum engine from memory
   quantum_engine.flush()

   print('''Random numbers''', random_numbers_list)



