[Numpy-discussion] Translation of a Matlab expresion

Miquel Poch miquel.poch at gmail.com
Mon Apr 9 06:28:33 EDT 2007


Hi,

I've got a function write in Matlab, and I need to tranlate it into python.
I've found an expresion like this:

BF = b0 + (b1 + (b2 + (b3 + (b4 + (b5 + b6*T).*T).*T).*T).*T).*T
or
dBFdT = b1 + (2 * b2 + (3 * b3 + (4 * b4 + (5 * b5 + 6* b6*T).*T).*T).*T).*T

T is a matrix and the rest of the variables are floats. I don't know why are
this '.' in the expresion, and that's why I can't translate it.

I tried to do it without the '.' but then the expression it's incorrect. We
can't multiply two matrix wich number of rows and columns are the same.

''' exceptions.ValueError : objects are not aligned '''

There's some function in numpy to translate this expression?

Thanks in advance,
Miquel
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://mail.python.org/pipermail/numpy-discussion/attachments/20070409/e6f561a1/attachment.html>


More information about the NumPy-Discussion mailing list