EDIT
Sorry. I have made a mistake in the choice of the initial conditions which is corrected below. This error does not change the general staetements.
Corrected exposition
As far as I can see there is no problem with the completeness of the solutions provided by Mathematica.
$Version
(* Out[16]= "10.1.0 for Microsoft Windows (64-bit) (March 24, 2015)" *)
The general solution to the ODE is found by Mathematica to be
sol = DSolve[f'[x] == -Sqrt[2] (1/4 - 2 f[x]^2), f[x], x]
(* Out[2]= {{f[x] -> -((-1 + E^(2 x + 4 Sqrt[2] C[1]))/(
2 Sqrt[2] (1 + E^(2 x + 4 Sqrt[2] C[1]))))}} *)
As expected, the solution contains one arbitrary constant C[1].
The two branches of the solution correspond just to different choices of C[1].
Notice also that C[1] can be a complex number.
Let us have closer look on the situation.
The critical value of the function is
fc = -(1/(2 Sqrt[2]));
Now we complete the problem by imposing an initial condition on f.
And we distinguish two cases (here I am correcting my mistake of not imposing the condition of on the module)
(1) Abs[f[0]] < Abs[fc]:
ff1[x_] = f[x] /.
DSolve[f'[x] == -Sqrt[2] (1/4 - 2 f[x]^2) && f[0] == 1/4, f[x], x][[1]]
During evaluation of In[12]:= Solve::ifun: Inverse functions are being
used by Solve, so some solutions may not be found; use Reduce for
complete solution information. >>
(* Out[14] = -((1 - 3 E^(2 x) + 2 Sqrt[2] E^(2 x))/(
2 Sqrt[2] (-1 - 3 E^(2 x) + 2 Sqrt[2] E^(2 x)))) *)
(2) Abs[f[0]] > Abs[fc]:
ff2[x_] = f[x] /.
DSolve[f'[x] == -Sqrt[2] (1/4 - 2 f[x]^2) && f[0] == 2, f[x], x][[1]]
During evaluation of In[14]:= Solve::ifun: Inverse functions are being
used by Solve, so some solutions may not be found; use Reduce for
complete solution information. >>
(* Out[15] = -((-7 - 9 E^(2 x) + 4 Sqrt[2] E^(2 x))/(
2 Sqrt[2] (7 - 9 E^(2 x) + 4 Sqrt[2] E^(2 x)))) *)
and compare the results in a plot:
Plot[{ff1[x], ff2[x]}, {x, 0, 3},
PlotLabel -> "Solution of ODE\nblue curve = ff1, yellow curve = ff2",
PlotRange -> {-2, 2}]
Summarizing: Mathematica in fact provides the general solution. This includes automatically the cases mentioned in the OP which correspond just to different initial conditions.
DSolve
doesn't find all solutions, rather generic ones. $\endgroup$sols = (Table[ DSolve[D[f[x], x] == -Sqrt[2]*(1/4 - 2 f[x]^2) && f[0] == -(a/(2 Sqrt[2])), f[x], x], {a, -2, 0, 1/2}] // Quiet // Simplify // Flatten)[[All, 2]]; Plot[sols, {x, -2, 2}, Evaluated -> True]
and compere the plots with e.g.Plot[{Tanh[x], Coth[x]}, {x, -2, 2}, Evaluated -> True]
. In the first case you got both corresponding cases. $\endgroup$a
in such a way withTable
to include solutions from the both classes. $\endgroup$