You will write three functions for the fields and forces of long conductors. All of them follow from Ampere's circuital law.
The idea. Inside a round wire of radius with an even current, . Outside it, . Inside a long solenoid, . Two long parallel wires pull on each other with on each metre. Use SI units.
Your tasks.
thick_wire_field, return the field at a distance r from the axis of a round wire of radius a. Use one formula for r < a and another for r >= a.solenoid_field, return the field inside a long solenoid with n turns in each metre.force_per_metre, return the force on each metre of one wire. Let a positive result mean an attraction and a negative result a repulsion. A negative current means the opposite direction.Have you tried it?
Do the tasks in the editor first, and run the checker after each one. Its hints help when a check fails. When you are ready, compare your code with this solution.
Log in to join the discussion.
Loading…