Preheat the oven to 200°C/fan180°C/gas 6.
In a saucepan, bring 200ml vegetable stock to the boil with 2 garlic cloves, lightly crushed.
Remove from the heat and stir in 200ml double cream.
Set aside to cool and infuse.
Heat 1 tbsp olive oil in a pan and gently fry 1 large onion, chopped, for 10 minutes, until very soft.
Peel and quarter 1 large celeriac, then slice to 3mm thickness.
Put in a bowl with 3 medium potatoes, sliced to 3mm thickness.
Toss with 1 tbsp plain flour, 1 tbsp chopped fresh flat leaf parsley and some seasoning.
Butter a 1.2-litre ovenproof dish and layer up the celeriac, potatoes and the softened onion.
Strain the cream mixture (discard the garlic) into a jug and pour over the gratin.
Bake for 1-1¼ hours, until golden brown and bubbling and the potatoes are cooked through.