Re: [Numpy-discussion] Array and vector initialization good practice

2008-06-18 Thread Anne Archibald
2008/6/18 Dinesh B Vadhia <[EMAIL PROTECTED]>: > Say, there are two initialized numpy arrays: It is somewhat misleading to think of numpy arrays as "initialized" or "uninitialized". All numpy arrays are dynamically allocated, and under many circumstances they are given their values on creation. >

[Numpy-discussion] Array and vector initialization good practice

2008-06-17 Thread Dinesh B Vadhia
Say, there are two initialized numpy arrays: A = numpy.blah B = numpy.blah.blah With, C = A*d + B*e which doesn't have to be initialized beforehand (as A and B are and so are d and e) Now, place this in a function ie. def havingFun(d, e) C = A*d + B*e return C The main program calls h