refactored unit tests.
added the ability to call numpy functions (jay)