diagrams-solve-0.1.3.1: Pure Haskell solver routines used by diagrams

Copyright | (c) 2011-2015 diagrams-solve team (see LICENSE)
License | BSD-style (see LICENSE)
Maintainer | diagrams-discuss@googlegroups.com
Safe Haskell | Safe-Inferred
Language | Haskell2010

Diagrams.Solve.Tridiagonal

Description

Solving of tridiagonal and cyclic tridiagonal linear systems.

Synopsis

- solveTriDiagonal :: Fractional a => [a] -> [a] -> [a] -> [a] -> [a]
- solveCyclicTriDiagonal :: Fractional a => [a] -> [a] -> [a] -> [a] -> a -> a -> [a]

# Documentation

solveTriDiagonal :: Fractional a => [a] -> [a] -> [a] -> [a] -> [a] Source #

`solveTriDiagonal as bs cs ds` solves a system of the form `A*X = ds` where `A` is an `n` by `n` matrix with `bs` as the main diagonal and `as` the diagonal below and `cs` the diagonal above. See: http://en.wikipedia.org/wiki/Tridiagonal_matrix_algorithm

solveCyclicTriDiagonal :: Fractional a => [a] -> [a] -> [a] -> [a] -> a -> a -> [a] Source #

Solves a system similar to the tri-diagonal system using a special case of the Sherman-Morrison formula (http://en.wikipedia.org/wiki/Sherman-Morrison_formula). This code is based on Numerical Recpies in C's `cyclic` function in section 2.7.