Dyspeptic retired Marine wife/tech wench attempts to enlighten the great unwashed of the blogosphere while dodging snarky commentary from the local knavery.

January 09, 2014

Public Policy and the Edge Case

One of the more interesting aspects of the Blog Princess's day job involves thinking about software algorithms. She works for a software firm that developed a suite of tools with distinct purposes and capabilities. Each tool can be used alone, but they were also designed to work together. Natürlich, the interfaces between applications greatly complicate the design of new features (and even trivial changes to existing features).

Dealing with any application in isolation is complex enough at times. But when changing a feature in one application can cause unintended consequences in other tools, making even the simplest decisions involves not only consideration of the instant requirement or problem, but careful thought as to how a change might cause unintended consequences in other tools.

To make things even more complicated, we have to satisfy a broad spectrum of end users ranging from nontechnical folks to engineers who don't trust any number or model unless they have personally worked through the math themselves. Most of the nontechnical folks don't use our tools every day. Consequently, they need only 10% of the core functionality. For this set of clients, ease of use and simplicity are paramount. They don't want to have to wade through a gazillion dialogs and settings and help topics to get what they want: fast results. They need simple, clear instructions with just enough "why" to support informed decisions but not so much detail that they get overwhelmed. Because most of these folks don't have a background in statistical modeling, explaining how our tools work is a real challenge (and arguably the favorite part of my job). To support them, I often resort to analogies - I try to relate some abstract concept to a familiar, real life situation they already understand intuitively.

Other clients are power users - they push the tools to (and sometimes past) the breaking point. These clients need a rich and complex set of features with maximum flexibility. Their needs are diametrically opposed to those of more infrequent users. They demand detailed, in depth instructions to support complex processes and decisions. To support this set of clients, I sometimes have to write long whitepapers that step through the logic in great detail, using a mix of math and everyday analogies.

Reading this story, I was struck by the similarities between algorithms - which are really nothing more than sets of rules that govern how software should behave - and the interlocking system of local, state, and federal laws we live under. Both systems are composed of individual laws or algorithms, typically designed to address a specific need or problem. But neither individual laws nor individual algorithms operate in isolation. They are part of a greater system in which new laws or changes to existing laws often cause unintended problems. And both systems must be flexible enough to be used in ways their creators never anticipated or intended:

The diagnosis was crushing and irrevocable. At 33, Marlise Munoz was brain-dead after collapsing on her kitchen floor in November from what appeared to be a blood clot in her lungs.

But as her parents and her husband prepared to say their final goodbyes in the intensive care unit at John Peter Smith Hospital here and to honor her wish not to be left on life support, they were stunned when a doctor told them the hospital was not going to comply with their instructions. Mrs. Munoz was 14 weeks pregnant, the doctor said, and Texas is one of more than two dozen states that prohibit, with varying degrees of strictness, medical officials from cutting off life support to a pregnant patient.

More than a month later, Mrs. Munoz remains connected to life-support machines on the third floor of the I.C.U., where a medical team monitors the heartbeat of the fetus, now in its 20th week of development. Her case has become a strange collision of law, medicine, the ethics of end-of-life care and the issues swirling around abortion — when life begins and how it should be valued.

In the natural order of things, when a pregnant mother dies (in this case, when nature is allowed to take its course) so does her child. But for the active intervention of the hospital, this poor woman would have passed on.

And so, tragically, would the tiny life growing inside of her.

This is what bothers me so much about the conflict between the rights of an individual - the baby - and the interests of her father and grandparents. I understand the purpose of laws that place individual welfare - even that of a 14 or 20 week old fetus - above the welfare or wishes of other individuals: this woman's family. But they're not just individuals - they're also a family whose lives are inextricably intertwined, and whose decisions impact the rest of the family.

I used to associate "individualism uber alles" with the political left, but (perhaps as a consequence of the encroachment of big government on individual liberties) I often hear right-leaning pundits stressing individual interests over the interests of institutions like family, community, the military, the church. These institutions are - like individuals - the building blocks of civilization. Tex touched briefly on the balancing of individual and group interests a while back:

The Burkean believes government is there to give all of the institutions of society room to thrive and discover what is good through trial and error. The Paineian sees progress as a society-wide movement, led by government, with no safe harbors from the Cause. This is why Paine was one of the earliest advocates of a welfare state — funded by a massive inheritance tax — that would intervene to empower every individual.

