FUNCTION
Evaluates the normal probability density function.
Interface
#include <codecogs/statistics/distributions/continuous/normal/pdf.h>
using namespace Statistics::Distributions::Continuous::Normal;
This function evaluates the normal probability density function.
\graph x=-4:4 m=0 s=1 "Standard Normal Distribution"
Example 1
#include <iostream>
#include <codecogs/statistics/distributions/continuous/normal/pdf.h>
int main()
{
std::cout << "normal PDF (2.31, 2, 5) = ";
std::cout << Stats::Dists::Continuous::Normal::PDF(2.31, 2, 5) << std::endl;
return 0;
}Output:
normal PDF (2.31, 2, 5) = 0.0796352Parameters
x
the value at which to evaluate the function
m
the mean of the distribution
s
the standard deviation of the distribution
Interactive Calculator
x
m
s
Result
Computing…
Set a range above first to export a graph.
This function's source code is only visible to registered users — documentation and the calculator above are free to use either way. Sign in to see it.