[Numpy-discussion] Any interest in a 'heaviside' ufunc?
Daπid
davidmenhur at gmail.com
Wed Feb 4 05:45:25 EST 2015
On 4 February 2015 at 11:05, Sturla Molden <sturla.molden at gmail.com> wrote:
> On 04/02/15 06:18, Warren Weckesser wrote:
>
>> By "discrete form", do you mean discrete time (i.e. a function defined
>> on the integers)? Then I agree, the discrete time unit step function is
>> defined as
>
> It is the cumulative integral of the delta function, and thus it can
> never obtain the value 0.5. The delta function is defined to have an
> integral of 0 or 1.
>
> Sturla
There are several definitions. Abramowitz and Stegun
(http://people.math.sfu.ca/~cbm/aands/page_1020.htm) assign the value
0.5 at x=0. It can also be defined as:
H(x) = 1/2 * (1 + sign(x))
Where sign(0) = 0, and therefore H(0) = 1/2.
Actually, Heaviside function is better seen as a distribution instead
of a function, and then there is no problem with the value at 0, as
long as it is finite.
More information about the NumPy-Discussion
mailing list