Implemented matrix exponential via truncated Taylor series