I am trying to determine all the variables used in list. For This I use:
DeleteDuplicates[Cases[l1,_Symbol,-1]]
This is great except that \Pi
etc. are symbols too. I want to add Except to this Cases
command to discard numeric symbols but I'm not sure where to add it.
I tried different combinations, but I either get errors, or it will interpret it differently to what I intended.
Alternatively, is there a better way of achieving this?
Variables
? $\endgroup$_?(Not@*NumericQ)
$\endgroup$