Search found 2809 matches

by Xenomortis
Sun Jan 08, 2017 12:01 pm UTC
Forum: News & Articles
Topic: In other news... (humorous news items)
Replies: 13564
Views: 1580940

Re: In other news... (humorous news items)

Being within three orders of magnitude is usually considered pretty good by astronomical standards.
by Xenomortis
Tue Jan 03, 2017 11:26 am UTC
Forum: Gaming
Topic: 2016 in review
Replies: 10
Views: 1176

Re: 2016 in review

I can only think of three 2016 releases I've played: Doom 4 (DOOM): It was pretty unstable when I played, but that was shortly after a highly stressful upgrade to Windows 10 which left me with a fairly unstable computer (8 months later, it's still causing problems). The odd blue-screen wouldn't be t...
by Xenomortis
Wed Dec 21, 2016 6:48 pm UTC
Forum: Coding
Topic: Coding: Fleeting Thoughts
Replies: 9546
Views: 1339805

Re: Coding: Fleeting Thoughts

It's not me that cares about types. It's Python!

Code: Select all

>>> arr = [1, 2, 3]
>>> arr[5.0 // 2]
TypeError


Or how about:

Code: Select all

>>> (5.0 // 2) ^ 1
TypeError
by Xenomortis
Wed Dec 21, 2016 4:40 pm UTC
Forum: Coding
Topic: Coding: Fleeting Thoughts
Replies: 9546
Views: 1339805

Re: Coding: Fleeting Thoughts

Code: Select all

>>> 3 // 2
1
>>> 3.0 // 2
1.0

Python, do you really have to be like that? It's so close, but worse than not close.

Trying to maintain compatibility between Python 2.7 and 3 is a pain the arse when you don't have a proper environment for the latter set up.
by Xenomortis
Fri Dec 09, 2016 10:25 am UTC
Forum: News & Articles
Topic: Dinosaur feathers and colours found in amber
Replies: 13
Views: 1351

Re: Dinosaur feathers and colours found in amber

Screw flying cars, I want my pet dino-sparrow.
by Xenomortis
Tue Dec 06, 2016 5:27 pm UTC
Forum: News & Articles
Topic: In other news... (humorous news items)
Replies: 13564
Views: 1580940

Re: In other news... (humorous news items)

CorruptUser wrote:18000 joules is roughly the same amount of energy as one of those fired bullets. That's a lot of energy in your pocket.

About 4 grams of TNT (equivalent).
Or about 2-3 g of Nitroglycerin (~2 mL).
Not much, but enough that you'd want to be careful with your hand. ;)
by Xenomortis
Sun Dec 04, 2016 11:18 am UTC
Forum: Coding
Topic: Coding: Fleeting Thoughts
Replies: 9546
Views: 1339805

Re: Coding: Fleeting Thoughts

To be fair, I will definitely press Ctrl-C after a while.
by Xenomortis
Thu Nov 03, 2016 4:28 pm UTC
Forum: Coding
Topic: Coding: Fleeting Thoughts
Replies: 9546
Views: 1339805

Re: Coding: Fleeting Thoughts

This problem would be so much easier if I could just allocate 200GB of memory. But no, I have to be clever and work out element repetitions and tiling patterns for these arrays that act as axes for some n-dimensional dataset, and filter out points that aren't inside some prism like region. And I tho...
by Xenomortis
Thu Nov 03, 2016 1:15 pm UTC
Forum: News & Articles
Topic: British EU referendum in June [update: Leave wins 52% - 48%, politics ensue]
Replies: 977
Views: 61124

Re: British EU referendum in June [update: Leave wins 52% - 48%, politics ensue]

The party heads can allow conscience votes by MPs at their discretion, right? I don't know how likely/unlikely that is in this case. Sure - suppose a Tory MP's constituency is strongly against a government motion, then Tory whips may not pressure them into voting the party line, particularly if the...
by Xenomortis
Thu Nov 03, 2016 11:43 am UTC
Forum: News & Articles
Topic: British EU referendum in June [update: Leave wins 52% - 48%, politics ensue]
Replies: 977
Views: 61124

Re: British EU referendum in June [update: Leave wins 52% - 48%, politics ensue]

Is it known if the MP vote will be anonymous? I can more easily imagine MPs voting to stay if its not known who voted which way. Divisions (votes) are not anonymous - party whips wouldn't have much power if they were. The process of divisions is somewhat arcane. The Speaker can simply ask everyone ...
by Xenomortis
Tue Nov 01, 2016 2:00 pm UTC
Forum: Coding
Topic: Coding: Fleeting Thoughts
Replies: 9546
Views: 1339805

Re: Coding: Fleeting Thoughts

Subtraction and Division are not associative: "20 o (10 o 2) != (20 o 10) o 2" for both o = - and o = /. Further, if pressed, I'd be inclined to make them left-associative, mirroring how naive calculators work, leaving exponentiation as right-associative. Edit: Use the correct symbol for s...
by Xenomortis
Thu Oct 27, 2016 3:42 pm UTC
Forum: News & Articles
Topic: 2016 US Presidential Election
Replies: 8482
Views: 463226

Re: 2016 US Presidential Election

Trump's really not that bad: he's just a horrible person in general who believes every conspiracy theory about Democrats, has horrible communication skills, zero attention span, does not seem to care or have any knowledge about issues that don't affect him personally (or that he perceives to), and ...
by Xenomortis
Wed Oct 26, 2016 4:31 pm UTC
Forum: Coding
Topic: Coding: Fleeting Thoughts
Replies: 9546
Views: 1339805

Re: Coding: Fleeting Thoughts

30 seconds is nothing. Let me know when you've tried spending hours on obvious-in-hindsight mistakes like that. Oh, I definitely have, but it's usually like some = in an if somewhere, where yeah it's a dumb mistake but the location of the mistake isn't easy to find. (That hasn't happened to me in a...
by Xenomortis
Tue Oct 25, 2016 12:10 pm UTC
Forum: News & Articles
Topic: In other news... (humorous news items)
Replies: 13564
Views: 1580940

Re: In other news... (humorous news items, etc)

The UK's Labour party have been fined over their general election campaign's tombstone.
(They forgot to declare receipts for the infamous tablet when filling in the paperwork).

Not many people live to regret their epitaph.
by Xenomortis
Mon Oct 24, 2016 5:46 pm UTC
Forum: News & Articles
Topic: 2016 US Presidential Election
Replies: 8482
Views: 463226

Re: 2016 US Presidential Election

The UK leans unusually far in the seesaw direction. You win an election, you immediately get to cleanse the government machinery of the opposition and push through your plans. Well, we have Lords, and manifestos aren't quite "we're going to do the reverse of everything the other guys did"...
by Xenomortis
Sun Oct 23, 2016 12:05 am UTC
Forum: Gaming
Topic: Heroes of the Storm (Moba Lite?)
Replies: 39
Views: 9086

Re: Heroes of the Storm (Moba Lite?)

Elite might punish really bad decisions a little more - the AI tends to like grouping up a lot and pushing with mercs. It's not uncommon for three to rotate to defend against one person that's pushed too deep. But if your team soaks experience from all three lanes (the AI frequently doesn't past the...
by Xenomortis
Sat Oct 22, 2016 10:36 pm UTC
Forum: Gaming
Topic: Heroes of the Storm (Moba Lite?)
Replies: 39
Views: 9086

Re: Heroes of the Storm (Moba Lite?)

I often play against the AI to power through the daily quest rewards (much shorter queue times, and usually quite short games). I've found games against Veteran AI are often much harder than Elite AI, because the human players you get matched with are often much worse. People also play very risky ag...
by Xenomortis
Thu Oct 20, 2016 8:53 am UTC
Forum: Science
Topic: Science fleeting thoughts
Replies: 76
Views: 6601

Re: Science fleeting thoughts

I don't think CO2 "capture" is the right word.
It's more energy storage - replacing batteries with ethanol.
by Xenomortis
Mon Oct 17, 2016 3:10 pm UTC
Forum: Coding
Topic: Coding: Fleeting Thoughts
Replies: 9546
Views: 1339805

Re: Coding: Fleeting Thoughts

Stackoverflow suggests that numpy.fromfunction has very deceptive docstrings and in fact, does not execute the function per coordinate point. What actually happens is the function is called once with arrays of the coordinates and operates directly on those. It so happens that numpy's array syntax wo...
by Xenomortis
Mon Oct 17, 2016 2:29 pm UTC
Forum: Coding
Topic: Coding: Fleeting Thoughts
Replies: 9546
Views: 1339805

Re: Coding: Fleeting Thoughts

Making arrays in python. size = int(4e6) s = time() l = list( (x - 0.5) * 0.5 for x in xrange(size) ) print time() - s 0.6 seconds (and a lot of memory) l = numpy.fromiter( ((x - 0.5) * 0.5 for x in xrange(size)), dtype=np.float64, count=size) 0.72 seconds Didn't expect that... at least it's less me...
by Xenomortis
Fri Oct 14, 2016 3:11 pm UTC
Forum: Coding
Topic: Coding: Fleeting Thoughts
Replies: 9546
Views: 1339805

Re: Coding: Fleeting Thoughts

Without thinking much about the problem: Pick a value based on the k-nearest neighbours, weighted by distance, culling those that are "shadowed" by other points (you'll need to decide on the angle to cull at). I imagine k should be quite small, the culling step is unlikely to be necessary ...
by Xenomortis
Fri Oct 07, 2016 9:51 pm UTC
Forum: Mathematics
Topic: Why does x=y -> f(x)=f(y)?
Replies: 12
Views: 1510

Re: Why does x=y -> f(x)=f(y)?

I don't think that makes sense.
Your function there is really f: N2 -> N, not Q -> N.
In Q, you don't differentiate 1/2 and 2/4.
by Xenomortis
Thu Oct 06, 2016 8:56 am UTC
Forum: Gaming
Topic: Heroes of the Storm (Moba Lite?)
Replies: 39
Views: 9086

Re: Heroes of the Storm (Moba Lite?)

2) HoTS is inferior to the other games. I tried it for a while but the fact there aren't items drastically reduce the complexity of For some (me at least), that's a significant advantage. It's much easier to pick up and play and games are shorter. Yes, there are fewer subtleties (no last hitting, e...
by Xenomortis
Wed Oct 05, 2016 4:43 pm UTC
Forum: News & Articles
Topic: British EU referendum in June [update: Leave wins 52% - 48%, politics ensue]
Replies: 977
Views: 61124

Re: British EU referendum in June [update: Leave wins 52% - 48%, politics ensue]

The reasoning there is that free movement means that refugees allowed into other EU countries will end up in Britain to take advantage of our benefits system.
by Xenomortis
Mon Sep 26, 2016 12:40 am UTC
Forum: Science
Topic: How serious is a 1st degree burn?
Replies: 15
Views: 1741

Re: How serious is a 1st degree burn?

The OP describes second degree - a hot stove would cause blistering and quite a bit of pain.
The primary risk is infection.
by Xenomortis
Tue Sep 20, 2016 4:09 pm UTC
Forum: Coding
Topic: faster function than 1/x?
Replies: 18
Views: 2473

Re: faster function than 1/x?

I seem to remember reading that the union variant is only safe in GCC, but I never really properly understood the logic around union aliasing rules from the standard.
by Xenomortis
Tue Sep 13, 2016 2:25 pm UTC
Forum: Coding
Topic: Coding: Fleeting Thoughts
Replies: 9546
Views: 1339805

Re: Coding: Fleeting Thoughts

Eclipse 'Problems' tab wrote:Warnings (100 of 8365)

Yeah...

Actually, this wasn't highlighted in a warning.
And to be fair, testing for referential equality on objects may be something you really want to do, although it's almost certainly not what you have in mind when Strings are involved.
by Xenomortis
Tue Sep 13, 2016 1:25 pm UTC
Forum: Science
Topic: Science-based what-if questions
Replies: 233
Views: 9963

Re: Core orbiting planet.

Magmar, obviously.
by Xenomortis
Tue Sep 13, 2016 11:39 am UTC
Forum: Coding
Topic: Coding: Fleeting Thoughts
Replies: 9546
Views: 1339805

Re: Coding: Fleeting Thoughts

Oh, I've known for a long time. But typing "==" is so instinctive that I often trip up (excluding Strings, equality testing for non primitives is really quite rare in our codebase, and it works as expected in every other language I've used). That it sometimes "appears" works is w...
by Xenomortis
Tue Sep 13, 2016 10:05 am UTC
Forum: Coding
Topic: Coding: Fleeting Thoughts
Replies: 9546
Views: 1339805

Re: Coding: Fleeting Thoughts

I've just fixed a bug in some code I wrote that compared Java strings using == instead of String.equals(...). This is ridiculous. String overloads "+" to do the "intuitive" thing, but not "==". But that's not the worst bit; the worst bit is that "==" will actu...
by Xenomortis
Tue Sep 06, 2016 4:29 pm UTC
Forum: Coding
Topic: Coding: Fleeting Thoughts
Replies: 9546
Views: 1339805

Re: Coding: Fleeting Thoughts

*Looks at a Java interface with a "write" method*
*Clicks, "Search for References" in Eclipse*
*Gets given a result of all calls to methods called "write", ignoring the interface*

Why do I bother with IDEs again?
by Xenomortis
Thu Aug 25, 2016 9:00 am UTC
Forum: Coding
Topic: Why does .NET seem so ugly?
Replies: 5
Views: 1912

Re: Why does .NET seem so ugly?

However, whenever I have to spin up a Visual Studio IDE, it's overwhelming and very complicated. ... even Eclipse seem intuitive. Eclipse is more intuitive than Visual Studio? I guess it's possible with a Java background... So, starting up Visual Studio, I count about six clicks to get something th...
by Xenomortis
Wed Aug 24, 2016 3:15 pm UTC
Forum: Mathematics
Topic: Goahead52's Math Posts
Replies: 148
Views: 7697

Re: Goahead52's Math Posts

The following is an identity - it is true for all (real) x:
sin2(x) + cos2(x) = 1
This is a useful identity, but it places no constraints on x.

The following is not an identity - it is not true for all x.
sin(x) + cos(x) = 1
This equation tells us x is an integer multiple of pi/2.
by Xenomortis
Fri Aug 19, 2016 9:30 am UTC
Forum: Coding
Topic: Bettering vs Bloat?
Replies: 19
Views: 2489

Re: Bettering vs Bloat?

Don't confuse features with bloat. By today's standards, Doom 1 was a relatively simple project. Here are a few statements that I strongly suspect to be true: * Doom 3's physics engine is an order of magnitude more complex than all of Doom 1 combined. * Doom 3's network code is more complex than al...
by Xenomortis
Wed Aug 17, 2016 9:56 pm UTC
Forum: Mathematics
Topic: Goahead52's Math Posts
Replies: 148
Views: 7697

Re: New Theorem (prime numbers)?

I think you can prove a slightly stronger statement, that is mu(n * phi(n)) != 0 implies n is prime. My maths is a little rusty, but I'll give it a go. Suppose n is *not* prime. Case 1: n is not square-free Then n * phi(n) is not square-free, hence mu(n*phi(n)) = 0 Case 2(a): n is square-free and ha...
by Xenomortis
Wed Aug 17, 2016 3:27 pm UTC
Forum: Individual XKCD Comic Threads
Topic: 1721: "Business Idea"
Replies: 55
Views: 4914

Re: 1721: "Business Idea"

I really doubt that the addition of a hose-worth amount of petrol will hurt your diesel engine, given a full tank of the correct fuel (or vice-versa). I have heard that around 10-20% of the wrong fuel won't cause issues, but I haven't found a credible source (not that I've really looked). Sounds li...
by Xenomortis
Wed Aug 17, 2016 2:55 pm UTC
Forum: Individual XKCD Comic Threads
Topic: 1721: "Business Idea"
Replies: 55
Views: 4914

Re: 1721: "Business Idea"

In the UK, it is different hoses for the different grades of fuel. And its mostly self service, You'll find many a Scotsman draining the hose and shaking the last drop off the end. Australia too. I had never thought anyone would do otherwise, so I'd thought the idea in the comic was even less sensi...
by Xenomortis
Mon Aug 15, 2016 6:10 pm UTC
Forum: Mathematics
Topic: Decimal like Concepts in Other Bases?
Replies: 7
Views: 1554

Re: Decimal like Concepts in Other Bases?

17 is 16 + 1 (2 4 + 2 0 ), so that's 10001. 0.32 is a little more tricky - you need to work out 32 / 100 in binary (specifically, 100000 2 / 1100100 2 ) - you can do the long division if you want, the technique is the same as it is in base 10. It won't be terminating - easy decimal expansions seldom...
by Xenomortis
Mon Aug 15, 2016 5:02 pm UTC
Forum: Coding
Topic: Coding: Fleeting Thoughts
Replies: 9546
Views: 1339805

Re: Coding: Fleeting Thoughts

TIL git automatically rewrites line endings... but only in the commits/compares and won't do it on disk... Though this is sort of disturbing, that means two different developers can have two different line ending settings in the same repository and cause each other headaches like this? Line ending ...
by Xenomortis
Mon Aug 15, 2016 4:50 pm UTC
Forum: Mathematics
Topic: Decimal like Concepts in Other Bases?
Replies: 7
Views: 1554

Re: Decimal like Concepts in Other Bases?

Digits in a decimal expansion merely represent multiples of a power of 10. So for instance: 17.32 is 1 * 10 1 + 7 * 10 0 + 3 * 10 -1 + 2 * 10 -2 That is "One 10, seven 1's, three 10ths, two 100ths". The idea is the same for other number bases, but instead of powers of 10, it's powers of th...

Go to advanced search