Skip to main content
2 of 3
deleted 9 characters in body

Why Mathematica solves that equation with the solution in complex numbers?

In order to solve the following Euler Differential Equation I write in the notebook:

In[15]:= Assuming[{y∈\[DoubleStruckCapitalR], n>0,x>0},DSolve[x^2 y''[x]+x  y'[x]- n y[x]==0,y[x],x]]

And I get as an output:

{{y[x]->Subscript[[ConstantC], 1] Cosh[Sqrt[n] Log[x]]+I Subscript[[ConstantC], 2] Sinh[Sqrt[n] Log[x]]}}

On the other hand when Mathematica solves the above equation with a specific value for n, for example $n=4$ , it returns the desired solution...

How can I fix this problem, please?

dmtri
  • 530
  • 3
  • 11