Want to read Slashdot from your mobile device? Point it at m.slashdot.org and keep reading!

 



Forgot your password?
typodupeerror
×

Comment IDL language (Score 3, Interesting) 729

Odd integers are true; even integers are false.

Arrays can be indexed with () or []. This leads to namespace problems with functions which are also called with (). For example:
x=a(1,2)
error: undefined variable a.
If you want to call function a, you have to forward declare it for this reason.
There's a different syntax for procedures (which don't have a return value) and functions (which do).

It is required to assign the result of a function to something. You have to write
dummy = foo(1,2,3)
as writing
foo(1,2,3)
will give an error.

Most of the time, a single element array is treated the same as a scalar. But not always, and not being very careful will lead to weird errors.
There are no zero length arrays.
An array can be length 1; a multidimensional array can be length [1,2,2], but a multidimensional array cannot be length [2,1,1]. If the last dimension has length 1, it simply vanishes to a smaller dimension, unless already 1 dimensional. Example:
a = make_array(1,2,2)
; a has dimensions [1,2,2]
a = make_array(2,1,1)
; a has dimensions [2]
This means special code must be written to handle any array operations that might end with last dimension 1.

Array slices are weird.
b = a[3,*,2]
means to take a slice of a along the second dimension. I'd expect the answer to be 1 dimensional, since there's only 1 scan in the slice. But the result has dimensions [1,3]
On the other hand, a[3,2,*] has dimensions [1,1,3], and a[*,3,2] has dimensions [3]. It makes sense in a convoluted way, but it sucks.

Businesses

Dramatic Shifts In Manufacturing Costs Are Driving Companies To US, Mexico 233

hackingbear writes: According to a new Cost-Competitiveness Index, the nations often perceived as having low manufacturing costs — such as China, Brazil, Russia, and the Czech Republic — are no longer much cheaper than the U.S. In some cases, they are estimated to be even more expensive. Chinese manufacturing wages have nearly quintupled since 2004, while Mexican wages have risen by less than 50 percent in U.S. dollar terms, contrary to our long-standing misconception that their labors were being slaved. In the same period, the U.S. wage is essentially flat, whereas Mexican wages have risen only 67%. Not all countries are taking full advantage of their low-cost advantages, however. The report found that global competiveness in manufacturing is undermined in nations such as India and Indonesia by several factors, including logistics, the overall ease of doing business, and inflexible labor markets.

Comment Re:Limits of Measurement (Score 2) 144

This isn't a perfect analogy, but think of a kink in the carpet. You can push it around, like a object, but you can't make it disappear without taking out some slack in the carpet. Now if we define this kink as a particle, it IS a particle. Using this definition, the particle doesn't have a precise position, nor a rigid shape. But a quantum particle isn't at all like a classical big object, which still has a precise position although it is extended over space. The difference is that a quantum particle appears to be a point particle whenever you look at it, located randomly on a screen in a region where the screen intersects the quantum particle wavefunction. That is, the wavefunction can be so large that the particle basically should cover the whole screen, but we only see a single dot on the screen somewhere. By 'appears to be a point', I mean that the particle collapses onto the resolution of the screen, no matter how high resolution the screen has, to the limits which we can make screens, and a single particle won't excite two neighboring screen pixels at once. Unfortunately, I don't think there's any way to understand this classically.

Comment Re:Limits of Measurement (Score 5, Informative) 144

IAAPhysicist. Parent isn't correct. I advise you to not worry too much about what is "real" and accept that physics looks for simple models which match our experiences. You need to think abstractly, and assume less. For example, everyone grows up with some intuition of what an object is, and then project that notion into realms where they don't apply. The letters on this webpage, for example.... These are black objects which move up and down when you scroll the page. Or, is it really the white spaces between the letters which are the real objects, and the black is just void? Actually both are wrong, and the "reality" is that your monitor is doing certain things, depending on how deep you want to look.

When physicists talk about a particle, they are talking about the smallest step in the amplitude of the fluctuation in some field or combination of fields. A fluctuation doesn't have to be purely one kind of field; for example, a phonon is made out of collective motions of atoms, and polaritons are sort of some mix of photon and phonon. These could be considered particles (but not fundamental particles). This isn't the only way to think about a particle (since it's all just a model anyways), but it is more accurate than billiard balls.

Heisenburg uncertainty principle exists because you are trying to pinpoint a fluctuation in fields which occupy all space.

Parent's description of the double slit experiment is fully wrong. Electrons do not interfere with some build up of electrons. Electrons interfere with themselves, because the fluctuation (which is the electron) exists in the full region between the source and screen. The interference pattern is the same no matter how slowly (in terms of electron rate) you fire the electrons, so build up is not a concern. A similar interference pattern exists in photons and neutrons as well, which aren't charged.

Comment Re:Mostly done by 1985... (Score 1) 227

From the perspective of someone falling in, the time to reach the singularity is not only finite, but quite short.

Assuming a static black hole exists in the first place. What if the black hole is changing on the time scale of the person falling in?

The Schwarzchild metric assumes that the mass distribution is stationary over some infinite duration. If black holes evaporate, then won't it evaporate before the person reaches it? What about cosmic expansion?

Slashdot Top Deals

Genetics explains why you look like your father, and if you don't, why you should.

Working...