« first day (998 days earlier)      last day (226 days later) » 

12:13 AM
@NathanMerrill That's mind-blowing.
 
1:08 AM
@flawr That was neat. I had no idea the Voyager spacecraft had so much redundancy.
 
 
11 hours later…
12:31 PM
Another Connect Four clue (easy, but fun):
New Year's Day = 1
Valentine's Day = 7
Christmas Day = 2.08333
 
1:10 PM
@NathanMerrill What's a connect four clue? What are we trying to solve?
 
Connect Four is the name of the game show
The question is: What is the meaning behind these clues?
There's something the connects the above 3 clues
(There's s 4th clue, but I think it's solvable with 3)
 
I understand the numbers, does that mean I solved it? Or do I have to guess what the fourth clue is?
Halloween = 3.1
 
there is a separate puzzle where you have to guess the 4th clue, but the one you gave works :)
 
2:06 PM
The numbers are all wrong. They should be 1, 0.1428..., and 0.48. ;)
 
2:52 PM
Chat Mini Puzzle: given a set of points (x, y), devise an O(n) algorithm that spits out a new point that is guaranteed not to be any of the others.
 
@El'endiaStarman This can even be done in O(log n) (assuming n was the size of the set). Finding the minimum of the set is O(log n), so we find the minimum and subtract 1 from both entries.
 
3:15 PM
How is finding the minimum O(log n)?
 
Uh you just follow the left branch down all the way
max is also O(log n)
Haskell's implementation does this.
 
Ah, you're assuming more structure than I'm giving you.
 
@El'endiaStarman are x and y real?
 
@flawr Yes. (Or integer.)
 
well you could do (sum(abs(x_i))+1, 0)
this point has certainly no x-coordinate in common with the rest of the points
 
3:24 PM
@El'endiaStarman How so? I mean there are other ways to represent sets, but all of the ones I can think of have a O(log n) minimum function.
 
@SriotchilismO'Zaic A flat list?
 
That's O(1).
Just the first element
 
I didn't say it was sorted.
 
Ok, well this is a particularly bad way to represent sets, but it does kick the order notation up to O(n)
 
Isn't O(n) optimal in the sense that you need to even look at each element at least once?
 
3:26 PM
For certain data structures
 
So how else would you represent a set of real pairs?
 
I mean, for certain data structures, it can be O(1). A sorted list of pairs
 
Aren't red-black-trees common for sets I think?
Or maybe that's maps that I'm thinking of
 
Yep
In computer science, a self-balancing (or height-balanced) binary search tree is any node-based binary search tree that automatically keeps its height (maximal number of levels below the root) small in the face of arbitrary item insertions and deletions.These structures provide efficient implementations for mutable ordered lists, and can be used for other abstract data structures such as associative arrays, priority queues and sets. The red–black tree, which is a type of self-balancing binary search tree, was called symmetric binary B-tree and was renamed but can still be confused with the generic...
 
but then you implicitly assume an ordering
 
3:29 PM
It's easy to come up with an ordering of pairs of reals.
 
@flawr The ordering can be arbitrary, it is just for internal use.
 
Ah, yes. std::set is indeed a red-black tree
 
I think Haskells is red black as well.
 
Python sets are hashtables
 
3:31 PM
Oh yeah, I forgot about Hashtables, because they are so bad. This would also be O(n) on hashtables.
 
@NathanMerrill I thought it would already be hard to determine whether two reals are distinct:)
 
@flawr You could argue that a "set" is an abstract data structure, so it has no time-complexity. A (hashtable|heap|array|red-black-tree...) are all "real" data structures, so they each have time-complexities
 
@SriotchilismO'Zaic I'd argue that hashing is a better implementation, because the average lookup time is O(1), and lookups are more important
 
@El'endiaStarman VTC unclear what you're asking=P
 
I prefer a hash set vs a red/black set pretty much any day. There are reasons to use red/black but for typical use, I find that lookup speed is far more important
 
3:35 PM
@NathanMerrill I was just now thinking along those lines. It's super convenient for Python to include a built-in set implementation, and the default should be a good fit for the most common use-cases.
 
@NathanMerrill Average lookup is not really O(1), it only is with a bunch of assumptions. Lookup is more important for maps, than for sets, sets.
 
@flawr :(
 
@SriotchilismO'Zaic Isn't the definition of "Average" make a bunch of assumptions?
 
It seems now some are talking about a mathematical algorithm while others are talking about an implementation on a computer:)
 
Like, when we talk about average use cases, we're talking about normal use cases, which makes assumptions.
 
3:36 PM
@NathanMerrill You need additional assumptions like ideal hash functions, which are not mathematically possible
 
And assumptions about distributions of the input.
 
Even "un-ideal" hash functions are going to have very few collisions
 
@SriotchilismO'Zaic But "good enough" works in O(1) on average.
 
I guess depending on the resulting length of the hash function
 
That's the purpose of making averages: You consider typical use cases.
 
3:38 PM
I wanna see an o(1) :D
 
@DJMcMayhem It's not really possible to talk about the asymptotic complexity of actual hash sets since they are limited in size. It is better to just say "lookup is fast"
The more important point is that for sets, insertion and deletion are actually more important operations than lookup
 
@SriotchilismO'Zaic this is fair :)
 
@SriotchilismO'Zaic I would disagree with that. It entirely depends on what you're using the set for
 
Yes, this is an entirely subjective argument
But I do believe that lookup is less useful.
Also for me an important fact is that hash sets are not a persistent data structure unlike rb trees.
 
CMC: Given a finite unsorted list of 2d points, find a point whose distance to its nearest neighbour is maximal in the least possible complexity.
 
3:45 PM
Find the point? i.e. does the point have to be in the list?
 
yes it has to be in the list, but it is not necessarily unique
 
@flawr If it's not unique, wouldn't it's nearest neighbor be the other point with the same coordinates?
 
I think unique in distance to nearest neighbor is meant?
 
Oh wait I see. The maximal distance doesn't necessarily have to be unique
ninja'd
 
Take a regular triangle: any of the three points would be valid as output
 
3:51 PM
Or any regular polygon (or even a line segment)
 
Regular polygons don't work though?
 
Why not?
 
Oh, regular in the sense of all sides being the same length, not in the sense of ordinary (like flawr's usage).
 
I think flawr also meant the same sense?
 
(and that all points are on the same circle)
 
3:53 PM
Why would you say "regular triangle" and not "equilateral triangle"?
 
shorter? :P
 
I didn't remember the word "equilateral", and in polygons they mean the same thing:) regular implies equilateral
 
fiiiiine :P
 
Wait, can the word "equilateral" apply to other polygons as well? I've only heard it in reference to triangles before
 
But I agree, regular is a little bit overused in maths, and it doesn't help that it is a (another) word stolen from regular everyday language
 
3:56 PM
@DJMcMayhem Technically it can, since "equilateral" literally means "same length".
 
@DJMcMayhem apparently yes: wikpedia
There are actually quite a few characterizations of quadrilaterals that I was not aware of: en.wikipedia.org/wiki/Template:Polygons
 
4:12 PM
@flawr Woah, same.
 
4:28 PM
@flawr apparently quadrilateral includes edges that are not straight?
that's odd
 
4:40 PM
@NathanMerrill Are you referring to Lambert and Saccheri quadrilaterals?
 
They are straight edged.
They are just embedded in Hyperbolic space.
 
ah ok
 
Well, really, the point of those is to investigate the Parallel Postulate.
 
I guess I should say the curvy looking ones are embedded in a non-euclidean space.
 
4:44 PM
So if you could find a quadrilateral where the sides weren't straight or where three right angles doesn't imply a fourth right angle, then you proved/disproved the Parallel Postulate (depending on your axioms, method of proof, etc).
 
5:17 PM
Ah, so it's essentially a theoretical shape that was proven to not exist (in euclidean space)
 
Basically, yeah.
 
Yes. The parrallel posulate proves they cannot be in euclidean space.
 

« first day (998 days earlier)      last day (226 days later) »