Mathematics Stack Exchange is a question and answer site for people studying math at any level and professionals in related fields. Join them; it only takes a minute:

Sign up
Here's how it works:
  1. Anybody can ask a question
  2. Anybody can answer
  3. The best answers are voted up and rise to the top

Probably a simple question, but my math is a bit rusty... I need a function which looks similar to logarithmic (fast rise at the beginning, then slows down). $f(0) = 0$, $f(b) = a$ ($a = 100$, $b = 2500$ but should be changeable, in between $500$-$5000$)

I don't need a horizontal asymptote because I'll cut off the values when $x$ reaches $b$.

Simply, I need it for my site for calculating a score as a percentage based on number of voters, which rises in a logarithmic fashion until $x$ reaches certain number ($500$-$5000$) and then it bumps the $100$ percent value. (thus giving new users instant gratification, and preventing score spamming for those with more votes).

I played with logarithmic functions but it's hard for me to get something which can be easily parametrized to easily change the parameter $b$ while keeping the flow.

Any ideas?

share|cite|improve this question
I can understand: f(0)=0 and f(b)=a. What do you mean by "until x reaches certain number (500-5000) and then it bumps the 100 percent value."? How about an example? – NoChance Aug 25 '12 at 11:53
Basically what I meant is to have function be close to 100 on y-axis when x approaches a. It doesn't have to reach 100 precisely in a, because I was cutting it off (accuracy wasn't an issue) – Robert Osswald May 13 '13 at 9:35

How about $ \frac{100}{\ln{2501}}\ln{(x+1)}$?

share|cite|improve this answer
i.e. $\frac{a}{\ln(b+1)}\ln(x+1)$ – You Aug 25 '12 at 12:00

Perhaps $a\sqrt{\frac{x}{b}}$ (however it "slows down" much slower than a logarithmic function...)?

share|cite|improve this answer
up vote 0 down vote accepted

Just in case someone wonders, I used a work-around -- tables of a couple of key values, while interpolating points in between. But thanks for your answers, actually they almost did the trick but tables are way more fitting for my purpose which is more of a numerical nature :)

share|cite|improve this answer

Your Answer


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.