Added 3d regression test and fixed other tests and travis file

Also fixed out3.f to print num_dim as required for python input.  (used in regression test)