Luke: This is literally the core of the code:
A = scipy.asmatrix(scipy.zeros((M, N), float)) q = scipy.asmatrix(scipy.zeros((N, 1)), float) b = scipy.asmatrix(scipy.zeros((1, N)), float) # populate A # x is a vector of valid floats (I've checked) # calculate b as: b = A * x After the matrix multiplication, the b vector elements are all "-1.#IND" 's. Note that there are no divisions by zero in the program. Cheers Dinesh ----- Original Message ----- From: Luke Paireepinart To: Dinesh B Vadhia Cc: tutor@python.org Sent: Saturday, January 26, 2008 11:12 PM Subject: Re: [Tutor] An -1.#IND error Dinesh B Vadhia wrote: > After a matrix*vector multiplication (ie. b = Ax, with A, x and b all > floats), the b vector elements are all "-1.#IND". What does this > mean? Btw, they are no divisions in the program eg. no divide by zeros. A code sample would be _much_ more helpful here. Please include one that exhibits the problem. > > Dinesh > > > ------------------------------------------------------------------------ > > _______________________________________________ > Tutor maillist - Tutor@python.org > http://mail.python.org/mailman/listinfo/tutor >
_______________________________________________ Tutor maillist - Tutor@python.org http://mail.python.org/mailman/listinfo/tutor