The Return of the King
The Two Towers is all about King Théoden's troubles: he gets possessed by Saruman, deceived by his advisor, and tricked into imprisoning his nephew (Éomer) and sending his son (Théodred) to be killed in battle. But by the time we get to The Return of the King, it's like all of Théoden's inner troubles never happened. There is just too much going on in this book to linger on Théoden's problems. Instead, he seems like a mostly uncomplicated kindly older king, and definitely a background character.
Théoden spends most of The Return of the King being blandly heroic. When he leads the Rohirrim to battle at the Fields of Pelennor, he fights like a madman:
Fey [Théoden] seemed, or the battle-fury of his fathers ran like new fire in his veins, and he was borne up on Snowmane like a god of old, even as Oromë the Great in the battle of the Valar when the world was young. His golden shield was uncovered, and lo! it shone like an image of the Sun, and the grass flamed into green about the white feet of his steed. For morning came, morning and a wind from the sea; and darkness was removed, and the hosts of Mordor wailed, and terror took them, and they fled, and died, and the hoofs of wrath rode over them. (5.5.66)
Théoden's strength here is superhuman. It doesn't even seem to belong to him in particular, instead calling up this legendary figure of "Oromë the Great." That's why we say that Théoden's specific and unique character does not seem as important in The Return of the King. He has become an abstract figure of strength and goodness.
When he dies, killed by a dart from the Lord of the Nazgûl, Théoden seems almost pleased to be going. Having done a good job on the battlefield, he can now proudly join his ancestors in the afterlife. He can die in peace.
Théoden's funeral gets a long description in The Return of the King. We think this is partly because, as King of Rohan, Théoden is an important dude. But we also think it's a way for the novel to mark all of the deaths in The Return of the King. His lavish funeral allows Tolkien to draw our attention to the people who have lost their lives over the course of The Lord of the Rings.
Of course there is a lot of celebration at the end of the War of the Ring, what with Aragorn's crowning and marriage and everything, but we like that Tolkien also takes the time to remember their losses in battle. There are lots of sad songs sung and rituals performed to say good-bye to Théoden, but the most moving words are also the simplest. Merry stands at his burial mound and says, "Théoden King, Théoden King! Farewell! As a father you were to me, for a little while. Farewell!" (6.6.25-6).