Rethinking the loop C, according to Ampere's law, because there is no current passing through the loop C, so the magnetic field is integrated along the line of the component of the loop C, also known as the loop flow of the magnetic field around the loop C, equal to zero. In the solenoid, because of symmetry, the magnetic flux around the radial part of the loop C is zero. However, the annular flow in the axial part of the solenoid (the direction of the z- axis) is not equal to zero: in the direction of the positive z- axis, the flux of the magnetic field around the straight line 1 is equal to the annular flow of the negative z- axis, the magnetic field around the straight line 2, and the two ring flow. As the solenoid tends to be infinitely long, we can assume that the magnetic field does not depend on the z- coordinates, and the magnetic fields at any location in line 1 are equal. Similarly, the magnetic field at any position in straight line 2 is equal. Therefore, the magnetic field at any position in straight line 1 is equal to the magnetic field at any position in line 2. Since we can change the size of the loop arbitrarily, the answer is still the same, so the only possible explanation is that the magnetic field in the solenoid is a constant, not changing with the position. The same argument can be applied to the loop a, so the magnetic field outside the solenoid is constant and does not vary with location. Assuming that the length of the solenoid tends to infinitely long, the edge effect (fringe effect) can be ignored. For the right picture, the thinking loop B, the right-hand rule is used to find the magnetic field around the current carrying wire. If we hold the current carrying wire in the right hand and thumb in the direction of the current, the other fingers will point to the direction of the magnetic field. For a solenoid with a long tube, the radial part of the magnetic field is offset by symmetry. So, only the z- component is not equal to zero. In the solenoid, the magnetic field moves towards the positive z- axis, and the magnetic field moves towards the negative z- axis outside the solenoid.