Vectorization and Numeric (Newbie)

Ronny Mandal ronnyma at math.uio.no
Tue Feb 28 07:49:33 EST 2006


Assume you have a mathematical function, e.g. f(x) = x + 4

To calculate all the values from 1 to n, a loop is one alternative.

But to make this function work with vectors instead i.e
f(x_vector) = result_vector,
how should the function then be implemented?

Thanks

RM

--

Support bacteria - it's the only culture some people have!



More information about the Python-list mailing list