<p>Two-electrode straight open magnetic source (TSOMS) has been widely used on the magnetic minesweeper and magnetic decoy. Fast-forward modeling and obtaining the high-precision magnetic field in the air are the prerequisites for real-time inversion and positioning of the TSOMS. In this paper, we propose an algorithm to calculate the magnetic field of the two-electrode straight open magnetic source (MFTSOMS) by previous theoretical research. And a classical algorithm of electric dipole magnetic field is used to verify the correctness of our algorithm.