#NEWLINE# def test_tilbert_relation( self ) : #NEWLINE# #INDENT# for n in [ 16 , 17 , 64 , 127 ] : #NEWLINE# #INDENT# x = ( ( ( arange ( n ) * 2 ) * pi ) / n ) #NEWLINE# f = ( sin ( x ) + ( cos ( ( 2 * x ) ) * sin ( y2 ) ) ) #NEWLINE# y = hilbert ( f ) #NEWLINE# y1 = direct_hilbert ( f ) #NEWLINE# assert_array_almost_equal ( y , y1 ) #NEWLINE# y2 = tilbert ( f , h = 10 ) #NEWLINE# assert_array_almost_equal ( y , y2 )