# Gas station without pumps

## 2015 April 23

### Very long couple of days

Yesterday and today have been draining.

Yesterday, I had three classes each 70 minutes long: banana slug genomics, applied electronics for bioengineers, and a guest lecture for another class on protein structure.  I also had my usual 2 hours of office hours, delayed by half an hour because of the guest lecture.

The banana-slug-genomics class is going well.  My co-instructor (Ed Green) has done most of the organizing and has either arranged guest lectures or taught classes himself. This week and part of next we are getting preliminary reports from the 5 student groups on how the assemblies are coming.  No one has done an assembly yet, but there has been a fair amount of data cleanup and prep work (adapter removal, error correction, and estimates of what kmer sizes will work best in the de Bruijn graphs for assembly).  The data is quite clean, and we have about 23-fold coverage currently, which is just a little low for making good contigs.   (See https://banana-slug.soe.ucsc.edu/data_overview for more info about the data.) Most of the data is from a couple of lanes of HiSeq sequencing (2×100 bp) from 2 libraries (insert sizes around 370 and 600) , but some is from an early MySeq run (2×300bp), used to confirm that the libraries were good before the HiSeq run.  In class, we decided to seek a NextSeq run (2×250bp), either with the same libraries or with a new one, so that we could get more data quickly (we can get the data by next week, rather than waiting 2 or 3 weeks for a HiSeq run to piggyback on).  With the new data, we’ll have more than enough shotgun data for making the contigs.  The mate-pair libraries for scaffolding are still not ready (they’ve been failing quality checks and need to be redone), or we would run one of them on the NextSeq run.  We’ll probably also do a transcriptome library (in part to check quality of scaffolding, and in part to annotate the genome), and possibly a small-RNA library (a UCSC special interest).

The applied electronics lecture had a lot to cover, because the material on hysteresis that was not covered on Monday needed to be done before today’s lab, plus I had to show students how to interpret the 74HC15N datasheet for the Schmitt trigger, as we run them at 3.3V, but specs are only given for 2V, 4.5V, and 6V.  I also had to explain how the relaxation oscillator works (see last year’s blog post for the circuit they are using for the capacitance touch sensor).

Before getting to all the stuff on hysteresis, I had to finish up the data analysis for Tuesday’s lab, showing them how to fit models to the measured magnitude of impedance of the loudspeakers using gnuplot.  The fitting is fairly tricky, as the resistor has to be fit in one part of the curve, the inductor in another, and the RLC parameters for the resonance peak in yet another.  Furthermore, the radius of convergence is pretty small for the RLC parameters, so we had to do a lot of guessing reasonable values and seeing if we got convergence.  (See my post of 2 years ago for models that worked for measurements I made then.)

After the overstuffed electronics lecture, I had to move to the next classroom over and give a guest lecture on protein structure.  For this lecture I did some stuff on the chalk board, but mostly worked with 3D Darling models. When I did the guest lecture last year, I prepared a bunch of PDB files of protein structures to show the class, but I didn’t have the time or energy for that this year, so decided to do it all with the physical models.  I told students that the Darling models (which are the best kits I’ve seen for studying protein structure) are available for check out at the library, and that I had instructions for building protein chains with the Darling models plus homework in Spring 2011 with suggestions of things to build.  The protein structure lecture went fairly well, but I’m not sure how much students learned from it (as opposed to just being entertained).  The real learning comes from building the models oneself, but I did not have the luxury of making assignments for the course—nor would I have had time to grade them.

Speaking of grading, right after my 2 hours of office hours (full, as usual, with students wanting waivers for requirements that they had somehow neglected to fulfill), I had a stack of prelab assignments to grade for the hysteresis lab.  The results were not very encouraging, so I rewrote a section of my book to try to clarify the points that gave the students the most difficulty, adding in some scaffolding that I had thought would be unnecessary.  I’ve got too many students who can’t read something (like the derivation of the oscillation frequency for a relaxation oscillator on Wikipedia) and apply the same reasoning to their slightly different relaxation oscillator.  All they could do was copy the equations (which did not quite apply).  I put the updated book on the web site at about 11:30 p.m., emailed the students about it, ordered some more inductors for the power-amp lab, made my lunch for today, and crashed.

This morning, I got up around 6:30 a.m. (as I’ve been doing all quarter, though I am emphatically not a morning person), to make a thermos of tea, and process my half-day’s backlog of email (I get 50–100 messages a day, many of them needing immediate attention). I cycled up to work in time to open the lab at 10 a.m., then was there supervising students until after 7:30 pm. I had sort of expected that this time, as I knew that this lab was a long one (see Hysteresis lab too long from last year, and that was when the hysteresis lab was a two-day lab, not just one day).  Still, it made for a very long day.

I probably should be grading redone assignments today (I have a pile that were turned in Monday), but I don’t have the mental energy needed for grading tonight.  Tomorrow will be busy again, as I have banana-slug genomics, a visiting collaborator from UW, the electronics lecture (which needs to be about electrodes, and I’m not an expert on electrochemistry), and the grad research symposium all afternoon. I’ll also be getting another stack of design reports (14 of them, about 5 pages each) for this week’s lab, to fill up my weekend with grading. Plus I need to update a couple more chapters of the book before students get to them.

## 2014 April 9

### Protein essentials and second gnuplot demo

Filed under: Circuits course — gasstationwithoutpumps @ 21:22
Tags: , , ,

I gave two lectures back-to-back today, which I found a little stressful.

The first lecture was a guest lecture in “Molecular biomechanics” on the basic of protein structure.  I spent some time earlier this week picking out protein structure to show the students; digging out my old Darling models protein chain, which I last used for assigning homework in Spring 2011( see also my instructions for building protein chains with the Darling models); and trying to boil down the basics of protein structures to one 70-minute talk. I was up at 3 in the morning setting up the proteins I wanted to show on my laptop, even though I planned to rely mainly on the chalkboard and the Darling model kit.

The protein talk went ok. I covered such basics as primary=covalent, secondary=H-bond, tertiary≈packing, quaternary=multiple chains; hydrogen bonding patterns for helices, antiparallel sheets, and parallel sheets; supersecondary structure; domains; CO-R-N mnemonic for chirality; s-twisted and z-twisted helices (left- and right-handed in the confusing nomenclature used by biochemists); SCOP and PFAM; and maybe a handful of other topics.  I only showed two structures on the screen: a TIM-barrel and alpha-hemolysin, and I pointed them to the PDB education pages, which are actually quite good.

The most exciting thing during the lecture was that we had the fire alarm go off, and had to vacate the room for 10–15 minutes.  I might have covered a little more if there had been more time, but I did not have a set topic list I had to cover, so it didn’t really matter—I was just giving an extemporaneous dump of protein structure information. I certainly told them all the stuff I had decided ahead of time was essential—I’ve no idea what else would have come out if I’d had 10–15 more minutes.  I also managed to get in a plug for the library—they have Darling model kits that the students can check out—and for the information sessions that I arranged for the library to run for bioengineering majors next week.

Right after that talk, I went to the classroom for my applied circuits class and set up for another gnuplot demo. I had about 10 minutes to get some candy from the vending machine also.

In the applied circuits class, I started out by showing them the result of fitting models to (some of) the data I had collected:

The linear-scaling version of the graph the students should produce (they should also plot it on a log-log scale, for a better view of the resistive region).

I had to lend my data to a couple of the students who had not managed to finish the lab yesterday—I assured them that they could continue the lab tomorrow, and that I would stay until everyone had completed both parts of the lab. They will have to use their own data in the design report. While they were copying the data, I took some time to talk about the “zone of proximal development”, imposter syndrome, and how my goal in the class was not to “weed them out”, but to help them achieve difficult success. My goal is to maximize their learning, which means that they will often be struggling with concepts or skills that seem just a bit too difficult. I’ll help them, but it might be such “unhelpful” help as telling them “your breadboard doesn’t match your schematic” and leaving them to find where the mismatch is, rather than debugging for them.  Sometimes I’ll have to do more, when the problems are beyond reasonable expectations (like finding the blown fuses in the multimeter and the broken clipleads yesterday). I promised to stay in the lab until everyone finished, even if it took them a long time.

Sometimes I’ll goof on the difficulty of a homework or lab, and they’ll be pushed into frustration rather than just being challenged, but my goal is to get them to persevere and to achieve that very rewarding feeling of finally accomplishing something that seemed too difficult when they started.  This course is only 3% of their college education, but I’m going to try to make it accomplish a lot more than that share.

Fortuitously, in my email today I got a story about someone (a marketing manager for an electronics parts company) learning to solder for the first time. I shared that story with my class by e-mail, as I thought that they could sympathize with him (having just learned to solder themselves last week), but also recognize the symptoms of imposter syndrome.

Getting back to the main material for the day, I started the guts of the gnuplot lesson. Building up the plot a little at a time, we first plotted the raw data from one PteroDAQ, then scaled the y values first to amps, then to microamps.  Because each group used a different resistor in their test setup, they couldn’t blindly copy what I was doing, but understand at least enough to put in the correct resistance value.  I showed them how to switch between linear and log scales on each axis with the plot-window keyboard shortcuts (“L” toggles the scaling on the nearer axis) and we noticed that the data from the first data set (the red one above) was rather sparse at the low end.

I then showed them how to get two plots on the same set of axes, and I managed to get them to tell me what the plot would look like if we had been testing a resistor instead of the electret mic.  We then fit a simple resistor model to the low end (the resistive region) of the curve.

I then took a break from gnuplot to explain how an electret mic works.  They were a little astonished at how many transformations of the information occurred in a simple device like a microphone: pressure to force to displacement  to capacitance to gate-source voltage to drain-source current (and I promised that we would convert back to voltage in tomorrow’s lab). We managed to follow the transformations and see that they were all linear (well, displacement to capacitance to gate-source voltage was a pair of inversions, and I had to wave my hands at $\frac{d I_{DS(sat)}}{d V_{GS}} \propto I_{DS(sat)}$, since we don’t have a model of FETs yet, and may not get to one complicated enough to derive that this quarter.

I then went back to gnuplot and showed them how to fit the Isat model to the data, first deliberately trying to fit the whole curve (which gives an obviously wrong result). I had deliberately omitted the amp-to-microamp scaling, and gotten a straight line at zero for my fit—I had them debug that as a group before we got a constant line that was in the middle of the graph. I got them to figure out what went wrong there also. Once they realized I was fitting the whole curve, I showed them how to limit the range of their fitting, and got a reasonable Isat value. My goal here was not to “show them how to use gnuplot”, but to show them that they could debug mistakes that they were likely to make, and that they should not shut down when things went wrong. (A lot of today’s class was this sort of meta-cognition stuff, while still getting in a reasonable amount of technical material.)

I then gave them the blended model, with $R_{DS} = \sqrt{R^2 + (V_{DS}/I_{SAT})^2}$, converting it to a current model on the board, then trying to fit the data. The result was (unexpectedly) a terrible fit—I did not have them try to debug this, because were were almost out of time, and just showed them that the problem was one of units: my initial guess for R was in Ω, but my currents were all in µA, so I needed to make the resistance in MΩ to have consistent units. After scaling the guess for R by 1e-6, I reran the fit and it worked fine. This gave me a chance to talk about the importance of starting fitting procedures with reasonable guesses, since they might not otherwise converge.

I’ve been getting good participation from the class, only occasionally having to get them to speak up (I’m getting a bit deaf, and when they mumble a guess, I can’t hear them). I’ve been trying not to suppress students who provide incomplete or wrong answers, but encourage them to amplify on or correct each other.  So far it seems to be working.

We did not have time to fit the 3-parameter empirical model, but they have the model in the lab assignment and they should be able to fit it using gnuplot now.  One student asked me if I was going to distribute a script, as I did last week. I assured him that I was not going to do that. The goal was to build up their gnuplot scripting capabilities, not provide them with crutches. There was very little “new” in this week’s lesson as far as gnuplot was concerned, and gnuplot does have an adequate help system for the sort of stuff they need (though I find the hierarchical help system to be quite poor for finding out about features you’ve not been exposed to—you have to know precisely what names things are hidden under).

I still haven’t gotten to complex impedance, but that will have to be Friday’s lecture.  I also wanted to get to load lines today, so that they could select an appropriate size for their load resistors that do the current-to-voltage conversion, but I’ll do that at the beginning of lab tomorrow, when they’ll be scratching their heads about how to choose the resistor.  Just-in-time teaching can be a powerful motivator, if they get concepts just after they realize the need for them, rather than months earlier in anticipation of need. I may at the beginning of lab if anyone figured out on their own how to choose the resistor, and get them to present first.