A structural form for higher-index semistate equations. I. theory and applications to circuit and control theory