[Numpy-discussion] I solved my fortran equivalence to Python conversion

Rob rob at pythonemproject.com
Sat Feb 16 11:40:01 CST 2002


Here is the code:


    ARL1=zeros((441),Complex)
    ARL2=zeros((341),Complex)
    ARL3=zeros((289),Complex)

    #DIMENSION ARL1(1), ARL2(1), ARL3(1)
    #EQUIVALENCE (ARL1,AR1), (ARL2,AR2), (ARL3,AR3), (XS2,XSA(2)),
(YS3,YSA(3))
    AR1=swapaxes(AR1,0,2)
    AR2=swapaxes(AR2,0,2)
    AR3=swapaxes(AR3,0,2)
    ARL1[1:]=ravel(AR1[1:,1:,1:])
    ARL2[1:]=ravel(AR2[1:,1:,1:])
    ARL3[1:]=ravel(AR3[1:,1:,1:])
-- 
The Numeric Python EM Project

www.pythonemproject.com




More information about the Numpy-discussion mailing list