Implement calculation and visualization of nonlinearity.