@@ -3,23 +3,19 @@ import ApproxFunBase: recA, recB, recC, transform!, itransform!
33import ApproxFunBaseTest: testspace
44import ApproxFunOrthogonalPolynomials: forwardrecurrence
55
6- @testset " Chebyshev" begin
6+ @verbose @ testset " Chebyshev" begin
77 @testset " Forward recurrence" begin
88 @test forwardrecurrence (Float64,Chebyshev (),0 : 9 ,1.0 ) == ones (10 )
99 end
1010
1111 @testset " ChebyshevInterval" begin
12- @test @inferred Fun (x-> 2 ,10 )(.1 ) ≈ 2
13- @test @inferred Fun (x-> 2 )(.1 ) ≈ 2
14- @test @inferred Fun (Chebyshev,Float64[]).([0. ,1. ]) ≈ [0. ,0. ]
15- @test @inferred Fun (Chebyshev,[])(0. ) ≈ 0.
16- @test @inferred Fun (x-> 4 ,Chebyshev (),1 ). coefficients == [4.0 ]
17- @test @inferred Fun (x-> 4 ). coefficients == [4.0 ]
18- @test @inferred Fun (4 ). coefficients == [4.0 ]
19-
20-
21- @test @inferred Fun (x-> 4 ). coefficients == [4.0 ]
22- @test @inferred Fun (4 ). coefficients == [4.0 ]
12+ @test @inferred (Fun (x-> 2 ,10 ))(.1 ) ≈ 2
13+ @test Fun (x-> 2 )(.1 ) ≈ 2
14+ @test @inferred (Fun (Chebyshev, Float64[])). ([0. ,1. ]) ≈ [0. ,0. ]
15+ @test Fun (Chebyshev, [])(0. ) ≈ 0.
16+ @test @inferred (Fun (x-> 4 , Chebyshev (), 1 )). coefficients == [4.0 ]
17+ @test Fun (x-> 4 ). coefficients == [4.0 ]
18+ @test @inferred (Fun (4 )). coefficients == [4.0 ]
2319
2420 f = @inferred Fun (ChebyshevInterval (), [1 ])
2521 @test f (0.1 ) == 1
@@ -61,8 +57,8 @@ import ApproxFunOrthogonalPolynomials: forwardrecurrence
6157
6258 r= 2 .* rand (100 ) .- 1
6359
64- @test @inferred maximum (abs,ef .(r)- exp .(r))< 200 eps ()
65- @test @inferred maximum (abs,ecf .(r).- cos .(r).* exp .(r))< 200 eps ()
60+ @test @inferred ( maximum (abs,ef .(r)- exp .(r))) < 200 eps ()
61+ @test @inferred ( maximum (abs,ecf .(r).- cos .(r).* exp .(r))) < 200 eps ()
6662
6763 @test (@inferred (cf .* ef)(0.1 )) ≈ ecf (0.1 ) ≈ cos (0.1 )* exp (0.1 )
6864 @test (@inferred domain (cf.* ef)) ≈ domain (ecf)
@@ -108,8 +104,8 @@ import ApproxFunOrthogonalPolynomials: forwardrecurrence
108104 ef = Fun (exp,1 .. 2 )
109105 cf = Fun (cos,1 .. 2 )
110106
111- ecf = Fun (x-> cos (x). *exp (x),1 .. 2 )
112- eocf = Fun (x-> cos (x). /exp (x),1 .. 2 )
107+ ecf = Fun (x-> cos (x)* exp (x),1 .. 2 )
108+ eocf = Fun (x-> cos (x)/ exp (x),1 .. 2 )
113109
114110 r= rand (100 ) .+ 1
115111 x= 1.5
@@ -216,16 +212,16 @@ import ApproxFunOrthogonalPolynomials: forwardrecurrence
216212 end
217213
218214 @testset " inplace transform" begin
219- @testset for T in [ Float32, Float64] , ET in Any[ T, complex (T)]
220- v = Array {ET} (undef, 10 )
215+ @testset for T in ( Float32, Float64) , ET in ( T, complex (T))
216+ v = Array {ET} (undef, 6 )
221217 v2 = similar (v)
222- M = Array {ET} (undef, 10 , 10 )
218+ M = Array {ET} (undef, 6 , 6 )
223219 M2 = similar (M)
224- A = Array {ET} (undef, 10 , 10 , 10 )
220+ A = Array {ET} (undef, 6 , 6 , 6 )
225221 A2 = similar (A)
226- @testset for d in Any[( ), (0 .. 1 ,)]
222+ @testset for d in (( ), (0 .. 1 ,))
227223 C = Chebyshev (d... )
228- Slist = Any[ C, NormalizedPolynomialSpace (C)]
224+ Slist = ( C, NormalizedPolynomialSpace (C))
229225 @testset for S in Slist
230226 test_transform! (v, v2, S)
231227 end
0 commit comments