Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- import math
- def _1_2_3____ (_ ):
- return ((_ -1 /3 )*(_ -1 /2 ))
- # new approximation function
- def _1_2_3_444 (_ ,_22_2 ,_123_4_11 ):
- return abs (_ -_22_2 )<=10 **-_123_4_11
- def __ (__x_1__ ,__x__2_ ,____ ):
- __0_0000_00000 =[]
- __y_1 =____ (__x_1__ )
- __y_2____ =____ (__x__2_ )
- if __y_1 ==0 :
- __0_0000_00000 .append (__x_1__ )
- if __y_2____ ==0 :
- __0_0000_00000 .append (__x__2_ )
- if __y_1 *__y_2____ <0 :
- _x_ =(__x_1__ +__x__2_ )/2
- _y =____ (_x_ )
- if _1_2_3_444 (_y ,0 ,18 ):
- print (_x_ )
- __0_0000_00000 .append (_x_ )
- if __y_1 *_y <0 :
- _1__3 =__ (__x_1__ ,_x_ ,____ )
- print (_1__3 )
- __0_0000_00000 .extend (_1__3 )
- if __y_2____ *_y <0 :
- _1__3 =__ (_x_ ,__x__2_ ,____ )
- print (_1__3 )
- __0_0000_00000 .extend (_1__3 )
- return __0_0000_00000
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement