You may consider to connect the 7805 reg to the batteries permanently via 2 diodes, so the switch-over of the batteries will not crash the arduino. I would add a simple filter into the arduino's power rail as the switching between the batteries with different voltages may cause pulses.
The 7805 requires two 100nF decoupling capacitors connected as close as possible to its pins.
BTW the recommended input voltage for arduino (when powered from the external power source) is 7V. How do you plan to connect the arduino to the "7805" in your schematics above? Do you want to connect the 5V from the 7805 to internal 5V rail (not to recommend..)?
Or, safer imho, would be to use a 7808 and feed the power into the standard arduino external source input (the barrel jack).
Or to use other voltage regulator which gives you 7V external power for arduino (for example a low-dropout one based on how minimal voltage the batteries can provide worst case).
Or, another variant is to feed arduino directly from the filter, into its standard external power input. I would prefer a pre-regulation with a 7V output fed into arduino's external power input (double stabilization), when you plan the system for the upcoming Mars expedition..
No warranties of any kind