pi@eng.cam.ac.uk (Pablo Iglesias) (03/25/91)
Hello I want to create a command in LaTeX which would do the following: \negate{A} would give me -A. \negate{-A} would give me A. I have tried tried using \@ifnextchar to test whether there is one or two minus signs. Unfortunately, I do not know how to extract the "absolute" part of the argument. Could anyone give me any pointers as to how to write this command, or even better, can someone show me how it's done! :-) Thanks in advance, Pablo -- Pablo Iglesias Phone : +44 223 332813 Department of Engineering Fax : +44 223 332662 Cambridge University email : pi@eng.cam.ac.uk Cambridge, CB2 1RD, UK