Meta::Math::Matrix - matrix class.


Meta documentation  | view source Contained in the Meta distribution.

Index


NAME

Top

Meta::Math::Matrix - matrix class.

COPYRIGHT

Top

LICENSE

Top

This program is free software; you can redistribute it and/or modify it under the terms of the GNU General Public License as published by the Free Software Foundation; either version 2 of the License, or (at your option) any later version.

This program is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License for more details.

You should have received a copy of the GNU General Public License along with this program; if not, write to the Free Software Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111, USA.

DETAILS

Top

	MANIFEST: Matrix.pm
	PROJECT: meta
	VERSION: 0.20

SYNOPSIS

Top

	package foo;
	use Meta::Math::Matrix qw();
	my($matrix)=Meta::Math::Matrix->new();
	my($matrix_size)=Meta::Geo::Pod2d->new();
	$matrix_size->set_x(8);
	$matrix_size->set_y(8);
	$matrix->set_size($matrix_size);
	my($pos)=Meta::Geo::Pos2d->new();
	$pos->set_x(5);
	$pos->set_y(5);
	$matrix->set_elem($pos,"mark");

DESCRIPTION

Top

This is a classic matrix. It has a size and makes sure all elements conform to it. Currently it doesn't do very much except help you forget about how to actually store the values. You can store values of whatever type you want in this matrix.

FUNCTIONS

Top

	new($)
	set_size($$)
	set_elem($$$)
	get_elem($$)
	check_pos($$)
	TEST($)

FUNCTION DOCUMENTATION

Top

new($)

This constructs a new matrix.

set_size($$)

This will set the size from the matrix.

set_elem($$$)

This will set an element in the matrix.

get_elem($$)

This will retrieve an element from the matrix.

check_pos($$)

This will check that a position is legal.

TEST($)

Test suite for this module.

SUPER CLASSES

Top

None.

BUGS

Top

None.

AUTHOR

Top

	Name: Mark Veltzer
	Email: mailto:veltzer@cpan.org
	WWW: http://www.veltzer.org
	CPAN id: VELTZER

HISTORY

Top

	0.00 MV chess and code quality
	0.01 MV more perl quality
	0.02 MV perl documentation
	0.03 MV more perl quality
	0.04 MV perl qulity code
	0.05 MV more perl code quality
	0.06 MV revision change
	0.07 MV languages.pl test online
	0.08 MV perl packaging
	0.09 MV md5 project
	0.10 MV database
	0.11 MV perl module versions in files
	0.12 MV movies and small fixes
	0.13 MV thumbnail project basics
	0.14 MV thumbnail user interface
	0.15 MV more thumbnail issues
	0.16 MV website construction
	0.17 MV web site automation
	0.18 MV SEE ALSO section fix
	0.19 MV teachers project
	0.20 MV md5 issues

SEE ALSO

Top

Meta::Development::Assert(3), Meta::Geo::Pos2d(3), Meta::Utils::Output(3), strict(3)

TODO

Top

-add check in set_elem that the position received is integral (composed of integers). The same goes for set_size and get_elem. Come to think of it, why not make a 2d object that inherits from the Geo::Pos2d which keeps the values in it integral. Here all you have to do is check that the object received is of that class.

-add various methods (multiplication, addition, substraction etc...).


Meta documentation  | view source Contained in the Meta distribution.