Article View: comp.lang.fortran
Article #4573Re: inverse matrix
From: Richard Maine
Date: Fri, 08 Jan 1993 17:01
Date: Fri, 08 Jan 1993 17:01
29 lines
1815 bytes
1815 bytes
On Fri, 8 Jan 1993 13:46:12 GMT, pfennige@scsun.unige.ch (PFENNIGER Daniel) said: PFENNIGER> Is it true that a Fortran-90 programme inverting matrix A would be: PFENNIGER> B = 1./A No. That would be a legal statement, but it makes each element of B the inverse of the corresponding element of A. The f90 arrays are better thought of as "arrays" than as "matrices". In particular, all the operations are element-by-element. There is a standard matmul subroutine for the usual matrix multiplication, but there is no matrix inversion. I wasn't on the committee at the time, but I believe the rationale was that there was no single matrix inversion technique good for all situations, and that numerically-oriented users were better off choosing a particular, appropriate one than whatever the vendor happened to implement (which might be different on different platforms). You (or a library writer) can make a "matrix" (or whatever you want to call it) user-defined type and define division for it such that the above sample line would do the matrix inversion, but such a type isn't part of the base language. -- -- Richard Maine maine@altair.dfrf.nasa.gov
Technical Details
Message-ID:
<MAINE.93Jan8090104@altair.dfrf.nasa.gov>Path:
arc1-ca.pugleaf.net!sparky!uunet!zaphod.mps.ohio-state.edu!cs.utexas.edu!sun-barr!ames!news.dfrf.nasa.gov!altair.dfrf.nasa.gov!maineReferences:
<C0I49C.Jrr@athena.cs.uga.edu> <1993Jan8.100315.5851@edf.fr> <1993Jan8.134612.18468@news.unige.ch>Show Full Headers
Complete Article Headers
Newsgroups: comp.lang.fortran Path: arc1-ca.pugleaf.net!sparky!uunet!zaphod.mps.ohio-state.edu!cs.utexas.edu!sun-barr!ames!news.dfrf.nasa.gov!altair.dfrf.nasa.gov!maine From: maine@altair.dfrf.nasa.gov (Richard Maine) Subject: Re: inverse matrix In-Reply-To: pfennige@scsun.unige.ch's message of Fri, 8 Jan 1993 13:46:12 GMT Message-ID: <MAINE.93Jan8090104@altair.dfrf.nasa.gov> Sender: news@news.dfrf.nasa.gov (Usenet news) Organization: NASA Dryden, Edwards, Cal. References: <C0I49C.Jrr@athena.cs.uga.edu> <1993Jan8.100315.5851@edf.fr> <1993Jan8.134612.18468@news.unige.ch> Date: Fri, 8 Jan 1993 17:01:10 GMT Lines: 30