Thursday, July 1, 2010

Feeling a little FOR Loop-y

Debugging is hard. Especially with FOR loops.

I have one file that creates the most beautiful simulated CMDs of a given absolute magnitude (the absolute magnitude of And XIX, to be exact), projected to five different distances. The issue is, the code was long and sloppy. I was hoping to condense the code using a FOR loop in a different file, but I've been banging my head against some error messages all morning. Every time I make progress and fix a problem, another one pops up. I'd really like to learn how to debug this more efficiently so I can have more efficient code!

However, we have to think positiviely-- my coding is becoming pretty sophisticated, and that's definitely something to be proud of. This code utilizes three different functions written to simulate different aspects of these dwarfs. It's pretty great that I'm able to do that.

... Now I just have to get to the next step...

1 comment:

  1. UPDATE: no more error messages, but it's not giving me the right output, either... progress?