The trouble with that is plenty of extensions legitimately need to run on all sites all the time for the user to get the value they want. Ad blockers, coupons for all stores, etc.
The thing is... it's generally safe to truncate a leading zero [0], but it's not necessarily safe to truncate a trailing zero. For example, sometimes trailing zeros convey precision, and then you've got SEMVER [1] causing situations like Drupal 7.1 and 7.10 and 7.100 (spanning 100 minor releases).
[0] ZIP codes and phone numbers are important exceptions, but it's a non-issue if you always process these as strings, never as numbers, which is a reasonable constraint because we don't need to sort these numerically. Lexicographical sort is perfectly fine.
[1] The concept mentioned in footnote 0 does not really apply to SEMVER, because we do like to sort versions numerically. Lexicographical sort is wrong. But it's a group of dot-delimited integers, not to be conflated with floats, so while 7.100 comes before 7.2 when sorting floats, 7.100 comes after 7.2 when sorting SEMVER because the 2 and 100 are just integers.
> The given examples seem disconnected from the duty cycle radios on my browser. I mean changing them changes the sound, but it's as if the one I selected is not the one playing.
Confirmed. Author, please fix! For example, in the first set of radio buttons:
1. Leave it at the 50% default
2. Press play
3. Change it to the 12.5% option -- we continue to hear the same sound
4. Change it back to 50% -- finally we hear a different sound
This is broken. Another example:
1. Listen to 12.5% after having come directly from 25%
2. Listen to 12.5% after having come directly from 50%
The 12.5% should sound identical in either case, but it erroneously does not.
This is correct, the demo not properly handling the selection of a new duty cycle. I pushed up a correction just now. Thanks for laying out a detailed replication - made for an easy fix
> almost identical ... components would be identical
I'm having a tough time reconciling how the former could be almost identical while the latter is identical. I guess the former involves a human listening through a speaker which has asymmetric imperfections (maybe the speaker moves outward more easily than it moves inward, or a DC offset in the signal leads to compression in the high-excursion side that doesn't exist on the low-excursion side, etc.) whereas the FFT readout doesn't necessarily have a speaker in the system at all.
25% and 75% would sound identical alone, but in a mix there often are interplays where it can create a difference. An easy way to hear it is to run two synced oscillators, say a square and a saw, with sharp attack. The resulting sound should be sufficiently different, one side would dampen the attack compared to the other. Furthermore, I think in hardware synths and those that emulate them changing pulse width can cause the module to implicitly shift the signal up or down to ensure consistent average voltage, further complicating things. I am curious what you mean by compression.
Good point. If I have 2 oscillators, and no control over their phase as they mix, then an option to choose 25% vs 75% for one of them would at least offer some variation instead of none.
As for compression, this [0] is a good intro. Most commonly it is applied to a signal deliberately to achieve a desired outcome, but I'm referring to a (generally) undesired speaker nonlinearity [1] near its maximum power handling capacity.
Different linearity properties on the positive and negative side would be pretty bad for a speaker, but possible. In the case of a square wave, non-linearity would be identical to a fixed amplitude change though, possibly with a DC bias.
Based on the gameboy wiki I looked up, the phase of the 25% duty and 75% duty are such that they are inverse of each other, seemingly eliminating the possibility of combining the two for different waveforms.
I tried putting a few of GP's multilingual paragraphs into google translate on detect mode, and it got everything into English perfectly! Interestingly, it declares a single language as having been detected, which varies perhaps based on majority input language.
I never got into this aspect of networking, so I truly don't know what I'm talking about and wish someone will correct me, but on some level, IP does indeed have broadcast/multicast capabilities that cause the sender's egress traffic to remain independent of the number of recipients rather than being equal to the sum of recipients' ingress traffic, right? Does this only work downstream of the last router, and therefore has limited usefulness on the internet?
> IP does indeed have broadcast/multicast capabilities that cause the sender's egress traffic to remain independent of the number of recipients rather than being equal to the sum of recipients' ingress traffic, right?
Yes multicast, however you can't do multicast over the internet. In practise the technology is mainly used in production and enterprise scenarios (broadcast, signage, hotels, stadiums, etc).
Instead big streaming platforms like netflix or twich use CDN boxes installed locally at major ISPs. Also with so much hardware acceleration on modern NICs these days, it's surprisingly easy to handle Gbits of throughput for audio/video streaming.
I think you are right. Multicast is typically udp and only available on your local net if the router is configured for it. I haven't used multicast in along so I might be wrong. I remember network updates breaking it.
Typing <word><hyphenminus><hyphenminus><word><space> yields an em dash.
Typing <word><space><hyphenminus><hyphenminus><space><word><space> yields an en dash.
That this has been true for some 3 or 4 decades makes me doubt all the comments that em dashes are a "tell" of LLM authorship. On the other hand, I guess when we confine this possibility to web content, I can see how people haven't used Office for web authoring lately, and whatever they do use (like web-based content management systems) don't tend to have this feature.
> Typing <word><space><hyphenminus><hyphenminus><space><word><space> yields an en dash.
More importantly, typing just a single hyphen minus in this constellation triggers the autoreplace, too. (Typing the double hyphen is only necessary without spaces in order to distinguish between an intentional hyphen and an em dash.)
Good point. Either way, it's kind of peculiar that getting an en dash in this manner demands flanking the hyphen(s) with spaces, and those spaces persist after replacement, when the typical usage of an en dash specifically doesn't demand spaces.
From TFA:
> August 1–August 31
From a top comment:
> Boston–San Francisco flight, 10–20 years
To achieve this using the replacement feature we're talking about would take something like <word><space><hyphenminus><space><word><space><alt+leftarrow><bksp><leftarrow><bksp><alt+rightarrow> which is ridiculous.
In professional typesetting, like a book, I sometimes see spaces flanking an em dash, however.
I can't get this to work in Powerpoint. It's funny, I clicked on this thread because I was struggling with trying to make an "emdash" in Powerpoint yesterday and couldn't find the correct search term for the "long hyphen" that I was looking for.
Works fine for me on PowerPoint for Mac, oddly enough. Unrelatedly, Mac also allows easy (non-alt-code) keyboard entry: option-hyphen yields an en dash, while option-shift-hyphen yields an em dash.
It just means that you can continue indefinitely with no end in sight. End could come from financial problems, consumer preferences to help the environment, environmental regulations, supply chain issues, and all sorts of other things.
It's like the sustain pedal on a piano: nothing actively dampens the sound, so the sound will continue for quite a while longer than is typically required.
For traditional lightbulbs, a PWM signal actually makes the light noticeably dimmer, and has a very simmilar effect to simply reducing the current. This is because the mechanism for them is heating up the filement, which happens on a much slower time scale then the PWM duty cycle.
In practice, traditional dimmers are not quite PWM as they do not generate a square wave. Instead they generate a sin wave with portions of each cycle clamped to 0.
LEDs already need driver circutry to condition the relativly high AC voltage into a stable lower voltage DC. Dimmable LEDs create a stable DC power supply from the chopped up AC power, then use the width of the active portions of the AC as a signal to drive their own dimmer logic.
That's a good PWM explanation but I think GP was asking a different question. Walter claimed that if the PWM was high enough frequency you would perceive it as full brightness while using less power.
It obviously wouldn't work that way when lighting a room, but what about for an LED indicator light that you look at directly? I don't know enough to form an opinion.
Without any more information on frequencies and measurements it's impossible to know. My guess is either A) They did not perceive the dimming, and/or B) The frequency was high enough that the inductive and capacitive effects of the circuitry became relevant and was filtering the PWM signal to DC signal that still drew the same amount of power as it did when fed the full voltage DC signal
The measurable brightness of the LED is a straightforward sum of the times it's on and the times it's off. Shift the ratio so it's off more than it's on and it gets dimmer.
The "fully bright" part is a consequence of human vision. Your brain is making sense of limited, noisy information coming from your eyes. A flickering light appears brighter than the light in steady state, lots of still images shown in rapid succession look like they're moving, as far as you can tell you can perceive the full range of colour out of the corner of your eyes, and the dress could be either colour.
Also (and I think more important, but I might be wrong), we don't perceive light intensity linear but logarithmic. A 50% duty cycle does appear brighter than half as bright. A 90% duty cycle might be only barely perceptible.
The apparent brightness is caused by the ratio of on/off and is called the duty cycle. 50% brightness would mean that half the time the light is on, and half the time the light is off.
If the cycling of the light on and off is done at say 10kHz it's perceived as a dim light.
Aside: >1000 comments in 2017 is significant. Is there a straightforward way to list such highly-engaged HN submissions? Ideally sorted by prominence within a short (1yr is fine) time window, but a simpler sort (no regard for prominence, just absolute engagement, which would strongly tilt the results toward the present, due to platform growth) would also be ok.
reply