President Obama's second inaugural was a thoroughly Paineian document. In his telling, America is made up of individuals and a government with nary anything in between. And because "no single person" can do the things that need to be done, "we must do these things together, as one nation."

The conflict between progressivism and conservatism is often described as a simplistic clash between collective and individual interests. But I don't think it's that clear cut. Both sides seem to move flexibly from defending individual or collective rights as the instant case demands, and the right in particular has recently placed increasing emphasis on individual rights, even to the point of worrying about how social pressure (which we used to prize as the natural ordering mechanism of civilization) can affect individual liberty.

This story lends itself to the individual/collectivist framework. The specter of the Nanny State stepping into what ought to be a private family decision is horrifying to me. At the same time, I recognize the value of that tiny life: one that cannot yet survive on its own and one whose soul - were nature allowed to take its course - would now be with its mother's in a far place none of us have ever seen, but to which we will all travel some day.

When we criticize laws we don't like, we almost always do so based upon their results in the instant case. We deplore the effects on the people and situation we're considering right now. We rarely if ever consider the vast spectrum of situations most laws will be applied to.

It's this result - this outcome - that infuriates us; that makes us say, "That's a bad law that should be abolished". All the other outcomes and scenarios, unconsidered, do not matter much at this moment. And that seems to me to be the impetus for many laws in the first place - this situation is intolerable. "Something" must be done to address it. But that something will not only be applied to the scenario we are dealing with today, but to so many situations we aren't considering right now.

This year, whilst designing test cases (this is a new thing for our group), one of our developers used a term I had never heard before: the edge case.

An edge case is a problem or situation that occurs only at an extreme (maximum or minimum) operating parameter. For example, a stereo speaker might distort audio when played at its maximum rated volume, even in the absence of other extreme settings or conditions.
An edge case can be expected or unexpected. In engineering, the process of planning for and gracefully addressing edge cases can be a significant task, and one that may be overlooked or underestimated.

Non-trivial edge cases can result in a failure of the object being engineered that may not have been imagined during the design phase or anticipated as possible during normal use. For this reason, attempts to formalize good engineering practices often incorporate information about dealing with edge cases.

In programming, an edge case is typically a unit test that tests a boundary condition of an algorithm, function or method. A series of edge cases around each "boundary" can be used to give reasonable coverage and confidence using the assumption that if it behaves correctly at the edges, it should behave everywhere else.
For example, a function that divides two numbers might be tested using both very large and very small numbers. This assumes that if it works for both ends of the magnitude spectrum, it should work correctly in between.

It's my sense that, like most statistical models, good laws are ones that work for the vast majority of cases they are applied to. But the edge cases, though statistically rare, can also have catastrophic consequences. We run into this a lot in testing: a client does some something unusual or unexpected and suddenly the design of a feature that has worked reliably for years - decades even! - is suddenly called into question. Is it worth redesigning the feature to handle the rare edge case? Will doing so make the model work less well in the middle?

Many years ago - 40 or more - I heard a news story about some poor Third World country. The government had decided it needed men to mine something or plant something or build a road or whatever. The government sent troops to a small village out in the middle of nowhere and scooped up all the men and boys who were the right age to do the work. The soldiers left with their captives and no one left in the village knew where the men and boys had been taken or if they would ever come home again.

I was horrified and heart-broken. That government, I was sure, was made up of cruel men who cared nothing for their fellow citizens. It never occurred to me that those men undoubtedly believed that they were doing the best thing for the country as a whole; that the suffering of a few was a fair price to pay for the betterment of many; and that those who opposed them were short-sighted and, quite possibly, selfish and hard-hearted to complain about the plight of a few when so many would benefit.

The damage from ObamaCare is not on the same scale as the damage from that Third World government’s policies, of course, but the shape of it is the same, as it is for the people displaced by the TVA, as it is for all the people whose lives have been disrupted or damaged in the name of progress or the greatest good for the greatest number or simply because those in our government are convinced they know what’s best for every man, woman, and child in the country. The intentions may have been good but the reality is that the government doesn’t know what’s best; the greatest good for the greatest number is an illusion; and progress is something people do, not something government creates. And you know what they say about the road to Hell.

