I am curious about how to differ between brackets for function calls like $f(x)$ and brackets for multiplication $x(y+1)$. I think there is the possibility to get confused by this, because the first example shows a function call, and the second a multiplication. Does there exist some general style guide for something like this? This is extremly confusing if I have a equation like $g(a,b) = \frac{2f(a)}{h(b+1)}$, where $h$ is not a function, but $f$ is a function.
1 Answers
I think the convention is just to remember which is which. I can see how your example may be confusing. I will give you two strategies for making it easier to distinguish which is which:
Name your variables consistently and intuitively! Your example is en excellent illustration of a poor choice of variable names. Since $f$ and $g$ are functions, $h$ is a poor choice for a variable which is not a function. Choose variables that are alphabetically contiguous for things "of the same type". What I mean by "the same type" will vary between situations. Bottom line: $h$ should get another name in your example.
If there are many brackets in an expression, you are allowed to use other brackets than $()$, like for example $[]$. In expressions involving nested brackets, some people choose $[]$ for the outer brackets and $()$ for the inner brackets. However, you should not substitute $[]$ for $()$ in function calls because some authors use this to distinuish between a function value, like $f(x)$, and the image of a set under some function, like $f[X]$.
- 3,416
-
2Note that functions can be added and multiplied as well, so with (real-valued) functions $f,g,k$, we might consider $fg$ or $f+g$ -- or unfortunately even $f(g+k)$! – Hagen von Eitzen Nov 24 '20 at 12:31
-
That is also a good point, yes! – Thusle Gadelankz Nov 24 '20 at 12:32
-
Some style guides use upright symbols for functions ($\mathrm{f}(x)$ rather than $f(x)$) although this is not standard and hard to represent in handwriting. – dbmag9 Nov 24 '20 at 12:37