Crates.io | topology-traits |
lib.rs | topology-traits |
version | 0.1.2 |
source | src |
created_at | 2021-08-12 16:01:06.27493 |
updated_at | 2023-06-01 18:20:57.770167 |
description | Topological traits for generic mathematics in Rust. |
homepage | |
repository | https://github.com/NicolasKlenert/topology-traits |
max_upload_size | |
id | 435296 |
size | 7,204 |
Topological traits for generic mathematics in Rust.
This crate is supposed to be an extension to num-traits. That is, often one has to work with more than simple numbers, for example Points in 3D space. topology-traits
aims to define traits describing element relationships in various mathematical spaces and properties of these spaces.
Add this to your Cargo.toml
:
[dependencies]
topology-traits = "0.1"
At the moment this crate contains traits to describe the distance of two elements and the points lying between those two elements. Hereby we define
For certain elements calculating the shortest path between two elements may be costly, such the trait Topology
allows to implement the calculation of the shortest path separately. Such algorithms are able to use this trait to gain performance if they need multiple properties between two elements.
This crate can be used without the standard library (#![no_std]
) by disabling the default std
feature. Use this in Cargo.toml:
[dependencies.topology-traits]
version = "0.1"
default-features = false
features = ["libm"]
If you have a requirement for elements in mind which describes a mathematical property which is not numerical in nature and which is not covered by this crate yet, please tell us about it and create a new issue.
Furthermore all contributions are welcome, no matter how huge or tiny.
Licensed under either of
at your option.
Unless you explicitly state otherwise, any contribution intentionally submitted for inclusion in the work by you, as defined in the Apache-2.0 license, shall be dual licensed as above, without any additional terms or conditions.