[Numpy-discussion] trouble ingegrating Numpy arrays into a class statement

Rob rob at pythonemproject.com
Mon Dec 24 09:40:02 CST 2001


I have this Class:

class Cond:
    x1=0
    y1=0
    z1=0
    x2=0
    y2=0
    z2=0
    DelX=0
    DelY=0
    DelZ=0

What I want is for Cond to be a Numpy array of 20 values, each with the
above members.  Thus I could say in a statement:

wire=Cond
a= wire[10].x1
b= wire[5].z2       etc...  

How can I go about this?  Thanks,  Rob.      and Merry Christmas!!!!!!!

ps. this is for an FEM-MOM grid generator



-- 
The Numeric Python EM Project

www.pythonemproject.com




More information about the Numpy-discussion mailing list