Defining and representing knowledge in electromagnetic field computation