C Library Functions  - unipdf (3)

NAME

unipdf(3f) - [M_datapac:PROBABILITY_DENSITY] trivially compute the Uniform probability density function

CONTENTS

Synopsis
Description
Input Arguments
Output Arguments
Examples
Author
Maintainer
License
References

SYNOPSIS

SUBROUTINE UNIPDF(X,Pdf)

       REAL(kind=wp),intent(in)  :: X
       REAL(kind=wp),intent(out) :: Pdf

DESCRIPTION

UNIPDF(3f) computes the probability density function value for the uniform (rectangular) distribution on the unit interval (0,1).

This distribution has mean = 0.5 and standard deviation = sqrt(1/12) = 0.28867513. this distribution has the probability density function

       f(X) = 1

That is, trivially no matter what the input the output is 1.

INPUT ARGUMENTS

X The REAL value at which the probability density function is to be evaluated. X should be between 0 and 1, inclusively.

OUTPUT ARGUMENTS

PDF The REAL probability density function value.

EXAMPLES

Sample program:

   program demo_unipdf
   !@(#) line plotter graph of probability density function
   use M_datapac, only : unipdf, label
   implicit none
   real,allocatable  :: x(:), y(:)
   integer           :: i
      call label(’unipdf’)
      x=[(real(i)/10.0,i=0,10,1)]
      if(allocated(y))deallocate(y)
      allocate(y(size(x)))
      do i=1,size(x)
         call unipdf( x(i), y(i) )
      enddo
      write(*,*)y
   end program demo_unipdf

Results:

      1.00  1.000000  1.000000  1.000000  1.000000
      1.00  1.000000  1.000000  1.000000  1.000000
      1.00

AUTHOR

The original DATAPAC library was written by James Filliben of the Statistical Engineering Division, National Institute of Standards and Technology.

MAINTAINER

John Urban, 2022.05.31

LICENSE

CC0-1.0

REFERENCES

o Johnson and Kotz, Continuous Univariate Distributions--2, 1970, pages 57-74.


Nemo Release 3.1 unipdf (3) July 22, 2023
Generated by manServer 1.08 from 22994248-7422-4fbd-b1bb-201b7db55afb using man macros.