I think I have a different problem. My matrix isn't even invertible, there are two zero lines, moreover there are some coefficients that are of order of 1e6. In my opinion at some point Matlab is doing some inversion that's why expm doesn't work properly with badly scaled matrices.
No, it's not an invertibility issue. The reason for the NaNs is the big 1e6 order numbers. Below is an example of a non-invertible matrix on which EXPM works fine.