When I write a prefix mathematical function (specifically an op) (like sin) applied to a literal number, it is shown with a space between the function and the operand. But, when I write the function applied to an expression in parentheses, there is no space between the function and the operand. That is shown in the example at the end.
How can I keep the space between the function and the operand when the operand is an expression in parentheses? The idea is that the the literal number and the expression in parentheses mean the same thing, so they should be treated the same way in the notation. That would be useful for a Haskell-like notation where functions are applied by juxtaposition, not by parentheses.
I could put every such operand in a box like on the third line of the example, but that is impractical because it requires too much extra code. So I am looking for a practical solution which could be applied to all ops. Ideally, I could redefine spacing rules for the math mode.
$sin 5$ \
$sin (2+3)$ \
$sin #box($(2+3)$)$

