parallel_operations

Crates.ioparallel_operations
lib.rsparallel_operations
version0.1.4
sourcesrc
created_at2024-11-18 21:33:31.556525
updated_at2024-11-19 02:12:18.696442
descriptionA library to perform binary operations in parallel using threads
homepage
repositoryhttps://github.com/jon429r/parallel_operations
max_upload_size
id1452683
size14,261
Jonathan (jon429r)

documentation

README

Parallel Operations Library

This Rust library provides a set of parallel binary operations such as addition, multiplication, and more. The operations are designed to be computed concurrently using threads, leveraging the power of multiple CPU cores for faster performance.

Features

  • Perform binary operations (e.g., addition, multiplication) concurrently using threads.
  • Automatically adjusts the number of threads based on the available CPU cores.
  • Optimized for large datasets, ideal for high-performance computing.
  • Simple and flexible API to support any binary operation on vectors of numeric types.

Getting Started

To use the parallel_operations crate in your project, follow these steps:

cargo add parallel_operations
use parallel_operations::parallel_binary_operation;

fn main() {
    let data = vec![1, 2, 3, 4, 5];
    
    // Parallel addition
    let addition_result = parallel_binary_operation(data.clone(), |a, b| a + b);
    println!("Addition result: {}", addition_result);
}
Commit count: 5

cargo fmt