Many tech companies and automakers believe that driverless cars will hit the roads within the next five years. The market demand certainly exists -- a recent survey by Pew Research Center found that nearly half of Americans wanted to ride in autonomous cars.

Investors who are interested in this fledgling market should check out three companies -- Google (GOOG -1.00%) (GOOGL -1.05%), Nokia (NOK -2.63%), and Mobileye (MBLY) -- as investment vehicles.

Google: Ambitious and expensive plans
Last year, Google unveiled prototype driverless vehicles which ferried passengers between two points at a max speed of 25 mph. The cars could automatically change lanes, make turns, and avoid collisions with nearby vehicles.

Google driverless cars. Source: Google

Google cars are impressive, but the technology is expensive. Each vehicle is equipped with approximately $250,000 of road-scanning equipment. A major expense is the LIDAR, a rotating laser on top of the vehicle which renders its surroundings in 3D. But since the LIDAR cannot process all that information in real time, roads for fully autonomous cars must be scanned again for road signs, obstacles, and curb heights. That is a painfully slow process. As of last year, Google had scanned just 2,000 miles of roads -- a tiny portion of the 170,000 miles of public roads in California.

But once Google maps out entire countries for driverless vehicles, the company could effectively take over entire transportation grids by simply licensing its technology to automakers. That would let Google accumulate user data on a deeper (and arguably creepier) level than ever before.

Nokia: The driverless cartographer
Nokia sold its handset division to Microsoft last year and recently acquired Alcatel-Lucent, streamlining itself into the second largest telecom equipment company in the world. However, the Nokia HERE division still has a 90% market share in embedded automotive maps. These maps gather data from over 80,000 sources -- including cars that use LIDAR technology and high resolution 360-degree cameras which "read" street signs.

HERE Maps for Windows. Source: Microsoft

The unit acquired Earthmine, a 3D street level imaging firm, in late 2012. The following year, it teamed up with Daimler Mercedes-Benz to test drive an autonomous vehicle over 60 miles of German roads. Like Google driverless cars, the system provided instant 3D modeling of nearby vehicles and adjusted the route accordingly. Last July, Nokia claimed that HERE will complete a high-definition map database for highways in the U.S. and Europe by 2018.

There has been a lot of buzz about Nokia possibly selling HERE to Apple, Facebook, Amazon, or other companies. The unit, which accounted for 7.6% of 2014 revenue, has a book value of around $2.1 billion. However, it could fetch twice that amount, thanks to its potential role in autonomous vehicles. Selling that unit would likely boost the stock, which plunged after the company reported weak bottom line growth at its network division last quarter.

Mobileye: Semi-autonomous driving
Whereas Google and Nokia are mapping out roads for fully autonomous driving, Mobileye currently offers cheaper solutions for "semi-autonomous" driving. The company calibrates a mix of cameras and radars -- which detect pedestrians, traffic lights, and signs -- to the brakes on your vehicle. An impressive 90% of leading automakers have already signed deals with Mobileye to install its "crash avoidance" systems in their newest vehicles.

The BMW i3 is equipped with Mobileye's collision avoidance system. Source: BMW

The MobilEye system only costs around $1,000 to install, making it a much more economical option than Google's prototype vehicles. Mobileye is also developing a system which lets drivers cruise along at freeway speeds on a single lane. Although the driver must manually change lanes, the roads do not need to be thoroughly scanned again.

Last August, RBC Capital analysts claimed that Mobileye will "experience hyper growth throughout the end of the decade" with a CAGR of nearly 50%. The firm also stated that Mobileye was the only "real pure play" for investing in autonomous vehicles. However, that widespread attention has also made the stock expensive at 64 times forward earnings.

The key takeaways
These three companies could all benefit from the rise of driverless vehicles, but they face near-term challenges as well. For now, Google must endure ecosystem battles against Facebook and Amazon more than its "moonshot" driverless project. Nokia must decide to invest more heavily in HERE Maps or sell it. Mobileye stock could be brought down by fundamental gravity.

Of these three companies, Nokia and Mobileye will be affected more by the shift toward autonomous vehicles. As for Google, it is a long-term ecosystem play which may or may not pan out.