Cheese makes for a wonderful addition to many recipes. In some cases, such as Welsh rarebit, it is an essential ingredient. But whether it's the centerpiece or just a tasty topping, cooking with cheese can be tricky.
Some, such as Brie or Camembert, become liquid easily since they are already quite soft. Others, like Parmesan, will simply become harder the longer they are heated. Much of the difference has to do with the amount and type of fat molecules suspended throughout the cheese. But we'll skip the chemistry lesson for now.
In general, the more aged the cheese, the grainier it becomes on being melted. Younger cheeses tend to be creamier. Cheddar is an interesting middle ground, since even a fine extra sharp will melt quite nicely and make for an excellent topping on many dish.
On the opposite end of the temperature scale, if your goal is to grate the cheese you'll want to firm it up in the refrigerator. Ditto for easy slicing. For hard cheeses 30 minutes is about right, for softer 20 minutes will often be enough.
However, in the latter case, if you intend to serve a nice cheese course you may want to strike a middle ground. Cheese eaten as an appetizer or after the main meal treat should be served at room temperature. Though a little more difficult to slice that way, it will dry less if sliced later.
If you're using cheese as a topping, to be melted and applied as a garnish, you'll want to grate rather than slice. This opens up all the cheese flavor and allows for a smoother melt. Also, cooking sliced cheese tends to make it rubbery or stringy. Raclette will melt smoothly, but Mozzarella becomes stringy, for example. Unless that's the effect you're going for, grate instead.
Some care is required when cooking cheese, since most cheeses will brown, then burn, in high heat. Some of that effect may be desired to bring out a certain flavor profile. But overdoing it just leads to hard, tasteless, carbonized cheese. So, think about adding the cheese later during the cooking time.
If you're counting calories, you may be concerned about the fat content in cheese. Apart from using low-fat cheeses, which can be bland tasting, you can be a little more generous when using it for cooking.
Soft cheeses, like Brie, have a high moisture content. Since fat content is measured dry, Brie and similar cheeses will actually have less fat content per unit weight when cooked than harder cheeses. More aged cheeses, like an extra sharp cheddar, have a more assertive flavor, allowing you to use less and still have a very tasty dish.
As a general rule of thumb, a half-pound of cheese will make about 2 cups of grated cheese. About 2 ounces per person is usually all you need to balance flavor and calories.
Cheese is a tasty and nutritious food, raw or cooked. But used in cooking it can have an entirely new flavor essence from the raw version. Experiment!