Robert B. Garrabrant, 77, a civil engineer and a retired head of the student science training program of the National Science Foundation, died Sunday at the National Institutes of Health in Bethesda. He had undergone heart sugery.

Mr. Garrabrant was born in Upper Montclair, N.J. He graduated from Cornell University in 1922 with a degree in a civil engineering and practiced his profession in the New York-New Jersey area for several years.

He came to Washington in 1936 as an editor of the Engineering New Record. He continued as a writer and editor on civil engineering matters with the McGraw-Hill Publishing Co., the U.S. Chamber of Commerce and the Urban Land Science until joining the National Science Foundation in 1958. He retired in 1971.

Mr. Garrabrant was a member of the National Press Club and a past-president of the Cornell Club of Washington.

Survivors include his wife, Elizabeth Ady Garrabrant, of the home in Chevy Chase; a son. Samuel R., of Bethesda; a daughter, Ann, of the home, and three grandchildren.

The family suggests that expressions of sympathy be in the form of contributions to the Patient Emergency Fund, National Institutes of Health, Bethesda, 20014.