I busted out the “to-do list” thing again, mainly just writing my lists into a text file and checking off the items as I go. That gets me through the more energetic part of the day — one morning I cleaned the bathroom and the brewing equipment, another day I did the bills and similar, and today I did a bit of overdue yardwork before lunch — leaving me a more guilt-free evening for computer play. (We’ve been running and lifting when we get up, so that’s already covered.)
Anyway, today’s chore was yardwork: there were a bunch of wildflowers — weeds, really — in the front yard that needed to be cut down. I went out to deal with them, and it was freezing out. Two minutes into the job and it’s blowing a hard bitter bluster, and another five minutes brought snow, which started as flurries but soon looked like a real snowstorm coming down, or rather sideways, in all that wind. Cutting the wildflowers was barely a half-hour’s work, and I much prefer cooler weather for outdoor work, but this was brutal, and as soon as I was done the snow stopped.
The rest of the day was spent indoors, guilt-free.
I got in a towpath ride this afternoon, and one on Friday as well. Both of them were short versions — now that the day ends earlier, I really have to get myself out earlier in the day — and both of them involved at least a little bit of snow. I felt pretty good on each, not too cold except my face at the very start. It really feels like winter is here, and I think I’m ready.
We did a run this morning and some errands later, so there was no bike ride for me today — maybe tomorrow, when the weather will be better, if a bit colder than today. Meantime, we hit the weights yesterday, including squats…
I woke up this morning sore, mostly my biceps and upper back: recovery, prostaglandins, the usual fallout I guess. I also have been finding myself needing a bit more sleep in general lately — I’ve also been a bit of a night owl recently though, and that may be why mornings are drifting later, but I suspect that it’s my typical reaction to heavier exercise: I need a lot more sleep.
By the way, WXPN is playing their entire song library, from A to Z. They’re deep into the L’s right now, and I’m jamming out to Gary Wright’s “Love is Alive,” super loud — the truth is, I’ve had it cranked since “Louie Louie.” My soul’s like a wheel that’s turning…
Now they’re playing “Love Is All Around” by the Troggs.
Me, Renee, Scott, and a few friends of Renee from the Poconos, good people and a good ride. We followed a pretty old-school route, except a few choices just towards the last singletrack. One take-away: dropping the seat while riding through the rock gardens made all the difference.
I’ve been doing yoga, running, and lifting this week, but that was the last time I rode. It’s been cold and wet, but tomorrow may be nice.
I had a problem to solve at work last year, basically to make a cone out of bent tubes, to form a cone-shaped “throat opening” in a wall made of vertical tubes. The task needed a bit of iterative trial-and-error to solve for each tube, which quickly becomes tedious when there are maybe a dozen tubes that have to be looked at — half a day’s work — for any given throat configuration, and there were a bunch of configurations we wanted to explore.
You can read about it here, but after that first day of tedium I decided to see if I could automate the process. I wrote a short C program, including set of vector functions and a root-finding function (using the Bisection Algorithm, which is supposedly slow but fast enough for my purpose — more important to me was that it’s pretty robust, and guaranteed to work in my situation), to find the necessary workpoints and design requirements for an individual tube in the cone. I then wrote another program to generate the input data for each individual tube, based on the tube, wall and cone parameters. I could give the “cone_maker” program the tube OD, bend radius and minimum allowed straight between bends (tube parameters), the number of tubes and tube spacing on the wall (wall parameters), and the cone inner and outer diameter (cone parameters), and pipe the results through my original “throat tube calculator” program, to get the data I needed. The programming took about two days, maybe a total of four actual hours of programming time, and it ran — flawlessly — in seconds.
Unfortunately, to use the program I had to go through a whole rigmarole, running it on my SDF free shell account and accessing it on my phone via ssh, since we had no real resources for running or compiling programs at work. The process was faster, but still very tedious — you try typing dozens of numbers into and reading the results off a tiny phone screen — but it got the job done.
The program did what it needed to, and it looked like I wouldn’t ever need to use it anymore, but I started thinking about program improvements to make the tube design process easier. You can read about these changes here, but what I decided to do was add new output options to the throat tube bend calculator: one option that produces AutoCAD commands to draw the “skeleton” of the tubes, and another to create a lisp file (AutoCAD uses lisp as its scripting language) to make a 3D model of the cone tubes. This took more work than it needed to because checking the results had to be done at work, while coding had to be done at home, but within days I had the program output running smoothly. I then armored the programs and turned them into a CGI script, and made a web page to access it.
Here’s the calculator web page, and the results can be seen to the left. I had absolutely no use for the calculator anymore, but it sure was fun to play with.
Fast forward to now, and I thought it would be fun to play with again — unfortunately, I don’t have AutoCAD at home, and am not likely to get it anytime soon, but I do have a program called FreeCAD. Now FreeCAD does not use the same things AutoCAD does, but it does have a built-in scripting language: Python.
Python has been on my radar for a while, and with my recent QGIS forays (QGIS also uses Python as a scripting language) I’ve been motivated to learn a bit more about it. Then I happened to see my version of FreeCAD get auto-updated the other day, and thought it would be nice to play with, and maybe pick up on some Python on the way….
So I rewrote my cone maker & tube calculator programs in Python script. Much (but not all) of the vector stuff is available in a library, and so are root-finding algorithms — just for laughs I used Brent’s Algorithm, a faster version of Bisection — and Python code is naturally more compact-looking than C, so the final program looked really nice, and much shorter than my original C programs. In terms of running, there seemed to be a lag at first (probably importing all the libraries I called for), but the output just about spit itself out.
Once I got the program to produce correct numerical output, I moved it into FreeCAD and started figuring out how to create the tubes. This took a bit of research, and a bit of trial and error, but the whole learning process took less than a day and then it was running beautifully — you can see the results to the right, and the full throat below.
I caught a bit of nature drama in the front yard earlier today: I walked out onto the front porch just in time to see a huge bird rocket by into the neighbor’s bushes. Out of the bush shot a little gray bird — across the street, into and through another bush, chirping as it flew, with a hawk in hot pursuit. The hawk basically got stuck or slowed down in the second bush and the little bird got away, and the hawk flew to a tree branch and landed, looking pissed.
Meanwhile, a yellow cat was slinking along the neighbor’s house, like it was creeping up on the birds, until it got a good look at that hawk and just froze, and stayed that way — “don’t eat me I’m a statue!” — until the hawk flew off, then made itself scarce pronto. (There was a whole lot of commotion heard, but not seen, among the crows as well.)
I’m pretty sure that that hawk is a regular, or some group of hawks are regulars in our neighborhood, since I saw one in the persimmon tree in the backyard about two weeks ago, and it stands to reason: there are purposely a whole lot of native plants nearby, and water, which attracts the native herbivores (not to mention all the squirrels our neighbor feeds), so the next step up the food chain is a pretty logical one. We’ve heard owls recently too, over near First Avenue after dark, which is where we see a lot of skunks — I’m pretty sure owls are among the few things that hunt skunks — and I haven’t seen any but there’s rumors of coyotes and bobcats down by the river, which is why the beavers, who made a comeback a few years ago, have become rare again.
So what else have I been up to lately? I decided to look a bit more closely at QGIS, the open-source GIS program, and so I found a group of online courses on using it. They’re free, and you kind of get what you pay for here, but they’ve been an eye-opener into QGIS and its capabilities — it’s a much more powerful program than I realized, and with the ability to run R, GRASS and Python scripts, as well as automating tasks (and linking them together like unix pipelines), it’s got almost limitless expandability. I’m working through the third course (of five) right now, and when I’m done with these I may start looking into possibly going further.
Just checking in. I’ve been a bit depressed about the election, and haven’t had much to say — I haven’t done much since then either, so there isn’t much to say — but but it’s time to start putting things back to normal in my life, our lives, so here goes…
Thanksgiving was awesome, if a bit overwhelming. Thursday was a bit quiet, just a small meal with Anne and me, and Ben who was up from Philly for the week (though we did stop at John & Donna’s place for a late dessert), because Friday was our day to get together with Anne’s family, at her mom’s place in Jim Thorpe. Us, and Ben, and all five of Anne’s siblings and their spouses, plus a good chunk of the grandchildren (Ben’s generation) and their spouses, and even a bunch of great-grandchildren running about. We ate, hung out and BS’ed, watched said kids run about… Fun, but a very tiring day.
We brewed on Saturday, making an oatmeal stout with the help of Peter C, another one of the “Quaker kids” who grew up with Emmi and Ben, who’d brewed before but only with malt extracts, and wanted to see how it was done using grain. (A Cornell grad and budding farmer, Peter’s unconventional but very sharp, and surprisingly pleasant to be around — but then he did let me mansplain the brewing process.) We also tapped our rye IPA that we’d made a few weeks before (verdict: delicious), and Anne also did some baking, something that had become pretty much a constant the entire past week, what with Ben home, and Thanksgiving treats to make, and us all being homebodies while the beer brewed… I had no complaints!
Bicycling: Not much going on there, but I did ride Sals with Doug on Sunday. Not much to say except that the both of us were pretty well matched in terms of being out of shape, and we did a few of the less used trails — we visited the old YCC pavilion, which had burned down years ago, but apparently had been rebuilt long enough ago to have sustained damage from a falling tree — and spent a lot of time catching up.
So that was last weekend. Other recent events included a recent trip to Bonn Place, seeing that movie Moonlight at SteelStacks, helping Josh B bottle about 42 cases of beer at Two Rivers last Tuesday, and seeing our friends Ed and Ann last night. We may stop in at Two Rivers tonight, since it’s Bacon Night — I have only a vague notion what that might mean — and some of the home-brew crowd might be there. Life goes on.
I was reading these before I decided on that book cull (and one was actually a re-read) but here are two more for the discard pile:
Into the Land of Bones, by Frank L Holt, a look at Alexander the Great’s campaigns in Afghanistan, from the perspective of modern scholarship, as a way of looking at our current war in Afghanistan. This is a subject I thought I knew a bit about, though my own knowledge was formed by older scholarship of the “we really don’t know what happened in Bactria” school, and the book was an eye-opener, especially on the subject of how successful Alexander was in subduing the country (answer: not very). A very good read, but one I’ve now read twice and it’s time to move on.
The Lost World of Byzantium, by Jonathan Harris, yet another book about the Byzantine Empire, but shorter, less expansive than most, one that focuses on the empire’s resilience and ability to change with the times, and the changes that eventually brought it down. Another good read, but not as good as that first one — I had to push through to finish, and it’s definitely a one-and-done.
After a long period thinking about it, I finally got around to downsizing my book collection. Some of my books I read on a regular basis, and others have sentimental value for me, but few are what anyone would call a collectible, and there are plenty I don’t read, don’t particularly like, and would be better off without — could theoretically be better off without, hence the equivocation/procrastination incubation period…
But I’m doing it. What triggered all this sudden activity was something that happened during my recent search (for that book on Indian Paths), which unearthed a bunch of other books I realized I hadn’t thought about in a while.
There was one I ran across called Deep Survival, which I bought years ago, disliked, and never finished. I picked it up and started reading again, and was intrigued enough to continue for a bit. But like the first time, my annoyance grew as I continued reading, and though this time I did make it through to the end, I had to force myself to finish. My original assessment stands: the author had a fetish for fighter-pilot types — which was his own background and also that of his father — and the book was an unfocused paean to militaristic, “can-do” attitudes. I was so annoyed I decided to get rid of the book, and to rid my collection of others I don’t want to ever read again. I made a discard pile, and at the start of a recent hike I took it over to one of those free mini-libraries nearby and made a donation.
Unfortunately, when I got home I found I’d left the Deep Survival book behind, so I started making another cull pile. That’s when I realized I really had two piles to make: one of books I definitely don’t want, and another of books that I probably wouldn’t want, but never read through to the end, and should finish before discarding — I guess you could say I’m back to sentimentalizing/procrastinating…
The first book I took up was Alan Garner’s Red Shift, which so far seems better than I remember, though it has its annoyances: it reads like YA literature (which it is, kind of), and everyone seems to be named either John or Tom, and it has the clever clipped dialogue that reminds me of all the other late-Sixties-early-Seventies British YA literature I’ve been annoyed with (and subsequently forgotten) over the years. I’m about halfway through, and I really am enjoying it, but I can already tell it’s going in the discard pile.