API Reference

ExaFMMt.ExaFMMType
ExaFMM{K, O} <: LinearMaps.LinearMap{K}

Represents an FMM matrix and can be multiplied by a vector containing the source charges. This type owns C++ storage and releases it through close! or its finalizer.

Fields

  • fmmoptions::FMMOptions: Initializer, either LaplaceFMMOptions, HelmholtzFMMOptions, or ModifiedHelmholtzFMMOptions.
  • nsources::Int: Number of sources.
  • ntargets::Int: Number of targets.
  • fmm::Ptr{Cvoid}: Pointer to the FMM struct generated by the C++ part.
  • fmmstruct::Ptr{Cvoid}: Pointer to a struct with the required C++ substructs.
  • sources::Ptr{Cvoid}: Pointer to the C++ struct of the sources.
  • targets::Ptr{Cvoid}: Pointer to the C++ struct of the targets.
source
ExaFMMt.HelmholtzFMMOptionsType
HelmholtzFMMOptions{I, C} <: FMMOptions

Helmholtz initializer for the setup function.

Fields

  • p::I: Multipole expansion order.
  • ncrit::I: Minimum number of points in each box of the tree.
  • wavek::C: Wavenumber.
source
ExaFMMt.LaplaceFMMOptionsType
LaplaceFMMOptions{I} <: FMMOptions

Laplace initializer for the setup function.

Fields

  • p::I: Multipole expansion order.
  • ncrit::I: Minimum number of points in each box of the tree.
source
ExaFMMt.ModifiedHelmholtzFMMOptionsType
ModifiedHelmholtzFMMOptions{I, F} <: FMMOptions

Modified-Helmholtz initializer for the setup function.

Fields

  • p::I: Multipole expansion order.
  • ncrit::I: Minimum number of points in each box of the tree.
  • wavek::F: Wavenumber.
source
ExaFMMt.HelmholtzFMMMethod
HelmholtzFMM(wavek::ComplexF32; p=8, ncrit=100)

Initializer for the Helmholtz-FMM in the C++ part.

Arguments

  • wavek::ComplexF32: Wavenumber.
  • p::Int: Multipole expansion order.
  • ncrit::Int: Minimum number of points in each box of the tree.
source
ExaFMMt.HelmholtzFMMMethod
HelmholtzFMM(wavek::ComplexF64; p=8, ncrit=100)

Initializer for the Helmholtz-FMM in the C++ part.

Arguments

  • wavek::ComplexF64: Wavenumber.
  • p::Int: Multipole expansion order.
  • ncrit::Int: Minimum number of points in each box of the tree.
source
ExaFMMt.LaplaceFMM32Method
LaplaceFMM32(;ncrit=100, p=8)

Initializer for the Laplace-FMM in the C++ part.

Arguments

  • p::Int: Multipole expansion order.
  • ncrit::Int: Minimum number of points in each box of the tree.
source
ExaFMMt.LaplaceFMM64Method
LaplaceFMM64(;ncrit=100, p=8)

Initializer for the Laplace-FMM in the C++ part.

Arguments

  • p::Int: Multipole expansion order.
  • ncrit::Int: Minimum number of points in each box of the tree.
source
ExaFMMt.ModifiedHelmholtzFMMMethod
ModifiedHelmholtzFMM(wavek::Float32; ncrit=100, p=8)

Initializer for the modified-Helmholtz-FMM in the C++ part.

Arguments

  • wavek::Float32: Wavenumber.
  • p::Int: Multipole expansion order.
  • ncrit::Int: Minimum number of points in each box of the tree.
source
ExaFMMt.ModifiedHelmholtzFMMMethod
ModifiedHelmholtzFMM(wavek::Float64; ncrit=100, p=8)

Initializer for the modified-Helmholtz-FMM in the C++ part.

Arguments

  • wavek::Float64: Wavenumber.
  • p::Int: Multipole expansion order.
  • ncrit::Int: Minimum number of points in each box of the tree.
source
ExaFMMt.clear_valuesMethod
clear_values(fmmstruct::Ptr{Cvoid}, T::Type{ComplexF32})

Clears the solution values in the FMM structure.

Arguments

  • fmmstruct::Ptr{Cvoid}: Pointer to a struct with the required C++ substructs.
  • T: Type must be ComplexF32 or ComplexF64 for Helmholtz-FMM and Float32 or Float64 for Laplace or Modified-Helmholtz-FMM.
source
ExaFMMt.clear_valuesMethod
clear_values(fmmstruct::Ptr{Cvoid}, T::Type{ComplexF64})

Clears the solution values in the FMM structure.

Arguments

  • fmmstruct::Ptr{Cvoid}: Pointer to a struct with the required C++ substructs.
  • T: Type must be ComplexF32 or ComplexF64 for Helmholtz-FMM and Float32 or Float64 for Laplace or Modified-Helmholtz-FMM.
source
ExaFMMt.clear_valuesMethod
clear_values(fmmstruct::Ptr{Cvoid}, T::Type{Float32})

Clears the solution values in the FMM structure.

Arguments

  • fmmstruct::Ptr{Cvoid}: Pointer to a struct with the required C++ substructs.
  • T: Type must be ComplexF32 or ComplexF64 for Helmholtz-FMM and Float32 or Float64 for Laplace or Modified-Helmholtz-FMM.
source
ExaFMMt.clear_valuesMethod
clear_values(fmmstruct::Ptr{Cvoid}, T::Type{Float64})

Clears the solution values in the FMM structure.

Arguments

  • fmmstruct::Ptr{Cvoid}: Pointer to a struct with the required C++ substructs.
  • T: Type must be ComplexF32 or ComplexF64 for Helmholtz-FMM and Float32 or Float64 for Laplace or Modified-Helmholtz-FMM.
source
ExaFMMt.close!Method
close!(x::ExaFMM)

Release the C++ storage owned by x.

Calling close! more than once is safe. Closed objects cannot be evaluated or multiplied again.

source
ExaFMMt.evaluateMethod
evaluate(
    A::ExaFMM{C},
    x::Vector{C},
    fmmoptions::HelmholtzFMMOptions{I, C}
) where {I, C <: Complex}

Evaluates the prebuilt FMM structure A for new values x.

Arguments

  • A::ExaFMM{C}: ExaFMM structure with pointers to all allocated variables.
  • x::Vector{C}: Values of for example the charge at each source location.
  • fmmoptions::HelmholtzFMMOptions{I, C}: Julia Helmholtz initializer for the setup function, used as identifier.
source
ExaFMMt.evaluateMethod
evaluate(
    A::ExaFMM{F},
    x::Vector{F},
    fmmoptions::LaplaceFMMOptions{I}
) where {I, F <: Real}

Evaluates the prebuilt FMM structure A for new values x.

Arguments

  • A::ExaFMM{F}: ExaFMM structure with pointers to all allocated variables.
  • x::Vector{F}: Values of for example the charge at each source location.
  • fmmoptions::LaplaceFMMOptions{I}: Julia Laplace-initializer for setup function, used as identifier.
source
ExaFMMt.evaluateMethod
evaluate(
    A::ExaFMM{F},
    x::Vector{F},
    fmmoptions::ModifiedHelmholtzFMMOptions{I, F}
) where {I, F <: Real}

Evaluates the prebuilt FMM structure A for new values x.

Arguments

  • A::ExaFMM{F}: ExaFMM structure with pointers to all allocated variables.
  • x::Vector{F}: Values of for example the charge at each source location.
  • fmmoptions::ModifiedHelmholtzFMMOptions{I, F}: Julia modified-Helmholtz initializer for the setup function, used as identifier.
source
ExaFMMt.freeC!Method
freeC!(x::ExaFMM{ComplexF32})

Frees the storage which is allocated by the C++ part for Helmholtz-FMM.

Arguments

  • x::ExaFMM{ComplexF64}: ExaFMM structure with pointers to all allocated variables.
source
ExaFMMt.freeC!Method
freeC!(x::ExaFMM{ComplexF64})

Frees the storage which is allocated by the C++ part for Helmholtz-FMM.

Arguments

  • x::ExaFMM{ComplexF64}: ExaFMM structure with pointers to all allocated variables.
source
ExaFMMt.freeF!Method
freeF!(x::ExaFMM{Float32})

Frees the storage which is allocated by the C++ part for the Laplace-FMM and Modified-Helmholtz-FMM.

Arguments

  • x::ExaFMM{Float32}: ExaFMM structure with pointers to all allocated variables.
source
ExaFMMt.freeF!Method
freeF!(x::ExaFMM{Float64})

Frees the storage which is allocated by the C++ part for the Laplace-FMM and Modified-Helmholtz-FMM.

Arguments

  • x::ExaFMM{Float64}: ExaFMM structure with pointers to all allocated variables.
source
ExaFMMt.init_sourcesMethod
init_sources(points::Matrix{F}, charges::Vector{C}) where {F <: Real, C <: Complex}

Creates struct for sources and charges in the C++ part from the Julia matrix. Complex charges are used for the Helmholtz-FMM.

Arguments

  • points::Matrix{F}: 3d-coordinates of sources.
  • charges::Vector{C}: Values of for example the charge at each source location.
source
ExaFMMt.init_sourcesMethod
init_sources(points::Matrix{F}, charges::Vector{F}) where F <: Real

Creates struct for sources and charges in the C++ part from the Julia matrix. Real charges are used and mandatory for the Laplace- and Modified-Helmholtz-FMM.

Arguments

  • points::Matrix{F}: 3d-coordinates of sources.
  • charges::Vector{F}: Values of for example the charge at each source location.
source
ExaFMMt.init_targetsMethod
init_targets(points::Matrix{F}, T::Type) where F <: Real

Creates struct for targets in the C++ part from a Julia matrix of points.

Arguments

  • points::Matrix{C}: 3d-coordinates of targets.
  • T: Type must be set for the Helmholtz-FMM to ComplexF32 or ComplexF64.
source
ExaFMMt.setupMethod
setup(
    sources::Matrix{F},
    targets::Matrix{F},
    fmmoptions::HelmholtzFMMOptions{I, Complex{F}}
) where {I, F <: Real}

Sets the FMM structure up in the C++ part and allocates all mandatory storage.

Arguments

  • sources::Matrix{F}: 3d-coordinates of sources.
  • targets::Matrix{F}: 3d-coordinates of targets.
  • fmmoptions::HelmholtzFMMOptions{I, Complex{F}}: Julia Helmholtz initializer for the setup function.
source
ExaFMMt.setupMethod
setup(
    sources::Matrix{F},
    targets::Matrix{F}, 
    fmmoptions::LaplaceFMMOptions{I}
) where {I, F <: Real}

Sets the FMM structure up in the C++ part and allocates all mandatory storage.

Arguments

  • sources::Matrix{F}: 3d-coordinates of sources.
  • targets::Matrix{F}: 3d-coordinates of targets.
  • fmmoptions::LaplaceFMMOptions{I}: Julia Laplace-initializer for setup function.
source
ExaFMMt.setupMethod
setup(
    sources::Matrix{F},
    targets::Matrix{F},
    fmmoptions::ModifiedHelmholtzFMMOptions{I, F}
) where {I, F <: Real}

Sets the FMM structure up in the C++ part and allocates all mandatory storage.

Arguments

  • sources::Matrix{F}: 3d-coordinates of sources.
  • targets::Matrix{F}: 3d-coordinates of targets.
  • fmmoptions::ModifiedHelmholtzFMMOptions{I, F}: Julia modified-Helmholtz-initializer for setup function.
source
ExaFMMt.update_chargesMethod
update_charges(fmmstruct::Ptr{Cvoid}, charges::Vector{ComplexF32})

Updates charges in already generated Helmholtz-FMM. Requires a ComplexF32 array of charges.

Arguments

  • fmmstruct::Ptr{Cvoid}: Pointer to a struct with the required C++ substructs.
  • charges::Vector{ComplexF32}: Values of for example the charge at each source location.
source
ExaFMMt.update_chargesMethod
update_charges(fmmstruct::Ptr{Cvoid}, charges::Vector{ComplexF64})

