Monday, September 12, 2016

Hip rolls and a spiritual exercise

The physical therapist gave me four or five exercises. Six months later, I’m still doing one of them: hip rolls, a set of 30, morning and evening. (This is not a dance move; I do these lying on the floor.)

The other day I thought of how it could be a spiritual exercise, not just a physical one. It would involve slowing down, probably a good idea for a perpetually-in-a-rush guy like me. Here’s the idea: as I begin the first iteration, to remember a phrase or a short passage from the Bible, from chapter 1 of something. On the second, something from chapter 2 of something. And so on. Here’s one possible list:

  1. The word became flesh and dwelt among us, from John 1. This is the astonishing idea that Jesus came to earth and pitched his tent among us. Amazing!
  2. Jesus grew in wisdom and stature, and in favor with God and man (everybody needs to grow: even Jesus needed to!), Luke 2
  3. Trust in the Lord with all your heart…, Proverbs 3
  4. Jesus was tempted in all things as we are, from Hebrews 4
  5. [A priest] can deal gently with the ignorant and wayward, since he himself is beset by weakness, from Hebrews 5 (a good reminder, since we are also priests according to 1 Peter 2)
  6. Seek first his kingdom… from Matthew 6
  7. If anyone wants to do God’s will, he’ll know whether I’m speaking from God or just making all this stuff up: it’ important to be willing to do God’s will, from John 7
  8. What does it profit a man to gain the whole world and forfeit his soul? from Mark 8
  9. And God is able to make all grace abound to you, that always having all suffiency in everything, you may have an abundance for every good work. from 2 Corinthians 9
  10. When words are many, sin is not absent; but he who holds his tongue is wise, from Proverbs 10
  11. He who goes about as a talebearer reveals secrets, but he who is trustworthy conceals a matter. from Proverbs 11
  12. Don’t be conformed to this world, but be transformed by the renewing of your mind: Romans 12
  13. A new command I give you: love one another as I have loved you, John 13
  14. He who has my commands and keeps them… I will reveal myself to him: knowledge through obedience, from John 14
  15. Remain in me, and I will remain in you, John 15
  16. Ask and you will receive, that your joy may be made full, John 16
  17. This is eternal life: to know God and Jesus Christ, John 17
  18. Death and life are in the power of the tongue, Prov. 18
  19. The son of man came to seek and to save the lost, Luke 19
  20. Whoever wishes to be great among you must be your servant… Matthew 20
  21. The king’s hand is in the heart of the Lord… Proverbs 21
  22. A prudent man sees danger and takes cover; the foolish keep going and suffer for it. Proverbs 22
    or My God my God why have you forsaken me Psalm 22. Jesus suffered much.
  23. The Lord is my shepherd; I shall not want
  24. I always do my best to keep a blameless conscience both before God and before men Acts 24
  25. A word aptly spoken is like apples of gold in settings of silver Pr. 25
  26. As a door turns on his hinges, so the sluggard turns on his bed Pr. 26 (probably there’s a better verse somewhere, but that’s what came to mind)
  27. Do not boast about tomorrow, for you don’t know… Pr. 27
  28. I am with you always even to the end of the age Matthew 28
  29. You will seek me and find me, and I will be found by you Jer. 29
  30. Every word of God proves true; he is a shield to all who take refuge in him Pr. 30
There’s already some variation in the verses I use, and sometimes I just murmur, “23” (or whatever number I’m skipping) but it’s good for me to remember these cautions and encouragements and examples, that is, when I remember to remember them.

Monday, September 05, 2016

If Finder (Mac OS X) is sluggish, maybe it's that memory leak; here's how to fix it

Short version: if Finder is hogging RAM, killall Finder in a terminal window. It'll automagically restart and work much better.
The lovely Carol called me from her desk. "There are stories in this folder," she said, indicating the Finder window, "but they don't show up."

The Activity Monitor showed the finder as consuming something like 698MB of RAM. Firefox had something close to 2GB, so Finder wasn't the #1 hog, but still, over 600MB? After a few futile web searches, I came to this article on howtogeek.com, where I spotted:

