Pattern formation on curved surfaces