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.

Someone me asked this and I was unable to answer. How can I maximize the function $f(x)=Ae^{-(x-b)^2}+Be^{-(x-c)^2}$?

Progress: For $A=B$, this is the same as maximizing $-(x-b)^2(x-c)^2$, which is easy. If $A\neq B$, I'm not sure how to factor in the coefficients, however.

share|improve this question
add comment

1 Answer 1

$f'(x)=-2(x-b)Ae^{-(x-b)^2}-2(x-c)Be^{-(x-c)^2}$. This looks like it won't yield to algebra and will need a numerical solution. I would start at the average of $b$ and $c$ and go from there. You could use a root-finder on this or a maximizer on the original. Routines are given in any numerical analysis text.

share|improve this answer
I was hoping there's an exact solution through some clever manipulation. Like, the derivative of $e^{-(x-b)^2}+e^{-(x-c)^2}$ is also difficult to solve with algebra, but since the relationship between the two summands is "equal" you can intuitively replace this problem with that of maximizing $-(x-b)^2(x-c)^2$ (i.e. the maximum is at the average). From here it doesn't seem like a far stretch to be able to do the same with unequal coefficients, as long as you figure out how they factor into the entire dirty business. But maybe this is just my lack of experience talking... –  add Feb 8 '13 at 22:38
add comment

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.