HNHacker News
TopNewBestAskShowJobs

rexpress

124 karma · joined December 6, 2016

submissionscomments
rexpress··on Map of quotation marks in European languages
I'm starting to doubt myself, but that was my understanding too. Furthermore "..." denotes a direct quote, whereas '...' can mean that the quote is indirect/paraphrased.
rexpress··on Derailing illusions that kill: misperceptions at railway crossings (2003)
Googling "MCB-OD crossings" will bring up various pages and videos that show such crossings in the UK. They are relatively new to the UK but I believe they have been used for some time in continental Europe.

They have disadvantages including expense, and additional road closure times (compared to automatic half-barriers) as they must be closed and proven clear early enough that an approaching train does not need to slow down.

rexpress··on Derailing illusions that kill: misperceptions at railway crossings (2003)
In the UK many crossings have full width barriers, and must be confirmed to be clear of road traffic after the barriers have closed before the protecting signal can be cleared for a train. These are effectively fail safe.

Confirmation comes from observation by a signaller or crossing operator either directly or by CCTV, or automatically by LiDAR and radar. These crossings tend to be used in areas of heavy road, pedestrian or rail movements, and when train speeds may exceed (from memory) 100 mph / 160 km/h.

Their disadvantage is additional installation, maintenance and operational costs. They must also be closed for longer before a train arrives than an automatic half-barrier crossing to allow for the required safety checks and ensure that signals are cleared far enough along the line that approaching trains do not need to slow down.

rexpress··on The Phix Programming Language
In the case of Mathematica, 1-based indexing also makes sense in the context of it being a lisp-like language where everything is an expression that can be represented as a tree.

So in the case of

exp = x + y + z

this is syntactic sugar for

exp = Plus[x, y, z]

As expected with 1-based indexing exp[[1]] returns x, but the zero index can also be used to access the head of the expression, so exp[[0]] returns Plus.

Another nice property of 1-based indexing in Mathematica's case is that by using negative indices you can access elements in the reverse direction, so exp[[-1]] would return z, and exp[[-3]] would return x.

rexpress··on Night train connecting Amsterdam to Scandinavian capitals under consideration
Variable gauge trains help overcome this problem:

https://en.m.wikipedia.org/wiki/Variable_gauge

I once took a night train from Barcelona to Paris that changed gauge at the border. It slowed to a walking pace and travelled through a shed like structure that housed the equipment. There was some mild clunking and clanging from underneath as we slid over the mechanism. Quite impressive.

rexpress··on Why Hasn’t Brexit Happened?
Brexit to some Brexiteers means what they rather fancifully believe is the 'clean break' of no-deal. To some other Brexiteers, Brexit means continued membership of the customs union, but not the single market. No doubt that there are numerous other configurations of Brexit that various people thought they were voting for, including staying in the single market.

These different Brexits would result in very different futures for the UK, and yet they were all aggregated into one vote, 'Leave'.

There has yet to be any evidence that there is greater support from the public for any particular Brexit than there is to remain.

rexpress··on Why do we need modules at all? (2011)
The proposed key-value function database mentioned in the article sounds like the recently launched Function Repository in the Wolfram Language...

https://resources.wolframcloud.com/FunctionRepository/

rexpress··on What We’ve Built Is a Computational Language
I came across Mathematica via Wolfram Alpha while studying for a Maths degree. I was quite astonished by its capabilities, and have been playing with it ever since.

For context I work full time in an industry unrelated to software, and have kids and all the chaos that goes with them, so have relatively little time to devote to programming. I need something that 'just works'.

I've always felt that I should enjoy programming, and have had several false starts including HyperCard and Eiffel back in the day. But Mathematica / Wolfram Language is the first time programming has actually clicked.

There are various aspects to the Wolfram Language that make it work for me;

- The documentation is enormous, comprehensive and even editable and executable (desktop install). I haven't seen anything that comes close in any other language (Racket would probably be a distant second). In the snatches of time I have, all the information I need can be found using the F1 key, I don't have to waste time going to Stack Exchange and asking others for help

