Building a 3d Printer

Building the printer.
Building the printer.

I took three students to a workshop were we’re building a 3d printer. It’s run out of the Whitfield School. We spend today putting together the electronics to run the five motors we need to get the thing to work, and starting to put the frame together.

The frame is based on the RepRap Prusa i3 (via DIY Tech Shop), and the plastic parts that hold the rods, electronics and other metal bits together are 3d printed themselves.

Students learn to solder.
Students learn to solder.

The motors is run by an Arduino, which is great because I’ve been thinking about using one to operate the doors to the chicken coops.

Notes on hardware

Microcontroller

  • Arduino Mega 2560 R3
  • RAMPS Shield 1.4
  • RepRap StepStick Pololu A4988 (I think) stepper driver (plus heat sinks)

Filament: 1.75 mm PLA

Experiments for Demonstrating Different Types of Mathematical Functions

This is my quick, and expanding, reference for easy-to-do experiments for students studying different types of functions.

Linear equations: y = mx + b

  • Bringing water to a boil (e.g. Melting snow)
  • Straight line, motorized, motion. (e.g. Movement of a robot/Predicting where robots will meet in the middle)
  • Current versus Voltage across a resistor as resistance changes.

Quadratic equations: y = ax2 + bx + c

Exponential functions: y = aekx

  • Cooling water (ref.)

Square Root Functions: y = ax1/2

Trigonometric Functions: y = asin(bx)+c

Teaching Organic Farming

Teaching Organic Farming and Gardening
UCSC’s Teaching Organic Farming and Gardening

One of these days I’d like to put in a garden at school. Or maybe a few gardens. An indoor hydroponic system would be nice for the winter months, as would a greenhouse. However, the easiest thing to start with might be putting in some raised beds. To this end, the University of Santa Cruz’s Center for Agroecology and Sustainable Food Systems has detailed information in their Teaching Organic Farming & Gardening: Resources for Instructors manual.

Mr. Sansone.

Harvesting and Processing Chickens

We successfully harvested and processed three chickens during last week’s interim. It was my first time going through the entire process, but fortunately we had a very experienced guide in Dr. Samsone who also happens to be a vet.

The interim focused on where food comes from (students also saw the documentary “King Corn”), and the cleaning of the chickens was tied into our Biology students’ study of anatomy (I’d done fish and squid before). Unfortunately, I was unable to find someone who knew how to read the entrails so we could tie the process into history and language arts as well.

Student holds a kidney. A heart is in the background.

When we were done with the processing and analysis, Mr. Elder cooked the chickens on our brand new grill (which worked quite well he says). The chickens were free-range (donated by Ms. Eisenberger), but a little on the old side, at about 7 months old; the chickens you buy at the grocery are somewhere around 2 months old.

Dr. Samsone recommended that next time we raise the chickens ourselves from chicks, which I’d love to try, but I suspect would run into some serious resistance from the students. We’d only had the chickens we harvested for five minutes before they’d all been given names. Raising chickens from chicks would bring a whole new level of anthropomorphizing.

Chicken on the grill. The culmination of the interim.

References

Being new to the chickens, I spent a bit of time researching how it is done.

Ken Bolte, from the Franklin County Extension of the University of Missouri, recommended the University of Minnesota’s Extension site on Home Processing of Poultry (the page on evisceration provided an excellent guide), as well as Oklahoma State’s much briefer guide (pdf).

Dr. Samsone recommended the series of videos from the Featherman Equipment Company. Videos are particularly useful for novices like myself.

Herrick Kimball’s excellent How to Butcher a Chicken is also a great reference.

Draining a Bottle Part 2: Linearizing Equations when you have to

Yesterday we used calculus to find the equation for the height of water in a large plastic water bottle as the water drained out of a small hole in the bottom.

Perhaps the most crucial point in the procedure was fitting a curve to the measured reduction of the water’s outflow rate over time. Yesterday, in our initial attempt, we used a straight line for the curve, which produced a very good fit.

Figure 1. The change in the outflow rate over time can be well approximated by a straight line.

The R2 value is a measure of how good a fit the data is to the trendline. The straight line gives an R2 value of 0.9854, which is very close to a perfect fit of 1.0 (the lowest R2 can go is 0.0).

The resulting equation, written in terms of the outflow rate (dV/dt) and time (t), was:

 \frac{dV}{dt} = -0.0035 t + 3.9113

However, if you look carefully at the graph in Figure 1, the last few data points suggest that the outflow does not just linearly decrease to zero, but approaches zero asymptotically. As a result, a different type of curve might be a better trendline.

Types of Equations

So my calculus students and I, with a little help from the pre-Calculus class, tried to figure out what types of curves might work. There are quite a few, but we settled for looking at three: a logarithmic function, a reciprocal function, and a square root function. These are shown in Figure 2.

Figure 2. Example curves that might better describe the relationship between outflow and time.

I steered them toward the square root function because then we’d end up with something akin to Torricelli’s Law (which can be derived from the physics). A basic square root function for outflow would look something like this:

 \frac{dV}{dt} = a \sqrt{t} + b

