Partial Discharges in Electrical Machines for the More Electric Aircraft - Part I: A Comprehensive Modeling Tool for the Characterization of Electric Drives Based on Fast Switching Semiconductors