-
Notifications
You must be signed in to change notification settings - Fork 1
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
add package extension for Meshes.jl (#63)
* add package extension for Meshes.jl * documentation at more places * add Meshes to docs/Project.toml * bump lower compar of StaticArrays to v1.2.12 * bump lower compat of StaticArrays in tests to v1.2.12 * bump lower compat of StaticArrays to v1.9 * prefix sample to avoid namespace conflict * skip problematic test for Windows * fix * fix typo * format
- Loading branch information
1 parent
6933647
commit 2ef5169
Showing
14 changed files
with
92 additions
and
18 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,9 +1,11 @@ | ||
[deps] | ||
Documenter = "e30172f5-a6a5-5a46-863b-614d45cd2de4" | ||
Meshes = "eacbb407-ea5a-433e-ab97-5258b1ca43fa" | ||
Plots = "91a5bcdd-55d7-5caf-9e0b-520d859cae80" | ||
QuasiMonteCarlo = "8a4e6c94-4038-4cdc-81c3-7e6ffdb2a71b" | ||
|
||
[compat] | ||
Documenter = "1" | ||
Meshes = "0.46" | ||
Plots = "1.9" | ||
QuasiMonteCarlo = "0.3" |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,23 @@ | ||
module KernelInterpolationMeshesExt | ||
|
||
using Meshes: Meshes, Point, PointSet, to | ||
using KernelInterpolation: KernelInterpolation | ||
|
||
# Meshes.jl uses Unitful.jl for units, which is not available in KernelInterpolation.jl | ||
# Thus, we need to remove the units from the Point struct | ||
val(u) = u.val | ||
val(p::Point) = val.(to(p)) | ||
|
||
function KernelInterpolation.NodeSet(points::Vector{P}) where P <: Point | ||
return KernelInterpolation.NodeSet(val.(points)) | ||
end | ||
|
||
function KernelInterpolation.NodeSet(points::PointSet) | ||
return KernelInterpolation.NodeSet(points.geoms) | ||
end | ||
|
||
function Meshes.PointSet(nodes::KernelInterpolation.NodeSet) | ||
return Meshes.PointSet(Tuple.(nodes.nodes)) | ||
end | ||
|
||
end |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters