A very long, thick cylindrical wire of radius R carries a current density J that varies across its cross-section. The magnitude of the current density at a point a distance r from the center of the wire is given by where is a constant. Find the magnetic field (a) at a point outside the wire and (b) at a point inside the wire. Write your answer in terms of the net current I through the wire.
Credit: University Physics Volume 2 by OpenStax, openstax.org, licensed under CC BY 4.0 (https://creativecommons.org/licenses/by/4.0/). Exercises adapted: converted to Kosoma's format, maths re-typeset, some exercises split into parts. Source commit db44eb99e9aa1d918fd8cf182f82ccdece9c7b11.