The model 3,1 can run a maximum of 10.7 Lion. You will need to upgrade to 10.6.8 Snow Leopard first.
You can upgrade from 10.4 straight to 10.6 with no problems. Any program that runs under 10.4 should run under10.6. See this list for compatibility with 10.6: http://snowleopard.wikidot.com/ You might have to upgrade some drivers for printers, etc.... And you will have to install Rosetta if you have any Power PC applications http://www.macobserver.com/tmo/article/snow_leopard_installing_rosetta/
A retail 10.5 Leopard disk will run you around $20
The Snow Leopard 10.6 DVD should still be available at this time from Apple for $19.99. You will have to call Apple Customer Care 1-800-692-7753 or 1-800-676-2775 to purchase it. It may still be in the Legacy Products list. The App Store which is required to download 10.7 Lion is part of the 10.6.6 update.
Once you are at 10.6.8 Lion is still available from Apple. You will have to call Apple Customer Care 1-800-692-7753 or 1-800-676-2775. to purchase it. Then within 3 days you will get an email with a code which you can use to download Lion from the App Store. The price is $19.99.
Lion will require at least 2gb of RAM but really needs 4gb to run smoothly.
As for third party programs see this list for compatibility with 10.7 http://roaringapps.com/apps:table
Also Lion doesn't run any Power PC programs. To see if you have any Power PC programs go to the Apple in the upper left corner and select About This Mac, then click on More Info. When System Profiler comes up select Applications under Software. Then look under Kind to see if any of your applications are listed as Power PC. Universal and Intel will run under Lion.
Before Mac switched to Intel processors in 2006 they used Power PC processors from 1994 to 2005. Power PC 601 through 604, G3, G4 and G5. Applications written for the Power PC processors need the application called Rosetta to run on Intel processors. This was part of the Operating System in 10.4 and 10.5 but was an optional install in 10.6. With 10.7 Lion Apple dropped all support for Power PC applications.
Sorry, I was thinking of the MacBook model 3,1. The model 3,1 MacBook Pro can run 10.8 Mountain Lion.