Trinity Industries (NYSE: TRN) reported earnings on July 31. Here are the numbers you need to know.

The 10-second takeaway
For the quarter ended June 30 (Q2), Trinity Industries beat expectations on revenues and beat expectations on earnings per share.

Compared to the prior-year quarter, revenue increased. Non-GAAP earnings per share grew significantly. GAAP earnings per share increased significantly.

Margins grew across the board.

Revenue details
Trinity Industries chalked up revenue of $1.07 billion. The 10 analysts polled by S&P Capital IQ predicted revenue of $1.02 billion on the same basis. GAAP reported sales were 3.7% higher than the prior-year quarter's $1.03 billion.

Source: S&P Capital IQ. Quarterly periods. Dollar amounts in millions. Non-GAAP figures are normalized by S&P Capital IQ and may vary to maintain comparability with normalized estimates.

EPS details
EPS came in at $1.09. The 12 earnings estimates compiled by S&P Capital IQ predicted $0.95 per share. Non-GAAP EPS of $1.09 for Q2 were 31% higher than the prior-year quarter's $0.83 per share. GAAP EPS of $1.06 for Q2 were 26% higher than the prior-year quarter's $0.84 per share.

Source: S&P Capital IQ. Quarterly periods. Non-GAAP figures are normalized by S&P Capital IQ and may vary to maintain comparability with normalized estimates.

Margin details
For the quarter, gross margin was 23.8%, 370 basis points better than the prior-year quarter. Operating margin was 17.1%, 240 basis points better than the prior-year quarter. Net margin was 7.9%, 130 basis points better than the prior-year quarter. (Margins calculated in GAAP terms.)

Looking ahead
Next quarter's average estimate for revenue is $1.05 billion. On the bottom line, the average EPS estimate is $1.06.

Next year's average estimate for revenue is $4.04 billion. The average EPS estimate is $4.00.

Investor sentiment
The stock has a five-star rating (out of five) at Motley Fool CAPS, with 1,039 members out of 1,069 rating the stock outperform, and 30 members rating it underperform. Among 234 CAPS All-Star picks (recommendations by the highest-ranked CAPS members), 234 give Trinity Industries a green thumbs-up, and give it a red thumbs-down.

Of Wall Street recommendations tracked by S&P Capital IQ, the average opinion on Trinity Industries is outperform, with an average price target of $45.75.

Is Trinity Industries the right retailer for your portfolio? Learn how to maximize your investment income and ""Secure Your Future With 9 Rock-Solid Dividend Stocks,"" including one above-average retailing powerhouse. Click here for instant access to this free report.

This article represents the opinion of the writer, who may disagree with the “official” recommendation position of a Motley Fool premium advisory service. We’re motley! Questioning an investing thesis -- even one of our own -- helps us all think critically about investing and make decisions that help us become smarter, happier, and richer.