add feedforward function