de Broglie wavelengths

For PC type software that runs under some PC opsys.

de Broglie wavelengths

Postby Doug Coulter » Fri Dec 06, 2013 9:00 pm

I wrote some code to do this for either electrons or nuclei. More words about it here.

But in case you're too lazy to follow that link, here it is in the "right" place. Well, that's the problem - there are a few "right places" on the board, no organization system can be perfect when things inter-relate.

Yeah, it's in perl. That means if you've got linux or mac os, you're ready to run this. As the joke goes "this software requires windows 98 or better to run" - so I installed linux instead. There is more than one free distribution of perl for windows. Active-state and DWIM perl come to mind. I'm not fond of active-state's module manager - it's so slooow when you invoke it, you think your computer locked up, even a fast one you go minutes with no progess shown at all - crap code (not all free code is crap, but activestate's is in this case), even though their perl is generally newer and it comes with more modules installed already. I'm playing with Padre's perl IDE, which comes with DWIM (strawberry perl) now, but I "don't do windows" much at all anymore.

Here's the (remember, programmer efficiency counts too - so I was lazy/sloppy - but correct) code.
debroglie.zip
simple perl program for de Broglie wavelengths of stuff.
Oops, has a bug, a missing e-24 in the amu constant.
(832 Bytes) Downloaded 302 times


*I* was too lazy and didn't check all my constants. Here it is fixed. Probably needless to say, an error of e24 in a constant does affect the results a good bit.
So, here's the corrected version:
debroglie2.zip
Bug fixed...sigh
(889 Bytes) Downloaded 305 times
Posting as just me, not as the forum owner. Everything I say is "in my opinion" and YMMV -- which should go for everyone without saying.
User avatar
Doug Coulter
 
Posts: 3515
Joined: Wed Jul 14, 2010 7:05 pm
Location: Floyd county, VA, USA

Return to PC

Who is online

Users browsing this forum: No registered users and 2 guests

cron