Every act, every decision we make in life has consequences. Some are immediate and obvious. Others are obscure or rarely encountered, but when they are they too can be extraordinarily painful.

Wherever you come down on the conflict between the state of Texas and a heartbroken family struggling with the loss of (depending on how you look at it) either one or two people they share a blood tie with, this seems like a great argument for humility.

Both from those who make laws, and those who comment upon them from the comfy chair. May God comfort and strengthen these poor folks.

Trackback Pings

TrackBack URL for this entry:
http://www.villainouscompany.com/mt/mt-tb.cgi/4932

Comments

What we don't see here is something that may be unknowable - what would the woman herself have wanted? Would she have wanted to have been kept alive in order to enable her child to be born?

Many people of both the left and the right would tell you that it is the proper function of the State to protect those who cannot protect themselves. The left holds this to be true in the case of a pregnant woman if she desires that the fetus she carries needs such protection (e.g., pre-natal health care). But they hold that it's not true if the woman does not desire that protection (e.g., if she wants an abortion). The right tends to hold that the fetus should be protected against death regardless of the desires of the mother.

The bottom line here is that due to the intervention of the State, a child will be born and life who otherwise would not have. Does that not outweigh imposing life support on this woman and delaying her woman's inevitable end a few months? Do we know what suffering - if any - she is undergoing?

The bottom line here is that due to the intervention of the State, a child will be born and life who otherwise would not have. Does that not outweigh imposing life support on this woman and delaying her woman's inevitable end a few months?

Honestly, I don't know that it does. The problem is that this is very much a value judgment (or as Herr Taranto so trenchantly put it the other day, a "moralistic fallacy" that "clouds social thought" :p)

Those pesky morals - they do make life complicated, n'est pas?