Currently, the only way to quit the Finder is by typing “killall Finder” in a Terminal window, which is inconvenient.
Whoa! “You had me at ‘Terminal window’!” so I opened one and typed "ps x|grep Finder" followed by "killall Finder"; my plan was to restart Finder via snarf-n-barf of the full path ps(1) had showed me. But Finder restarted all by itself, performing quite snappily and using only a little RAM. Wow! That was easy!

Update: creating the "Quit Finder" menu item

Now, to make it easier for the lovely Carol to fix a sluggish finder herself, I decided to create a "Quit Finder" menu item. The method described in the above article or this one doesn't quite work—at least it didn't for me today:
defaults write com.apple.Finder QuitMenuItem -bool YES
This following works fine, though; it's the same thing except with a lowercase "f" in "finder":
defaults write com.apple.finder QuitMenuItem -bool YES
It's shown in these postings:

Wednesday, August 10, 2016

Open letter to Amit

The other day, someone at work asked me if I had regrets over choosing a career in tech. Here's my response.
Updates 2016-08-11:
  1. Last night, Kesavan (the unnamed guy below) said it was fine to name him.
  2. This morning, I realized that I'd forgotten to mention something really important, perhaps the most important fact about me: I've been extremely lucky. More on this is in the addendum.

Amit,

Thank you for asking about regrets over choosing a career in tech; your question honors me, and I hope my answer doesn't disappoint.

I think I mentioned that my career began over forty (40) years ago, which is a source of great amusement and sometimes astonishment. A few years back I was in a hackathon with Mohit and Katiyar and Narver and one other guy who I won't name… trying to do something in javascript, which I still don't know. And I was mumbling about how I wish I'd learned it in grad school. "But wait," I said, "when I was in grad school, javascript hadn't been invented yet."

The unnamed guy in our hackathon team said, "I wonder how many of us were even born when Collin was in grad school?" and it turned out he was the only one... which is why I don't include his name here :)

But to your question: do I regret my career choice? Well, after my bachelor's degree I needed to do something to pay for rent and groceries. I wasn't good at anything in school except math and circuits and programming. Maybe I could have gone into statistics or become an actuary or something, but frankly the path into a tech career seemed more straightforward.

I have been thinking recently about something Garrison Keillor said in one of his "Lake Wobegon" monologues: "I wonder if perhaps we are less than our parents, and have given less to our children." I think of my dad, who ran out of money and didn't finish college. He got drafted and taught electronics for a while. He got a radiotelephone license and was engineer at a radio station. He was a sales/support guy for IBM and worked under some pretty unpleasant conditions. He switched to working for the FAA, and had to spend months at a time away from home for training. He went out and found work to do on the side: he fixed and built and invented things. He knew how to learn stuff and made the effort to do it. Car repair, electronic equipment repair, remodeling—he did it all. One day when he was in his 60s, he called a plumber for the first time in his life.

In contrast, I've had an easy life. I've had two professional employers—essentially two professional jobs since college. I haven't had to reinvent myself, I haven't had to take a lot of initiative. Have I had to work long hours debugging something? Sure; everybody has. But that's not the same thing as having to invent myself or figure out my next step in life.

I think what I'd say is that I did the best with what I had and with who I was. Sure, sometimes these days when I speak with our friends who go to Mexico and do medical work, I wish I had gone into that field so that I could help people in a more direct, intense, meaningful way. Given my constraints at the time (private college was expensive, even in the 1970s), I needed to finish quickly and start making money soon.

Could I have switched at some point? Maybe, but things got a lot more complicated with a mortgage and children. Shoulda, coulda, woulda—but I'm no hero or sage; it was enough effort to keep all the balls in the air, without also thinking about making a major change. Like many, I never got dissatisfied enough to consider a career change seriously, until getting laid off in 2002.

