
<PAGE>
 
                                                                    EXHIBIT 5.1
 
                [LETTERHEAD OF SHARTSIS, FRIESE & GINSBURG LLP]
 
                                 July 1, 1997
 
Lam Research Corporation
4650 Cushing Parkway
Fremont, California 94538
 
  Re: REGISTRATION STATEMENT ON FORM S-4
 
Ladies and Gentlemen:
 
  You have requested our opinion with respect to certain matters in connection
with the filing by Lam Research Corporation (the "Company") of a Registration
Statement on Form S-4 (the "Registration Statement") with the Securities and
Exchange Commission covering the offering of 9,000,000 shares of the Company's
Common Stock (the "Shares"), with a par value of $0.001, pursuant to the
Agreement and Plan of Merger (the "Agreement") by and among the Company, Omega
Acquisition Corporation and OnTrak Systems, Inc.
 
  In connection with this opinion, we have examined the Registration
Statement, the Company's Certificate of Incorporation and Bylaws, as amended,
and such other documents, records, certificates, memoranda and other
instruments as we deem necessary as a basis for this opinion. We have assumed
the genuineness and authenticity of all documents submitted to us as
originals, the conformity to originals of all documents submitted to us as
copies thereof, and the due execution and delivery of all documents where due
execution and delivery are a prerequisite to the effectiveness thereof.
 
  On the basis of the foregoing, and in reliance thereon, we are of the
opinion that the Shares, when sold and issued in the manner referred to in the
Agreement and the Registration Statement, and in accordance with resolutions
adopted by the Board of Directors of the Company, will be validly issued,
fully paid, and nonassessable.
 
  We consent to the use of this opinion as an exhibit to the Registration
Statement and to the reference to our firm appearing in the Registration
Statement.
 
                                          Very truly yours,
 
                                          SHARTSIS, FRIESE & GINSBURG LLP
 
                                          Carolyn R. Klasco
