I got myself a collection of solved questions from math, and currently, I am solving linear equations with parameters. Now, in the book authors plugin 1 and -1 after they solve equations, and check how many solutions an equation for those numbers have. It happens to be 1 and -1 every time, no other numbers are used, and an equation always end up with no solution or infinite number of solution for those numbers.
Now, I can't ask a teacher because I am learning this on my own(don't go to school), but is that something I should do? Should I check how many solutions an equation has for 1 and -1 or not? Or should I just write a condition that says that I can't divide with an expression if the expression is equal to zero?
I mean it is not hard to check for 1 and -1 but I don't plan to check for every number, so what is the point of checking for 1 and -1? Okay, now is easy and relatively visible but what when it gets really complicated?
Here is the picture of how it looksan example of solved task
At the end, it says for a=0, a=1, and a=-1 an equation has no solution, for everything else solution is unique.
Thank you for your advice.
It is not that we check $1$ and $-1$ every time; rather, in all such examples, we check to make sure that we do not divide by $0$.
The example you link to starts with the equation $$\frac{x-a}{x^2-1} + \frac{a}{x^2+x} = \frac{x+a}{x^2-x}$$ and gets the solution $x = -\frac{2a}{a+1}$. There are two possible problems:
So it would be correct to say that the equation has a unique solution when $a$ is not any of $-1$, $-\frac13$, $0$, or $1$.
The solved example does not notice the $a = -\frac13$ case, so they are not being very careful. (Also, if all the examples lead to $1$ and $-1$, then that's bad practice, since it leads to the confusion you're noticing. And if checking $1$ and $-1$ is all they do even when this doesn't make sense, then the authors are the ones who are confused!)