I would like to start the discussion with this question:
Are proofs or solutions to mathematical problems merely discovered, or can one get the starting point of a proof or a solution using a well-defined method?
I will explain the above question using this example:
Suppose we are given a problem to find the maximum and minimum values of a function. The problem is as follows:
Let $f:\mathbb R\to \mathbb R$, such that $f(x)=a\cos x+b\sin x$.
Now, my book starts with a very illogical statement: Let $a=r\cos\alpha$ and let $b=r \cos\alpha$. How can this statement be true? We chose any $r$ and $\alpha$ such that the above relation for $a$ is true, how can we be sure that the same $r$ multiplied by $\cos\alpha$ give us $b$?
I spent some time on this problem, but couldn't solve it. So I checked the solution somewhere else. I saw a pdf file where, first they drew a graph of the function, and it very clearly was the graph of a cosine. So from the graph, it was observable that this function is of the form $r\cos(x+\alpha)$, since it had a shift too. But, my question is not regarding this particular problem.
Now, like in the above example, we had to do an analysis of the function first, to obtain the relation and from there, we solved the problem. But is there any way we can do all this without this analysis, which sometimes take a lot of time?
Suppose I just give this problem to you:"Find the maximum and minimum values of the function given". How will you know that it is of a particular form, how will you know there is an identity you can apply to it, how will you know there is a special technique for it?
So finally: Is there any easier way of spotting patterns in a problem, or finding the starting point at least? Or is it just time consuming to find a pattern? How do great mathematicians start when they encounter a new problem?