The Monty Hall problem is to me one of the most fascinating probability problem (for it's simpleness and unintuitive results) that got my mind blown since I learned about it in high school.
One day in high school, in my Math class, the teacher told us about that famous problem.
Monty Hall was an old and popular TV show in the states were you had to choose a door to open from three different ones. Behind one of them was a car, behind the two others were goats. Obviously, the goal of the game was to win the car (except if you were really into goats, but then I guess you could have bought a lot of those with a car).
Anyway, the tricky part was that when you made a choice, the host asked you to wait before opening it and would open another door, revealing a goat. Then he would give you the opportunity to waive your initial choice and swap door one last time.
Here lies the probability problem. Do you think you would have more chance of winning if you changed your choice?
My math teacher said yes, and I could not believe that, I remember loudly objecting, telling the teacher it was not possible, that it was not logical. I declined what seemed grotesque at the time, I refused to acknowledge such an unintuitive result, such a simple thing, my brain could do the calculation easily so why would you tell me I was wrong on such a trivial thing.
But yes, I was wrong. I knew I was wrong. I was upset at my own mind. I didn't understand how I could be so convinced that changing choice wouldn't change my chances of winning the car. The problem was simple, so simple. And yet my mind couldn't make its way around it.
After many years of training my brain to think differently about probabilities, I can know see how this problem works. 7 years after my first introduction to this problem, I can now grasp a part of it. I understand it, I know the probabilities enrolled in the resolution of this problem, I've learned them at uni and I made the effort to think about that problem quite a lot during those last years. I actually often ask that problem to my friends, to blow their mind.
But still, 7 years after being introduced to that problem, I still have troubles finding its probabilities "natural". My brain still cannot process the fact that it HAS to work that way, that the world is turning in that direction and no others.
I hope I didn't send you to sleep with this. If you want to know more about the mathematician who published this result and got insulted by numerous math PHD for being wrong, you can take a stroll on the wikipedia page.
My technique to wire my brain on the right path? Thinking about a hundred doors, 1 car, 99 goats. I open one door, the host closes 98 others.
It feels easier to process when told this way, but there is still a part of me, somewhere, that tells me it wouldn't change a thing. Even with 98 doors opened. What is wrong with my brain?
If you still don't believe me, there is a short and visually clear explanation here.
PS: this is one of my go to when I want to be amazed at how unintuitive or how little we know about how things work. If you like that kind of thing, you can also check the twin paradox or the biography of Milton H. Erickson.
The last things we studied in Arithmetic are the Reed-Solomon codes. It's a type of code you use to, not encrypt your information, but create redundant information in your final code. So when you read your code, if there are errors or missing parts, you can still decode it. It's not perfectly redundant like dog's ADN is. The redundant code is changed in a certain way so you can guess what the missing parts are.
A few days ago I was on the road to La Fête des Lumières (in Lyon) with 4 germans I met in Bordeaux. The driver had an old CD with a few mainstream and german songs on it that he wanted to play, problem, the CD was damaged, solution? None. Didn't need a solution. The CD still played, although sometimes it was indeed jumping, most of the time it was playing correctly. How is that?
Well, the information burned on the CD is coded thanks to Reed-Solomon's algorithm so that you can still guess what was burned on it through particular redundant code. This redundant code is (and I'm taking a guess here) what is used when your computer asks you "do you want to check if there was no error?" right after burning your CD.
more info on wikipedia
Ahhhh, what is P, NP, NP-Complete and NP-hard. Found this quick explanation. Still reading on the subject. I feel like It might take me a lot of time until I can be able to explain that easily to someone who has no idea what it is.
true mastery of a subject is achieved when you can explain it simply
Here's a stackoverflow pretty simple explanation
A decision problem is in P if there is a known polynomial-time algorithm to get that answer. A decision problem is in NP if there is a known polynomial-time algorithm for a non-deterministic machine to get the answer.
In my quest to better support to learn, I've again stumbled into a complicated, badly explained and unclear paper from my prof about discreet and time-memoryless channels.
Although it might be just me, but when I don't understand something from one source I like to diversify, and papers from Polytechnique (in french) are always a good snack :
Learning about Shannon's theorem in class I got curious and googled the guy.
One extract I found interesting in his wikipedia biography :
Shannon and his wife Betty also used to go on weekends to Las Vegas with M.I.T. mathematician Ed Thorp, and made very successful forays in blackjack using game theory type methods co-developed with fellow Bell Labs associate, physicist John L. Kelly Jr. based on principles of information theory. They made a fortune, as detailed in the book Fortune's Formula by William Poundstone and corroborated by the writings of Elwyn Berlekamp, Kelly's research assistant in 1960 and 1962. Shannon and Thorp also applied the same theory, later known as the Kelly criterion, to the stock market with even better results. Claude Shannon's card count techniques were explained in Bringing Down the House, the best-selling book published in 2003 about the MIT Blackjack Team by Ben Mezrich. In 2008, the book was adapted into a drama film titled 21.
Apart for inventing most of cryptography concepts, and doing chess IA, he also made a fortune from gambling and playing with stocks. Interesting.
My portfolio/vitrine/online resume... call it what you want, which is available on davidwong.fr, is now available on david.wong.emi.u-bordeaux1.fr as well. I thought that was pretty cool to have a bordeaux1.fr url. I think I can also have a univ-lyon1.fr since my account is still active but I can't be bothered looking at where it is.
Anyway, just this small piece of news in the ocean of bitcoin/litecoin news I've been posting here. Exams are coming soon and I should blog more about them than cryptocoins but yeah...
posted November 2013
So after a long night staying up and coding I finally handed in my project including my report in LaTeX.
I'm not really proud of what I did, I felt like I could have done much better if given more time (okay I slacked and I had enough time).
BUT, as I already said earlier, I've accomplished a lot and even though I'm done with this project I still kinda want to keep working on it.
Things that I've learned doing this class :
- C is awful. But now I know the basics. I wish we had one more project to code in C to really get it though.
- Makefile? Headers? I still don't really get the structure of a C project (and I'm ashamed).
- I know Linux! Okay I don't know Linux that much, but I'm getting really causy there. I installed debian on a VM and I'm considering setting up a dual boot on my laptop now.
- Emacs emacs! I was postponing learning it because I was afraid, and just forced myself to use it for this project and goshh am I fast when I use it. When I go back to Sublime Text I just want to C-M-F, C-A, C-K, C-Y...
- LaTeX! As a Math major I've always been ashamed not knowing it. Now that I got a taste of it I'm wondering if I should use it to write my book on.
- Svn and Git. I'm not a stranger anymore! And I use them for all my websites as well now :)
I think that's it, but I feel like I've learned a lot and I wished this course was a year thing rather than a semester thing.
The course is not over yet though and next week we'll dive into java for... a quick swim since it will be our last week.
I feel like I've been doing a hackaton these past few days trying to finish my sudoku solver. I had to hand it in 2 hours ago but still haven't finished... I really hope this won't affect my grade too much.
I've been learning a lot of Emacs, C, using gcov, gprof, LaTeX... I'm so confused right now and my code has became so dense that it's hard for me to debug it.
Yesterday, suddenly, I found something really stupid in my sudoku grid generation that I couldn't fix. A day after, I found the solution, randomly, fixing it created a huge load of other issues. I have been re-inspecting my whole code all day long and I'm stressed by this deadline that I already passed.
Gosh that is a hard course.
And... because of this, I missed a day writing on my new application. I was on a 9-day strike :(
I'm studying automata, it's sort of a "logical" subject that reminds me of studying mathematics. It looks cool, it only asks your brain to think, not to memorize, and you don't really know what's the real use of it.
If you want to take a peak at what I'm studying, you can find a similar course on Coursera given by Jeff Ullman from Stanford (yes, obviously I should have moved to the US and attend Stanford).
Well, someone nicely asked what I was thinking on Stackoverflow, and someone else nicely answered.
posted November 2013
I have an exam of Réseaux (Network) tomorrow and the slides of my prof are... how could I say this... not really clear. We have practical applications classes but they were... organized in the worst possible way. The subject did seem interesting at first but I felt like I learned nothing. Hopefully for the past few weeks I've been using the wonderful online course An Introduction to Computer Networks given by Nick McKeown and Philip Levis both very competent profs from Stanford. It seems like I should have gone there for my master of Cryptography :) Anyway, I'm doing with what I have here and I feel blessed studying Cryptography right when free online courses started becoming a thing.
The course is available here.
My Programmmation class first part is about coding a sudoku solver. We have to do everything in english, we have to commit with svn, we have to write a final report with LaTeX.
Every week we're given some vague guidelines and we have to dive deep into C to first, understand what we have to do, and secondly, find solutions in a language we've never really played with before. We have to turn in what we did every week, if our code doesn't compile it's a zero, if it does compile it goes through a multitude of tests that quickly decrease your grade (out of 20). Let's just say I spent many nights and early mornings coding and I started the first week with a 2/20.
It felt like a crash course, it felt unfair at times, but holy cow did I learn some C in a really short amount of time. Props to my professor for that, and I wish I had more courses like that. I might not get the best grade out of this course but I sure learn the most things there.
I've also committed everything I've done on a public git repo so everyone can see how it looks like here :
You can compile with make, learn how to use with ./sudoku -h
It can read sudokus of different sizes from 1x1 to 64x64 as long as it is presented like this :
I have at the moment 5 classes which are all taught in french (I guess because there are not enough foreigners this year), but some of them use english for their slides.
#this is a comment
5 3 _ _ 7 _ _ _ _
6 _ _ 1 9 5 _ _ _
_ 9 8 _ _ _ _ 6 _
8 _ _ _ 6 _ _ _ 3
4 _ _ 8 _ 3 _ _ 1
7 _ _ _ 2 _ _ _ 6
_ 6 _ _ _ _ 2 8 _
_ _ _ 4 1 9 _ _ 5
_ _ _ _ 8 _ _ 7 9
Nothing really new to me, some people coming from the same bachelor as I (mathematics) have difficulties getting to know Linux and programming as a whole for the first time. I'm used to coding so I'm pretty confident (I shouldn't relax too much though). We started on a fast-course on C, GCC, Emacs, SVN... and will move on later with Java.
It's taught by Emmanuel Fleury who is a very chill professor, good vibe, very easy to talk to. And the best part is that everything he talks about is online here so if you're interested in the course I'm taking you can have a look there.
PS: we're learning a bit of LaTeX AND will have to submit final reports in LaTeX. This is great as I have sought a good occasion to learn it for a while.
PS2: I'm using LearnXinYminutes.com to get back into C (haven't coded in C for more than 4 years). It's a great website and I recommend it to you if you want to learn something about any language and already have knowledge in programming.
Théorie de l'information
Taught by the head of the Cryptology Master, Gilles Zemor, the course seems like an introduction to some of the concepts around Cryptography. Our first classes were about Entropy (which I talked about a bit in the previous post) and easy notions of probability. Here are the professor's notes about the course.
The only "real" Math course we have, and I'm a bit surprised since this is a "Mathematics" Master". It's essentially about rings, it's about stuff I already learned. Nothing really captivating at the moment.
Automates et Complexité
This is one of the most intriguing course, people coming from an IT bachelor seem to have no problem with it. I don't really understand the point of learning this but I like it, it's a lot like Regular Expressions and is about logic more than learning concepts by heart. As a programmer it just seems like funny games to me :) (it might get more difficult very quickly).
Note : it's taught by Anca Muscholl.
The only course I had to choose, but we didn't have much choice since they removed half of the available courses including the one I wanted to take (Probability). The course is taught by... it's a rapid introduction about network concept. I'm not really into it, it speaks too briefly about many things, some are interesting, some are not. I was supposed to have an application class but apparently our professor fell asleep on his way (he's narcoleptic).
Overall I was surprised by the absence of real "cryptology courses". But the professors told us they would come very quickly in the second semester, so nothing to worry about.
Hey guys, I'm David Wong, a 24 years old french dude who's going to start a Master of Cryptology in the university of Bordeaux 1.
Cryptology (or as Americans like to call it: Cryptography, because we all know they don't care about etymology) is the study of the techniques for secure communications (thanks Wikipedia!), from withdrawing money with a fake credit card to establishing a safe phone conversation between two government officials, it can mean a lot of things... I still have no clue what my future job will be, that's why I had the idea of making this small blog where I could post about my ventures into this new world and, hopefully, being able to take a step back and see what I did, what I liked, what happened in two years of Master (and maybe more).
I've already took Cryptography I given by Dan Boneh from Stanford and I must say I really enjoyed going through his course. Might be one of the most interesting and eloquent teacher I had in my life, and I have never met him. Had a few back and forth mail exchanges with him but sadly, there was no collaboration between our universities. California I'll see you later in life I guess.
I'll also post some thoughts about the new city I'll be moving to : Bordeaux. This is for at least 2 years, or less if I change my mind. Anyway, this is going to be exciting!