Logo video2dn
  • Сохранить видео с ютуба
  • Категории
    • Музыка
    • Кино и Анимация
    • Автомобили
    • Животные
    • Спорт
    • Путешествия
    • Игры
    • Люди и Блоги
    • Юмор
    • Развлечения
    • Новости и Политика
    • Howto и Стиль
    • Diy своими руками
    • Образование
    • Наука и Технологии
    • Некоммерческие Организации
  • О сайте

Скачать или смотреть Calculating Pi using Python - Gauss-Legendre and Monte Carlo methods -

  • NCOT Technology
  • 2024-03-13
  • 905
Calculating Pi using Python - Gauss-Legendre and Monte Carlo methods -
pidaypi daypi_daypie day
  • ok logo

Скачать Calculating Pi using Python - Gauss-Legendre and Monte Carlo methods - бесплатно в качестве 4к (2к / 1080p)

У нас вы можете скачать бесплатно Calculating Pi using Python - Gauss-Legendre and Monte Carlo methods - или посмотреть видео с ютуба в максимальном доступном качестве.

Для скачивания выберите вариант из формы ниже:

  • Информация по загрузке:

Cкачать музыку Calculating Pi using Python - Gauss-Legendre and Monte Carlo methods - бесплатно в формате MP3:

Если иконки загрузки не отобразились, ПОЖАЛУЙСТА, НАЖМИТЕ ЗДЕСЬ или обновите страницу
Если у вас возникли трудности с загрузкой, пожалуйста, свяжитесь с нами по контактам, указанным в нижней части страницы.
Спасибо за использование сервиса video2dn.com

Описание к видео Calculating Pi using Python - Gauss-Legendre and Monte Carlo methods -

Let's celebrate #piday in this appropriately short video by writing some #python programs to calculate Pi.

The first method uses something called the Gauss-Legendre method. It works by iteratively refining an approximation of Pi, generating the answer digit by digit.

When writing code to calculate Pi we run into issues trying to store the calculated value. A floating point or double precision float will only store so many bits. It's like fractal zoom programs where there is a maximum depth due to the computer being unable to store the values being used.

Generating Pi digit by digit seems to get around this problem for the most part. Although I'm sure the intermediate values stored in the variables will eventually overflow.

The second way uses a statistical method that you've unknowingly seen if you've ever used Blender. Based on the Monte Carlo statistical methods, there is a way to calculate Pi by simply drawing a circle inside a square and randomly filling it with points.

Dividing the number of points inside the circle by the number of points plotted, and multiplying the result by four gives an approximation of Pi.

Coding this is quite easy because it doesn't need to be done visually. Working out whether a point is inside a circle is a simple piece of maths.

Interestingly if we draw all the points on the screen and colour them, the result draws an arc.

But since Pi is an irrational number, we could just round it down to 3 and use that. It's probably close enough. Although saying this near mathematicians makes them go all irrational too.

Happy Pi day!

Links:
Web - https://ncot.uk
Gauss-legendre python code - https://gist.github.com/ncot-tech/4b1...
Monte-Carlo method for calculating pi - https://gist.github.com/ncot-tech/2f2...

Credits:
Raspberry Pi Pico 3D Model - https://www.blendswap.com/blend/27180

Комментарии

Информация по комментариям в разработке

Похожие видео

  • О нас
  • Контакты
  • Отказ от ответственности - Disclaimer
  • Условия использования сайта - TOS
  • Политика конфиденциальности

video2dn Copyright © 2023 - 2025

Контакты для правообладателей [email protected]