Showing posts with label math. Show all posts
Showing posts with label math. Show all posts

Reshaping heat transfer

The last step in production from my home bioreactor is to heat the mixture to a specified internal temperature, about 95-98C. The first few times I tried, I followed the instructions exactly and it worked great.

Then I decided that the final shape of the product when following the instructions was not as convenient to me as I would like. Using a different shaped container was in order. However, this different container was not only a different shape, it was not conducive to pre-heating and had nowhere near the capacity for storing heat and holding its temperature as the original, inconveniently-shaped container did.

I tested it out anyway, and while it did produce a final product of about the shape I wanted, the characteristics of the material in the centre had changed. It was usable, but not as easily so. I eventually figured out that it hadn't heated up right through as it should have. I tried heating it for a slightly longer period, but that didn't seem to make much of a difference.

Trial and error will take far too long. Clearly, this calls for some math.

Overflowing with math

New toy!

After discussing the options with one of my co-workers, I installed SciPy and all its associated dependencies, because it was free and had more than enough computational power to do what I wanted to play with. I don't know enough about any of the computer-math programs to make a case for work buying me one of the very expensive programs, and I couldn't rationalize buying such a program for myself at home to play with, so open source it is.

My first "project", such as it was, was both somewhat practical and relevant to my work, while still being easy enough for a first project: calculating how long it takes for the flow to reach steady state in a series of tanks with a pump at one end (step change input) and gravity flow all the way through.

Bioreactor growth rates

My home bioreactor took 48 hours to get going where the instructions said 24-36 hours was typical, but it got going. About two weeks after startup the active cell culture had matured and I decided to put it into production. The instructions indicated that 1.5 hours at room temperature would be an adequate first stage reaction period. Four hours into it the first reaction stage wasn't finished, so I put the lot into the fridge and went to bed; clearly the time estimates were not representative.

I knew putting it in the fridge would slow the reaction down to the point where I could pick it up again the next day, because it's a bioreactor and they're sensitive to temperature - specifically, the reproduction rate of the cell culture slows down dramatically when cooled.

That's when I realized that my bioreactor had been reacting more slowly than the instructions suggested was normal every step of the way.

Boiling with salt

Getting back into chemistry after last week's fun little diversion into mechanics, I feel like doing some more math. I was looking for a recipe not long ago and ran across repeated mentions that one adds salt to water when boiling food in order to raise the temperature at which the water boils, thus cooking the food faster.

Boiling point elevation is a real thing, as is freezing point depression, and it's not hard to calculate.

The boiling point of pure water at sea level is 100oC. In order to calculate the change in temperature, we need the following equation:

\[\Delta T = K_b m\]

Violent separation

In keeping with my original plan for this blog, I am now going to teach myself something new.

Here is something I have known about and occasionally seen since I was a kid, and know the name of, but hadn't seen it in operation and didn't actually know how it worked until I decided to write this post and figure it out:

It works exactly the same way as this thing, which I saw for the first time as an adult:

Mortality

Here's a pair of medical terms I have often seen together. One of them I thought I had a moderately good understanding of the meaning, and the other I wasn't really sure exactly what it meant.

As with my previous post in this series, the same comment applies: If a medical doctor happens to read this and notices that I have something wrong, I would be thrilled to get a correction. I'm not a doctor and I'm writing this for other not-doctors; while I'm ok with simplification I don't want to be wrong.

Now, for my pair of terms: mortality is the former; it means how many people die. (Rather appropriate for a Hallowe'en post!) But it's also more than that; it is, specifically, the number of deaths in a given group over a given time period, and what the group and time period is has to be defined. The restrictions make sense, once I stopped to think about it: ultimately, the mortality of humans is 100% - everybody dies of something, at some point. But if you look at the mortality of a disease, or a type of accident, then the group is restricted to the people who have that disease or that injury, and the time is restricted to the time of the study, and the mortality is less than 100%. Something else kills the other people in the study at some other time, not covered by the study.

Splat!

Figuring out where a spatter came from is useful sometimes. Not in any field I've personally worked in, but then I don't usually work with things that go splat. Some things which go splat, where the spatter marks remaining after the fact are the only evidence available to figure out how exactly it happened, include volcanoes (which can make very big, very dangerous splats most sane people wouldn't want to watch in person) and people being attacked (which often ends with the source of the spatter in no condition to describe the attack).

One obvious thing about spatters is that the individual marks are ovals, and they point in the direction of their source. This has been known for a long time now, and has been used in forensics to determine where a victim was. It could also be used for volcanoes, if nobody saw which of the vents erupted due to running for their lives.

What the oval spatters didn't accurately point to was how high the source was.

How much does a cloud weigh?

I was chatting with a friend not long ago, and he mentioned that he sometimes pictured clouds as these malevolant, multi-ton monstrosities hovering overhead, just waiting to smash down on us tiny humans. And by the way, how much does a cloud actually weigh?

Clearly, this calls for some math: I decided to calculate how much a cloud actually massed.

I started out by finding a cloud that I could measure reasonably well.

Snow eater

The Chinook wind is a warm dry wind that comes down from the Rocky Mountains into Alberta, and can turn a winter day into short-sleeve weather in the space of hours. But what heats up the air? It wasn’t that warm on the BC side of the rockies, before it crossed the mountain range. Well, I decided that I was going to calculate it. Let's see if this works.

Let’s say the air comes off the ocean at about 10 degrees Centigrade and 90% relative humidity, which isn't actually typical for a dreary Vancouver winter day—but that's because the Chinook is powered by the Pineapple Express, which is warm, wet air coming inland from Hawaii. It travels inland, raining on Vancouver as it goes, until it hits the coast mountain range, and is forced to rise.

You’ve probably noticed, if you’ve ever changed altitude quickly, that it gets colder the higher you are. Well, that wind from the ocean is going to do exactly that.

To do the math, we’ll look at a small piece of the wind, pretend it stays together to simplify things, and follow it over the mountains.

Up, up, a little bit higher

In honour of today's shuttle launch, I thought I'd start off with a bang, or at least a roar of fire: rocket fuel!

The shuttle uses two different styles of rockets with two very different types of fuel: liquid and solid. The shuttle itself has three big rocket engines that run on liquid hydrogen and liquid oxygen, stored in the big orange external tank, while the rest of the thrust is provided by solid fuel in the solid rocket boosters, a mixture of ammonium perchlorate (NH4ClO4), aluminum, iron oxide, and some binders to hold it in its moulded shape.

The liquid fuel engines fire first; they are the controllable ones. If there's a problem, they can be shut down. Once the solid fuel starts burning, they only stop by running out of fuel - and the solid rockets provide the majority of the boost to get the shuttle off the ground.

And since this is a chemical engineer's blog, I'm going to do some calculations around the chemistry of those engines. Of course, this won't be nearly enough to design your own rocket engine from, but then I'm just doing this for fun, I'm not a rocket scientist.