Skip to content

Commit 3d60247

Browse files
committed
Interface change
1 parent 10fa684 commit 3d60247

7 files changed

Lines changed: 14 additions & 18 deletions

File tree

README.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -60,7 +60,7 @@ mesh = meshsphere(1.0, 0.4)
6060
space = raviartthomas(mesh)
6161
operator = Maxwell3D.singlelayer(; wavenumber=1.0)
6262

63-
matrix = CFMM.assemble(operator, space)
63+
matrix = CFMM.assemble(operator, space, space)
6464
result = matrix * rand(scalartype(operator), numfunctions(space))
6565
```
6666

docs/src/assets/examples/efie_results.html

Lines changed: 3 additions & 3 deletions
Large diffs are not rendered by default.

docs/src/assets/examples/mfie_results.html

Lines changed: 3 additions & 3 deletions
Large diffs are not rendered by default.

docs/src/manual/examples.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -40,7 +40,7 @@ excitation = Maxwell3D.planewave(;
4040
)
4141
rhs = assemble((n × excitation) × n, space)
4242

43-
matrix = CFMM.assemble(operator, space)
43+
matrix = CFMM.assemble(operator, space, space)
4444
current, stats = Krylov.gmres(
4545
matrix, rhs; rtol=1.0e-4, itmax=200, history=true, verbose=1
4646
)

examples/efie.jl

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -16,7 +16,7 @@ operator = Maxwell3D.singlelayer(; wavenumber)
1616
excitation = Maxwell3D.planewave(; direction=ẑ, polarization=x̂, wavenumber)
1717
rhs = assemble((n × excitation) × n, space)
1818

19-
matrix = CFMM.assemble(operator, space)
19+
matrix = CFMM.assemble(operator, space, space)
2020
current, stats = Krylov.gmres(matrix, rhs; rtol=1.0e-4, itmax=200, history=true, verbose=1)
2121

2222
@show stats

src/CFMM/assemble.jl

Lines changed: 0 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -20,7 +20,6 @@ using ..CorrectionFactorMatrixMethod:
2020

2121
"""
2222
assemble(operator, testspace, trialspace; kwargs...)
23-
assemble(operator, space; kwargs...)
2423
2524
Assemble a matrix-free correction-factor FMM operator.
2625
@@ -59,8 +58,4 @@ function assemble(
5958
)
6059
end
6160

62-
function assemble(operator, space; kwargs...)
63-
return assemble(operator, space, space; kwargs...)
64-
end
65-
6661
end

test/test_operators.jl

Lines changed: 5 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -35,11 +35,12 @@
3535
testoperator(operator, scalarproblems)
3636
end
3737

38-
# Single-space convenience form assemble(op, space)
38+
# Matching spaces use the symmetric FMM.
3939
scalar_problem = last(scalarproblems)
40+
operator = Helmholtz3D.singlelayer(; wavenumber=k)
4041
square_matrix = CFMM.assemble(
41-
Helmholtz3D.singlelayer(; wavenumber=k), scalar_problem.testspace
42+
operator, scalar_problem.testspace, scalar_problem.testspace
4243
)
43-
@test size(square_matrix) ==
44-
(length(scalar_problem.testspace), length(scalar_problem.testspace))
44+
@test square_matrix.fmm.fmm isa CorrectionFactorMatrixMethod.SymmetricFMM
45+
@test_throws MethodError CFMM.assemble(operator, scalar_problem.testspace)
4546
end

0 commit comments

Comments
 (0)