Variable number of inputs for formula node
A few minor fixes for formula node