Skip to content

Commit

Permalink
test(matrices): add chebspec tests
Browse files Browse the repository at this point in the history
  • Loading branch information
AnzhiZhang committed Aug 7, 2024
1 parent 3f67296 commit e3c76d5
Showing 1 changed file with 16 additions and 0 deletions.
16 changes: 16 additions & 0 deletions test/matrices/chebspec.jl
Original file line number Diff line number Diff line change
@@ -0,0 +1,16 @@
# content
@test ChebSpec(5) [5.5 -6.828427124746192 2.0000000000000004 -1.17157287525381 0.5; 1.707106781186548 -0.7071067811865477 -1.4142135623730951 0.7071067811865476 -0.2928932188134525; -0.5000000000000001 1.4142135623730951 -3.061616997868383e-17 -1.414213562373095 0.5; 0.2928932188134525 -0.7071067811865476 1.414213562373095 0.7071067811865474 -1.7071067811865472; -0.5 1.17157287525381 -2.0 6.828427124746189 -5.5]

# eltype
@test test_matrix_elements(ChebSpec{Float32}(5))

# constructors
@test allequal([
ChebSpec(5),
ChebSpec(5, 0),
ChebSpec{Float64}(5),
ChebSpec{Float64}(5, 0),
])

# linear algebra functions
test_linearalgrbra_functions(ChebSpec.(1:5))

0 comments on commit e3c76d5

Please sign in to comment.