Raoul Peck is the Haitian film-maker who has an Oscar nomination this year with his James Baldwin documentary I Am Not Your Negro. Now he comes to Berlin with this sinewy and intensely focused, uncompromisingly cerebral period drama, co-written with Pascal Bonitzer, about the birth of communism in the mid-19th century. It gives you a real sense of what radical politics was about: talk. There is talk, talk and more talk. It should be dull, but it isn’t. Somehow the spectacle of fiercely angry people talking about ideas becomes absorbing and even gripping.

Despite the title, it is not exactly about the young Karl Marx, more about Marx’s bromance with the young Friedrich Engels. Given the potent presence of his wife Jenny, they for a microsecond almost threaten to become the Jules et Jim of the Revolutionary left. Peck saves up his biggest joke, or coup de cinéma, for the very end. After an austere movie featuring men in top hats and mutton chop whiskers, the closing credits explode in a boisterous and even euphoric montage of political events in the 20th century – Che, the Berlin Wall, Ronnie and Maggie, Nelson Mandela, the Occupy movement – to the accompaniment of Bob Dylan. No Stalin or Lenin or gulags or Erich Honecker in the montage, though.

Marx is played by August Diehl: ragged, fierce with indignation and poverty, addicted to cheap cigars, spoiling for an argument and a fight. Engels, played by Stefan Konarske, is the rich kid whose father is a mill owner, with a dandy-ish manner of dress and a romantic mien, like a young Werther who isn’t sorrowful but excited about the forthcoming victory for the working class.

They meet cute. Marx glowers on being introduced; he remembers the young Friedrich from an earlier encounter, strutting and entitled, for all the world as if he had invented the class struggle. The chippy young bruiser clashes with the arrogant puppy. But the ice breaks: Engels admires the clarity of Marx’s material thinking; Marx is a massive fan of Engels’s groundbreaking study of the English working class. Together, they inhale the new thinking in the air, ideas for which Pierre Proudhon (seductively played by Olivier Gourmet) is partly responsible. Expelled by the French, Marx flees to London with Engels where they are invited to join the socialist fraternity League of the Just, and lend intellectual and methodological rigour to their evangelical movement. But the break with Proudhon emboldens them both, and in slightly entryist style, Engels finally declares to its stunned annual congress that the League of the Just is to be reconstituted as the Communist League.

This is a film which sticks to a credo that people arguing about theories and concepts – while also periodically angrily rejecting the notion of mere abstraction – is highly interesting. And Peck and Bonitzer pull off the considerable trick of making it interesting: aided by very good performances from Diehl and Konarske, although a real flaw is the film’s relative lack of interest in their partners: Jenny, played by Vicky Krieps, and millworker Mary Burns (Hannah Steele) with whom Engels is in love: it is a rather perfunctory relationship.

There is a tense moment when Marx and Engels chance across a wealthy mill owner who is a friend of Engels’s plutocratic father: Marx coldly challenges him with his practice of exploiting child labour and says that the market force that demands this is not a law of nature, but a matter of manmade “relations of production”. The man replies sneeringly that this phrase sounds like “Hebrew” to him.

The action of the movie proceeds at a steady, intense rate: a pressure-cooker tempo, which despite the periodic shouting and yelling, does not vary much. But you can see Marx visibly ageing from his mid-20s to the brink of 30, exhausted by the birth of communism and the composition of his Communist Manifesto. It shouldn’t work, but it does, due to the intelligence of the acting and the stamina and concentration of the writing and directing.