Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]
Groups > comp.lang.python > #110513 > unrolled thread
| Started by | Lawrence D’Oliveiro <lawrencedo99@gmail.com> |
|---|---|
| First post | 2016-06-26 00:36 -0700 |
| Last post | 2016-06-28 18:15 +1200 |
| Articles | 20 on this page of 95 — 21 participants |
Back to article view | Back to comp.lang.python
Assignment Versus Equality Lawrence D’Oliveiro <lawrencedo99@gmail.com> - 2016-06-26 00:36 -0700
Re: Assignment Versus Equality BartC <bc@freeuk.com> - 2016-06-26 11:48 +0100
Re: Assignment Versus Equality Steven D'Aprano <steve@pearwood.info> - 2016-06-26 23:21 +1000
Re: Assignment Versus Equality Rustom Mody <rustompmody@gmail.com> - 2016-06-26 07:26 -0700
Re: Assignment Versus Equality Dennis Lee Bieber <wlfraed@ix.netcom.com> - 2016-06-26 11:31 -0400
Re: Assignment Versus Equality Christopher Reimer <christopher_reimer@icloud.com> - 2016-06-26 11:47 -0700
Re: Assignment Versus Equality Michael Torrie <torriem@gmail.com> - 2016-06-26 15:28 -0600
Re: Assignment Versus Equality Bob Gailer <bgailer@gmail.com> - 2016-06-27 08:22 -0400
Re: Assignment Versus Equality Rustom Mody <rustompmody@gmail.com> - 2016-06-27 05:48 -0700
Re: Assignment Versus Equality Steven D'Aprano <steve@pearwood.info> - 2016-06-27 23:28 +1000
Re: Assignment Versus Equality Marko Rauhamaa <marko@pacujo.net> - 2016-06-27 16:58 +0300
Re: Assignment Versus Equality Rustom Mody <rustompmody@gmail.com> - 2016-06-27 07:23 -0700
Re: Assignment Versus Equality Steven D'Aprano <steve@pearwood.info> - 2016-06-28 11:05 +1000
Re: Assignment Versus Equality Rustom Mody <rustompmody@gmail.com> - 2016-06-27 21:31 -0700
Re: Assignment Versus Equality Steven D'Aprano <steve+comp.lang.python@pearwood.info> - 2016-06-28 15:42 +1000
Re: Assignment Versus Equality Chris Angelico <rosuav@gmail.com> - 2016-06-28 16:04 +1000
Re: Assignment Versus Equality Marko Rauhamaa <marko@pacujo.net> - 2016-06-28 09:12 +0300
Re: Assignment Versus Equality Jussi Piitulainen <jussi.piitulainen@helsinki.fi> - 2016-06-28 11:04 +0300
Re: Assignment Versus Equality Rustom Mody <rustompmody@gmail.com> - 2016-06-27 23:09 -0700
Re: Assignment Versus Equality Lawrence D’Oliveiro <lawrencedo99@gmail.com> - 2016-06-28 00:12 -0700
Re: Assignment Versus Equality Chris Angelico <rosuav@gmail.com> - 2016-06-28 17:26 +1000
Re: Assignment Versus Equality Lawrence D’Oliveiro <lawrencedo99@gmail.com> - 2016-06-28 01:49 -0700
Re: Assignment Versus Equality Chris Angelico <rosuav@gmail.com> - 2016-06-28 20:34 +1000
Re: Assignment Versus Equality Lawrence D’Oliveiro <lawrencedo99@gmail.com> - 2016-06-28 17:42 -0700
Re: Assignment Versus Equality Random832 <random832@fastmail.com> - 2016-06-28 10:13 -0400
Re: Assignment Versus Equality Marko Rauhamaa <marko@pacujo.net> - 2016-06-28 19:39 +0300
Re: Assignment Versus Equality Marko Rauhamaa <marko@pacujo.net> - 2016-06-28 19:41 +0300
Re: Assignment Versus Equality Random832 <random832@fastmail.com> - 2016-06-28 13:19 -0400
Re: Assignment Versus Equality Ian Kelly <ian.g.kelly@gmail.com> - 2016-06-28 12:27 -0600
Re: Assignment Versus Equality Marko Rauhamaa <marko@pacujo.net> - 2016-06-28 22:40 +0300
Re: Assignment Versus Equality Gene Heskett <gheskett@shentel.net> - 2016-06-28 16:59 -0400
Re: Assignment Versus Equality Gregory Ewing <greg.ewing@canterbury.ac.nz> - 2016-06-30 12:29 +1200
Re: Assignment Versus Equality Steven D'Aprano <steve@pearwood.info> - 2016-06-30 12:50 +1000
Re: Assignment Versus Equality Marko Rauhamaa <marko@pacujo.net> - 2016-06-30 09:22 +0300
Re: Assignment Versus Equality Steven D'Aprano <steve@pearwood.info> - 2016-06-29 12:27 +1000
Re: Assignment Versus Equality Rustom Mody <rustompmody@gmail.com> - 2016-06-28 20:52 -0700
Re: Assignment Versus Equality Rustom Mody <rustompmody@gmail.com> - 2016-06-28 21:03 -0700
Re: Assignment Versus Equality Random832 <random832@fastmail.com> - 2016-06-29 00:52 -0400
Re: Assignment Versus Equality Lawrence D’Oliveiro <lawrencedo99@gmail.com> - 2016-06-27 18:14 -0700
Re: Assignment Versus Equality Gene Heskett <gheskett@shentel.net> - 2016-06-27 11:21 -0400
Re: Assignment Versus Equality Dennis Lee Bieber <wlfraed@ix.netcom.com> - 2016-06-27 20:04 -0400
Re: Assignment Versus Equality Dennis Lee Bieber <wlfraed@ix.netcom.com> - 2016-06-26 11:21 -0400
Re: Assignment Versus Equality Cousin Stanley <HooDunnit@didly42KahZidly.net> - 2016-06-26 08:47 -0700
Re: Assignment Versus Equality BartC <bc@freeuk.com> - 2016-06-26 16:56 +0100
Re: Assignment Versus Equality Gregory Ewing <greg.ewing@canterbury.ac.nz> - 2016-06-27 11:38 +1200
Re: Assignment Versus Equality Dennis Lee Bieber <wlfraed@ix.netcom.com> - 2016-06-27 07:30 -0400
Re: Assignment Versus Equality Gregory Ewing <greg.ewing@canterbury.ac.nz> - 2016-06-28 18:17 +1200
Re: Assignment Versus Equality Grant Edwards <grant.b.edwards@gmail.com> - 2016-06-27 13:59 +0000
Re: Assignment Versus Equality Marko Rauhamaa <marko@pacujo.net> - 2016-06-27 17:09 +0300
Re: Assignment Versus Equality sohcahtoa82@gmail.com - 2016-06-27 17:33 -0700
Re: Assignment Versus Equality Marko Rauhamaa <marko@pacujo.net> - 2016-06-28 07:25 +0300
Re: Assignment Versus Equality Rustom Mody <rustompmody@gmail.com> - 2016-06-27 23:54 -0700
Re: Assignment Versus Equality Rustom Mody <rustompmody@gmail.com> - 2016-06-27 07:10 -0700
Re: Assignment Versus Equality Steven D'Aprano <steve@pearwood.info> - 2016-06-29 12:35 +1000
Re: Assignment Versus Equality Chris Angelico <rosuav@gmail.com> - 2016-06-29 14:19 +1000
Re: Assignment Versus Equality Lawrence D’Oliveiro <lawrencedo99@gmail.com> - 2016-06-28 21:51 -0700
Re: Assignment Versus Equality Chris Angelico <rosuav@gmail.com> - 2016-06-29 15:07 +1000
Re: Assignment Versus Equality Rustom Mody <rustompmody@gmail.com> - 2016-06-28 22:55 -0700
Re: Assignment Versus Equality Chris Angelico <rosuav@gmail.com> - 2016-06-29 16:26 +1000
Re: Assignment Versus Equality Rustom Mody <rustompmody@gmail.com> - 2016-06-28 23:33 -0700
Re: Assignment Versus Equality Rustom Mody <rustompmody@gmail.com> - 2016-06-28 23:37 -0700
Re: Assignment Versus Equality Steven D'Aprano <steve+comp.lang.python@pearwood.info> - 2016-06-29 15:26 +1000
Re: Assignment Versus Equality Lawrence D’Oliveiro <lawrencedo99@gmail.com> - 2016-06-28 22:51 -0700
Re: Assignment Versus Equality Steven D'Aprano <steve+comp.lang.python@pearwood.info> - 2016-06-29 16:45 +1000
Re: Assignment Versus Equality Lawrence D’Oliveiro <lawrencedo99@gmail.com> - 2016-06-29 01:07 -0700
Re: Assignment Versus Equality Chris Angelico <rosuav@gmail.com> - 2016-06-29 18:09 +1000
Re: Assignment Versus Equality Steven D'Aprano <steve@pearwood.info> - 2016-06-29 22:36 +1000
Re: Assignment Versus Equality BartC <bc@freeuk.com> - 2016-06-29 14:24 +0100
Re: Assignment Versus Equality Chris Angelico <rosuav@gmail.com> - 2016-06-29 23:35 +1000
Re: Assignment Versus Equality BartC <bc@freeuk.com> - 2016-06-29 15:47 +0100
Re: Assignment Versus Equality Chris Angelico <rosuav@gmail.com> - 2016-06-29 23:34 +1000
Re: Assignment Versus Equality BartC <bc@freeuk.com> - 2016-06-29 10:49 +0100
Re: Assignment Versus Equality Lawrence D’Oliveiro <lawrencedo99@gmail.com> - 2016-06-29 02:56 -0700
Re: Assignment Versus Equality BartC <bc@freeuk.com> - 2016-06-29 11:10 +0100
Re: Assignment Versus Equality Rustom Mody <rustompmody@gmail.com> - 2016-06-29 03:24 -0700
Re: Assignment Versus Equality Alain Ketterlin <alain@universite-de-strasbourg.fr.invalid> - 2016-06-27 16:48 +0200
Re: Assignment Versus Equality Rustom Mody <rustompmody@gmail.com> - 2016-06-27 22:00 -0700
Re: Assignment Versus Equality Steven D'Aprano <steve@pearwood.info> - 2016-06-28 11:34 +1000
Re: Assignment Versus Equality MRAB <python@mrabarnett.plus.com> - 2016-06-27 16:27 +0100
Re: Assignment Versus Equality Lawrence D’Oliveiro <lawrencedo99@gmail.com> - 2016-06-27 14:56 -0700
Re: Assignment Versus Equality Lawrence D’Oliveiro <lawrencedo99@gmail.com> - 2016-06-27 15:45 -0700
Re: Assignment Versus Equality BartC <bc@freeuk.com> - 2016-06-28 00:08 +0100
Re: Assignment Versus Equality Dennis Lee Bieber <wlfraed@ix.netcom.com> - 2016-06-27 20:11 -0400
Re: Assignment Versus Equality BartC <bc@freeuk.com> - 2016-06-28 11:35 +0100
Re: Assignment Versus Equality Gregory Ewing <greg.ewing@canterbury.ac.nz> - 2016-06-28 18:59 +1200
Re: Assignment Versus Equality Steven D'Aprano <steve@pearwood.info> - 2016-06-28 11:28 +1000
Re: Assignment Versus Equality Grant Edwards <grant.b.edwards@gmail.com> - 2016-06-27 15:42 +0000
Re: Assignment Versus Equality Marko Rauhamaa <marko@pacujo.net> - 2016-06-26 19:11 +0300
Re: Assignment Versus Equality MRAB <python@mrabarnett.plus.com> - 2016-06-26 16:41 +0100
Re: Assignment Versus Equality BartC <bc@freeuk.com> - 2016-06-26 17:08 +0100
Re: Assignment Versus Equality Christopher Reimer <christopher_reimer@icloud.com> - 2016-06-26 11:53 -0700
Re: Assignment Versus Equality Gregory Ewing <greg.ewing@canterbury.ac.nz> - 2016-06-27 11:41 +1200
Re: Assignment Versus Equality Gregory Ewing <greg.ewing@canterbury.ac.nz> - 2016-06-27 11:22 +1200
Re: Assignment Versus Equality BartC <bc@freeuk.com> - 2016-06-27 00:39 +0100
Re: Assignment Versus Equality Gregory Ewing <greg.ewing@canterbury.ac.nz> - 2016-06-28 18:15 +1200
Page 2 of 5 — ← Prev page 1 [2] 3 4 5 Next page →
| From | Chris Angelico <rosuav@gmail.com> |
|---|---|
| Date | 2016-06-28 17:26 +1000 |
| Message-ID | <mailman.65.1467098776.2358.python-list@python.org> |
| In reply to | #110663 |
On Tue, Jun 28, 2016 at 5:12 PM, Lawrence D’Oliveiro
<lawrencedo99@gmail.com> wrote:
> <https://github.com/ldo/dvd_menu_animator/blob/master/spuhelper.c>.
do { /* once */
if (error) break;
...
} while (false);
do_cleanup;
Why not:
if (error) goto cleanup;
...
cleanup:
do_cleanup;
Oh, right. XKCD 292. I still think it's better to use the goto, though
- you just need velociraptor repellent.
ChrisA
[toc] | [prev] | [next] | [standalone]
| From | Lawrence D’Oliveiro <lawrencedo99@gmail.com> |
|---|---|
| Date | 2016-06-28 01:49 -0700 |
| Message-ID | <01ed522b-71d6-4535-8d49-b0e32c33ee3a@googlegroups.com> |
| In reply to | #110664 |
On Tuesday, June 28, 2016 at 7:26:30 PM UTC+12, Chris Angelico wrote: > Why not: > > if (error) goto cleanup; > ... > cleanup: > do_cleanup; They all fall into that same trap. Doesn’t scale. Try one with allocation inside a loop, e.g. lines 488 onwards.
[toc] | [prev] | [next] | [standalone]
| From | Chris Angelico <rosuav@gmail.com> |
|---|---|
| Date | 2016-06-28 20:34 +1000 |
| Message-ID | <mailman.70.1467110107.2358.python-list@python.org> |
| In reply to | #110673 |
On Tue, Jun 28, 2016 at 6:49 PM, Lawrence D’Oliveiro <lawrencedo99@gmail.com> wrote: > On Tuesday, June 28, 2016 at 7:26:30 PM UTC+12, Chris Angelico wrote: >> Why not: >> >> if (error) goto cleanup; >> ... >> cleanup: >> do_cleanup; > > They all fall into that same trap. Doesn’t scale. Try one with allocation inside a loop, e.g. lines 488 onwards. How is that different? You can use a goto inside a for loop just fine. (You can even, if you are absolutely insane and begging to be murdered by the future maintainer, use a goto outside a for loop targeting a label inside. See for example Duff's Device, although that's a switch rather than an actual goto.) You have a loop, and inside that loop, the exact same error handling pattern; so it should be possible to perform the exact same transformation, albeit with a differently-named local cleanup label. So, yes. It doesn't scale, if by "scale" you mean "so many separate local instances of error handling that you lose track of your cleanup labels". But you should be able to keep half a dozen labels in your head (if they're named appropriately), and if you have that many local error handlers, you probably want something to be refactored. ChrisA
[toc] | [prev] | [next] | [standalone]
| From | Lawrence D’Oliveiro <lawrencedo99@gmail.com> |
|---|---|
| Date | 2016-06-28 17:42 -0700 |
| Message-ID | <1b05c0b1-95b6-4b7c-9d2f-a28fcdaaf44d@googlegroups.com> |
| In reply to | #110678 |
On Tuesday, June 28, 2016 at 10:35:21 PM UTC+12, Chris Angelico wrote: > On Tue, Jun 28, 2016 at 6:49 PM, Lawrence D’Oliveiro wrote: > > On Tuesday, June 28, 2016 at 7:26:30 PM UTC+12, Chris Angelico wrote: >>> Why not: >>> >>> if (error) goto cleanup; >>> ... >>> cleanup: >>> do_cleanup; >> >> They all fall into that same trap. Doesn’t scale. Try one with >> allocation inside a loop, e.g. lines 488 onwards. > > How is that different? You can use a goto inside a for loop just fine. You have my code; show us how you can do better.
[toc] | [prev] | [next] | [standalone]
| From | Random832 <random832@fastmail.com> |
|---|---|
| Date | 2016-06-28 10:13 -0400 |
| Message-ID | <mailman.82.1467123199.2358.python-list@python.org> |
| In reply to | #110642 |
On Tue, Jun 28, 2016, at 00:31, Rustom Mody wrote:
> GG downgrades posts containing unicode if it can, thereby increasing
> reach to recipients with unicode-broken clients
That'd be entirely reasonable, except for the excessively broad
application of "if it can".
Certainly it _can_ do it all the time. Just replace anything that
doesn't fit with question marks or hex notation or \N{NAME} or some
human readable pseudo-representation a la unidecode. It could have done
any of those with the Hindi that you threw in to try to confound it, (or
it could have chosen ISCII, which likewise lacks arrow characters, as
the encoding to downgrade to).
It should pick an encoding which it expects recipients to support and
which contains *all* of the characters in the message, as proper
characters and not as pseudo-representations, and downgrade to that if
and only if such an encoding can be found. For most messages, it can use
US-ASCII. For most of the remainder it can use some ISO-8859 or
Windows-125x encoding.
Or include the UTF-8 and some other character set as
multipart/alternative representations.
[toc] | [prev] | [next] | [standalone]
| From | Marko Rauhamaa <marko@pacujo.net> |
|---|---|
| Date | 2016-06-28 19:39 +0300 |
| Message-ID | <87bn2lnu7g.fsf@elektro.pacujo.net> |
| In reply to | #110701 |
(sorry for the premature previous post)
Random832 <random832@fastmail.com>:
> All objects, not just black holes, have those properties. The point
> here is that we are in fact observing those properties of an object
> that is not yet (and never will be) a black hole in our frame of
> reference.
A physicist once clarified to me that an almost-black-hole is
practically identical with a black hole because all information about
anything falling in is very quickly red-shifted to oblivion.
However, there is some information that (to my knowledge) is not
affected by the red shift. Here's a thought experiment:
----------
/ \
/ (almost) \ N
| black | |
| hole | S
\ /
\ /
----------
We have a stationary, uncharged (almost) black hole in our vicinity and
decide to send in a probe. We first align the probe so it is perfectly
still wrt the black hole and let it fall in. Inside the probe, we have a
powerful electrical magnet that our compass can detect from a safe
distance away. The probe is also sending us a steady ping over the
radio.
As the probe approaches the event horizon, the ping frequency falls
drastically and the signal frequency is red-shifted below our ability to
receive. However, our compass still points to the magnet and notices
that it "floats" on top of the event horizon:
----------
/ \
/ (almost) \ N
| black ||
| hole |S
\ /
\ /
----------
/
/ compass needle
/
The compass needle shows that the probe is "frozen" and won't budge no
matter how long we wait.
Marko
[toc] | [prev] | [next] | [standalone]
| From | Marko Rauhamaa <marko@pacujo.net> |
|---|---|
| Date | 2016-06-28 19:41 +0300 |
| Message-ID | <877fd9nu4y.fsf@elektro.pacujo.net> |
| In reply to | #110715 |
Marko Rauhamaa <marko@pacujo.net>: > (sorry for the premature previous post) Screw it! Wrong thread! Marko
[toc] | [prev] | [next] | [standalone]
| From | Random832 <random832@fastmail.com> |
|---|---|
| Date | 2016-06-28 13:19 -0400 |
| Message-ID | <mailman.88.1467134346.2358.python-list@python.org> |
| In reply to | #110715 |
On Tue, Jun 28, 2016, at 12:39, Marko Rauhamaa wrote: > A physicist once clarified to me that an almost-black-hole is > practically identical with a black hole because all information about > anything falling in is very quickly red-shifted to oblivion. Subject to some definition of "quickly" and "oblivion", I expect.
[toc] | [prev] | [next] | [standalone]
| From | Ian Kelly <ian.g.kelly@gmail.com> |
|---|---|
| Date | 2016-06-28 12:27 -0600 |
| Message-ID | <mailman.92.1467138503.2358.python-list@python.org> |
| In reply to | #110715 |
On Tue, Jun 28, 2016 at 10:39 AM, Marko Rauhamaa <marko@pacujo.net> wrote: > > (sorry for the premature previous post) > > Random832 <random832@fastmail.com>: >> All objects, not just black holes, have those properties. The point >> here is that we are in fact observing those properties of an object >> that is not yet (and never will be) a black hole in our frame of >> reference. > > A physicist once clarified to me that an almost-black-hole is > practically identical with a black hole because all information about > anything falling in is very quickly red-shifted to oblivion. > > However, there is some information that (to my knowledge) is not > affected by the red shift. Here's a thought experiment: > > ---------- > / \ > / (almost) \ N > | black | | > | hole | S > \ / > \ / > ---------- > > We have a stationary, uncharged (almost) black hole in our vicinity and > decide to send in a probe. We first align the probe so it is perfectly > still wrt the black hole and let it fall in. Inside the probe, we have a > powerful electrical magnet that our compass can detect from a safe > distance away. The probe is also sending us a steady ping over the > radio. > > As the probe approaches the event horizon, the ping frequency falls > drastically and the signal frequency is red-shifted below our ability to > receive. However, our compass still points to the magnet and notices > that it "floats" on top of the event horizon: > > ---------- > / \ > / (almost) \ N > | black || > | hole |S > \ / > \ / > ---------- > > > / > / compass needle > / > > The compass needle shows that the probe is "frozen" and won't budge no > matter how long we wait. I'm skeptical of this. As the ping frequency falls drastically due to relativistic effects, so too does the observed current powering the electromagnet, does it not?
[toc] | [prev] | [next] | [standalone]
| From | Marko Rauhamaa <marko@pacujo.net> |
|---|---|
| Date | 2016-06-28 22:40 +0300 |
| Message-ID | <87twgdm79b.fsf@elektro.pacujo.net> |
| In reply to | #110722 |
Ian Kelly <ian.g.kelly@gmail.com>: > On Tue, Jun 28, 2016 at 10:39 AM, Marko Rauhamaa <marko@pacujo.net> wrote: >> Inside the probe, we have a powerful electrical magnet that our >> compass can detect from a safe distance away. >> >> [...] >> >> The compass needle shows that the probe is "frozen" and won't budge no >> matter how long we wait. > > I'm skeptical of this. As the ping frequency falls drastically due to > relativistic effects, so too does the observed current powering the > electromagnet, does it not? Actually, that would be a great question for a physicist to resolve. Next question: would a permanent magnet make any difference? I admit I changed my thought experiment at the last minute to use a magnet instead of a charge because I could more realistically imagine a powerful magnet and a simple detector. That may have been a mistake. A charge, however, would do the "floating" I presume. It's difficult to find a straight answer online. The topic of a charge falling into a black hole is addressed from one angle at: <URL: http://adsabs.harvard.edu/full/1971PASP...83..633R> This is from an answer by a guy who says he's got a PhD in general relativity: there's no problem with information falling IN to a black hole, which is allowed to externally display it's mass, charge, angular momentum and linear momentum, all of which get inprinted on the horizon as matter falls in <URL: http://physics.stackexchange.com/questions/6432/gravitational-r edshift-of-virtual-photons> Again, I'd like a physicist to give a straight answer. Marko
[toc] | [prev] | [next] | [standalone]
| From | Gene Heskett <gheskett@shentel.net> |
|---|---|
| Date | 2016-06-28 16:59 -0400 |
| Message-ID | <mailman.93.1467148292.2358.python-list@python.org> |
| In reply to | #110724 |
On Tuesday 28 June 2016 15:40:48 Marko Rauhamaa wrote: > Ian Kelly <ian.g.kelly@gmail.com>: > > On Tue, Jun 28, 2016 at 10:39 AM, Marko Rauhamaa <marko@pacujo.net> wrote: > >> Inside the probe, we have a powerful electrical magnet that our > >> compass can detect from a safe distance away. > >> > >> [...] > >> > >> The compass needle shows that the probe is "frozen" and won't budge > >> no matter how long we wait. > > > > I'm skeptical of this. As the ping frequency falls drastically due > > to relativistic effects, so too does the observed current powering > > the electromagnet, does it not? > > Actually, that would be a great question for a physicist to resolve. > Next question: would a permanent magnet make any difference? > > I admit I changed my thought experiment at the last minute to use a > magnet instead of a charge because I could more realistically imagine > a powerful magnet and a simple detector. That may have been a mistake. > > A charge, however, would do the "floating" I presume. It's difficult > to find a straight answer online. The topic of a charge falling into a > black hole is addressed from one angle at: > > <URL: http://adsabs.harvard.edu/full/1971PASP...83..633R> > > > This is from an answer by a guy who says he's got a PhD in general > relativity: > > there's no problem with information falling IN to a black hole, > which is allowed to externally display it's mass, charge, angular > momentum and linear momentum, all of which get inprinted on the > horizon as matter falls in > > <URL: > http://physics.stackexchange.com/questions/6432/gravitational-r > edshift-of-virtual-photons> > > Again, I'd like a physicist to give a straight answer. > > > Marko I am not a physicist, but consider this: At the event horizon, which is that point where the mass of the probe has become very near infinite because it is moving very very close to the speed of light, time also becomes stretched by the same effect, so that in the probe as it falls thru the event horizon, time is so stretched that for the people in the probe, everything matches up and to them it took perhaps a microsecond to fall past the horizon. But to an external observer, its entirely possible that the probe is frozen at the horizon because the infinite mass prevents the infall from completion for billions of our years. In fact, I'd say that it will eventually sink thru and disappear, but it will do so because the holes event horizon will grow as it absorbs the mass of other things its pulling in, placeing the probe inside the horizon without the probe moving inward. Somewhere in all that math that breaks down inside the event horizon, is probably the reason that well fed black holes are also ejecting matter from their rotational axis, surplus because the event horizon is also subject to the infinite limitation, and because its "stuck" the surplus matter over and above that which creates the event horizon, is ejected from the poles of its spin axis. We have millions of examples of that in the visible universe. Just be glad as can be that we don't have one for a neighbor that could point one of those beams at earth from 10 ly away. Instant planet wide sterilization. Cheers, Gene Heskett -- "There are four boxes to be used in defense of liberty: soap, ballot, jury, and ammo. Please use in that order." -Ed Howdershelt (Author) Genes Web page <http://geneslinuxbox.net:6309/gene>
[toc] | [prev] | [next] | [standalone]
| From | Gregory Ewing <greg.ewing@canterbury.ac.nz> |
|---|---|
| Date | 2016-06-30 12:29 +1200 |
| Message-ID | <dtj7g7Fpla2U1@mid.individual.net> |
| In reply to | #110715 |
Marko Rauhamaa wrote: > ---------- > / \ > / (almost) \ N > | black || > | hole |S > \ / > \ / > ---------- > > > / > / compass needle > / > > The compass needle shows that the probe is "frozen" and won't budge no > matter how long we wait. All your experiment shows is that the last information we had about the magnet is that it was nearly stationary just above the horizon. It doesn't prove that the probe itself is frozen, any more than the fact that a photograph you took of something last month doesn't move proves that the object you photographed is stuck in the state it was in a month ago. Keep in mind that changes in the magnetic field propagate at the speed of light and are subject to the same redshift, etc. as any other signal. It doesn't matter whether you use a permanent magnet, an electric charge, or coconuts banged together in morse code, relativity still applies. -- Greg
[toc] | [prev] | [next] | [standalone]
| From | Steven D'Aprano <steve@pearwood.info> |
|---|---|
| Date | 2016-06-30 12:50 +1000 |
| Message-ID | <577488e7$0$1589$c3e8da3$5496439d@news.astraweb.com> |
| In reply to | #110792 |
On Thu, 30 Jun 2016 10:29 am, Gregory Ewing wrote: > All your experiment shows is that the last information we had > about the magnet is that it was nearly stationary just above > the horizon. > > It doesn't prove that the probe itself is frozen, any more than > the fact that a photograph you took of something last month > doesn't move proves that the object you photographed is > stuck in the state it was in a month ago. The easy way to see that it isn't frozen in place is to try to fly down to meet it. > Keep in mind that changes in the magnetic field propagate at > the speed of light and are subject to the same redshift, etc. > as any other signal. It doesn't matter whether you use a > permanent magnet, an electric charge, or coconuts banged > together in morse code, relativity still applies. An electric charge is a much better approach. Because it is a monopole, it is detectable from a distant more easily than a magnetic bipole, and while magnets are going to be vaporised into plasma (hence losing their magnetic field), electrons are electrons (at least until you get into the quantum gravity regime, at which point we don't know what happens). -- Steven “Cheer up,” they said, “things could be worse.” So I cheered up, and sure enough, things got worse.
[toc] | [prev] | [next] | [standalone]
| From | Marko Rauhamaa <marko@pacujo.net> |
|---|---|
| Date | 2016-06-30 09:22 +0300 |
| Message-ID | <87d1mzmc1h.fsf@elektro.pacujo.net> |
| In reply to | #110792 |
Gregory Ewing <greg.ewing@canterbury.ac.nz>: > All your experiment shows is that the last information we had about > the magnet is that it was nearly stationary just above the horizon. > > It doesn't prove that the probe itself is frozen, any more than the > fact that a photograph you took of something last month doesn't move > proves that the object you photographed is stuck in the state it was > in a month ago. Interaction defines scientific reality. Things that don't interact don't exist. Call it cosmic duck-typing: you are what you appear to be. Marko
[toc] | [prev] | [next] | [standalone]
| From | Steven D'Aprano <steve@pearwood.info> |
|---|---|
| Date | 2016-06-29 12:27 +1000 |
| Message-ID | <57733227$0$1608$c3e8da3$5496439d@news.astraweb.com> |
| In reply to | #110701 |
On Wed, 29 Jun 2016 12:13 am, Random832 wrote:
> On Tue, Jun 28, 2016, at 00:31, Rustom Mody wrote:
>> GG downgrades posts containing unicode if it can, thereby increasing
>> reach to recipients with unicode-broken clients
>
> That'd be entirely reasonable, except for the excessively broad
> application of "if it can".
>
> Certainly it _can_ do it all the time. Just replace anything that
> doesn't fit with question marks or hex notation or \N{NAME} or some
> human readable pseudo-representation a la unidecode. It could have done
> any of those with the Hindi that you threw in to try to confound it, (or
> it could have chosen ISCII, which likewise lacks arrow characters, as
> the encoding to downgrade to).
Are you suggesting that email clients and newsreaders should silently mangle
the text of your message behind your back? Because that's what it sounds
like you're saying.
I understand technical limitations. If I'm using a client that can't cope
with anything but (say) ISCII or Latin-1, then I'm all out of luck if I
want to write an email containing Greek or Cyrillic. I get that.
But if the client allows me to type Greek or Cyrillic into the editor, and
then accepts that message for sending, and it mangles it into "question
marks or hex notation or \N{NAME}" (for example), that's a disgrace and
completely unacceptable.
Yes, software *is capable of doing so*, in the same way that software is
capable of deleting all the vowels from your post, or replacing the
word "medieval" with "medireview":
http://northernplanets.blogspot.com.au/2007/01/medireview.html
This is not a good idea.
> It should pick an encoding which it expects recipients to support and
> which contains *all* of the characters in the message,
That would be UTF-8. That's a no-brainer. Why would you use any other
encoding?
If you use UTF-8, it just works. It supports the *entire* Unicode character
set, which is a superset of virtually all code pages and encodings you are
likely to encounter in practice. (No, your software probably isn't running
on a 1980s vintage Atari, and if you're in Japan using TRON you've got your
own software.) And your text widget or editor surely supports Unicode,
because if it didn't, the user couldn't type those Hindi or Greek letters.
So there's an obvious, sensible algorithm:
- take the user's Unicode text, and encode it to UTF-8
In pseudo-code:
content = text.encode('utf-8')
And there's the actual algorithm used by mail clients and newsreaders:
- take the user's Unicode text, and try encoding it as a variety of
different encodings (US-ASCII, Latin-1, maybe a few others); if they fail,
then fall back to UTF-8
Or in pseudo-code:
list_of_encodings = ['US-ASCII', 'Latin-1', ...]
for encoding in list_of_encodings:
try:
content = text.encode(encoding)
break
except UnicodeEncodingError:
pass
else:
content = text.encode('utf-8')
Why would you write the second instead of the first? It's just *dumb code*.
Maybe 20 year old applications could be excused for thinking that this
newfangled Unicode thing should be the last resort instead of the code page
system, but its 2016 now and code pages are just holding us back.
This is *especially* egregious since UTF-8 text containing only ASCII
characters is (by design) indistinguishable from US-ASCII, so even if there
is some application out there from 1980 that can only cope with ASCII, your
UTF-8 email will be perfectly readable to the degree that it only
uses "plain text".
> as proper
> characters and not as pseudo-representations, and downgrade to that if
> and only if such an encoding can be found. For most messages, it can use
> US-ASCII. For most of the remainder it can use some ISO-8859 or
> Windows-125x encoding.
There's never any need to downgrade to a non-Unicode encoding, at least not
by default. Well, maybe in Asia, I don't know how well Asian software
supports Unicode.
--
Steven
“Cheer up,” they said, “things could be worse.” So I cheered up, and sure
enough, things got worse.
[toc] | [prev] | [next] | [standalone]
| From | Rustom Mody <rustompmody@gmail.com> |
|---|---|
| Date | 2016-06-28 20:52 -0700 |
| Message-ID | <3d06b35d-c437-48e7-916f-16eeae99e8ff@googlegroups.com> |
| In reply to | #110741 |
On Wednesday, June 29, 2016 at 7:58:04 AM UTC+5:30, Steven D'Aprano wrote:
> On Wed, 29 Jun 2016 12:13 am, Random832 wrote:
>
> > On Tue, Jun 28, 2016, at 00:31, Rustom Mody wrote:
> >> GG downgrades posts containing unicode if it can, thereby increasing
> >> reach to recipients with unicode-broken clients
> >
> > That'd be entirely reasonable, except for the excessively broad
> > application of "if it can".
> >
> > Certainly it _can_ do it all the time. Just replace anything that
> > doesn't fit with question marks or hex notation or \N{NAME} or some
> > human readable pseudo-representation a la unidecode. It could have done
> > any of those with the Hindi that you threw in to try to confound it, (or
> > it could have chosen ISCII, which likewise lacks arrow characters, as
> > the encoding to downgrade to).
>
> Are you suggesting that email clients and newsreaders should silently mangle
> the text of your message behind your back? Because that's what it sounds
> like you're saying.
>
> I understand technical limitations. If I'm using a client that can't cope
> with anything but (say) ISCII or Latin-1, then I'm all out of luck if I
> want to write an email containing Greek or Cyrillic. I get that.
>
> But if the client allows me to type Greek or Cyrillic into the editor, and
> then accepts that message for sending, and it mangles it into "question
> marks or hex notation or \N{NAME}" (for example), that's a disgrace and
> completely unacceptable.
>
> Yes, software *is capable of doing so*, in the same way that software is
> capable of deleting all the vowels from your post, or replacing the
> word "medieval" with "medireview":
>
> http://northernplanets.blogspot.com.au/2007/01/medireview.html
>
> This is not a good idea.
Yeah
I remember it silently converted «guillemets» to <<guillemets>>
[This is an experiment :-) ]
[toc] | [prev] | [next] | [standalone]
| From | Rustom Mody <rustompmody@gmail.com> |
|---|---|
| Date | 2016-06-28 21:03 -0700 |
| Message-ID | <a7b13069-187a-4ee2-9624-4f1f9d75cb16@googlegroups.com> |
| In reply to | #110744 |
On Wednesday, June 29, 2016 at 9:27:44 AM UTC+5:30, Rustom Mody wrote: > On Wednesday, June 29, 2016 at 7:58:04 AM UTC+5:30, Steven D'Aprano wrote: > > This is not a good idea. > [This is an experiment :-) ] Um... So now its working ie the offensive behavior (to me also) that Steven described is not the case any more?? Or did I mis-remember which characters it mauls and which leaves alone Maybe a ‹single guillemet› ?
[toc] | [prev] | [next] | [standalone]
| From | Random832 <random832@fastmail.com> |
|---|---|
| Date | 2016-06-29 00:52 -0400 |
| Message-ID | <mailman.97.1467175960.2358.python-list@python.org> |
| In reply to | #110741 |
On Tue, Jun 28, 2016, at 22:27, Steven D'Aprano wrote: > Are you suggesting that email clients and newsreaders should silently > mangle the text of your message behind your back? Because that's what > it sounds like you're saying. That was how I was characterizing Rustom Mody's position; he seemed to be justifying a supposed "feature" of Google Groups to mangle Unicode arrow characters into ASCII pseudorepresentations such as <- and ->.
[toc] | [prev] | [next] | [standalone]
| From | Lawrence D’Oliveiro <lawrencedo99@gmail.com> |
|---|---|
| Date | 2016-06-27 18:14 -0700 |
| Message-ID | <18475c25-543d-42b8-a2bf-905cfe681e18@googlegroups.com> |
| In reply to | #110590 |
On Tuesday, June 28, 2016 at 2:23:16 AM UTC+12, Rustom Mody wrote: > python 2 → 3 making breaking changes but not going beyond ASCII lexemes? You do know Python 3 allows Unicode letters in identifiers, right?
[toc] | [prev] | [next] | [standalone]
| From | Gene Heskett <gheskett@shentel.net> |
|---|---|
| Date | 2016-06-27 11:21 -0400 |
| Message-ID | <mailman.39.1467042263.2358.python-list@python.org> |
| In reply to | #110576 |
On Monday 27 June 2016 09:28:00 Steven D'Aprano wrote: > On Mon, 27 Jun 2016 10:48 pm, Rustom Mody wrote: > > PS Google Groups is wise enough to jump through hoops trying to > > encode my message above as latin-1, then as Windows 1252 and only > > when that does not work as UTF-8 > > There is nothing admirable about GG (or any other newsreader or email > client) defaulting to legacy encodings like Latin-1 and especially not > Windows 1252. > > Certainly the user should be permitted to explicitly set the encoding, > but otherwise the program should default to UTF-8. > Both of you mentioned 2 bad words, now go and warsh yer fungers with some of grandma's lye soap. > > -- > Steven > “Cheer up,” they said, “things could be worse.” So I cheered up, and > sure enough, things got worse. Cheers, Gene Heskett -- "There are four boxes to be used in defense of liberty: soap, ballot, jury, and ammo. Please use in that order." -Ed Howdershelt (Author) Genes Web page <http://geneslinuxbox.net:6309/gene>
[toc] | [prev] | [next] | [standalone]
Page 2 of 5 — ← Prev page 1 [2] 3 4 5 Next page →
Back to top | Article view | comp.lang.python
csiph-web