Utility functions

NESSie.meshunionFunction
meshunion(
    model1::Model{T, Tetrahedron{T}},
    model2::Model{T, Tetrahedron{T}}
)

Merges two volume models, e.g., the models of a protein and the solvent. Duplicate nodes (e.g., the nodes on the protein surface) are merged into a single node, duplicate elements and charges (if any) are retained as well as the system constants of the first model.

Return type

Model{T, Tetrahedron{T}}

Note

This function assumes that there are no duplicates within either of the node lists!

source
NESSie.obspoints_lineFunction
obspoints_line(
    u::AbstractVector{T},
    v::AbstractVector{T},
    n::Int
)

Generates n evenly distributed observation points along the line segment from u to v.

Return type

Generator -> Vector{T}

Example

for ξ in obspoints_line([0, 0, 0], [1, 1, 1], 10)
    ...
end
source
NESSie.obspoints_planeFunction
obspoints_plane(
    a  ::AbstractVector{T},
    b  ::AbstractVector{T},
    c  ::AbstractVector{T},
    nba::Int,
    nbc::Int
)

Generates nbanbc evenly distributed observation points on the parallelogram with the sides $\overline{BA}$ and $\overline{BC}$ and a, b, c being the location vectors to the points $A$, $B$, and $C$, respectively.

Arguments

  • nba Number of observation points along $\overline{BA}$
  • nbc Number of observation points along $\overline{BC}$

Return type

Generator -> Vector{T}

Example

for Ξ in obspoints_plane(...)
    for ξ in Ξ
        ...
    end
end
source