At that point, I briefly considered becoming a teacher. However, as I have since learned (from teaching Eng101), it would be a YUGE effort for me to become suited to classroom instruction. Also, with two college educations still ahead, it just didn't seem practical to take a significant drop in income.

So as I think back, my career in tech has been a good fit for me. It's a good fit for my personality and my talents. and has enabled my kids to graduate from college with no loans. My wife has been able to spend a lot of time at home when the kids were growing up, and she's now working on a novel and a collection of poetry. We've had some extra money to give to those less fortunate than ourselves.

Now the content of the work hasn't been really significant in itself. It's not like inventing dwarf wheat (Norman Borlaug did that and saved literally over a billion people from starvation); it's just solving problems and writing stuff.

What has been rewarding in my view is learning stuff and helping others. It's like what does a plant do? It grows, it reaches for the sun, it pulls carbon out of the atmosphere, it drops seeds, it provides shade. In doing that stuff, it brings glory to its maker. I don't know if plants know they're created by God, or if when they do what they do they "feel his pleasure," but I certainly do. Feel God's pleasure I mean. The stuff I do isn't grand or terribly significant in a dwarf wheat kind of way, but when my code works, or when I can help somebody learn something, or encourage someone to try one more time, that's a good feeling.

You're near the beginning of your career, a career that I hope will bring you as much stimulation and challenge and learning and joy as mine has. I suppose I could try to tell you to take more risks than I did, or try more new things, or push yourself upward, but I obviously didn't follow that advice, and I'm not sure it's good advice anyway.

No, what's really important in life, in my view anyway, is to be home for dinner, to play with your kids, to manage your boss's expectations so you can live a balanced life. Because really, who's gonna hold your hand when you die? It's not gonna be your boss, or if you're a manager/director/VP, any of the dozens or hundreds of people below you in the org chart. It's your family and your close friends. The patents, the certificates, the quarterly recognition awards, etc. will be forgotten.

OK, that's way too long. Thanks for reading this far. I'd love to hear your story and your thoughts on all this.

      -collin

Addendum: the role of luck in my story
If when you read the above, you think, "he sure was lucky," I'm here to tell you that you are 100% right. Did I work hard? Sometimes. Did I get good genes from my parents? The smartest thing I ever did was to pick the right parents at the right time in history.

Because all the talent and grit and determination and hard work in the world won't get you far if bombs are constantly falling outside your house, or if there's no electricity and you can't go to school because you need to help your parents gather food, or if your parents died in their 20s from AIDS or ebola or something. Robert Frank made a terrific case for the role of luck in this article in the Atlantic. And in the latest Hedgehog Review, Frank quotes David Brooks:

You should regard yourself as the sole author of all your future achievements and as the grateful beneficiary of all your past successes.... As you go through life, you should pass through different phases in thinking about how much credit you deserve. You should start your life with the illusion that you are completely in control of what you do. You should finish life with the recognition that, all in all, you got better than you deserved.... As an ambitious executive, it's important that you believe that you will deserve credit for everything you achieve. As a human being, it's important for you to know that's nonsense.
The Credit Illusion NY Times 2012-08-02 link

Monday, August 08, 2016

Corporate Benevolence and Investment Strategies?

In the 1970s, a company called Merck discovered a cure for "river blindness," a disease that afflicted thousands (millions?) of people in the developing world. The disease was carried by a certain fly, which bites people, introducing bacteria that create tremendous itching and, in severe cases, blindness.

This wasn't an accidental discovery; Merck had another medication that they thought might work if suitably modified. Long story short, they had to spend millions of dollars to develop and test the medicine and prove it safe and effective on humans. There had been some hope that someone (charities, the World Health Organization, somebody like that) might help defray the costs of manufacture and distribution, but it never happened. Merck has given out some hundreds of millions of doses and impacted millions of lives, and never received a penny for this miracle drug.

