From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.org!not-for-mail From: Neon Absentius Newsgroups: gmane.emacs.help Subject: Re: Non-Commutative calculations in Calc, Revisited Date: Fri, 7 Oct 2005 00:47:45 +0000 Message-ID: <20051007004745.GD29712@SDF.LONESTAR.ORG> References: <878xx66b1c.fsf@vh213602.truman.edu> <851x2yu5gv.fsf@lola.goethe.zz> <20051006180113.GA24696@SDF.LONESTAR.ORG> NNTP-Posting-Host: main.gmane.org Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii X-Trace: sea.gmane.org 1128646156 18947 80.91.229.2 (7 Oct 2005 00:49:16 GMT) X-Complaints-To: usenet@sea.gmane.org NNTP-Posting-Date: Fri, 7 Oct 2005 00:49:16 +0000 (UTC) Original-X-From: help-gnu-emacs-bounces+geh-help-gnu-emacs=m.gmane.org@gnu.org Fri Oct 07 02:49:14 2005 Return-path: Original-Received: from lists.gnu.org ([199.232.76.165]) by ciao.gmane.org with esmtp (Exim 4.43) id 1ENgPn-0008Pp-GB for geh-help-gnu-emacs@m.gmane.org; Fri, 07 Oct 2005 02:48:47 +0200 Original-Received: from localhost ([127.0.0.1] helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1ENgPm-0006Bj-Vd for geh-help-gnu-emacs@m.gmane.org; Thu, 06 Oct 2005 20:48:46 -0400 Original-Received: from mailman by lists.gnu.org with tmda-scanned (Exim 4.43) id 1ENgPQ-0006BC-0S for help-gnu-emacs@gnu.org; Thu, 06 Oct 2005 20:48:24 -0400 Original-Received: from exim by lists.gnu.org with spam-scanned (Exim 4.43) id 1ENgPP-0006Aw-F0 for help-gnu-emacs@gnu.org; Thu, 06 Oct 2005 20:48:23 -0400 Original-Received: from [199.232.76.173] (helo=monty-python.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1ENgPP-0006At-CK for help-gnu-emacs@gnu.org; Thu, 06 Oct 2005 20:48:23 -0400 Original-Received: from [192.94.73.21] (helo=sdf.lonestar.org) by monty-python.gnu.org with esmtp (Exim 4.34) id 1ENgPP-0004bP-G4 for help-gnu-emacs@gnu.org; Thu, 06 Oct 2005 20:48:23 -0400 Original-Received: from sdf.lonestar.org (IDENT:absent@ukato.freeshell.org [192.94.73.7]) by sdf.lonestar.org (8.13.1/8.12.10) with ESMTP id j970ljV3012642 for ; Fri, 7 Oct 2005 00:47:45 GMT Original-Received: (from absent@localhost) by sdf.lonestar.org (8.13.1/8.12.8/Submit) id j970ljUu025496 for help-gnu-emacs@gnu.org; Fri, 7 Oct 2005 00:47:45 GMT Original-To: help-gnu-emacs@gnu.org Mail-Followup-To: Neon Absentius , help-gnu-emacs@gnu.org Content-Disposition: inline In-Reply-To: <20051006180113.GA24696@SDF.LONESTAR.ORG> User-Agent: Mutt/1.4.2.1i X-BeenThere: help-gnu-emacs@gnu.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: Users list for the GNU Emacs text editor List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Original-Sender: help-gnu-emacs-bounces+geh-help-gnu-emacs=m.gmane.org@gnu.org Errors-To: help-gnu-emacs-bounces+geh-help-gnu-emacs=m.gmane.org@gnu.org Xref: news.gmane.org gmane.emacs.help:30008 Archived-At: On Thu, Oct 06, 2005 at 06:01:13PM +0000, Neon Absentius wrote: > On Thu, Oct 06, 2005 at 03:42:40PM +0200, David Kastrup wrote: > > Jay Belanger writes: > > > > > Neon Absentius writes: > > > > > >> When in non-commutative (aka `matrix') mode calc calculates > > >> (a b)^-1 to be a^-1 b^-1 instead of the correct b^-1 a^-1. > > > > Uh, what's correct about b^-1 a^-1? > > > > Set a=[1,1], b=[1;0], then (a b)^-1 = [1], and neither b^-1 nor a^-1 > > exist. > > > > This only works with a and b being square matrices. > > Yes you are right. > OTH, now that I thought litle bit about it, there is a way in which my statement makes sence even for non-square matrices. Here is the general setting: Let (C,*) be a set with a partially defined associative multiplication (called composition) such that each element has a left and a right identity element (such a structure is usually known as a "category"). The set of all matrices satisfy these conditions. Assume that for two composable elements a,b the composition a*b has an (bi-sided) inverse (ab)^-1. Then a has a *right* inverse a^-1 and b has a *left* inverse b^-1 and the identity (ab)^-1 = b^-1a^-1 holds. Proof: Since ab(ab)^-1 = (ab)^-1 ab = 1 we can take a^-1 = b(ab)^-1 and b^-1 = (ab)^-1 a. Then b^-1 a^-1 = [(ab)^-1 a] [b (ab)^-1] = (ab)^-1, by associativity. It is also straightforward to check that all elements that I composed are indeed composable. QED I leave it as an exersise to find a^-1 and b^-1 for your example :)). I am not sure it is a good idea to implement the rule in general though. In any case I do think that is a good idea to have a command that assumes that all variables are square matrices or, in the abstract language, that any two elements are composable. Of course being square matrices, the variables will have more properties, eg determinats etc. That might also be useful in some cases. -- There is no national science just as there is no national multiplication table; what is national is no longer science. -- Anton Checov