Services & Resources / Wolfram Forums
MathGroup Archive
*Archive Index
*Ask about this page
*Print this page
*Give us feedback
*Sign up for the Wolfram Insider

MathGroup Archive 2000

[Date Index] [Thread Index] [Author Index]

Search the Archive

Re: Commuting Matrices

  • To: mathgroup at
  • Subject: [mg24639] Re: Commuting Matrices
  • From: Sotirios Bonanos <sbonano at>
  • Date: Mon, 31 Jul 2000 09:23:13 -0400 (EDT)
  • Organization: National Technical University of Athens, Greece
  • References: <8lgs2f$>
  • Sender: owner-wri-mathgroup at

Vishnu Jejjala wrote:

> I have a collection of matrices which satisfy a matrix algebra.
> Call three of the matrices Phi1, Phi2, and Phi3.  I want to take
> expressions of the form (Phi1.Phi2.Phi3)^n and `normal order' them
> using the commutation relations of the algebra so that the terms
> in the expansion are of the form Phi1^a.Phi2^b.Phi3^c.  Is there
> a slick way to do this?
> My brute force method of using replaces isn't working.  One of
> the problems I run into is that when I obtain an expression like
> Phi3.(k Phi1.Phi3).Phi2.Phi3, I can't seem to teach Mathematica
> to realize that the k is a scalar and factors through and that it
> should apply the commutation rules to k Phi3.Phi1.Phi3.Phi2.Phi3.
> Perhaps someone can offer suggestions.  Thanks.
> --Vishnu

Hi Vishnu,

    You must first teach "Dot" to distinguish scalars from matrices, and
then apply the rules of your algebra. Here is one way:


(** The above rules are not needed if your "Algebra Rules" do not
involve sums of matrices **)
Dot[x_,Times[y_^n_.,z_]]:=y^n x.z/;(!MemberQ[MatNameList,y]);
Dot[Times[y_^n_.,z_],x_]:=y^n z.x/;(!MemberQ[MatNameList,y]);
(*** Sample of "Algebra Rules" ***)
Phi1.Phi2=a1 Phi1+a2 Phi2+a3 Phi3;
Phi2.Phi1=b1 Phi1+b2 Phi2+b3 Phi3;
Phi1.Phi3=c1 Phi1+c2 Phi2+c3 Phi3;
Phi3.Phi1=d1 Phi1+d2 Phi2+d3 Phi3;
Phi2.Phi3=e1 Phi1+e2 Phi2+e3 Phi3;
Phi3.Phi2=f1 Phi1+f2 Phi2+f3 Phi3;
(** etc **)

(** Now Dot behaves as you want. Try the following: **)

Phi1.(a Phi1+b Phi2+c Phi3).( k2 Phi1^2+k1 Phi1+l Phi2+m Phi3)


   Hope this helps.
    S. Bonanos

  • Prev by Date: Re: Help on Partitions, Again!!!
  • Next by Date: Re: Help on Partitions, Again!!!
  • Previous by thread: Commuting Matrices
  • Next by thread: FourierTransform