MathGroup Archive 2011

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

Search the Archive

A two part notation question

  • To: mathgroup at smc.vnet.net
  • Subject: [mg120957] A two part notation question
  • From: Ethan Dyer <ethansdyer at gmail.com>
  • Date: Fri, 19 Aug 2011 06:32:55 -0400 (EDT)
  • Delivered-to: l-mathgroup@mail-archive0.wolfram.com

Hi. I have a two part question regarding notation in general and OverBar 
in particular.

Part 1)

	There seems to be a peculiarity in the notation package which I 
would like to know how to get around. The following works correctly:

<<Notation`


Notation[ParsedBoxWrapper[OverscriptBox["x_","a"]]<=>ParsedBoxWrapper[RowBox[List["f","[","x_","]"]]]].

This replaces f[x_] with the letter "a" appearing over x_. What I really want to do is have f[x_] display as OverBar[x] for both input and output.

When I try to do this:


Notation[ParsedBoxWrapper[OverscriptBox["x_","_"]]<=>ParsedBoxWrapper[RowBox[List["f","[","x_","]"]]]].

I get an error because Notation interprets the underscore that should appear over the argument as another Blank to be matched.

My first question is how to do this correctly in the notation package?

Part 2)

	What is the way to do this correctly, not using Notation. I can do Format[f[x_]]:=OverBar[x] which works great for output. What is the correct way to have this also work for input, ie be able to copy and paste expressions with overbar apearing?

Thank you very much.

Ethan





  • Prev by Date: Re: Compression of Plot[] to reduce notebook size
  • Next by Date: Re: Inverse Interpolation
  • Previous by thread: Re: Parameter Optimization to match a PDE solution to experimental results
  • Next by thread: Re: A two part notation question