Updates charges in already generated Helmholtz-FMM. Requires a ComplexF64 array of charges.

Arguments

  • fmmstruct::Ptr{Cvoid}: Pointer to a struct with the required C++ substructs.
  • charges::Vector{ComplexF64}: Values of for example the charge at each source location.
source
ExaFMMt.update_chargesMethod
update_charges(fmmstruct::Ptr{Cvoid}, charges::Vector{Float32})

Updates charges in an already generated Laplace or Modified-Helmholtz-FMM. Requires a Float32 array of charges.

Arguments

  • fmmstruct::Ptr{Cvoid}: Pointer to a struct with the required C++ substructs.
  • charges::Vector{Float32}: Values of for example the charge at each source location.
source
ExaFMMt.update_chargesMethod
update_charges(fmmstruct::Ptr{Cvoid}, charges::Vector{Float64})

Updates charges in an already generated Laplace or Modified-Helmholtz-FMM. Requires a Float64 array of charges.

Arguments

  • fmmstruct::Ptr{Cvoid}: Pointer to a struct with the required C++ substructs.
  • charges::Vector{Float64}: Values of for example the charge at each source location.
source
ExaFMMt.verifyMethod
verify(exafmm::ExaFMM{ComplexF32}, fmmoptions::HelmholtzFMMOptions{I, ComplexF32}) where I

Computes the accuracy of the evaluated FMM exafmm.

Arguments

  • exafmmm::ExaFMM: ExaFMM structure with pointers to all allocated variables.
  • fmmoptions::HelmholtzFMMOptions{I, ComplexF32}: Julia Helmholtz initializer for the setup function, used as identifier.
source
ExaFMMt.verifyMethod
verify(exafmm::ExaFMM{ComplexF64}, fmmoptions::HelmholtzFMMOptions{I, ComplexF64}) where I

Computes the accuracy of the evaluated FMM exafmm.

Arguments

  • exafmmm::ExaFMM: ExaFMM structure with pointers to all allocated variables.
  • fmmoptions::HelmholtzFMMOptions{I, ComplexF64}: Julia Helmholtz initializer for the setup function, used as identifier.
source
ExaFMMt.verifyMethod
verify(exafmm::ExaFMM{Float32}, fmmoptions::LaplaceFMMOptions{I}) where I

Computes the accuracy of the evaluated FMM exafmm.

Arguments

  • exafmm::ExaFMM{Float32}: ExaFMM structure with pointers to all allocated variables.
  • fmmoptions::LaplaceFMMOptions{I}: Julia Laplace-initializer for setup function, used as identifier.
source
ExaFMMt.verifyMethod
verify(exafmm::ExaFMM{Float32}, fmmoptions::ModifiedHelmholtzFMMOptions{I, Float32})

Computes the accuracy of the evaluated FMM exafmm.

Arguments

  • exafmm::ExaFMM{Float32}: ExaFMM structure with pointers to all allocated variables.
  • fmmoptions::ModifiedHelmholtzFMMOptions{I, Float32}: Julia modified-Helmholtz-initializer for setup function, used as identifier.
source
ExaFMMt.verifyMethod
verify(exafmm::ExaFMM{Float64}, fmmoptions::LaplaceFMMOptions{I}) where I

Computes the accuracy of the evaluated FMM exafmm.

Arguments

  • exafmm::ExaFMM{Float64}: ExaFMM structure with pointers to all allocated variables.
  • fmmoptions::LaplaceFMMOptions{I}: Julia Laplace-initializer for setup function, used as identifier.
source
ExaFMMt.verifyMethod
verify(exafmm::ExaFMM{Float64}, fmmoptions::ModifiedHelmholtzFMMOptions{I, Float64})

Computes the accuracy of the evaluated FMM exafmm.

Arguments

  • exafmm::ExaFMM{Float64}: ExaFMM structure with pointers to all allocated variables.
  • fmmoptions::ModifiedHelmholtzFMMOptions{I, Float64}: Julia modified-Helmholtz-initializer for setup function, used as identifier.
source