I am trying to find the function that converts the result of FullForm back into a standard pretty looking output. Here is what I mean:
expr = FullForm[2 + 2 Sin[x]]
> Plus[2,Times[2,Sin[x]]]
Normal[expr]
Evaluate[expr]
DisplayForm[expr]
> Plus[2,Times[2,Sin[x]]] (* not good, it's still displays as text *)
%
> 2+2Sin[x] (* good, I have a pretty formula again *)
Ok, so evaluating % just after does the trick, but it's not a function call. I was wondering what is the proper function that does this:
ProperFunctionCall[expr]
> 2+2Sin[x]
The secondary question is: does ProperFunctionCall
works on all types of inputs, for example, would it work on:
expr2=FullForm[Graphics[Disk[]]];
ProperFunctionCall[expr2]
and show the pretty black disk instead of the text ?
I had a look at the online help of all the entries of ?*Form
that seemed meaningful but it did not help me. I also had a look at this post and a few others, but it does not seem to be the same problem so the answer did not help either.
Thanks.
ProperFunctionCall = First
. $\endgroup$ProperFunctionCall = # /. FullForm -> Identity &
$\endgroup$