There are so many unknowns here. Having carried two children inside me, I can't help but wonder about the effects on a baby when its mother dies, both psychological and physical. Call me silly, but you'd be surprised how much nonverbal communication takes place between an unborn child and its mother. My babies reacted when I was feeling strong emotion, to the point that one of my fondest memories is of being maybe 5-6 months pregnant and in a bar (no, I wasn't drinking) with a band playing "Tulsa Time".

My oldest, then still inside me, became very agitated and scared when the crowd started clapping and singing along. I had to walk out of the main part of the bar and place both hands over my tummy and speak soothingly until he calmed down.

This kind of thing happens every day when you're pregnant.

And then there's the whole question of oxygen deprivation. It's one thing for the parent(s) to say, "We want to take that chance and we'll deal with whatever happens." But the State forcing that decision on parents who will then have to care for a child that - were we to accept nature's course - would never be born?

That's obscene to me. I can understand all the arguments made on the baby's behalf, but to me there's a difficult and tragic balancing act here that transcends simple answers (not accusing you of this!) or ideology.

It is for this the concept of subsidiarity had been formulated, and formalized (Catholic Church). In its dismissal we relegate ourselves to regulations, -ethecists, and apparently, ultimately, to a single judgment, or a best of three appellate, or best of nine supreme.

The realization and acceptance that we live in an imperfect world is our greatest achievement. Failing that, we make for everyone a living hell, i.e., an arena and a brawl.

OK, I had to look up "subsidiarity". I thought I might be able to glean the meaning from the root word and context (and it meant pretty much what I thought it did_, but I'm glad I looked it up because the definition added to my understanding.

George, you've neatly captured part of what I was trying to convey but couldn't quite wrap my typing fingers around in the short time available this morning. Thanks for teaching me something I did not know :)

The problems of edge cases begin with that there are so very many of them that we know of, even more that we don't, discovering them only with careful hindsight, and frequently they are so hard to test -- and harder to fix -- if you can correctly describe them.

(A famous one in the computer hardware industry is the Intel F5 DIV error; it's exceedingly expensive to test such a branching matrix completely, and very expensive to test just the choices you're sure are the edges. This is part of the reason that military comuter hardware and software is so bleeding expensive, the deeper testing.)

I sit in my study and read proposed laws and write to legislators pointing out edges; if they reply, it's almost always to say that those things won't happen. When the legal system is making millions of decisions a day, that one in a billion chance will happen every three years.

But the State forcing that decision on parents who will then have to care for a child that - were we to accept nature's course - would never be born?

Gandalf said:

"Many that live deserve death. And some that die deserve life. Can you give it to them?"

The state seems to me to be acting wisely here, preserving what can be preserved out of hope. But I have said sometimes lately that I want the state to be unable to interfere within the family; and I think that's a good example of your point. Almost all the time, the state's interference in families is baleful. So we accept the destruction of the few cases on the edges, in return for having a good rule that limits the exercise of power.

Your reading of what I propose is, I think, the opposite of what I said. (It could be the "Perhaps" that is throwing you off; but it's honestly included, because it's a dangerous conclusion that might need to be explored further.)

It could be that the best course is for the state to be stripped of the power to interfere within families; that the family, like the Church, should be autonomous within its sphere and protected from intrusion. Its influence is usually baleful, and in numerous ways.

However, there are perils in doing so -- including perhaps this one. I am uncomfortable with the idea that the child's right to live can be discarded by its mother (as in abortion); here we are extending that power to discard it to the family more broadly. It's not clear to me why this doesn't end up endorsing even exposure of living infants in the case where the family doesn't want them: after all, they too will die in the course of nature without constant care.

If the state has any right to act, it would seem to be to protect those children who have rights as individuals that must be enforced upon families. That's the usual argument against the idea of making the family autonomous: think what it would mean for children trapped in bad families!

If that is the right role for the state, then this case seems to fall within it. But if the family should be autonomous, as churches are, then the state should not be able to interfere here (or elsewhere: opposition to abortion would have to be purely moral and persuasive, and could encompass no laws of any kind, because the state would have no power to interfere within the family's -- the mother's -- decision).

So which should it be? I am lately considering that a child trapped in a bad family is not necessarily worse off than a child trapped in a bad church: a church that raises her to believe she ought to be invisible, or sacrificed when her husband dies.

We don't pull children out of churches like that. Is it really worse to believe that the child should be sacrificed if her mother dies than if her husband does?

As a moral point, I think that surely both propositions are wrong; but the question isn't whether these are moral beliefs (or actions), but whether the state should have the power to enforce the right on families who disagree.

Let me make sure I have this right. The mother is definitely dead. Her unborn child is not, and by keeping the mother's body viable, the child has a good chance to live, probably a full life.

Well, I can think of a few things:

1. The mother is brain dead and is only alive because she's being kept on artificial life support.

2. The family wants to let her die naturally. They don't want artificial life support.

3. Who is going to pay for all of this? I'm guessing the hospital hasn't offered to foot the bill for six months of treatment the family didn't ask for.

4. The mother's brain died because it was deprived of oxygen. The baby's body and brain get oxygen (and everything else) through the mother's body.

5. If the baby lives, it may well have very serious medical problems (including the strong possibility of brain damage because of the aforementioned oxygen deprivation). Who will care for the baby? Who will pay for a lifetime of medical treatment?

6. Several medical ethicists say the hospital isn't even interpreting the law correctly - there's a HUGE difference between being in a coma or vegetative state and being brain dead. The law doesn't prohibit withdrawal of life support for brain dead patients. It prohibits withdrawal of life support for patients in a coma (who might well regain consciousness).

7. This sentence:

...Mrs. Machado said the doctors had told her that they would make a decision about what to do with the fetus as it reached 22 to 24 weeks, and that they had discussed whether her daughter could carry the baby to full term to allow for a cesarean-section delivery. “That’s very frustrating for me, especially when we have no input in the decision-making process,” Mr. Machado added.

So here we have a hospital that has - on the basis of a possibly mistaken interpretation of state law - completely overridden the family's wishes and cut them out of the picture.

If the end justifies the means, I guess that's OK. I'm not sure it does.

The obvious analogy here is to families whose religion prohibits medical treatment - the state just takes the child away and treats him or her regardless of the wishes of the parents. But this is a different situation in that these same parents could not legally kill their child to spare it from suffering.

The Machados could abort a pre-viable baby quite legally if (for instance) it were discovered the baby had severe brain damage or some horrific medical condition. Quite frankly, they could do so even if there were absolutely nothing wrong with the baby. There are sound moral arguments for and against such a course, but there's no doubt that it's legal.

Yet in this case, the Nanny state can order the parents to incur huge medical costs and suffer enormous mental anguish against their will in a case where, in the natural order of things, the baby would already have died.

I think where people come down on this one depends on whether you believe the individual is more important than the family, or whether the State has the right to cut the family out of the decision making process and then turn around and tell them to deal with a situation that would not exist, but for their interference.

Here's the really ironic twist: I've seen many, many conservatives argue that abortion unfairly considers ONLY the mother's wishes.

If she wants the baby, it's a baby.

If she doesn't want the baby, it's a clump of cells.

Here, we don't know the mother's wishes because she's dead. If she were alive and learned her child's brain had been deprived of oxygen, she might well decide to abort. We'll never know.

Once again, the father's wishes are not considered at all. They simply don't matter (even though he will have to bear the financial and emotional burden of the State's decisions regarding his unborn child).

Observations:
1. In higher math, edge case = boundary value equation (particularly DiffEQ's)
2. I am unable to resolve the issue of the differing interests between a mother and not yet viable fetus.
3. The link at the end includes a photo of 'Galloping Gridy' (Original Tacoma Narrows bridge). That bridge failed due to a lack of understanding of harmonics, and is not an 'edge case.'
BTW, in engineering calculations the boundary values are almost always some sort of assumption.' Though these starting points often have historical bases (think prevalence of fires, earthquakes, storms, etc), they fundamentally rely on subjective judgment.
4. Notwithstanding any theories about morality, I have a *huge* personal problem w/ the gov't making decisions about life and death in lieu of family. Just.not.right.

Notwithstanding any theories about morality, I have a *huge* personal problem w/ the gov't making decisions about life and death in lieu of family. Just.not.right.

I think this is my primary problem with this - it's almost an aesthetic consideration, as I can readily think of examples where the state would be right to step in (malicious/abusive families causing - through inaction, perhaps, needless suffering to a helpless child, etc). As such, my aesthetic or gut reaction is very hard to defend.

One can think of cases where such interference seems right and just and cases where it does not. The differences tend to center around motive (benign or malicious?) and outcome (child lives/suffers less, or child dies/suffers more).

The scary thing here is that we honestly don't know if the "child lives" outcome will result in the "child suffers less" outcome. Absent some very compelling reason, I suppose I prefer to err on the side of telling the government (state or federal) to stay the heck out of it.

Let's say that the child had been 1 month old when the mother died while cooking dinner and in the process started a fire. The firefighters show up and find that the child had been pinned down somehow and could not be removed in time. The firefighter decides that perhaps he can buy the child time until the fire can be put out by covering him with the mother's body. There is a chance that doing so may smother the child and kill it, but there is also a chance that the mother's body will provide insulation and prevent the child from being burned. There are no guarantees that the child will be unharmed. He may survive but with severe injuries that come with a lifetime of expensive treatments, but doing nothing will kill him.

Furthermore, when the firefighter walks out of the house to inform the family what he had done, they get angry because the mother had vehemently opposed being cremated as she didn't like the connotation to burning in Hell. They then tell the firefighter to go back in (let's ignore the risk to the firefighter as the doctors face no personal physical risk) to retreive the mother's body to prevent it from being burned and "let nature take it's course" with the baby.

Let's say that the fireman did as the family wished.

Do you think the fireman should go to jail for negligent homocide as he took an affirmative action (that is not mitigated by saving another person's life, but rather to ensure the family's desired disposal of a dead person's body) that guaranteed the death of a child?

I think a fireman can't be held to the same standard of care as a medical doctor.

I also think a 1 month old baby is different from a 14 week old fetus (but I realize this will get me into BIG trouble in some quarters). The salient point here is that the fetus can't possibly survive - even for an instant - without the mother. If she dies, the fetus dies.

Whereas a baby can survive without it's mother - any competent/caring adult can care for it, really.

Essentially I don't think leaving the baby in the house would be letting nature take it's course. Firemen have a pre-existing duty to save people from fires that is mitigated only by the longstanding recognition that we don't require someone to throw their own life away needlessly if there's no hope. I don't see this situation fitting that template.

A doctor's duty is to provide medical treatment and advice. So there's a big difference in the standard of care (the nature of the duty, and the degree of care we expect).

I also think a 1 month old baby is different from a 14 week old fetus (but I realize this will get me into BIG trouble in some quarters).

Ultimately, this is where most of the arguments around abortion and such revolve around. Whether or not the fetus does, in fact, have a right to life. Honestly, it seems that once one answers this central question everything else follows from that. Even, quite possibly, whether or not this situation is even an edge case.

That said, do firefighters actually have a legal duty to rescue people when they haven't been paid to do so? Us city dwellers don't have to worry about that because we pay for that service through our taxes. But for those areas where there is only fire service if the home owner buys service, do firefighters still have a legal duty to go in even if the homeowner didn't buy service? I know they wouldn't be prevented from doing it, but I really don't know if refusal would be considered a crime (if you could show little personal risk). Scumbaggy certainly, but I don't think it's criminal.

And granted, a medical doctor doesn't have to worry about his own life, but if you are a paying customer I'm pretty certain witholding care is a big no-no unless you've told them otherwise up-front. Accidentally witholding care is malpractice. I would think intentially witholding care would be much, much worse. Legally, this is even true, under certain circumstance, when they have no expectation of being paid. Life-Saving is one of those cases.

So, if I'm correct (and I may not be) an MD may have a greater legal duty towards saving a life, all else being equal.

I really hope someone is working on an artificial womb and a way to transplant the unborn.

Ultimately, this is where most of the arguments around abortion and such revolve around. Whether or not the fetus does, in fact, have a right to life. Honestly, it seems that once one answers this central question everything else follows from that. Even, quite possibly, whether or not this situation is even an edge case.

I'm not sure that's really the question, though.

It seems to me the question is more, "Before birth, is the child a completely separate being from the mother?" I would argue that until viability, it is not. It will be, someday. But there's a literal physical dependence on the mother that can't currently be filled by any other person. Mothers and babies exchange blood, hormones, germs, oxygen, nutrients, and even genes during gestation.

Both current and historical laws on this subject seem to view things in just this light: they view the fetus as a child only if it has a chance of surviving outside the womb.

This is one of those areas where I really have a hard time with the conservative line. We're all "biology rulez - get used to it!" until biology becomes inconvenient to the argument, then suddenly it can be set aside. But biology here is pretty compelling - before it is born, a baby derives everything it needs for life from the mother. It literally cannot survive without her.

I'm not sure about the ethics of artificial wombs. There is so much we don't understand about gestation. It seems really arrogant to me to assume that chemistry is all that's going on there. That seems even more peculiar to me coming from people whose objections to abortion include concerns for the child's soul and for God's will.

I have a really hard time saying to myself that God intended humans to stray so far from his creation. But I admit that may be arrogance/lack of imagination on my part :p Maybe anything humans can think of is "God's will" (I don't incline to this view, but I can't disprove it either). We certainly like to convince ourselves of that, but if that's true then we don't really have free will at all. It's all predetermined.

As for firefighters, most negligence law is state law, so that varies by state. I'll bet DL Sly knows!

"Before birth, is the child a completely separate being from the mother?"

Possibly so. But that also seems to be something of a rubric to try to get to whether (or when) the fetus has any enforcable rights. Some may get there through faith, some may get there through biology (though Grim takes a biological view and reaches a different conclusion), some may get there through potential harm, etc.

Maybe anything humans can think of is "God's will"

Yeah, that's a tricky one. After all, some already declare that modern medicine isn't in "God's will". If we could descern that, the world would be a different place. Myself, I usually take the tack that God is more concerned about our character than our physicality. If we could stick implants into our eyes that allowed augmented reality functionality, I think God would be concerned with what we did with that technology rather than whether or not we had it.

But what do I know? Maybe that's just post hoc rationalization because I think stuff like that is cool.

Volunteer fire departments will, in general, not save the buildings or property of someone who hasn't paid. Life saving they might do, but it's very dangerous for them to do so, as those making the attempt would have no insurance coverage and would expose their (say) township to a great financial risk. It's like buying insurance; you make the purchase before making the claim. (And yes, city slickers who come to the country have tried to write checks for the current year when they see their house going up, having refused to do so for a decade. They even become violent and shoot at both people and equipment.)

I'm a little curious about the case that started the discussion; "the hospital" ... was this a doctor, a committee of doctors, an administrator, a nurse, a lawyer ... who was "the hospital"?

Post a comment

To reduce comment spam, comments on older posts are put into moderation 5 days after the last activity. Comments with more than one link also go into moderation. If you don't see your comment after posting it, try refreshing the screen. If you still don't see it, your comment is probably in the moderation queue.