Mariner 4 was a flyby orbiter launched on November 28, 1964.
Engineers designed the spacecraft to conduct field and particle experiments in interplanetary space. It was designed with three main experimental objectives in mind: measure the Martian magnetic field, cosmic dust and rays, and the solar wind.
If Mars had a magnetic field, as we do on Earth, it would protect the planet from potentially life-threatening cosmic radiation and solar radiation.
Here is a short video on how we measure magnetic fields in space:
For more information on the interaction between solar particles and Earth's magnetic field, check out this short video:
Most importantly, scientists wanted Mariner 4 to provide close-range images of Mars in order to provide us with the most detailed surface pictures ever obtained of the planet, hopefully revealing geologic and atmospheric processes.
Mariner 4 would not enter the Martian orbit. Instead, engineers designed it as a flyby mission that would pass as closely as possible in order to take pictures and measurements. Mariner 4 had only one chance to do perform its scientific work, since the probe could not return to Mars again.
On July 15, 1965, the camera began snapping pictures. Here is the first close-up picture of Mars ever taken:
Mars scientists hypothesized that the hazy area barely visible above the limb on the left side of the image might be clouds. This close-up image was the first visual evidence of a Martian atmosphere!
A rocky surface
The relayed surface images revealed a cratered and moon-like surface, findings that were contrary to even conservative estimates of the Martian topography. This image was taken from 13,400 km and covers and area of 255 km by 296 km. The two craters at the center of the image are about 32 km in diameter.
Roughly 1% of the surface was photographed, leaving many questions unanswered...
Atmosphere & Temperature
One of the great achievements of the Mariner 4 mission was the modification of mission plans while the spacecraft was in transit in order to accommodate the radio-occultation experiment. The experiment took advantage of radio waves from the spacecraft passing through the Martian atmosphere. Variations in the amplitude, frequency, and phase of the returned signal allowed rough calculations of atmospheric density & temperature.
The results of the experiment suggested that Mars generates surface pressures of around 4.1 to 7.0 mbar (for comparison Earth has a surface pressure of 1013 mbar). This would mean that the Martian atmosphere is less than 1% the density of Earth. These findings led to surface temperature estimates of -100 degrees celsius.
The spacecraft did not detect a magnetic field around Mars, meaning the surface is not protected from solar wind as compared to Earth.