In a large bowl, combine cream, stock, thyme, salt, and a healthy pinch of black pepper. Stir in carrot and potato slices, and let sit for 5 minutes to soak. You can choose to split mixture in half and add potatoes to one and carrots to the other, but I found it easy to pick through it after the fact.
In a small bowl, mix together garlic and shallots. Set aside.
In another small bowl, mix together gruyere and swiss cheese. Set aside.
Generously grease the bottom of a 9 by 5 inch bread pan with butter. Pick up a small handful of potatoes and lay them in the bread pan with their edges on the diagonal. Next, layer a few pieces of carrot in the same manner. Sprinkle a bit of garlic and shallots on top, then a pinch of the cheese mixture. Repeat the process again, starting with potatoes, then carrots, then garlic/shallots, then cheese. Continue to work until all the vegetables have been used up and you've reached the other end of the bread pan. Pour about ½ of the remaining liquid from the potato/carrot bowl on top of the gratin. Top with any remaining gruyere/swiss cheese, then dollop goat cheese all over the top.
Bake gratin for 45-60 minutes, until the top has browned and the vegetables are fully cooked through. Let cool for 10 minutes before serving.