the a coefficient stretches the equation out, while the b coefficient moves the curve up and down.

Fitting the Curve

Having decided on a square-root type function, the next problem was trying to find the actual equation. Previously, we used Excel to find the best fit straight line. However, while Excel can fit log, exponential and power curves, there’s no option for fitting a square-root function to a graph.

To get around this we linearized the square-root function. The equation, after all, looks a lot like the equation of a straight line already, the only difference is the square root of t, so let’s substitute in:

 x = \sqrt{t}

to get:

 \frac{dV}{dt} = a x + b

Now we can get Excel to fit a straight line to our data, but we have to plot the square-root of time versus temperature instead of the just time versus temperature. So we take the square root of all of our time measurements:

Time Square root of time Outflow rate
t (s) t1/2 = x (s1/2) dV/dt (ml/s)
0.0 0 3.91
45.5 6.75 3.52
97.8 9.89 2.94
140.9 11.87 3.52
197 14.04 3.21
257 16.05 3.01
315.1 17.75 2.81
380.1 19.50 2.53
452.9 21.28 2.23
529.6 23.01 1.92
620.7 24.91 1.69
742.7 27.25 1.45

We can now plot the outflow rate versus the square root of time (Figure 3).

Figure 3. Linear trend relating the outflow rate to the square root of time. The regression coefficient (R2) of 0.9948 is better than the simply linear trend of outlfow rate versus time (which was 0.9854).

The equation Excel gives (Figure 3), is:

 \frac{dV}{dt} = -0.1395 x + 5.21

and we can substitute back in for x=t1/2 to get:

 \frac{dV}{dt} = -0.1395 \sqrt{t} + 5.21

Getting back to the Equation for Height

Now we can do the same procedure we did before to find the equation for height.

