Matlab cant find the inverse of my function

7 ビュー (過去 30 日間)
Muhammad Adillah
Muhammad Adillah 2023 年 12 月 6 日
コメント済み: Muhammad Adillah 2023 年 12 月 6 日
My matlab cant find the inverse of this function
f =
It results in "warning: Unable to find functional inverse" and "ans = Empty syms: 0-by-1"
I've tried to remove the a variable of a and change it into a number, but the result is still the same
syms x a real
f = sqrt((a+1)/(a-1))*atan(sqrt((a-1)*(x^2-1)/(a+1)))-atan(sqrt(x^2-1))
f = 
finverse(f, a)
Warning: Unable to find functional inverse.
ans = Empty sym: 0-by-1
  2 件のコメント
Dyuman Joshi
Dyuman Joshi 2023 年 12 月 6 日
Are you sure that an inverse exists?
Walter Roberson
Walter Roberson 2023 年 12 月 6 日
Not every function has a recognizable functional inverse.

サインインしてコメントする。

採用された回答

Sam Chak
Sam Chak 2023 年 12 月 6 日
The main issue is caused by the product term because it lacks a functional inverse:
.
Perhaps you will gain a clearer understanding when you plot the product and its numerical functional inverse. Complex values are omitted. While the inverse exists (see red curve), it cannot be expressed in terms of standard mathematical functions.
% assume x = 3
a = -5:0.001:5;
f = atan(sqrt((a - 1)*(3^2 - 1)./(a + 1))).*sqrt((a + 1)./(a - 1));
idx = find(f == real(f));
areal = a(idx);
freal = f(f == real(f));
plot(areal, freal, '.', 'markersize', 1), hold on, grid on
plot(freal, areal, '.', 'markersize', 1)
plot(a, a, '--'), hold off
axis equal
axis([-5 5 -5 5]), xlabel a
legend('f(a)', 'f^{-1}(a)', 'location', 'NW')
  1 件のコメント
Muhammad Adillah
Muhammad Adillah 2023 年 12 月 6 日
I see, so the problem were at the given function and not the code then. Thank you very much for the insight

サインインしてコメントする。

その他の回答 (0 件)

カテゴリ

Help Center および File ExchangeAssumptions についてさらに検索

製品


リリース

R2022b

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!

Translated by