Math::SparseMatrix::Operations - Mathematical operations with matrices
Version 0.05
This module introduces new utilities and mathematical functions for matrices from the module Math::SparseMatrix. This is not a class module, it contains only the subroutines for the operations. All the subroutines described below will only function with Math::SparseMatrix objects.
Please consider the subroutines names before using the module, the module usage will bring to your namespace all the subroutines described below.
This subroutines prints the value of each cell.
# Input: $matrix_a. # Output: matrix content. &op_print_matrix($matrix_a);
This subroutines puts a number 1 inside each matrix cell.
# Input: $matrix_a. # Output: none. &op_fill_matrix($matrix_a);
Returns a new Math::SparseMatrix object with the selected column. (Not tested yet!)
# Input: $matrix_a, $column_number. # Output: $matrix_b. my $matrix_b = &get_col($matrix_a, $column_number);
Returns a new Math::SparseMatrix object with the selected row. (Not Tested Yest!)
# Input: $matrix_a, $row_number. # Output: $matrix_b. my $matrix_b = &get_col($matrix_a, $column_number);
Basic matrix addition, returns a new Math::SparseMatrix object.
# Input: $matrix_a, $matrix_b. # Output: $matrix_c. my $matrix_c = &op_addition($matrix_a, $matrix_b);
Basic matrix subtraction, returns a new Math::SparseMatrix object.
# Input: $matrix_a, $matrix_b. # Output: $matrix_c. my $matrix_c = &op_subtraction($matrix_a, $matrix_b);
Basic matrix multiplication, returns a new Math::SparseMatrix object.
# Input: $matrix_a, $matrix_b. # Output: $matrix_c. my $matrix_c = &op_multiply($matrix_a, $matrix_b);
Returns the identity matrix for the given input matrix. Returns a new Math::SparseMatrix object.
# Input: $size. # Output: $matrix_a. my $matrix_a = &op_identity($size);
Returns the transposed matrix for the given input matrix. Returns a new Math::SparseMatrix object.
# Input: $matrix_a. # Output: $matrix_b. my $matrix_b = &op_transpose($matrix_a);
Returns the dot product for the given input matrix.
# Input: $matrix_a. # Output: $dot_product. my $dot_product = &op_dot_product($matrix_a);
Felipe da V. Leprevost, <leprevost at cpan.org>
<leprevost at cpan.org>
Please report any bugs or feature requests to bug-math-sparsematrix-operations at rt.cpan.org, or through the web interface at http://rt.cpan.org/NoAuth/ReportBug.html?Queue=Math-SparseMatrix-Operations. I will be notified, and then you'll automatically be notified of progress on your bug as I make changes.
bug-math-sparsematrix-operations at rt.cpan.org
You can find documentation for this module with the perldoc command.
perldoc Math::SparseMatrix::Operations
You can also look for information at:
RT: CPAN's request tracker (report bugs here)
http://rt.cpan.org/NoAuth/Bugs.html?Dist=Math-SparseMatrix-Operations
AnnoCPAN: Annotated CPAN documentation
http://annocpan.org/dist/Math-SparseMatrix-Operations
CPAN Ratings
http://cpanratings.perl.org/d/Math-SparseMatrix-Operations
Search CPAN
http://search.cpan.org/dist/Math-SparseMatrix-Operations/
Copyright 2013 Felipe da V. Leprevost.
This program is free software; you can redistribute it and/or modify it under the terms of either: the GNU General Public License as published by the Free Software Foundation; or the Artistic License.
See http://dev.perl.org/licenses/ for more information.
To install Math::SparseMatrix::Operations, copy and paste the appropriate command in to your terminal.
cpanm
cpanm Math::SparseMatrix::Operations
CPAN shell
perl -MCPAN -e shell install Math::SparseMatrix::Operations
For more information on module installation, please visit the detailed CPAN module installation guide.