From: "chris.danx" <spamoff.danx@ntlworld.com>
Subject: In place matrix multiplication?
Date: Sun, 01 Jun 2003 02:35:18 +0200
Date: 2003-06-01T02:35:18+02:00 [thread overview]
Message-ID: <1JcCa.16479$Mu3.361103@newsfep4-glfd.server.ntli.net> (raw)
Hi,
Does anyone know how to do this? At first I thought it'd be something
along the lines of...
procedure Multiply (A : in out Matrix;
B : in Matrix) is
T : Scalar;
Z : Scalar := Create(0);
begin
for rCount in Matrix_Size'range loop
for cCount in Matrix_Size'range loop
T := Z;
for iCount in Matrix'range loop
T := T + A.Mx(rCount, iCount) * B.Mx(iCount, cCount);
end loop;
A.Mx(rCount, iCount) := T;
end loop;
end loop;
end Multiply;
But this is obviously wrong. Is there an algorithm to do this? I
googled for it, but haven't found anything yet. I gather it's possible
because some libraries do it. They just don't say how they do so.
Cheers,
Chris
next reply other threads:[~2003-06-01 0:35 UTC|newest]
Thread overview: 4+ messages / expand[flat|nested] mbox.gz Atom feed top
2003-06-01 0:35 chris.danx [this message]
2003-06-01 9:18 ` In place matrix multiplication? Dmitry A. Kazakov
2003-06-01 12:54 ` chris.danx
2003-06-01 14:26 ` Bill Findlay
replies disabled
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox