The New York politician and the English painter-they seem, at least at first, somewhat unlikely friends.

Henry Geldzahler is erudite, affectionate, impressive. He wears, behind his lapel, a badge of his position. Made of gold and blue enameling, it dazzles cops and meter maids; it says "Commissioner of Cultural Affairs of the City of New York." Geldzahler went to Yale, then to Harvard. His family dealt in diamonds. At 43, he is well-known for his wit.

David Hockney is reticent and pensive. He grew up in the working class in the north of England. As a young man he would hitchhike because he could not afford train fare. Each Christmas he would work delivering the mail. But that was long ago. Hockney, 41, is now famous for his art.

Geldzahler worked for 18 years as the curator of 20th-century art at the Metropolitan Museum. One day in his office there he took a phone call from the switchboard. "This simply has to stop," the chief operator told him. "Two of every three calls to his museum are personal calls for you."

"Can I hlep it," he replied, "if I'm the only curator whose artists are still alive?"

Eventually they'll die and fade into the art books. Geldzahler will go with them. A century from now he will be remembered neither for his city office nor his exhibitions, but for the many splendid portraits of his face, beard and bow tie which his friend, David Hockney, has printed, drawn and painted since 1963.

Eight of them, all striking, are included in the Hockney show, "Travels With Pen, Pencil, and Ink," which went on view here yesterday at the Hirshhorn Museum and Sculpture Garden.

Last night at the gallery the two of them, together, lectured on the artist's work. They joked, explained and laughed.

When they met, for the first time, in 1963 in Andy Warhol's studio, Hockney was a neophyte, a man just out of art school. Geldzahler was already a kind of New York star.

Everybody knew him-young Henry, Pop Art's champion. He dined with the best people, Claes Oldenburg and others cast him in their happenings, his photo made the papers. The Met ahd never seemed so staid, the art scene in Manhattan had never seemed so flashy. Geldzahler moved in both worlds. When he met David Hockney they became friends at once.

Both were bright, concerned with art history, ambitious, independent. And both of them are gay.

Hockney never hid it. He figured, "What's the point?" and his preferences were clearly reflected in his art. Geldzahler's did not show up in his curatorial efforst. When he mentioned it in public-after his appointment-his "official coming out" was at lenght reported in the New York press.

"Mayor Koch called me the next morning. He said, 'Henry, that was gutsy. I'm proud of you. Now call your mother.'"

Hockney and Geldzahler have traveled together in France, England, Italy and Spain. Yesterday at lunch they met once again at Georgetown home at their old friends Ambassador and Mrs. Stanley Woodward.

When they talk of painting, Hockney speaks in favor of Balthus, Richard Estes, Oldenburg, van Gogh. Geldzahler interrupts. "I once wrote two post-Impressionist cheers." he says. "'Go-van-Gogh!' and 'Gauguin-go!'"

"In England," says Hockney, "The artist's name is often pronounced 'van guff.'" "There is a solution," says Geldzahler. "You can always say, 'I've just seen the van Gogh shuff.'"

The more the two men smile at each other's joke, the more they seem alike. They both were born on July 9. They share a London tailor. Geldzahler, at the opening, wore a red bowtie made of porcelain. One of Hockney's socks is yellow. The other one is blue. Each of them is wearing a pre-Columbian ring of heavy yellow gold.

"Once at a candlelight dinner," says Geldzahler, "someone saw it glint and asked, 'Is that your class ring?' I told her, 'Yes. I went to pre-Columbia.' "

In one drawing in the Hirschhorn show Geldzahler, a Havana cigar in one hand, a book in the other, reclines on what appears to be a vast cushioned bed. "The line drawings are the most difficult," says Hockney. "You must really concentrate. I drew that one in Italy. It's a sofa, not a bed. It was made by the man who was designed furniture ofr Mussolinie."

Hockney's largest Geldzahler painting, a double portrait in single-point perspective of Geldzahler and his friend, Christopher Scott, was painted in London in 1968. "It's a watershed painting," says Geldzahler. "In his picutre David finally gave up the idea of being a 'modern artist' and decided, instead, to be the best artist he could be."

"It took two or three months to paint. To draw the parquet floor I laid tapes from the vanishing point, which is two inches above Henry's head, to the bottom of the canvas. There were 20 or 30 tapes radiating from his head. At that stage it looked like an incredible radiant glow from a halo around Henry's head-with an angel in a raincoat visiting him."

"You were worried about me," Geldzahler said. "You were afraid Christopher would leave me and I'd be all alone. But Christopher is still with me after a dozen years."

There is much that's autobiographical in David Hockney's art. In each of his drawings one can see precisely how he felt about his friends. Of his Henry portraits, some are cool, some warm. "My mother," Geldzahler says, "complains that David's drawings make me look older than I am."

"Sometimes, drawing Celia, she would make me stop. 'David,' she would say, 'you're really off me at the moment.' "

"In the receiving line at the opening," said Geldzahler, "David called me aside and said let's take a couple of weeks and go traveling again. I suggested Kenya."

"What about Death Valley?" said Hockney.

"Only if your promise," Geldzahler answered, "that we'll come back alive."