The inverse of a function
, is the function
, that reverses f. That means that if
, then
. For example, the function to convert celsius temperature to fahrenheit is:
, the inverse function (convert from fahrenheit to celsius) is:
. So that,
and
.
Given a polynomial function P (presented as vector of numbers), and a value n, if
, write a program that evaluates
, where
.
For example, if
, and
, then
and
. Therefore
.
NOTE: It is possible for
to return some complex numbers. We are interested only with real values, so in cases where there are no real
, please output an empty vector. Also please round-off your output to 4 decimal places, and sorted in ascending order.
Solution Stats
Problem Comments
4 Comments
Solution Comments
Show comments
Loading...
Problem Recent Solvers7
Suggested Problems
-
Maximum running product for a string of numbers
2257 Solvers
-
3944 Solvers
-
Remove the polynomials that have positive real elements of their roots.
1743 Solvers
-
Least common multiple of many numbers
256 Solvers
-
Project Euler: Problem 5, Smallest multiple
1674 Solvers
More from this Author116
Problem Tags
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!
I haven't quite figured out what problem 8 is supposed to do. I am getting a large number of real solutions, mostly 0.0 or 0.0001. I used unique() to reduce the solution to four values. These values are all correct except that they include 0.0.
Hi William, I missed to write "0.0000" in the solution set of test #8. Sorry for that. Corrected it.
Please rate the problem. Thanks.
For problem 8 I see only three real solutions--none that give R=0.0000.
I see now--you want to round off R before testing for an imaginary part.