(Hey everyone, I'm new to Stack Exchange and this is actually my first question, so if I'm doing anything inappropriate regarding asking questions, please point that out for me.)
So I've been taking an ODE course lately, and I encountered a question in my homework, which is basically an Initial Value Problem that goes by $$y^\prime = (1 - 2x)y^2, \ y(0) = -\frac{1}{12}.$$
This is a pretty standatd IVP, so I just attempted by dividing both sides by $y^2$ (while noting the trivial solution $y = 0$):
$$\frac{dy}{y^2} = (1-2x)dx$$
Integrating both sides gives me
$$-\frac{1}{y} = -x^2 + x + C$$
Plugging in the initial conditions gives $C = 12$, so after doing some algebraic manipulations, the final answer I obtained is $y = 0$ and $y = \frac{1}{x^2 - x -12}.$
But here's the thing: the solution given by my teacher is $$y = \frac{1}{x^2 - x - 12}, \ -3 < x < 4,$$
about which there are several things I'm not so sure.
First, I don't really understand why the trivial solution is missing in the suggested solution. Also, I'm not sure whether it's necessary at all to include the domain of the function in the answer (since the solutions to problems as such on textbooks don't seem to bother including the domains), although in this case since the polynomial with $x$ terms is in the denominator, there is certain constraints on the interval on which $y$ is defined--which brings out my third confusion: why is the domain here not simply $x \neq -3, x \neq 4$, but an open interval $(-3, 4)$? One possible reasoning I came up with is that, given the initial point $(0, -\frac{1}{12})$, we only care about the part of the function close to that point. But if the answer is given solely by the suggested solution, isn't the trivial solution completely ignored?
My concerns here are really just about subtlties, but as a beginner in ODE, I find these minor issues especially convoluted and needs clarifications, so I'd be appreciative if anyone can help with this!
$\textbf{EDIT}$: $y^2$ is not a trivial solution in this case, as it does not satisfy the initial condition, so I've made a dumb mistake...It is better though, to explicitly write down the domain of the function (see Anne's comment below). Thank you guys for helping!
Under some mild conditions (such as local Lipschitz continuity of the right-hand side with respect to $y$) the solution of an initial value problem is locally unique. That means that on any interval $I$ containing the origin, there is at most one function $y: I \to \Bbb R$ satisfying $$ y'(x) = (1-2x^2)y(x)^2 $$ for all $x \in I$ and $y(0) = -1/12$.
If you allow arbitrary domains then the uniqueness is lost: As an example, the function $y: \Bbb R\setminus \{ -3, 4\} \to \Bbb R$ defined as $$ y(x) = \begin{cases} 0 & \text{ for } x < -3 \\ \frac{1}{x^2 - x - 12} & \text{ for } -3 < x < 4 \\ \frac{1}{x^2 - x - \pi^2} & \text{ for } x > 4 \\ \end{cases} $$ is differentiable everywhere in its domain, and satisfies the differential equation and the initial value condition. It is not unique at all: on each of the intervals $(-\infty, -3)$ and $(4, \infty)$ the integration constant can be chosen arbitrarily. The initial value $y(0) = -1/12$ is irrelevant there.
Therefore the solutions of initial values problems are usually considered on intervals (or in connected domains). One can then try do find the “maximal solution,” that is the solution defined on the largest possible interval containing the initial value. In your case the maximal solution is the function $y = \frac{1}{x^2 - x - 12}$ on the interval $(-3, 4)$.