Hacker News new | past | comments | ask | show | jobs | submit login
Gray code at the pediatrician's office (plover.com)
221 points by J3L2404 on May 24, 2011 | hide | past | favorite | 24 comments



Hmm. As a geek I like Gray code and think it has many useful applications, but this is not one of them: Iris stood against the post and the nurse adjusted the bracket to exactly the top of her head. Then she read off Iris's height from an attached display.

How is this an advance on looking at a conventionally numbered ruler (with a similar bracket to touch the top of the head) and writing down the number? It's technological and presumably expensive, but it isn't delivering any discernible benefit that I can see. Measuring height via computer vision + Gray code would be very useful in security applications where you want to log biometric information for a large number of people efficiently (camera + abstract-looking wall design in an access corridor or at a security checkpoint), but if you're paying a human to take the measurement you might as well use a scale that's easily human-readable (ie at a glance). I hope the doctor's scale was at least using bluetooth or similar to automatically update the patient's digital record...but I wouldn't bet on it.


Presumably it's considered useful because there's a measurable error rate in the nurse a) reading -and/or- b) recording the observed data. Assuming this thing works properly more often, you've not only guaranteed you get the data entered properly, but it's more likely to be right.


I imagine this is compounded by the subject matter being measured. A simple "click and lock the measurement" button would be invaluable when trying to measure the height of a squirming child.

Simple, easy to read numbers that eliminate guesswork would seem to make a nurse's job much simpler (or allow them to utilize people who are not registered nurses to collect this data). There have been similar advances in scales, blood pressure cuffs, heart rate monitors, etc. All are readable using analog gauges, yet they progressed to digital devices.


What people here don't seem to realize is that a doctors' scale or measuring tapes are not used for precision measurements anyway.

If the doctor sees the patient only every few months, individual variations (kids will grow, adults will gain (or, sometimes, hopefully) loose weight)) in body height or weight will exceed the precision you can get even out of the cheapest scale or measurement tape.

And as for the purpose of the measurements: The doctor will use the values acquired from the tools to categorize patients in categories: E.g. a obese person has a higher risk of cardiac arrest, someone looking quite anorexic will have other problems with his blood chemistry... And here a few kilograms/centimeters don't influence the general statement at all.


The same question came up on Reddit (in the agressive know-it-all tone typical of Reddit (http://www.reddit.com/r/programming/comments/8ufl1/gray_code...) when I first posted this blog article. So I asked the pediatrician, and the answer (http://www.reddit.com/r/programming/comments/8ufl1/gray_code...) was surprising:

>I was back at the office today and I asked one of the senior doctors about it. She said that the manual stadiometers were always giving inaccurate readings and that they constantly had to have the service guys in to recalibrate them. The electronic stadiometer, she said, is much more reliable.

>"But it's a really expensive stadiometer," I said.

>"The service calls on the manual stadiometers were costing us a fortune."

>The radio connection to the portable readout is a red herring. They had the display mounted on the wall right next to the stadiometer. I asked if they ever took it down and moved it around; the doctor said they never did.

>So there's your answer. It's nothing clever, but it's totally reasonable, and it's nothing you could deduce from your armchair. This is why it's important to suspend judgment of someone's actions when you don't have any direct knowledge of their situation.

Hope this helps.


The article didn't say, but I would imagine the actual records would receive the vitals directly from the machine, rather than going through a nurse (it also may be a work in progress as an office moves to electronic records and streamlining vitals). The nurse reads the number off the indicator for the benefit of the patient, not the records.

I agree, as the article reads, it would just be silly to add the additional cost with no change other than needing a machine to read the numbers.


I assume that the reason is to reduce error from having a person read the height from a scale. It would also make the nurse's job easier because they wouldn't need to have to fiddle with the analog scale. I know my kid hates getting his height/weight measured, so anything that speeds up the process is good.

Another potential benefit is that the digitized scale could be directly attached to a wall without regard for it's height relative to the ground. There could be a defined calibration offset stored in the reader, so the contractor wouldn't need to be exact when the bar is installed.



OK, it may be an old question but why doesn't HN search for old URLs before allowing you to post? I missed this the first time around and am really glad that it got posted (and glad you found the dupes) but most reposts are bad. I think something like a URL check would be valuable.


There is a URL check, but it only finds exact matches, and only if the URL tested against is in memory. If it's old enough and hasn't been accessed recently, it's not found.

I thought this was in jacquesm's FAQ, but it appears not to be:

http://jacquesmattheij.com/The+Unofficial+HN+FAQ

You might suggest it to him, although he's very busy.



Here's another visualization of the Gray code: http://billmill.org/static/perm4.png

(it's from a few visualizations of permutations I did a while ago: http://billmill.org/permvis.html )


A partially related topic(maybe many of you already know): I was learning about minimizing logic expressions the other day, and I learned about the Karnaugh Map, which uses Gray code for its axes. You can read more about it here: http://en.wikipedia.org/wiki/Karnaugh_map


When I looked at that pattern I though "Looks like one of Wolframs FSAs". And after reading the encoding algorithm, seems like it is. See http://demonstrations.wolfram.com/ElementaryCellularAutomato...


Gray code was used as long ago as the Atari 2600 game system, designed in 1977. The system's clock for drawing out sprite graphics pixels counts in Gray code internally. Why? Because a binary adder could have too long a propagation delay. To increment 01111111 to 10000000 requires seven carry operations which would not always complete within a single clock cycle. (A modern ALU has tons of transistors to compute all those bits in parallel, but the Atari 2600 mass market game console did not have the budget for that many transistors.) Gray code was the solution. It always changes only one bit to increment a counter so the operation was guaranteed to complete quickly.


No, they didn't use Grey code for that, they used a "linear feedback shift register". A LFSR has lower propagation delay than a normal binary counter.

The driving controllers did use Grey code.


extremely fascinating, but what problem does this solve that a standard analog equivalent ruler/markings didn't?


The optical machine doesn't have to count lines, it can read it's place on the bar from a small (2cm wide) part, rather than keeping an incrementer from the bottom or top.


I understand that. but whenever I'm at the doctor's they still have a graduated wall against which they put patients to get their height.

I'm all for digitizing things, but is there any reason to replace this?


In regard to digital measuring devices, they are much easier to recalibrate than say a strip of metal with graduated marks. This can lengthen it's lifetime of use, as well as speed installation and manufacturing time as neither has to be as precise as the analog versions.

Another perceived benefit is that the indicator dial/display can be offset from the scale. I know I've seen some height gauges that partially cover the numbers that indicate their position. Digital solutions allow the measuring marks to be independent of how one takes the measurement.


Why would a ruler marked in binary not need to be as precise as a ruler marked in decimal? Changing the base of the numbers does little to affect how one attaches it to the wall.


After it was manufactured, it could be calibrated and the counter could then tell itself that 100cm is actually only 98cm due to manufacturing tolerance errors, for example. Then, after it was installed on the wall one centimeter too high, it could then be re-calibrated to reflect that error as well.

Abstracting the way the device counts (incremented binary marks on the wall) away from the measurement (inches or centimeters, etc) with a re-programmable digital device has many benefits.


Any medical data that can be recored in a mechanical fashion should be.

The nurse writing things down is just a temporary artifact of the existing process.


This is incredibly interesting. Thank you!




Guidelines | FAQ | Lists | API | Security | Legal | Apply to YC | Contact

Search: