comp.lang.idl-pvwave archive
Messages from Usenet group comp.lang.idl-pvwave, compiled by Paulo Penteado

Home » Public Forums » archive » Help - generate bell shaped function
Show: Today's Messages :: Show Polls :: Message Navigator
E-mail to friend 
Switch to threaded view of this topic Create a new topic Submit Reply
Help - generate bell shaped function [message #90242] Fri, 13 February 2015 07:42 Go to next message
g.nacarts is currently offline  g.nacarts
Messages: 148
Registered: November 2013
Senior Member
Hi

I was wondering if there is any way to create my own bell shape function. I want a function which have a bell shaped but it's pick is not at zero (y=0). I need it to start from zero and stay zero for few points e.g.20 and then starts going up (e.g. pick y=5) and then coming down to zero and stay zero for few points again. Does anyone can help with this?
Re: Help - generate bell shaped function [message #90243 is a reply to message #90242] Fri, 13 February 2015 07:47 Go to previous messageGo to next message
chris_torrence@NOSPAM is currently offline  chris_torrence@NOSPAM
Messages: 528
Registered: March 2007
Senior Member
On Friday, February 13, 2015 at 8:42:50 AM UTC-7, g.na...@gmail.com wrote:
> Hi
>
> I was wondering if there is any way to create my own bell shape function. I want a function which have a bell shaped but it's pick is not at zero (y=0). I need it to start from zero and stay zero for few points e.g.20 and then starts going up (e.g. pick y=5) and then coming down to zero and stay zero for few points again. Does anyone can help with this?

exp(-(y-5)^2) ?
Re: Help - generate bell shaped function [message #90245 is a reply to message #90242] Fri, 13 February 2015 08:10 Go to previous messageGo to next message
g.nacarts is currently offline  g.nacarts
Messages: 148
Registered: November 2013
Senior Member
the peak of that function it's at 1 (i.e. y=1). I need it to be higher like 5 or 6
Re: Help - generate bell shaped function [message #90246 is a reply to message #90245] Fri, 13 February 2015 08:16 Go to previous messageGo to next message
Matthew Argall is currently offline  Matthew Argall
Messages: 286
Registered: October 2011
Senior Member
On Friday, February 13, 2015 at 11:10:58 AM UTC-5, g.na...@gmail.com wrote:
> the peak of that function it's at 1 (i.e. y=1). I need it to be higher like 5 or 6

http://en.wikipedia.org/wiki/Gaussian_function

Play with the values of a, b, and c to see how the function behaves.
Re: Help - generate bell shaped function [message #90247 is a reply to message #90245] Fri, 13 February 2015 09:10 Go to previous messageGo to next message
chris_torrence@NOSPAM is currently offline  chris_torrence@NOSPAM
Messages: 528
Registered: March 2007
Senior Member
On Friday, February 13, 2015 at 9:10:58 AM UTC-7, g.na...@gmail.com wrote:
> the peak of that function it's at 1 (i.e. y=1). I need it to be higher like 5 or 6

Ah, "peak", not "pick"... Try multiplying by 5?
-C
Re: Help - generate bell shaped function [message #90249 is a reply to message #90247] Sat, 14 February 2015 05:19 Go to previous messageGo to next message
g.nacarts is currently offline  g.nacarts
Messages: 148
Registered: November 2013
Senior Member
On Friday, 13 February 2015 19:10:20 UTC+2, Chris Torrence wrote:
> On Friday, February 13, 2015 at 9:10:58 AM UTC-7, g.na...@gmail.com wrote:
>> the peak of that function it's at 1 (i.e. y=1). I need it to be higher like 5 or 6
>
> Ah, "peak", not "pick"... Try multiplying by 5?
> -C

yeah, it works like this. There is any way to make make it zero only in the one side and very close to zero (but not zero) in the other? or it's too difficult? :)
Re: Help - generate bell shaped function [message #90260 is a reply to message #90249] Sun, 15 February 2015 08:29 Go to previous message
chris_torrence@NOSPAM is currently offline  chris_torrence@NOSPAM
Messages: 528
Registered: March 2007
Senior Member
On Saturday, February 14, 2015 at 6:19:23 AM UTC-7, g.na...@gmail.com wrote:
> On Friday, 13 February 2015 19:10:20 UTC+2, Chris Torrence wrote:
>> On Friday, February 13, 2015 at 9:10:58 AM UTC-7, g.na...@gmail.com wrote:
>>> the peak of that function it's at 1 (i.e. y=1). I need it to be higher like 5 or 6
>>
>> Ah, "peak", not "pick"... Try multiplying by 5?
>> -C
>
> yeah, it works like this. There is any way to make make it zero only in the one side and very close to zero (but not zero) in the other? or it's too difficult? :)

Hi, yes, there is an easy way to do this. However, I suggest that you read the IDL online help, and play around with your equation. It's better to learn how to do these things yourself, instead of relying on the newsgroup. "Give a man a fish..."
Cheers,
Chris
  Switch to threaded view of this topic Create a new topic Submit Reply
Previous Topic: TNMIN from mpfit library
Next Topic: Bridge Logging = OFF not working using the Java Bridge

-=] Back to Top [=-
[ Syndicate this forum (XML) ] [ RSS ] [ PDF ]

Current Time: Wed Oct 08 13:32:37 PDT 2025

Total time taken to generate the page: 0.00410 seconds