Chris Riley, Engineering Manager, Cobham Technical Services
Python has been integrated into the Opera-3d solvers in order to allow data calculated during a particular simulation process to be made available to other Opera-3d simulations. For example, force densities at each output time, or indeed time-step, of a transient electromagnetic simulation could be made available to a series of Opera-3d static stress analyses. Consequently, the stress analyses can be run as the data becomes available without having to wait for the transient to finish. Python integration can also be used to determine steady state performance following a transient event and obtain averaged results (such as losses) over a number of time-steps.
Recently, Python has also been used to supply multiphysics capabilities directly in some applications, which will be discussed during this presentation. In a Quench simulation, the heat lost through heat transfer at the surface of the coil has been calculated using Python and the corresponding temperature rise of the helium coolant has been determined, assuming that the whole system is adiabatic. The temperature of the helium coolant is then fed back to Quench to update the ambient temperature in the heat transfer boundary condition for the next time-step.
A second example computes rigid body dynamics in a rail gun calculation. The total force acting on the armature is computed at each time-step using Python and the corresponding distance that the armature will move is determined. The increase in distance is used to determine the corresponding increase of resistance and inductance outside the model space and Python is used to update the external circuit.
Finally, Python could also be used to exchange data calculated inside Opera-3d with external Python instances via the COM interface. The talk will demonstrate a simple example where an array of values stored in an Opera-3d Post-processor buffer is exported to a stand-alone Python instance to allow further calculations to be performed.