Skip to content

Latest commit

 

History

History
101 lines (67 loc) · 3.91 KB

File metadata and controls

101 lines (67 loc) · 3.91 KB

Jedvek

crates.io docs.rs Build Status Build Status GitHub stars

Jedvek /jɛdvɛk/ [derived from the Czech jednorozměrný (one-dimensional) + vektor (vector)] is a Rust library for multidimensional data structures backed by a contiguous 1D memory footprint.

Installation

Add Jedvek as a dependency in your Cargo.toml:

Via Crates.io (Recommended)

To use the latest stable release, add jedvek as a dependency:

[dependencies]
jedvek = "0.X.X" # Always use the latest version available on crates.io

Or, use Cargo:

cargo add jedvek

Via Git Repository (Latest Development Build)

[dependencies]
jedvek = { git = "https://github.com/lignum-vitae/jedvek.git" }

Then run:

cargo build

Matrices

The Matrix2D struct provides a convenient way to use a two-dimensional matrix that is a one-dimensional vector under the hood. This allows for efficient memory usage while enabling standard matrix operations.

Matrix2D implements a wide range of methods and traits, including:

  • Linear Algebra: dot product, inverse, transpose.
  • Arithmetic: Implementations of multiplication by matrices, vectors, and scalars and division by scalars
  • Manipulation: shape, size, full, reshape, map
  • Conversion: from_flat, From, TryFrom
  • Utility: new, max, min, is_empty

Project layout

Within these crates, the following modules jedvek::<module name> are provided

Module Description
- Matrix2D struct and implementations
substitution Backward and forward substitution algorithms
decomposition Decomposition algorithms including LU decomposition and LU decomposition with partial pivoting

Running Examples

Working examples of the available algorithms as well as a full list of available algorithms can be found in the examples/ directory.

Run any example with the following command:

cargo run --example <example_name>

Do not include .rs when running examples.

Contributing

We welcome contributions! Please read our:

Note

Before submitting a PR, install just and run just check to pull the latest changes from the main branch as well as to format, test, and lint your code. Just can be installed using cargo install just, curl, or your favourite package manager.

Stay connected via our Discord Server

Stability

This project is in the alpha stage. APIs may change without warning until version 1.0.0.

Special Mentions

A special thank you to Mittei for his contributions to the Spindalis project. The Arr2D implementation he authored serves as the structural backbone for Jedvek’s Matrix2D struct.