- The concept of everything being an M-expression makes the language very logical. Sub-expressions can themselves be evaluated and understood, larger expressions built out of smaller ones etc

- Lots of syntactic sugar IMO makes the M-Expressions more readable than Lisp S-Expressions, while retaining their usefulness in making code understandable

- Very powerful pattern matching and structural operations on expressions, which are great tools for manipulating expressions and extracting code or data

- Strong support for functional programming, which I find to be more enjoyable than procedural programming

- The language is symbolic, which often allows you to 'play' with programs and understand how they will work in an abstract way before using with real data. As a toy example you can literally fold an abstract function with abstract expressions, e.g. inputting Fold[f,x,{a,b,c,d}] returns f[f[f[f[x,a],b],c],d].

- a huge standard library built in, all working in a way that is remarkably consistent for such a wide diversity of domains, and a language that has been in development for 30+ years

- interactive notebook programming allows me to document my notes and progress along with the code

I did try a few FLOSS options primarily for access to their communities and also ease of deployment (e.g. F#, Clojure, Java) but haven't found anything comes close for my particular needs. I suspect that Racket would be the next best thing.

I think the Wolfram Language does suffer from the Lisp curse, in that it is sufficiently powerful and well documented that individual developers can go a long way without recourse to a community, which in turn hence hinders the establishment and growth of such communities.

I would strongly recommend spending some time learning the fundamentals of the language. My favourite resource is Paul Wellin's An Introduction to Programming with Mathematica (2013). I suspect a lot of the criticism of Mathematica comes from those who haven't learnt the fundamentals, and expect it to work like Python or Java etc, when in fact it is more like a cousin of Lisp.

rexpress··on Ask HN: High-Quality Online Degree for Mathematics?
I did my BSc in Mathematics with the OU. Overall it was a very good experience. Rather than teaching by lectures, the OU provides you with high quality and substantial written materials. As with any other university you are expected to keep up with the course schedule, and will be required to submit assessments and sit exams at certain times.

The reliance on written materials with much less face-to-face teaching (compared with a traditional university) was to me a distinct advantage as it gave me more control over the pace of the course.

rexpress··on 9999999999999999.0 – 9999999999999998.0
Mathematica interprets the real numbers 9999999999999999.0 and 9999999999999998.0 as having machine precision. To work in arbitrary precision, you need a backtick after the number, followed by the number of significant digits.

In this case,

9999999999999999.0`17-9999999999999998.0`17 does indeed return 1.

https://reference.wolfram.com/language/ref/Precision.html

rexpress··on Coca-Cola to buy Costa coffee for £3.9bn
McDonald's double espresso poured over a 99p sundae (plain, just ice cream) makes for a decent cut-price affogato.
rexpress··on Jupyter, Mathematica, and the Future of the Research Paper
Regarding the double brackets for representing Part, you can instead use〚 and 〛which can be input with `ESC`-[-[-`ESC` and `ESC`-]-]-`ESC` respectively. This makes the code prettier and easier to read.

There is a very easy to implement modification you can make to allow the keyboard shortcuts `CMD`-[ and `CMD`-] for the double bracket symbol, which is described here:

http://szhorvat.net/pelican/pages/mathematica.html

I rather wish Wolfram would provide these keyboard shortcuts in the base software

rexpress··on Jupyter, Mathematica, and the Future of the Research Paper
I suspect that the OP used the "Print..." command in the File menu, and selected PDF as the printer option. ISTR that this can sometimes result in poor quality results as presumably it is relying on an external PDF engine to render the notebook.

Whenever I've used the "Save As..." command, choosing PDF as the target, I've also only had good quality output.

rexpress··on [dead]
Pret is dismissed early in the article, but having previously been an espresso lover, I'm now hooked on Pret's filter coffee. At 99p a cup it has the best bang for buck of any takeaway coffee, and although I occasionally encounter a rough batch, it is usually more flavoursome than most espresso based beverages.
← PreviousPage 2 of 2