It wasn't just this one drug, either—that was an extreme example, but Merck were not in the habit of maximizing income to the detriment of patients. In an interview on American Public Media's Marketplace radio program, a former CEO commented that the purpose of Merck was to relieve suffering and cure disease; if they did that, they'd get some money. This CEO did not think it reasonable to raise the price of any medicine any more than the rate of inflation. In his view, it was okay to "leave money on the table," since Merck could get a reasonable return while fulfilling their mission.

What would happen to such a CEO today? Would activist investors take over the board and replace the CEO with someone that would raise prices and stop the giveaways? How can Merck continue to give away medicines in today's climate of fear and greed?

And what, if anything, can I do as an investor to help companies like Merck continue to do acts of benevolence?

One theory of investing says to forget about benevolence and invest for maximum return. But wouldn't that tend to discourage, even extinguish, corporate benevolence of the "river blindness" variety?

One could imagine creating a stock fund concentrating on socially responsible investments, but if the returns aren't there, there won't be enough investors. The system of capitalism tends to concentrate wealth, as many have pointed out—perhaps most notably Professor Piketty in his Capital in the 21st Century; trying to counteract this tendency is like trying to fight the laws of physics.

Yet we must at least think about trying. Philanthropy on the scale of Merck's giveaway of the "river blindness" drug would be exceedingly difficult to get with individual donations or government subsidies. If Merck were of a mind to make money on the drug, no amount of government subsidies would be enough to supply the drug to all who need it. (Government subsidies can barely keep our 20th-century Caltrain system afloat financially.)

So I'm stumped, at least for the moment. I'm sure others have given a lot more thought to this, and from my understanding, Merck are still giving away the "river blindness" medication. So it appears that there's still hope. But a comprehensive answer? I've no idea.

Thursday, July 21, 2016

Saved by… obedience?

For years I've heard (and sometimes said) that salvation comes “by grace alone through faith alone in Christ alone.” So I was a little surprised to read in Hebrews 5 that Jesus “became the source of eternal salvation to all who obey him.” (emphasis added)

What's this about obedience? Does that contradict "by grace alone"? Maybe not.

Suppose you're in the middle of the ocean, after a plane crash or something, and can't see any land. A boat comes along, offering to save you. Sounds like grace to me! But when someone says, “Grab this rope,” you gotta obey and grab it.

If you instead say, “Wait, obedience? I thought this was by grace alone,” then you won't be saved. Silly, I know. But earlier in the letter, we read that faith and obedience come to the same thing.

[T]o whom did God swear that they would never enter his rest if not to those who disobeyed? So we see that they were not able to enter, because of their unbelief.
Hebrews 3:18–19 NIV (1984)

So no, we aren't saved by obedience; it really is by grace alone through faith alone. But if I'm unwilling to obey, that's not a disconnected random bit of information; it speaks to my lack of faith. And without faith … hey, without faith it's impossible to please God! Without faith, grace doesn't do me much good.

So it's not a paradox or a contradiction after all.

Update: the next morning

I opened my reading plan in the "Bible" app, where I read this:
... But the Hebrew word for 'faith' - emunah - is less about KNOWING, and more about DOING.

'Emunah' literally means "to take firm action", so to have faith is to act.

How about that! The Old Testament writers weren't confused at all about this the way we modern evangelicals sometimes are. Guess I shouldn't be surprised.

Tuesday, July 12, 2016

Thoughts on the 3rd lap

It struck me on my third trip around the jogging track how similar the first parts of these verses are:
Therefore, holy brothers, who share in the heavenly calling… (Hebrews 3:1)
Therefore, as God’s chosen people, holy and dearly loved… (Colossians 3:12)
Ignoring the context for a bit, I find it wondrous to think of myself as holy, chosen by God. How did this ever happen to me, of all people? Or you? Yet we are told this over and over in the Scriptures: Jesus says, “You did not choose me, but I chose you….” Paul says that God “chose us… before the foundation of the earth that we should be holy” and “He destined us in love to be his sons through Jesus Christ.” There are many, many more like this. The word “holy” means, basically, to be set apart for some purpose. We’re chosen, in other words, for a purpose.

