@@ -152,7 +152,7 @@ for i in 1:5
152
152
153
153
end
154
154
155
- # Construct 5 arbitrary RobinBC operators w/non-uniform grid
155
+ # Test complex Robin BC, w/non-uniform grid
156
156
al = rand (ComplexF64,5 )
157
157
bl = rand (ComplexF64,5 )
158
158
cl = rand (ComplexF64,5 )
@@ -198,19 +198,21 @@ for j in 1:2
198
198
end
199
199
end
200
200
201
- # Test Neumann and Dirichlet as special cases of RobinBC
202
- dx = [0.121 , 0.783 , 0.317 , 0.518 , 0.178 ]
203
- αC = (0.539 + 0.653im , 0.842 + 0.47im )
204
- αR = (0.045 , 0.577 )
205
- @test NeumannBC (αC, dx). b_l ≈ - 0.065219 - 0.079013im
206
- @test DirichletBC (αR... ). b_r ≈ 0.577
207
- @test DirichletBC (Float64, αC... ) ≈ 0.123 # broken
208
-
209
- @test Dirichlet0BC (Float64). a_r ≈ [- 0.0 ,0.0 ]
210
- @test Neumann0BC (dx). a_r ≈ [0.3436293436293436 ]
211
- @test Neumann0BC (ComplexF64,dx). a_l ≈ [0.15453384418901658 + 0.0im ]
212
-
213
- @test NeumannBC (αC, first (dx)). b_r ≈ 0.101882 + 0.05687im
214
- @test Neumann0BC (first (dx)). a_r ≈ [1.0 - 0.0im ]
215
- @test Neumann0BC (ComplexF64,first (dx)). a_l ≈ [1.0 + 0.0im ]
216
-
201
+ # Test NeumannBC, DirichletBC as special cases of RobinBC
202
+ let
203
+ dx = [0.121 , 0.783 , 0.317 , 0.518 , 0.178 ]
204
+ αC = (0.539 + 0.653im , 0.842 + 0.47im )
205
+ αR = (0.045 , 0.577 )
206
+ @test NeumannBC (αC, dx). b_l ≈ - 0.065219 - 0.079013im
207
+ @test DirichletBC (αR... ). b_r ≈ 0.577
208
+ @test DirichletBC (Float64, αC... ). b_l ≈ 0.539 + 0.653im
209
+ @test DirichletBC (Float64, αC... ). a_r ≈ [- 0.0 + 0.0im , 0.0 + 0.0im ]
210
+
211
+ @test Dirichlet0BC (Float64). a_r ≈ [- 0.0 ,0.0 ]
212
+ @test Neumann0BC (dx). a_r ≈ [0.3436293436293436 ]
213
+ @test Neumann0BC (ComplexF64,dx). a_l ≈ [0.15453384418901658 + 0.0im ]
214
+
215
+ @test NeumannBC (αC, first (dx)). b_r ≈ 0.101882 + 0.05687im
216
+ @test Neumann0BC (first (dx)). a_r ≈ [1.0 - 0.0im ]
217
+ @test Neumann0BC (ComplexF64,first (dx)). a_l ≈ [1.0 + 0.0im ]
218
+ end
0 commit comments