Deprecated: Methods with the same name as their class will not be constructors in a future version of PHP; plgContentJComments has a deprecated constructor in /var/www/astarmathsandphysics/plugins/content/jcomments/jcomments.php on line 25 Call Stack: 0.0001 360992 1. {main}() /var/www/astarmathsandphysics/index.php:0 0.0730 1209832 2. Joomla\CMS\Application\SiteApplication->execute() /var/www/astarmathsandphysics/index.php:49 0.0730 1209832 3. Joomla\CMS\Application\SiteApplication->doExecute() /var/www/astarmathsandphysics/libraries/src/Application/CMSApplication.php:267 0.1422 4162672 4. Joomla\CMS\Application\SiteApplication->dispatch() /var/www/astarmathsandphysics/libraries/src/Application/SiteApplication.php:233 0.1435 4190528 5. Joomla\CMS\Component\ComponentHelper::renderComponent() /var/www/astarmathsandphysics/libraries/src/Application/SiteApplication.php:194 0.1442 4208240 6. Joomla\CMS\Component\ComponentHelper::executeComponent() /var/www/astarmathsandphysics/libraries/src/Component/ComponentHelper.php:356 0.1442 4225248 7. require_once('/var/www/astarmathsandphysics/components/com_content/content.php') /var/www/astarmathsandphysics/libraries/src/Component/ComponentHelper.php:381 0.1450 4232984 8. ContentController->execute() /var/www/astarmathsandphysics/components/com_content/content.php:42 0.1450 4232984 9. ContentController->display() /var/www/astarmathsandphysics/libraries/src/MVC/Controller/BaseController.php:710 0.1901 4873488 10. ContentController->display() /var/www/astarmathsandphysics/components/com_content/controller.php:113 0.1925 4958720 11. Joomla\CMS\Cache\Controller\ViewController->get() /var/www/astarmathsandphysics/libraries/src/MVC/Controller/BaseController.php:663 0.1931 4979648 12. ContentViewArticle->display() /var/www/astarmathsandphysics/libraries/src/Cache/Controller/ViewController.php:102 0.2026 5089272 13. Joomla\CMS\Plugin\PluginHelper::importPlugin() /var/www/astarmathsandphysics/components/com_content/views/article/view.html.php:189 0.2026 5089528 14. Joomla\CMS\Plugin\PluginHelper::import() /var/www/astarmathsandphysics/libraries/src/Plugin/PluginHelper.php:182 Deprecated: Methods with the same name as their class will not be constructors in a future version of PHP; JCommentsACL has a deprecated constructor in /var/www/astarmathsandphysics/components/com_jcomments/classes/acl.php on line 17 Call Stack: 0.0001 360992 1. {main}() /var/www/astarmathsandphysics/index.php:0 0.0730 1209832 2. Joomla\CMS\Application\SiteApplication->execute() /var/www/astarmathsandphysics/index.php:49 0.0730 1209832 3. Joomla\CMS\Application\SiteApplication->doExecute() /var/www/astarmathsandphysics/libraries/src/Application/CMSApplication.php:267 0.1422 4162672 4. Joomla\CMS\Application\SiteApplication->dispatch() /var/www/astarmathsandphysics/libraries/src/Application/SiteApplication.php:233 0.1435 4190528 5. Joomla\CMS\Component\ComponentHelper::renderComponent() /var/www/astarmathsandphysics/libraries/src/Application/SiteApplication.php:194 0.1442 4208240 6. Joomla\CMS\Component\ComponentHelper::executeComponent() /var/www/astarmathsandphysics/libraries/src/Component/ComponentHelper.php:356 0.1442 4225248 7. require_once('/var/www/astarmathsandphysics/components/com_content/content.php') /var/www/astarmathsandphysics/libraries/src/Component/ComponentHelper.php:381 0.1450 4232984 8. ContentController->execute() /var/www/astarmathsandphysics/components/com_content/content.php:42 0.1450 4232984 9. ContentController->display() /var/www/astarmathsandphysics/libraries/src/MVC/Controller/BaseController.php:710 0.1901 4873488 10. ContentController->display() /var/www/astarmathsandphysics/components/com_content/controller.php:113 0.1925 4958720 11. Joomla\CMS\Cache\Controller\ViewController->get() /var/www/astarmathsandphysics/libraries/src/MVC/Controller/BaseController.php:663 0.1931 4979648 12. ContentViewArticle->display() /var/www/astarmathsandphysics/libraries/src/Cache/Controller/ViewController.php:102 0.3266 12943200 13. JEventDispatcher->trigger() /var/www/astarmathsandphysics/components/com_content/views/article/view.html.php:199 0.3268 12943600 14. plgContentJComments->update() /var/www/astarmathsandphysics/libraries/joomla/event/dispatcher.php:160 0.3268 12943600 15. plgContentJComments->onContentAfterDisplay() /var/www/astarmathsandphysics/libraries/joomla/event/event.php:70 0.3270 12951848 16. plgContentJComments->onAfterDisplayContent() /var/www/astarmathsandphysics/plugins/content/jcomments/jcomments.php:339 0.3316 13332120 17. JComments::show() /var/www/astarmathsandphysics/plugins/content/jcomments/jcomments.php:282 0.3322 13365168 18. JCommentsFactory::getACL() /var/www/astarmathsandphysics/components/com_jcomments/jcomments.php:188 0.3322 13365192 19. spl_autoload_call() /var/www/astarmathsandphysics/components/com_jcomments/classes/factory.php:274 0.3323 13365272 20. JLoader::load() /var/www/astarmathsandphysics/components/com_jcomments/classes/factory.php:274

Proof That the Binomial Distribution is a Probability Distribution

In order to be a probability distribution for a random variable, a function must sum or integrate over all the possible values of the random variable to 1.
If a random variable  
\[X\]
  is modelled by the binomial distribution,  
\[X \sim B(n,p)\]
  then  
\[P(X=x) = \frac{n!}{x! (n-x)!} p^x (1-p)^{n-x}\]

The binomial expansion tell us  
\[\begin{equation} \begin{aligned} (a+b)^n &= a^n + n a^{n-1} b + \frac{n(n-1)}{2} a^{n-2} b^2 +...+ \frac{(n-1)n}{2}a^2 b^{n-2} + (n-1) ab^{n-1} + b^n \\ &= \sum_{k=0}^n \frac{n!}{k!(n-k)!} a^k b^{n-k} \end{aligned} \end{equation}\]

Substitute  
\[a=p, b=1-p\]
  then
\[ \sum_{k=0}^n \frac{n!}{k!(n-k)!} p^k (1-p)^{n-k} =(p+1-p)^n =1 \]

Add comment

Security code
Refresh