Age is out of joint onstage at the Yale Repertory Theatre, where Paul Giamatti’s Hamlet seems both too old and too young to carry out his ghost-given mission of revenge. His Prince of Denmark seems far too old to be passed over for the Danish crown, yet also too immature to stake a claim to it, even when prompted to revenge by heaven and hell. In his first scene he wanders listlessly in the background of his uncle’s court before “accidentally” upstaging the king. He is a moody teenager in an overgrown body, Denmark’s perpetual problem child. This “Hamlet,” which reunites Giamatti with his fellow Yale School of Drama graduate and the Rep’s artistic director James Bundy DRA ’95, presents Shakespeare’s longest play as a tragedy of arrested development: the Melancholy Dane by way of Buster Bluth.

Elsinore Castle is a house divided, but still a feast for the eyes and ears. Meredith B. Ries has a created an ornate multilevel wooden set halfway between a playground castle and a pipe organ. A quintet of musicians, including a harpist, nestles in the crenellations, filling scene transitions with composer Sarah Pickett’s lovely original score. From the beginning, however, the design also hints of foul deeds on the rise, as costume designer Jayoung Yoon dresses Bernardo and Francisco (Mickey Theis GRD ’14 and Charlie Tirrell) in camouflage fatigues and heavy modern armament. They are standing guard for a military threat, but unprepared for the apparition of Hamlet’s father, initially conjured only by the actors’ horrorstruck gazes and the clever light and sound design of Stephen Strawbridge and Keri Klick.

When the Ghost does appear in the flesh (as it were), the effects are equally impressive, with smoke rising from Old Hamlet’s coat as if a whiff of brimstone from hell or purgatory were still clinging to him. He speaks in a voice of thunder, and when he reaches to lay a hand of blessing on his son he is dragged back as if by invisible chains. The total effect is spectral enough that one might not instantly realize that the Ghost is played by the same actor who plays Claudius (Marc Kudisch), not an unusual double but one used to especially good effect here. Claudius, with his ingratiating laugh, double-breasted suit and Danish-flag coffee mug, is a suave corporate climber, image-conscious enough to leave the lionizing portrait of his brother on the wall for a few scenes before having it replaced with a painting of Claudius arm-in-arm with his brother’s widow Gertrude (Lisa Emery).

The cracks in Claudius’ façade start to show, rather melodramatically, when he shatters a wine glass in his hand while viewing the play-within-a-play, and more subtly when Kudisch interprets Claudius’ attempt to pray for forgiveness as a crisis of faith. “My words fly up, my thoughts remain below / Words without thoughts never to heaven go,” he says, tearing the cross of state from his neck and leaving it on the chapel floor. Gertrude, for her part, moons over Claudius shamelessly in their early scenes, giving Hamlet ample reason to bitterly jest at her o’er-hasty remarriage.

Giamatti’s Hamlet seems most comfortable in moments of dark humor like this, when his excellent comic delivery comes from a place of bitterness and pain — as is the case with all the best comedians, of course. He also admirably commits himself to the physical demands of the role. This is a Hamlet who stumbles on the stairs to the battlements, greets Horatio (a stalwart Austin Durant) by leaping into his arms like Scooby-Doo, who prances about Elsinore in boxers and bathrobe when he puts on his “antic disposition.” In the duel scene, adroitly choreographed by fight director Rick Sordelet, Hamlet gleefully bounces around the stage like a rubber ball, landing cheap mock blows on the leg and crotch of an incensed Laertes (Tommy Schrider).

What seems like a missed opportunity is the potential for chemistry between Hamlet and Ophelia (Brooke Parks). She seems charming and spirited enough when she sidles behind her father, Polonius (Gerry Bamman), and mouths along with his trite advice to Laertes, but completely wilts in front of Giamatti in the nunnery scene, which he plays largely to the curtains that hide Claudius and Polonius. One wishes that something had been made of the large age disparity between this Hamlet and this specific Ophelia, but instead it is merely there, unexplained and uninterpreted.

Polonius is another mixed blessing, as Bamman dodders and blathers with laughable self-importance and utter emotional obliviousness, but lacks any edge of the spymaster or shrewd counselor that can give the role more weight. It becomes baffling to see Ophelia go so violently, bloody-shirt-wearing and nonsense-song-singing insane when neither of the men she has lost seem like crucial figures in her life.

Hamlet is always an unsuitable revenge hero, more comfortable punning with the gravedigger (here an excellently wry Jarlath Conroy) than executing his father’s command. Giamatti’s performance pushes this to an extreme, with a Hamlet who in his first monologue, flails red-faced on the marble floor like an oversized infant and calls for “this too, too solid flesh” to melt.

The very final moments of the play give us in Fortinbras (a martial Paul Pryce), the long-delayed military threat to Denmark, all that Hamlet wishes he could be: a confident man who strides onto the stage, calmly assesses the situation and takes a seat in the throne with consummate swagger. Hamlet claims self-deprecatingly that Claudius is “no more like my father / Than I to Hercules.” Never has the latter contrast been more apparent. But by highlighting the inadequacy of Hamlet the prince, this production succeeds at mounting “Hamlet” the play.