How to rotate a function about the origin?

I am trying to model something as an exponential function. The exponential function I first came up with is

y = b^x

However, I needed to reflect that curve across the x axis. That was easy:

y = b^(-x)

Now I need to rotate it 90[sup]o[/sup]. I can’t remember how to rotate a function. I’m sure I learned it in high school analytic geometry. Searches turn up how to do much more complex rotations, like rotating a curve in 3-space to create a surface for computer graphics purposes. I’m looking for something that I think should be pretty basic.

I know how to rotate a linear function, and rotate a given point using a 2x2 rotation matrix. I just can’t figure out how to generalize it for an exponential function…

Doesn’t just swapping x and y do that?

Yes, although you will have to restrict to domain in order for it to remain a function.

It appears that switching to a logarithmic function works pretty well.

The graph of your function is the set of 2-vectors of the form (x, b^(-x)). You can rotate the graph by multiplying each of those vectors by the appropriate rotation matrix, but getting a new equation of the form y = f(x) will require some clever algebraic manipulation.

Swapping x and y is how you reflect the graph, not rotate it.

I ended up using

y = c*log(dx)

where c and d are arbitrary constants.

Terminology aside, though, it sounds like that’s what the OP is actually trying to do.

What you’re doing is switching from one function (the exponential) to its inverse function (the logarithm). If you want to do the same flip with y=x^2, you’ll end up using y=sqrt(x). This amounts to swapping x and y as beowulff said.

I’m a bit out of my depth here, but isn’t this an application of complex numbers? I think if you map onto the complex plane, and multiply by i, that will rotate everything by 90[sup]o[/sup]. If you’ve gone the wrong direction, try -i.

You can do a quick-and-dirty rotation by replacing y with x everywhere it appears, and replacing x with (-y). (The minus sign there is what makes it a rotation rather than a reflection.) In other words, if you plot all the points in the plane satisfying y = f(x), then the points satisfying x = f(-y) will look like the same graph rotated 90[sup]o[/sup] clockwise about the origin. In your example, if you take

y = b[sup]x[/sup]

and do this swap, you end up with

x = b[sup]-y[/sup]

which, rearranging things, gives

y = - log[sub]b[/sub] x.

Of course, you can’t always write the relation x = f(-y) in the form y = g(x) — it’s just luck that you can do so here, and even in this case the domain of the function is only the positive real numbers, not all real numbers.