The simplest picture one can form about the creation of an emperical science is along the lines of an inductive method. Individual facts are selected and grouped together so that the laws that connect them become apparent…However, the big advances in scientific knowledge originated in this way only to a small degree…The truly great advances in our understanding of nature originated in a way almost diametrically opposed to induction. The intuitive grasp of the essentials of a large complex of fatcs leads the scientist to the postulation of a hypothetical basic law or laws. From these laws, he derives his conclusions.

-Albert Einstein

This is my personal website, where I blog about stuff involving programming and deep learning, my personal insights on the world, and my life experiences.

Check out my recent blog posts

A simple two-layered neural network from scratch in python: Part I, forward-propagation and the computational graph

Neural networks may seem mysterious to most people, and thus theirs capabilities are often overestimated. However, in truth, any neural network is just a combination of elementary mathematical operations and in turn, a computational graph. In this post, I am going to show you to how to build a simple neural network with two layers for a classification problem and the math behind it. Part I here is about forward-propagation and the computational graph.

Read More

How many cards until an ace appears? A Monte Carlo Approach

Today we are going to look at Problem 40 from the book 50 Challenging Problems in Probability by Frederick Mosteller. However, instead of solving it analytically, we are going to use the Monte Carlo method (random sampling) to solve it.

The problem goes like this:

Shuffle an ordinary deck of 52 playing cards containing four aces. Then turn up cards from the top until the first ace appears. On the average, how many cards are required to produce the first ace?

cards

Read More

Like what you see? Click here for more posts...