1
$\begingroup$

The known analytical formula for composite functions is:

f[Sqrt[x] + 1/Sqrt[x]] == x + 1/x

The analytical formula for f [x] cannot be obtained through this method:

In[62]:= Clear["Global`*"]
RSolve[{f[Sqrt[x] + 1/Sqrt[x]] == x + 1/x}, f[x], x] // FullSimplify

Out[63]= RSolve[{1/x + x == f[(1 + x)/Sqrt[x]]}, f[x], x]

and this method is also cannot

Clear["Global`*"]
Simplify /@ (f[Sqrt[x] + 1/Sqrt[x]] == x + 1/x /. 
    Solve[y == Sqrt[x] + 1/Sqrt[x], x][[1]]) /. {y -> x, 
  Equal -> Rule}

enter image description here

$\endgroup$
4
  • 1
    $\begingroup$ Could you explain what The known analytical formula for composite functions is: f[Sqrt[x] + 1/Sqrt[x]] == x + 1/x mean? According to Reduce, Reduce[Sqrt[x] + 1/Sqrt[x] == x + 1/x] is true when x=1 only. What is f role here? I am not reading your question right it seems. $\endgroup$
    – Nasser
    Jun 6, 2023 at 3:28
  • $\begingroup$ fF represents the corresponding relationship of the function $\endgroup$
    – csn899
    Jun 6, 2023 at 3:31
  • $\begingroup$ What is the analytical expression required for f [x]. Known conditions are f[Sqrt[x] + 1/Sqrt[x]] == x + 1/x $\endgroup$
    – csn899
    Jun 6, 2023 at 3:32
  • $\begingroup$ Well, according to reduce, if you give me Sqrt[x] + 1/Sqrt[x] and want me to return back x + 1/x then only when x=1 this is possible. I am not sure what you mean by how to represent f in this case. Hopefully someone will have an answer. $\endgroup$
    – Nasser
    Jun 6, 2023 at 3:34

2 Answers 2

10
$\begingroup$
Clear["Global`*"]

eqn1 = f[Sqrt[x] + 1/Sqrt[x]] == x + 1/x;

sol = Solve[y == Sqrt[x] + 1/Sqrt[x], x] // Quiet

(* {{x -> 1/2 (-2 + y^2 - y Sqrt[-4 + y^2])}, 
    {x -> 1/2 (-2 + y^2 + y Sqrt[-4 + y^2])}} *)

Using first solution,

eqn2 = f[y] == Simplify[x + 1/x /. sol[[1]]] /.
  {y -> x, Equal -> Rule}

(* f[x] -> -2 + x^2 *)

Verifying,

eqn1 /. f -> Function[{x}, x^2 - 2] // Simplify

(* True *)

Using the second solution,

eqn3 = f[y] == Simplify[x + 1/x /. sol[[2]]] /.
  {y -> x, Equal -> Rule}

(* f[x] -> -2 + x^2 *)

This is identical to the first result.

$\endgroup$
6
$\begingroup$

Assuming f is invertible:

eqn = f[y] == f[Sqrt[x] + 1/Sqrt[x]] == x + 1/x;
Solve[Eliminate[eqn, {x}], f[y]]

InverseFunction::ifun: Inverse functions are being used. Values may be lost for multivalued inverses.

{{f[y] -> -2 + y^2}}

Note: The solution f is invertible on the implicit domain, which is the range of the argument Sqrt[x] + 1/Sqrt[x] (Re[y] >= 0). However, the method works on Solve[Eliminate[f[y] == f[Sqrt[x] + 1/Sqrt[x]] == 2, {x}], f[y]], even though f[y] -> 2 is not invertible. The warning arises because Solve uses InverseFunction[f][f[u]] to extract the argument u, which is what you see others (in the OP and other answer) doing by hand.

$\endgroup$

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.