I’ve heard this many times in sermons as well, but it still takes my breath away, because I know that I’m weak and easily distracted, my mind cluttered with carnal thoughts. I often see myself as a child, tossed back and forth by the waves, blown here and there, wishing I were more grown up. So these passages remind me that God has indeed set me aside for a purpose. Besides being deeply loved, I “share in the heavenly calling,” so I’m not rudderless. God has called me heavenward; he is working in me to fulfill his purpose as I seek him. Good news!

In both passages, this astounding good news of our identity as beloved holy brothers (male and female) is mentioned in passing, an “as-you-already-know”; the authors are about to tell us something even more important. What could that be? And is there any overlap in what follows?

Well, there’s not a lot. Hebrews chapter 2 ends with the encouragement that our brother Jesus knows our sufferings and temptations and can help us; then in chapter 3 we’re told, “therefore,” to consider Jesus, to fix our thoughts on him, and how he’s greater than Moses, worthy of greater honor. The author loves to tell us how great Jesus is: greater than the angels, greater than the priests of the old sacrificial system, and so on.

In Colossians, this reminder of our identity stands in the midst of a list of exhortations to live a holy life (3:5–17). In this letter, Paul seems fond of giving us lists of five: put to death sexual immorality, impurity, lust, evil desires and greed (3:5); to put aside anger, wrath, malice, slander and abusive speech (3:8). And then:

Therefore, as God’s chosen people, holy and dearly loved, clothe yourselves with compassion, kindness, humility, gentleness and patience, bearing with one another and forgiving each other, whoever has a complaint against anyone, just as the Lord forgave you, so also should you.
Colossians 3:12–13
There’s more after that, but what I wanted to notice from these passages is that the implications of our identity (as holy, chosen, beloved, called) involve our attitudes and actions (Colossians 3) and also how we focus our thoughts (Hebrews 3). Turning that around, when I remember I’m holy, chosen, beloved, called, then I’m better equipped in my efforts to fix my thoughts on Jesus and to live a holy life.

In other words, it’s not just the good news itself, but also the remembering of this good news, that enables me to become a good man.

Saturday, July 09, 2016

Stockholm, random notes 2016-07-09 Saturday.

We heard yesterday in Helsinki (where prices are lower!) that one can take a ferry overnight to Stockholm, spend a day here in S-town, and take the ferry back to Helsinki. And, I suppose, the reverse.

