MathGroup Archive 2002

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

Search the Archive

RE: CirclePlus precedence and bigoplus

  • To: mathgroup at smc.vnet.net
  • Subject: [mg36171] RE: [mg36138] CirclePlus precedence and bigoplus
  • From: "David Park" <djmp at earthlink.net>
  • Date: Mon, 26 Aug 2002 04:15:48 -0400 (EDT)
  • Sender: owner-wri-mathgroup at wolfram.com

Lucas,

I hope that your question will provoke a number of replies because I think
it is an interesting topic.

First, it would be nice if Mathematica had a ShowPrecedence statement to
quickly retrieve a precedence number for any command. It is a bit time
consuming to search through the table in Section A.2.7.

Next, it would be nice if the user could set the precedence for operators
that don't have built-in definitions.

Since it appears that you can't do that, is it possible to switch the
meanings of Plus and CirclePlus in your theory? Are you depending on the
numerical behavior of Plus? Go with the precedence that Mathematica gives
you. Or you could use something like VerticalBar or RightTee which have
lower precedence than Plus, but perhaps don't have the look that you want.

You could try to use the Notation package for your CirclePlus sum. But I
always find the Notation package difficult to use and like to use
StandardForm as much as possible. One possibility is...

\!\(\((\[Sum]\+\(i = 1\)\%5 x[i])\) /. Plus -> CirclePlus\)

These are weak answers to your question, but maybe they will bring in more
discussion.

David Park
djmp at earthlink.net
http://home.earthlink.net/~djmp/



From: Lucas [mailto:lscharen at d.umn.edu]
To: mathgroup at smc.vnet.net

Hello,

I'm attempting to implement an abstract mathematica package in
mathematica that utilized the \[CirclePlus] operator in an unusual
way.  Specifically, the \[CirclePlus] has a precidence lower than +
and introduces barriers in the computation.  So, an expression such as

a + b \[CirclePlus] c + d   --> (a+b) \[CirclePlus] (c+d)

The mathematica ouput of

a + d + (b \[CirclePlus] c) is incorrect.  I've tried playing with the
PrecedenceForm[] function, but that does not seem able to produce the
desired effect.

Also, I would like to introduce a notation like

        N
\[BigCirclePlus] x[[i]] --> x[[1]] \[CirclePlus] x[[2]] \[CirclePlus]
....
       i=0

analagous to summation, but mathematica does not appear to offer the
CirclePlus in a large format.  to relate this to the case above, x[1]
= (a + b) and
x[2] = (c + d), so each indexed element is a subexpression.

Finally, I would like to be able to set up the CirclePlus operator
such that the following algebraic relations hold:


\Sum \BigCirclePlus E    =  \BigCirclePlus \Sum E
  i        j         ij            j         i   ij

d                                        d
-- \BigCirclePlus E    =  \BigCirclePlus -- E
dx        j        j             j       dx  j


Thanks in advance for any help on the above.

-Lucas Scharenbroich
-MLS Group / JPL




  • Prev by Date: Re: Re: An interesting math problem
  • Next by Date: RE: Fwd: Fwd: RE: rectangle intersection
  • Previous by thread: CirclePlus precedence and bigoplus
  • Next by thread: Re: CirclePlus precedence and bigoplus