Lockheed Corp. earned $51.8 million ($2.68 a share) in the second quarter compared with $14.8 million (83 cents) a year ago, when profits were slashed by a $19.5 million loss on the TriStar program. Sales increased to $1.475 billion from $1.238 billion.

First-half net income was $89.3 million ($4.89) on sales of $2.619 billion compared with $51.1 million ($3.09). Sales in the first half of last year were $2.387 billion.

B.F. Goodrich Co.'s second-quarter earnings dropped to $19.4 million (95 cents a share) from $26.5 million ($1.38) a year ago, but offset the first-quarter loss to create a first-half profit.

Second-quarter sales fell to $793.5 million from $828.5 million a year earlier. The 1982 second-quarter profit included a gain of $4.4 million on the sale of an isoprene plant and $5.2 million on a reduction in pension expense.

First-half net income was $1 million after an $8 million loss because of the devaluation of the Mexican peso. Sales were $1.5 billion. In the 1981 first half, Goodrich earned $53.8 million ($2.87 a share) on sales of $1.6 billion..

Union Carbide Corp. yesterday blamed the slumping U.S. auto industry and the 1981 divestititure of its ferroalloys business for a 39 percent drop in second-quarter earnings to $118.2 million ($1.71 a share) from $193.4 million ($2.86) and a 14 percent decline in revenues to $2.3 billion from $2.7 billion for the same period last year.

First-half net income was $209 million ($3.03) compared with $371.4 million ($5.50), and revenues were $4.61 billion, down 13 percent from $5.3 billion.

Republic Steel Corp., which had predicted a substantial loss for the second quarter, yesterday reported that loss as $85.3 million compared with a 1981 second-quarter profit of $43.1 million ($2.67 a share) as sales dropped sharply to $752.9 million from $1.2 billion.

Republic attributed the loss to "the sustained severe weakness in the economy and resulting low steel demand."

During the first half, Republic, the nation's No. 5 steel maker, lost $104 million compared with a profit of $75.7 million ($4.68 ) during the comparable span in 1981. Revenue was $1.64 billion compared with $2.33 billion.

Bendix Corp. said its fiscal third-quarter earnings were about half those of a year ago, dropping to $38.1 million ($1.66 a share) from $77.6 million ($3.39)in the same period last year. Sales were 8.7 percent lower, at $1.05 billion compared with $1.16 billion.

Nine-month net income was $119.3 million ($5.21), down 69.4 percent from $389.1 million ($15.56), and sales were $3.17 billion, down 7.3 percent from $3.42 billion.