If you buy stocks in a bear market, you better prepare for some downside volatility, and you need to be sure the company will emerge from the economic slowdown in good shape. If investors can do the former, then I think the latter is covered by looking at stocks like Google parent Alphabet (GOOG 1.77%) (GOOGL 1.77%) and industrial software company PTC (PTC 0.49%). Here's why. 

Alphabet 

It might seem strange to describe a $1.5 trillion market cap company as a value play, but that's how it is with Alphabet. The company's dominating market position in online search and its breathtaking cash flow generation and resources make it a must-buy in a weak market. The chart below shows how Wall Street sees Alphabet's earnings before interest, taxes, depreciation, and amortization (EBITDA) at the end of 2022 and 2023, as well as trailing-12-month EBITDA. It implies mid-teens growth in earnings. 

GOOG EBITDA Estimates for Next Fiscal Year Chart

Data by YCharts

So Alphabet is a growth story. However, it's also a value story. Here's a look at the trailing-12-month free cash flow (FCF) and "net financial debt," which is negative $126.8, meaning Alphabet has $126.8 billion in net cash. In addition, analysts believe Alphabet will generate $267 billion in FCF over the next three years -- a figure equivalent to almost 18% of its current market cap.

GOOG Free Cash Flow Chart

Data by YCharts

While these assumptions are under threat if the economy falls into a lengthy recession, Alphabet's market position and relevance to IT trends make it a sure winner when the economy emerges from a slow period. 

Another industrial revolution is in progress

Companies like Alphabet are high-profile winners from the online age. Still, it would be a mistake to miss out on investing in companies that benefit from an explosion in investment in internet-based technology. Of course, I'm talking about the industrial software business PTC and its relevance to the industrial internet of things (IIoT). 

The company's core products lie in computer-aided design (CAD) and product lifecycle management software (PLM). However, management sees a growth opportunity as it transitions CAD and PLM to a cloud-based software-as-service (SaaS) solution. One key benefit is that users can use CAD and PLM across different devices, and putting them in the cloud allows for easier collaboration between workers and company functions. 

Moreover, PTC's growth products, internet of things (IoT) solutions, and augmented reality (AR) solutions lie at the heart of the digital revolution. PTC's IoT solutions connect a company's physical assets to the digital world. Through the analysis of digital data created by the physical asset, owners can use sophisticated analysis to improve the performance and efficacy of the physical asset. With AR, companies can overlay complex digital information (say, a plan of electrical or plumbing connections) on a physical asset to allow for easier servicing of complex machinery. As such, the equipment can be serviced without key personnel being present, and technicians have instant access to key digital information. 

Fortunately, these trends will remain in place even if PTC suffers near-term demand degradation from a slowing economy. As such, don't be surprised if PTC reports slowing end demand in coming quarters. However, its relevance to the modern economy isn't going away anytime soon -- management estimates that "70% of companies accelerated their use of digital to transform business processes since COVID[19]."

Turning to valuation matters, PTC's management is targeting $700 million to $750 million in FCF in 2024. Conservatively plugging in the low end of the range ($700 million) would put PTC on a price-to-FCF multiple of less than 18 times 2024 FCF. Again, that's an excellent value for a company with mid-teens growth potential. 

Buying Alphabet and PTC

Before hitting the buy button, it's worth noting that both companies depend on cyclical spending in the economy -- advertising spending for Alphabet and manufacturing, design, and engineering spending for PTC. As such, they will both suffer if the economy slows markedly. However, recessions don't last forever, and both companies are likely to come out of one in solid shape.