Coder Social home page Coder Social logo

pg_linearalgebra's Introduction

pg_linearalgebra

A PostgreSQL extension for basic linear algebra operations.

Functions

mAdd(matrix1: &str, matrix2: &str, rows: i32, cols: i32) -> Result<String, &'static str>

Adds two matrices.

Example

SELECT mAdd('[[1.0, 2.0], [3.0, 4.0]]', '[[5.0, 6.0], [7.0, 8.0]]', 2, 2);

mSubtract(matrix1: &str, matrix2: &str, rows: i32, cols: i32) -> Result<String, &'static str>

Subtracts matrix2 from matrix1.

Example

SELECT mSubtract('[[1.0, 2.0], [3.0, 4.0]]', '[[5.0, 6.0], [7.0, 8.0]]', 2, 2);

mMultiply(matrix1: &str, matrix2: &str, rows: i32, cols: i32) -> Result<String, &'static str>

Multiplies two matrices.

Example

SELECT mMultiply('[[1.0, 2.0], [3.0, 4.0]]', '[[5.0, 6.0], [7.0, 8.0]]', 2, 2);

mTranspose(matrix: &str, rows: i32, cols: i32) -> Result<String, &'static str>

Transposes a matrix.

Example

SELECT mTranspose('[[1.0, 2.0], [3.0, 4.0]]', 2, 2);

mSvd(matrix: &str, rows: i32, cols: i32) -> Result<String, &'static str>

Computes the Singular Value Decomposition of a matrix.

Example

SELECT mSvd('[[1.0, 2.0], [3.0, 4.0], [5.0, 6.0]]', 3, 2);

pg_linearalgebra's People

Contributors

joshuajerin avatar

Stargazers

Ian Stanton avatar  avatar Evan H Stanton avatar

Watchers

 avatar

Forkers

evanhstanton

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.