- #1
fog37
- 1,568
- 108
Hello,
I am numerically plotting a sine function sin(x) with amplitude 1 from x=0 to x=15. No problem with that.
The next step gives me problems: I would like the sine function amplitude to decay exponentially starting at x=5 and not before that (the amplitude remains 1). I think I need to multiply the sine function by exp[-(x-5)] to have the amplitude decay starting from x=5. But that alone causes problems with the values less than 5...How should I deal with it?
thanks!
fog37
I am numerically plotting a sine function sin(x) with amplitude 1 from x=0 to x=15. No problem with that.
The next step gives me problems: I would like the sine function amplitude to decay exponentially starting at x=5 and not before that (the amplitude remains 1). I think I need to multiply the sine function by exp[-(x-5)] to have the amplitude decay starting from x=5. But that alone causes problems with the values less than 5...How should I deal with it?
thanks!
fog37