Take the 2-minute tour ×
Mathematics Stack Exchange is a question and answer site for people studying math at any level and professionals in related fields. It's 100% free, no registration required.

For a mapping algorithm I'm working on, I'm trying out the effect of sigmoid weightings.

Right now I'm using $$y = \frac{1}{1+x^n}$$ where n is the steepness of the sigmoid function.

This graph shows values of x between 0 and 256 and the following values of n: 2, 4 and 32. X values have been scaled to a range of -10 to 10. Also plotted is equivalent $y=x$ line.

alt text

The effect I would like to achieve is a function that lies somewhere between the $y=x$ and the $n=2$ functions. When I set n to be between 1 and 2 however, the location of the asymptotes changes.

How can I use values of n such that $1 < n < 2$ and keep the asymptotes at 0 and 1?

share|improve this question

2 Answers 2

up vote 1 down vote accepted

You can also use $y = \frac{1}{1+ax^n}$ to give yourself another parameter to play with. It will still go from 0 to 1 as x goes from -infinity to infinity, but you can change how quickly it gets close.

share|improve this answer
1  
There's also the arctangent, the hyperbolic tangent, and if you're feeling cocky enough, the error function... ;) –  J. M. Nov 6 '10 at 15:15
    
This is the approach I ended up using, but with some amplification to keep the range neat. –  Tom Wright Dec 12 '11 at 16:19

I think it would help if you quantified what you mean by the location of the asymptote. In your graph, it looks like $y$ takes on the values 0 or 1 at different places for different values of $n$, but $y \ne 0$ for any $x > 0$ and $y \ne 1$ for any finite $x$ no matter the value of $n>0$. You could define the location of the asymptotes, for example, as the values of $x$ where $y$ equals 0.001 and 0.999. Or you could define the locations of the asymptotes as places where the derivative $y'$ equals 0.001, for example.

share|improve this answer

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

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