Skip to main content
added 98 characters in body
Source Link
Ulrich Neumann
  • 56.8k
  • 2
  • 26
  • 60

If you solve your ode without initial conditions

ode = y'[x] == (y[x]^2 - x^2 - 2*x*y[x])/(y[x]^2 + 2*x*y[x] - x^2)
ic = y[1] == -1
{y1, y2} = (Values@DSolve[{ode }, y, x ] // Flatten) /. C[1] -> c1

you get two solutions.

Only the secondfirst solution may fullfill y[1]==1y[1]==-1

Plot[{y1[1], y2[1]}, {c1, -5, 5}, PlotRange -> {-2, 2},PlotStyle -> {Blue, Red}]

enter image description here

Asymptotic[y1[x], c1 -> Infinity] 
(*ConditionalExpression[-x, x \[Element] Reals]*)

If you solve your ode without initial conditions

ode = y'[x] == (y[x]^2 - x^2 - 2*x*y[x])/(y[x]^2 + 2*x*y[x] - x^2)
ic = y[1] == -1
{y1, y2} = (Values@DSolve[{ode }, y, x ] // Flatten) /. C[1] -> c1

you get two solutions.

Only the second solution may fullfill y[1]==1

Plot[{y1[1], y2[1]}, {c1, -5, 5}, PlotRange -> {-2, 2},PlotStyle -> {Blue, Red}]

enter image description here

If you solve your ode without initial conditions

ode = y'[x] == (y[x]^2 - x^2 - 2*x*y[x])/(y[x]^2 + 2*x*y[x] - x^2)
ic = y[1] == -1
{y1, y2} = (Values@DSolve[{ode }, y, x ] // Flatten) /. C[1] -> c1

you get two solutions.

Only the first solution may fullfill y[1]==-1

Plot[{y1[1], y2[1]}, {c1, -5, 5}, PlotRange -> {-2, 2},PlotStyle -> {Blue, Red}]

enter image description here

Asymptotic[y1[x], c1 -> Infinity] 
(*ConditionalExpression[-x, x \[Element] Reals]*)
Source Link
Ulrich Neumann
  • 56.8k
  • 2
  • 26
  • 60

If you solve your ode without initial conditions

ode = y'[x] == (y[x]^2 - x^2 - 2*x*y[x])/(y[x]^2 + 2*x*y[x] - x^2)
ic = y[1] == -1
{y1, y2} = (Values@DSolve[{ode }, y, x ] // Flatten) /. C[1] -> c1

you get two solutions.

Only the second solution may fullfill y[1]==1

Plot[{y1[1], y2[1]}, {c1, -5, 5}, PlotRange -> {-2, 2},PlotStyle -> {Blue, Red}]

enter image description here