Sunday, March 3, 2019

Martian dust / soil

Back in 1990, I had just graduated from high school and was working for Bill Borucki at NASA Ames.  I wrote a report on Martian Dust and electrical charge/discharge.  I remember working so hard on that report trying to figure out how to do background research and digging through the NASA libraries.  For all that hard work, I didn't end up with much.  My report is painful to read now.  It's full of typos and doesn't actually say much.  Now we have wikipedia and there are these:


And so on and so forth...

Grains in desert sandstorms spontaneously generate strong electrical charges; likewise volcanic dust plumes produce spectacular lightning displays. Charged particle clouds also cause devastating explosions in food, drug and coal processing industries. Despite the wide-ranging importance of granular charging in both nature and industry, even the simplest aspects of its causes remain elusive, because it is difficult to understand how inert grains in contact with little more than other inert grains can generate the large charges observed. Here, we present a simple yet predictive explanation for the charging of granular materials in collisional flows. We argue from very basic considerations that charge transfer can be expected in collisions of identical dielectric grains in the presence of an electric field, and we confirm the model's predictions using discrete-element simulations and a tabletop granular experiment.

Tuesday, January 22, 2019

If I were to redo my 2011 Research Tools class

If I were doing the equivalent of my 2011 Research Tools class, I would do it as much as possible in Python 3 (python 2 is dead) with Jupyter notebooks.  I don't know what editor, but maybe PyCharms?  But I would prefer to pick something opensource.  Here are some of the things I was just thinking about while on the bus this morning:


  • Teaching python should be taught through multiple methods.  Incorporate or at least give guided options for self learning, normal classes focused on using Python and Jupyter, included in other courses that the same students will take.
  • Teach unit testing from the beginning
  • Beware the Python examples in some commercial products.  Their examples can sometimes be kinda crazy and detrimental to learning how to write Python effectively.
  • Start with version control from the beginning for projects of all sizes.  There is no project too small for git (or I guess mercurial)
  • Treat python 2 as persona non grata
  • Introduce style guides early.  If you can, pick one for the department.  Code should be like formal writing and lab notebooks: Correct grammar, spelling, formatting, etc. make things grow faster and last longer. e.g. http://google.github.io/styleguide/pyguide.html
  • To go with the style guide, teaching about code formatting tools (and having a required one) can take away a lot of stress from the code.  Go ahead and write that messy looking code.  Then run the formatter and linter when you are ready.  A much lower stress way of getting readable code.  codespell is another of my favorite tools
  • Teach pip + virtual environments
  • Teach the basics of copyright rules and what licenses mean.  When is it okay to use other code.  When is it okay or not okay to share your code with others.  What does it mean to not put a license on code
  • Encourage sending pull requests to projects.  Especially for projects with CI setup so you can see what it's like to have your code checked
  • Stack overflow and the like are used by the pros.  Everyone should use them and learn how to interpret the quality of answers