In Physics, I often have functions like f(x)
, but also multiplications like y(-x)
. I would like my math to be easy to understand, so I am looking for a way to suggest function calls and multiplications.
In programming languages like C or Python, this is easy. A function call is f(x)
and a multiplication has to have a *
in it. I think it would be ugly and confusing to put \cdot
everywhere, since that is more thought of as am inner product.
In Mathematica, function calls are with square brackets, like f[x]
, whereas multiplication is with round parenteses y(-x)
.
Since LaTeX has the \!
command, a friend thought of using that between the function name and the parameters.
I tried the negative spacing and the square brackets, but I am not sure whether it is valid to use \!
at that point. Or should I use even more negative spacing?
(source: stw-bonn.de)
The font in the image is Bitstream Charter with mathdesign
.
The code for the examples is:
f\del x y \del{-x}
f\sbr x y \del{-x}
f \! \del x y \del{-x}
f \! \sbr x y \del{-x}
Where \del
and \sbr
come from the commath
package and create automatically sized parenteses and square brackets.
y(-x)
you could either usey\times(-x)
(the\times
might be confudes with the cross product) or you could write-xy
instead ofy(-x)
which is, I believe, the best option - unless, of course, you're not in a commutative algebra. I don't think readers will see the difference betweeny(-x)
andy\!(-x)
. – gniourf_gniourf Jun 21 '13 at 9:30\del
and\sbr
macros. Don't use them. – egreg Jun 21 '13 at 11:51