D =
How exactly are Zbus and ybus related? [From your description is sounds like those are commonly used terms/variable names in your area of study, but please explain the relationship for those of us who aren't familiar with that area.]
How are you storing ybus? Is it a full matrix that has only a few non-zero elements (sparsely populated but not sparsely stored) or is it a sparse matrix (sparsely populated and sparsely stored)?
fullWithOnlyFewNonzero = eye(5)
sparseWithOnlyFewNonzeros = speye(5)
whos full* sparse*
Generally speaking, as John D'Errico said unless you absolutely positively explicitly need an inverse matrix you should not invert the matrix but should try an alternate approach. For example, if you're trying to solve a system of equations use the backslash operator \. [Yes, when you did this type of exercise in class while you were learning, you may have been told to invert. That's one of the cases where there's a difference between theory and practice.]