Inverting a function? f(y) instead of f(x)

  • Thread starter iLIKEstuff
  • Start date
  • Tags
    Function
In summary, the conversation discusses comparing two fitted curves by looking at the difference in x and the challenges in inverting the function to calculate the difference in x for a given y. The problem is solved using eigenvalues and the knowledge of the approximate root values. The conversation also mentions using the inverse function theorem and solving the equation for x to find the roots.
  • #1
iLIKEstuff
25
0
I'm trying to compare two fitted curves by looking at the difference in x. Standard regression analysis tools always give you a delta Y (residual) and this is how the fit is done in the first place.

So I have the coefficients of each of the terms for my 7th-order polynomial. it's in the form

[itex]y = f(x) = ax^7 + bx^6 + cx^5 + dx^4 + ex^3 + fx^2 + gx + h[/itex]

The two curves have slightly different coefficients. Now how do I invert this function to get an f(y) so that I can calculate the difference in X for a given Y?

This problem is easy for a simple function like [itex]y = f(x) = ax^2[/itex] then inverting it you get [itex]x = f(y) = \sqrt{y}/a[/itex] for positive y-values.

Since I have the actual X and Y sets of values, I tried rotating the values 90 degrees (http://en.wikipedia.org/wiki/Rotation_matrix) and then looking at the delta Y, but the problem is the X values aren't the same anymore. Yes, a somewhat pointless attempt, but potentially serendipitous nonetheless.

I have the X and Y data and also have access to a basic PC with MATLAB for number crunching if needed.
Are there any clever tricks I can play to get the difference in X for a given Y? I'm sure I'm missing something here...
 
Last edited:
Physics news on Phys.org
  • #2
Since polynomials are infinitely-differentiable, you can use the inverse function theorem to determine where/if a local or global inverse exists. For one, your function must be 1-1 and onto ℝ (which I assume is your codomain) for a global inverse to exist.

You may want to try 'solving for x' in your equation, see what you get.
 
  • #3
Thanks for the help. I managed to figure it out using eigenvalues to find the roots and also the fact that I know roughly what the root should be (since my function is completely arbitrary). Basically I fed in the Y values for both equations, then solved each one for X by finding the eigenvalues. Since I know the X for one set isn't too far off from the X in the other set, I can reject all complex roots and roots that are way off.
 

1. What does it mean to "invert a function"?

Inverting a function means to find another function that "undoes" the original function. In other words, if the original function takes an input x and produces an output y, the inverse function will take y as its input and produce x as its output.

2. How do I know if a function can be inverted?

A function can be inverted if it is a one-to-one function, meaning that each input has a unique output. This can be determined by graphing the function and seeing if it passes the horizontal line test. If the function passes the test, it can be inverted.

3. What is the notation for an inverted function?

The notation for an inverted function is f-1(y), where y is the input and f-1(y) is the output.

4. How do I find the inverse of a function?

To find the inverse of a function, first set the function equal to y. Then, swap the x and y variables and solve for y. The resulting equation will be the inverse function. It is important to remember to switch the domain and range of the function when finding the inverse.

5. Can all functions be inverted?

No, not all functions can be inverted. Functions that are not one-to-one, such as quadratic functions, cannot be inverted. In some cases, a portion of a function can be inverted, but not the entire function. It is important to check the function's one-to-one status before attempting to find the inverse.

Similar threads

  • Calculus and Beyond Homework Help
Replies
5
Views
221
  • Precalculus Mathematics Homework Help
Replies
15
Views
633
  • General Math
Replies
11
Views
398
  • Linear and Abstract Algebra
Replies
2
Views
1K
  • Programming and Computer Science
Replies
3
Views
352
Replies
6
Views
1K
  • Precalculus Mathematics Homework Help
Replies
12
Views
1K
  • Linear and Abstract Algebra
Replies
4
Views
1K
  • General Math
Replies
5
Views
1K
  • Topology and Analysis
Replies
6
Views
912
Back
Top