Recent content by Well_InTheory

  1. W

    Command line argument in fortarn 77

    (at least in Intel's compiler, specifically f90) I use call getarg(1,buffer) read(buffer,*) variable to read from the input, i.e. $ ./my_program abc to set 'variable' to abc...
  2. W

    Problem on atomic spectra of H-atoms

    We're just talking about the spectrum due to the atom here. This depends on your knowledge level, but since this is a homework question, I'm guessing you have learned a little on the fact that the Hydrogen atom has discrete energy levels. Depending on where (in terms of energy level) the...
  3. W

    Problem on atomic spectra of H-atoms

    What do you know about the energy levels that the electron can be in? Ground state? Excited state? Are these continuous? ...
  4. W

    Question about mathematics commands

    I don't think I follow... This is a command // remove this bit in PHP (or C++) This is a command ! remove this bit in Fortran This is a command (* remove this bit in Mathematica *) This is a command /* remove this bit in C */ The start and end braces mean you can have it mid-line, whereas the...
  5. W

    Question about mathematics commands

    You mean comment out a line? (* This is a Mathematica comment *)
  6. W

    Fortran Fortran: Writes to screen, not to file

    Is your file writable? (check directory permissions) Also, I'd add a status='unknown' to the open command to make sure it's not worried about overwriting. Tried printing the values of ist1,ist2 to screen with a print command at the same time? Tried watching the file real-time to make sure...
  7. W

    Fortran Help with FORTRAN: 200,100,100 & 1H1 Interpretation

    http://en.wikipedia.org/wiki/Arithmetic_IF IF (expression) negative,zero,positive
  8. W

    Strange indexing in Fortran Code

    The formatting of the data file is irrelevant - the entries could all be in a single column for all Fortran cares, as long as it knows how to read it. Since the third index only runs over [1,2] you could simply have two blocks of code for which in each you hold that last index fixed. The...
  9. W

    Strange indexing in Fortran Code

    Well, it *IS* ambiguous to read if you don't inherently know the rule it will go by, made worse that the choice to have 4 datum per line is thus entirely arbitrary. Especially if you're more used to an iterated approach which might fill a series of 1D arrays where the data progresses down a...
  10. W

    Strange indexing in Fortran Code

    The fact that it's 3D isn't a problem - that last dimension just corresponds to whether the variable will multiply RR1 or RR2, my problem is that given the do-loops, ALL of the elements should be populated, but there's complete ambiguity over which will get filled when. Note: as long as the...
  11. W

    Strange indexing in Fortran Code

    6. dimension FF0(988),xm0(441),F2(13,76,2),FM3(9,49,2) declares the variables F2 and FM3 to be arrays with the listed dimensions. 15. read(77,'(4E16.8)') F2,FM3 reads the values into the variables according to the style (4E16.8) i.e. 4 blocks of E16.8 data, as you see in the data...
  12. W

    Undergrad Is the Gambler's Fallacy Really a Fallacy?

    No. This statement is exactly the gambler's fallacy. You will win exactly 50% of the time. The chances of BBBBBBBBBBB is the same as BBBBBBBBBBR. Pick any specific 11-long sequence and it will have the same probability of any other 11-long sequence. Turning your thought-experiment...
  13. W

    Undergrad Is the Gambler's Fallacy Really a Fallacy?

    You're still arguing that 'regression to the mean' is enforced by some higher power. i.e. Given that highly unlikely events are usually followed by less unlikely events, you are saying it is because 'nature demands it' while in truth it's just that the probability that two unlikely events...
  14. W

    Undergrad Is the Gambler's Fallacy Really a Fallacy?

    Baye's Theorem (conditional probability) solves this one. The chances of red (R) and black (B) are the same, so P(R) = P(B) = 0.5 The same goes for any string of reds or blacks, with probability P(nR) = P(nB) = \frac{1}{2^n} You want the probability of the (n+1)th result being...