First we substitute in V=πr2h:

 \frac{d(\pi r^2 h}{dt} = -0.1395 \sqrt{t} + 5.21

Factor out the πr2 and move it to the other side of the equation to solve for the rate of change of height:

 \frac{dh}{dt} = \frac{-0.1395}{\pi r^2} \sqrt{t} + \frac{5.21}{\pi r^2}

Then integrate to find h(t) (remember \sqrt{t} = t^{1/2} ) :

 \int \frac{dh}{dt} dt = \int \left( \frac{-0.1395}{\pi r^2} t^{1/2} + \frac{5.21}{\pi r^2} \right) dt

gives:

 h =  \frac{-0.1395}{(3/2) \pi r^2} t^{3/2} + \frac{5.21}{\pi r^2} t + c

which might look a bit ugly, but that’s only because I haven’t simplified the fractions. Since the radius (r) is 7.5 cm:

 h =  -0.000526 t^{3/2} + 0.029 t + c

Finally we substitute in the initial value (t=0, h=11) to solve for the coefficient:

 c = 11

giving the equation:

 h =  -0.000526 t^{3/2} + 0.029 t + 11

Plotting the equations shows that it matches the measured data fairly well, although not quite as well as when we used the previous linear function for outflow.

Figure 4. Integrating a square root function for the outflow rate gives a modeled function for the changing height over time that slightly undermatches the measured heights.

Discussion

I’m not sure why the square root function for outflow does not give as good a match of the measurements of height as does the linear function, especially since the former better matches the data (it has a better R2 value).

It could be because of the error in the measurements; the gradations on the water bottle were drawn by hand with a sharpie so the error in the height measurements there alone was probably on the order of 2-3 mm. The measurement of the outflow volume in the beaker was also probably off by about 5%.

I suspect, however, that the relatively short time for the experiment (about 15 minutes) may have a large role in determining which model fit better. If we’d run the experiment for longer, so students could measure the long tail as the water height in the bottle got close to the outlet level and the outflow rate really slowed down, then we’d have found a much better match using the square-root function. The linear match of the outflow data produces a quadratic equation when you integrate it. Quadratic equations will drop to a minimum and then rise again, unlike the square-root function which will just continue to sink.

Conclusions

The linearization of the square-root function worked very nicely. It was a great mathematical example even if it did not produce the better result, it was still close enough to be worth it.

Science Starts with Careful Observation

Page 1 of my notes: Diagram of our mysterious mixture.
Sealed jar with a number of unknown substances.

The middle school started science this week with a mysterious jar of unknown substances: a couple immiscible liquids; some plastics and metals of different densities.

As they try to separate and identify the mixture they’ll be learning about handling potentially hazardous materials, material physical and chemical properties (like density and pH), and a little chemistry.

But the first thing they need to learn is how to take notes. Science starts (and ends) with observation. Careful observation. And most middle schoolers need mentoring to make sure their notes are rigorous.

To this end, after they wrote up their observations of what was in the jar, I put together my own notes as a general reference. This is not the only way to take notes, but I’m going to have them amend their own notes to make sure they’re neater and have as much detail as possible.

Page 2 of notes on the mysterious jar.
Page 3 of notes on the mysterious jar.

How to Write Lab Reports

If I have seen further it is only by standing on the shoulders of giants
— Isaac Newton (1676) via Wikiquotes.

Science advances when scientists share their results. If someone tests an hypothesis and finds that it’s wrong, if they share their results, others won’t have to waste time by repeating the same experiments. If someone makes a breakthrough and publishes what they found, then scientists all around the world can use that information to develop new experiments and new applications of that newly discovered principle. Sharing is essential, so it’s important for students to learn how to share well.

Scientists usually communicate their results by giving presentations to other scientists at conferences and publishing articles in scientific journals. Often these presentations are full of the specialized language different types of scientists use with each other, so sometimes science journalists will translate that into regular English news articles that everyone can read and understand. The New York Times and the BBC have good science sections, but what they present comes first from scientists’ formal presentations and articles.

As a result, good presentations and good lab reports are a great way to start learning how to communicate like a scientist.

Lab Reports

A good way to figure out what should go into a lab report is to look at a published article. We have a bunch of copies of Science, which has research articles toward the middle and the back. Articles in Science tend to be brief and fairly dense because it’s one of the premiere journals, so the outlines are not as explicit as you’d find in other places; an Open Access Journal might provide better examples, especially if you’re looking them up online.

Based on our observations, we decided on the following parts for a good lab report:

  • Title: Be short, but unique to give a good idea of what your project is about. Since my classes seldom all do the same experiment, this is very useful. Answer the questions: What did you do? Why did you do it? and What did you find?
  • Authors: Who gets the credit for the work. Usually authors are listed by who did the most work first, but since everyone’s expected to work equally on their group projects you can choose some random or arbitrary order.
  • Abstract: A brief summary of the work, include: what is the problem you’re trying to solve; what you did to solve the problem; and what results you came up with. The abstract should contain all the spoilers.
  • Introduction: Go into some more detail about what the problem is you’re working on, and why it’s important. State your hypothesis and how you’re going to test it. Overview previous work your project is based on.
  • Procedure/Methods: Describe, in detail, what you did, what apparatus you used. Both words and diagrams are useful here.
  • Results: Tell us what you found. Graphs, charts and tables will be very useful here.
  • Figure 1. An example of a diagram. In this case labels have been placed on a photograph of the apparatus. Notice also the caption, which you are reading at this very moment, that goes with the figure.
  • Note on Figures: You should have figures, charts, diagrams and tables in your Procedure and Results sections, but you can have them anywhere they’re appropriate. Each figure needs to have a caption explaining the figure. A useful approach to figures and captions is to try to write them so that someone could understand the entire article by only looking at the figures and reading their captions. One of my students says that popular magazines, like People, are written that way (or at least that’s how they’re read).
  • Analysis and Discussion: To paraphrase a student, “Explain why you think you got those results.” Even if the results are unexpected, or especially if they’re unexpected, you need to explain them. This is also your chance to explain why all of your critics are wrong and you were right all along. If you do that though, it should be written in scientific, passive-aggressive language.
  • Conclusions: Summarize. In the abstract you’re telling them what you’re going to tell them. In the Introduction, Procedure, Results and Discussion sections you’re telling them. In the Conclusion, you’re telling them what you told them. Hopefully by that time they’ll have had enough chances to figure out what you were trying to tell them.
  • Figure 2. An example of a citation for a website.
  • References: Be sure to include a list of the references you used to do your work. This is how you give credit to the people who’s work you are building on. The Yale Library has an excellent page on citing sources. There are a different citation styles you can use but remember the purpose: to give credit where it’s due, and to allow others to be able to find those references easily. All citations should have the author, the date published (or when you accessed it if it is a website), the title, and a way to track down the work.

Note that scientific magazines, like Science and Nature, are very different from a popular magazine like People, for one thing, as was pointed out to me today, the pages don’t smell like perfume (instead they smell like science).

Updates

This paper, on how to bend a soccer ball, is a good example of a student research paper.

Guide to Using a Microscope

Sitting innocuously on the clearance table at a Barnes & Noble (in Cedar Rapid, Iowa actually) was a copy of Georg Stehli’s The Microscope and How to Use It.

At 75% off it was less than $3, which is quite a steal for a guide to what I found to be the most fascinating piece of scientific equipment for my middle schoolers. One of their first natural world lessons was on how to use the microscope. In the classroom there was always one sitting on the shelf, protected by its translucent plastic cover, but easily accessible.

I also took one everywhere, including to the cabins on our immersion trips, which is where they discovered the crystalline structure of salt and sugar grains, and the microfossils at Coon Creek.

And, interestingly enough, my microscopy posts are some of the most popular posts on this blog (the onion cell is regularly in the top ten).

The Microscope and how to use it by Georg Stehli.

Apart from the basics of how to use a microscope, Stehli’s book goes into simple sample preparations and preservation for almost everything you’re likely to encounter in the curriculum, in the classroom, and in the back yard. Though neither crystal structure nor microfossils are covered, the techniques for looking a the hard parts of biological specimens are applicable.

I would have loved to have had a copy of this last year when I was trying to figure out which were the best dyes to use for some of the odder samples my students came up with, and how to make them into permanent slides. It’s not easy to find this kind of broad reference online.