Certainly one could travel Helsinki to Tallinn and back -- probably just a few hours each way. On arrival in Stockholm we had a choice of transportation:

  • excursions organized by the cruise ship line (which are more expensive but you get preferential treatment: first off the boat; they'll hold the boat if you're late getting back; if you can't dock in port, that portion of the tour fee is refunded)
  • hop-on hop-off tours:
    • bus: 300 SEK (or SKr?) -- at $1=8.5 SEK, that's about $35
    • boat: 180 SEK or about $21
    • bus+boat: bus+boat, 400 SEK or about $47
  • The above options are offered by red sightseeing and also by the green outfit. Price and itineraries are basically the same, EXCEPT
    • first few departures of the RED boats from cruise ship dock go directly to the Vasa museum. This is a deviation from the published route (wherein you'd make 5? stops before getting there). I don't know if the green boats go there; I suspect not.
    • According to one of our fellow-passengers, the green boats were smaller and fuller -- that is, you might not be able to board!
  • According to one of the guys, boats come every 15 minutes. i don't think this is true: Carol swears we waited 30 minutes at one point. I'm not sure it was quite that long, but it was definitely more than 15 minutes. But every time we saw a green boat, a red boat was not far behind.
WHAT WE DID TODAY
  • Decided to get on the red boat. Because of price we went for boat-only. We got red by pure dumb luck, and went to Vasa museum. Admission 180SEK each, I think. We took the [free] English-language tour; guide was excellent.

    The Vasa was commissioned in 1625 and construction completed in 1628, taking 2+1/2 years to build. King Gustav II Augustus (I might have that name wrong) wanted to have 72 cannon on board--never been done before. The shipwright/architect said it would be unsafe, but as the king wanted that, he got it. Due to the unprecedented weight, the ship was built with very strong+heavy timbers belowdecks (this was usual) but also above (this was not usual) to support the heavy armaments. Turns out only 64 of the requisitioned 72 were ever delivered...

    Vasa was the eldest of four sisters: two big and two smaller vessels. The king was annoyed because Vasa took so long to build: usual construction time was well under two years. Construction of Vasa's sister (whose name I've already forgotten) was halted while all hands were on deck so to speak to complete Vasa.

    Vasa sailed on her maiden voyage, and the 2nd gust of wind tipped her a bit too much, and water rushed into her gun ports. The listing to one side was exacerbated by [1] all the cannon being on one side of the ship (I guess port side but am not sure) to fire a salute to the king, who was not even there to hear it; and [2] ballast in the stern (I think rocks) which shifted to the side, accentuating the list. Water entered the ship through the gun-ports and she sank in 20 minutes, killing we think 30 or 40 souls. Fifteen skeletons were found inside when she was raised in the 1960s; others escaped the ship but were drowned (couldn't swim).

    Vasa's sister was given a hull one meter wider and I think with fewer cannon. She sailed for 30 years (vs 20 minutes), so i guess they did learn something.

    The Vasa was discovered in the late 1950s (1956?) by some guy who was looking for it with a coring tool. After finding black oak in quite a large area, he understood that he'd found Vasa, but it took several years to rescue her from the bottom. Steel cables were placed under the keel, and affixed to pontoons floating on either side. (This was attempted shortly after she sank, but with ships anchored on either side. This is why many anchors were found atop Vasa when she was eventually raised.) The wood began to warp (etc) and they began spraying her with polyethelyne glycol (sounds like Saran Wrap(R) + antifreeze). They replaced her bolts with iron bolts (today most of these have been replaced yet again with stainless steel bolts). Once they got the water out of her, she floated! She was made of wood, right?

    btw she sank in very cold and brackish waters, which contributed to her survival. also there weren't any shipworms (i guess these things eat ships).

    About the sculptures around the boat; the bow has the lion, representing Gustaf ii adolphus/augustus/whatever. Near bow, on starboard side, is a man hiding under a table, supposedly for fear of the lion. The Swedish king was younger brother and protestant to the king of poland, who was Catholic. But Swedes didn't want to be Catholic. Other statues near the bow are the likenesses of Roman emperors; Gustav identified with them.

    At the stern, Gustav is seen (did i take a pic of this?) leading and protecting his people.

    Back to the Saran Wrap + antifreeze stuff; they've stopped spraying that. instead Vasa is kept in a temp/humidity-controlled environment. On many places the ship has reflectors. They want to preserve her for another 100 years (she was underwater for 333 years!) so want to be able to measure when she's deformed by gravity, by the wood's compression as it settles, etc.

    Something like 98% of the wood in Vasa was preserved; there are a few places where it was replaced. The bowsprit is one; the stern-most mast is another. You can tell by the color of the wood (new=lighter). Not all of Vasa is inside the museum; there are three masts visible outside the museum, indicating the full height of the original ship.

  • Afterward, we walked to Skansen, enjoying the beautiful Stockholm weather along the way. We entered Skansen by the not-main entrance (Hazelius?) and walked in. We saw King Oscar's Terrace and the rose garden, then turned to Makaloes (oe=o-umlaut) and followed the path to see reindeer and elk and some other domestic & wild animals.
  • Then we took the 15? minute walk to the hop... boat around to the first stop moderately close to Gamla Stan. The "Miss Behavin'"(?) Bar was right there, and we had 3 hot dogs (the "alex wiener") for SEK175; a cobb salad (another SEK175) and a beer (SEK75? 85?). Yeah, that's like $20 per entree, and about $10 for a beer.
  • At about 2:25 we boarded the boat, arriving at the pier about 3:10. We were on board well ahead of the 3:30pm deadline.