{"nbformat":4,"nbformat_minor":0,"metadata":{"colab":{"provenance":[],"authorship_tag":"ABX9TyMrrT047FPz9oI78AfwCXoF"},"kernelspec":{"name":"python3","display_name":"Python 3"},"language_info":{"name":"python"}},"cells":[{"cell_type":"code","execution_count":1,"metadata":{"id":"qSnZRAteUHeI","executionInfo":{"status":"ok","timestamp":1717751287213,"user_tz":-330,"elapsed":539,"user":{"displayName":"Amit Sachan","userId":"17076119069500437280"}}},"outputs":[],"source":["import scipy.stats as stats\n","import matplotlib.pyplot as plt\n","import math"]},{"cell_type":"code","source":["λ=250/60\n","ansa=stats.poisson.pmf(0,λ)\n","print(\"one minute mean             \",λ)\n","print(\"answer of part a              \",ansa)"],"metadata":{"colab":{"base_uri":"https://localhost:8080/"},"id":"7ZcHZG83UYYa","executionInfo":{"status":"ok","timestamp":1717751287214,"user_tz":-330,"elapsed":32,"user":{"displayName":"Amit Sachan","userId":"17076119069500437280"}},"outputId":"9806a632-a2d6-4e96-8f8e-32501dd183f9"},"execution_count":2,"outputs":[{"output_type":"stream","name":"stdout","text":["one minute mean              4.166666666666667\n","answer of part a               0.015503853599009314\n"]}]},{"cell_type":"code","source":["λb=λ*2\n","ansb=stats.poisson.pmf(10,λb)\n","print(\"two minute mean        \",λb)\n","print(\"answer of part b       \",ansb)"],"metadata":{"colab":{"base_uri":"https://localhost:8080/"},"id":"zvMblQM0UYck","executionInfo":{"status":"ok","timestamp":1717751287214,"user_tz":-330,"elapsed":24,"user":{"displayName":"Amit Sachan","userId":"17076119069500437280"}},"outputId":"74a7e728-9497-4141-aac0-fab112b86ca4"},"execution_count":3,"outputs":[{"output_type":"stream","name":"stdout","text":["two minute mean         8.333333333333334\n","answer of part b        0.1069803031251672\n"]}]},{"cell_type":"code","source":["λc=λ*3\n","m, v, s, k = stats.poisson.stats(λc, moments='mvsk')\n","print(\"three minute mean             \",m)"],"metadata":{"colab":{"base_uri":"https://localhost:8080/"},"id":"tNUMEMdCUYfj","executionInfo":{"status":"ok","timestamp":1717751287214,"user_tz":-330,"elapsed":19,"user":{"displayName":"Amit Sachan","userId":"17076119069500437280"}},"outputId":"f722f4fa-d23b-44e3-df53-674952dd1043"},"execution_count":4,"outputs":[{"output_type":"stream","name":"stdout","text":["three minute mean              12.5\n"]}]},{"cell_type":"code","source":["ansd=stats.poisson.pmf(10,λc)\n","print(\"three minute mean\",λc)\n","print(\"answer of part d \",ansd)"],"metadata":{"colab":{"base_uri":"https://localhost:8080/"},"id":"yHnNk_JJUYin","executionInfo":{"status":"ok","timestamp":1717751287215,"user_tz":-330,"elapsed":17,"user":{"displayName":"Amit Sachan","userId":"17076119069500437280"}},"outputId":"d2dbd660-18ed-4369-aace-10cc96067377"},"execution_count":5,"outputs":[{"output_type":"stream","name":"stdout","text":["three minute mean 12.5\n","answer of part d  0.09564363500108167\n"]}]}]}