LFD Book Forum  

Go Back   LFD Book Forum > Course Discussions > Online LFD course > Homework 1

Thread Tools Display Modes
Prev Previous Post   Next Post Next
Old 01-11-2013, 04:37 PM
gah44 gah44 is offline
Invited Guest
Join Date: Jul 2012
Location: Seattle, WA
Posts: 153
Default Computing Pr(f(x) != g(x))

I am not sure how others compute Pr(f(x) != g(x)).

It isn't so hard to do analytically, but there are a lot of cases to consider, depending on which boundary of the square the lines cross.

I now have one that just does the cases where both lines intersect the top and bottom of the square. By symmetry, the cases that intersect the left and right sides should be the same.

That leaves out the ones where lines intersect top or bottom and side. Those might have smaller area (probability) but maybe not too much smaller.

So far, it is close enough to one of the answers that I will go for that one. The other cases are enough harder to write that I won't try them.
Reply With Quote

Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump

All times are GMT -7. The time now is 08:55 PM.

Powered by vBulletin® Version 3.8.3
Copyright ©2000 - 2021, Jelsoft Enterprises Ltd.
The contents of this forum are to be used ONLY by readers of the Learning From Data book by Yaser S. Abu-Mostafa, Malik Magdon-Ismail, and Hsuan-Tien Lin, and participants in the Learning From Data MOOC by Yaser S. Abu-Mostafa. No part of these contents is to be communicated or made accessible to ANY other person or entity.