Formally, a tree-LSTM calculates a cell state through an input gate, an output gate and two forget gates at each time step.
at time step t, the input gate i t and the output gate o t are calculated respectively as follows: co and b o are parameters of the input gate and the output gate, respectively.