Saturday, March 19, 2016

Arduino Powered Sous Vide

Hi all,
 I have been playing around a lot w/ electronics, in particular the Arduino. For those that don't know, Arduino is basically an open-source microcontroller (coded in C) that can be used for reading sensors and controlling electronic devices as a result. In this particular post, I decided to do a food-related project called "Sous Vide" that consists of a constant temperature water bath that you can cook various meats in to a perfect, uniform temperature that makes them taste amazing. While there are many commercial products on the market (Amazon affiliate link: Anova Culinary PCB-120US-K1 Bluetooth Precision Cooker, 800 Watts, Black), I wanted to make my own as a fun project.
I started by putting together a power box. This consisted of a solid state relay, a wall outlet (GFCI is probably best), a fused/switched  power input line, a project enclosure box, and an external power source (wall voltage, 120V). The relay was triggered on/off by a 5V signal from the Arduino. I used an Arduino with a buttoned LCD display, and a thermistor temperature sensor. Using these, I was able to build a setup that I could set the temperature I wanted to run at, plug in my crock pot, and control using my power box. (Feel free to purchase components through my Amazon affiliate links)
Unfortunately, the crock pot heated very slowly, taking 1.5 hours to get to temperature. I decided to augment the system using a standard coffee pot heater. Here is a picture of the setup:
ubn1ocgHere, I used a wall powered GFCI outlet (for safety), with the powerbox/arduino setup, a slow cooker pot, water pump, and a coffee machine water heater.
The coffee pot heater that I salvaged from an old hot water heater, I used in conjunction with some food safe, high temperature compatible tubing (I had to buy the 1/2" to 1/4" adapter hose barbed pieces on E-bay). The heater  took 120V AC power directly, which I hooked up directly through the solid state relay in the power box.
I purchased a 9V submersible pump that could handle up to 180°F from E-bay, and pumped water through the coffee pot heater at a rate of ~400 mL/min. After hooking up the thermistor and Arudino to complete the control loop. I was able to maintain reasonable control of the temperature. In order to implement my chemical engineering controls knowledge, I built a PID temperature controller that viewed each of the integral, derivative, and proportional controls in Python (wxpython, matplotlib; used Arduino serial communication to send data to laptop):
The first graph: Black is the set point, and red is the temperature (see that it overshoots by ~1.5 degreesF at first, then dampens out). The second graph shows the controller parameters: black is the p (proportional), red is the integral (builds up over time the longer that the system is away from the setpoint), blue is the derivative (accounts for how quickly the temperature is changing), and green is the overall %on (the sum of the others, except for the derivative which is subtracted).
The finished product after I had set the crock pot at 135°F (medium rare temp) for about an hour w/ a nice Ribeye:
After a quick sear (a minute or so) on each side (cast-iron pan with a little bit of oil, quite hot), the steak looked amazing (and tasted the same). The texture was uniform all the way through, and was extremely juicy!

Overall a fun project, let me know if you've got any questions!

Sunday, January 24, 2016

Frost On My Car

Frost On My Car

So, with the brunt of winter upon us I thought that I would share some of my experiences. Living in Oklahoma, our winter hovers on the edge of freezing quite often. One thing that I noticed right away was that on many nights that were near freezing (35°F or so), I would have to scrape ice off of one side of my car, but not the other. A few questions came to mind, First: Why is my car frosting when the low temperature was not below freezing (32°F)?, Second: Why was the ice only forming on one side of my car and not the other?

So this is approximately the setup of my car sitting in the drive way (garage door in front of it):

First, the initial question: Why would ice form when the temperature wasn't freezing yet? The answer is simple, but probably not something that most people think about. It boils down to radiation. If we think about what temperature the car is in absolute terms (i.e., with the vacuum of space defining a temperature of absolute zero--Zero degrees Kelvin), your car sits at let's say 35°F=1.7°C=275 °K. This is significantly higher temperature than the vacuum of space, which is readily accepting the radiated heat from your vehicle. Of course if the sky is cloudy, the clouds will be significantly hotter than outer space and the chance of frosting over will be much lower.

Question 1: Temperature at Which the Window Should Frost

Now, to do a quick thought experiment to determine lowest approximate ambient temperature (T∞) that might lead to the window frosting over.


The amount of heat radiated from your car window to space can be described using the Stephan Boltzmann Law (assuming your car window is a black body):

 q = σ (Twindow - Tspace)^4

Where q is the heat flux (per unit area), σ is the Stefan Boltzmann constant (5.67E-8 W/m^2/K^4), Twindow is the temperature of your car in Kelvin, and Tspace is the temperature of outer space. 

However, the story is not so simple because the car window is actually receiving radiation from all around (the adjacent buildings, walls, etc). Here is a schematic (and actually picture) from the car of the adjacent building that shows the "view factor" of the window to space.

And the actual picture from the car:

In this case, the "view factor", accounts for what percentage of the window surface can radiate to another object (in this case, we'll consider outer space and the adjacent house). From this picture, I'll estimate the view factor of the window to space as ~0.1 (i.e., 10% of the radiation from the window is radiated to space while 90% is radiated to the adjacent house/ground/etc.). Also, the window is at a slightly lower temperature (let's say the freezing temperature of water, Twindow=32°F=0°C=273.15°K) than the adjacent house (which is warmer--possibly around or slightly higher than the ambient temperature, T∞).

The net  heat loss from the window due to radiation can be computed by:

Where we've assumed that space is approximately 0°K and that the adjacent house temperature is slightly higher than the ambient temperature (Thouse = T∞+ΔT). With this, we've developed a function for the amount of radiative heat transfer out of the window given the ambient temperature (T∞) and an assumption for the house temperature relative to ambient (say ΔT = 4°C or so--as in the house hasn't quite cooled down to ambient yet--which is reasonable).

Natural Convection

Now that we've considered the radiative component of heat transfer, let's consider the counteracting force of convective heat transfer. In this case, because the window is at the frosting temperature (Twindow=0°C=273.15K) and the ambient air is possibly a higher temperature, the ambient air will actually act to warm the window. This will be what is known as natural convection (i.e., cooling by air that moves over a surface due to the fact that  it's being heated or cooling, as opposed to force convection which might happen if it is windy). 

The relevant equations that allow us to compute the convective heat transfer coefficient, h is that for the Nusselt number (Nu):

Where kair is the thermal conductivity of air at 0°C ( and Lwindow is the characteristic dimension of the window (assumed to be ~1 meter). The remaining parameter is the Rayleigh number (Ra), which is given by:

The Rayleigh number is a dimensionless number that is the product of two other dimensionless numbers: the Grashof number (Gr) and the Prandtl number.
The Grashoff number takes the ratio of the fluid buoyancy to the viscous driving forces. Here, we use the thermal expansivity (β = 1/T for an ideal gas) and the kinematic viscosity of air (νair).

We can compute the Ra number for a given ambient temperature (T∞).

Which can be used to compute the convective heat transfer coefficient (h) as a function of T∞.

By balancing the convective (qconv = h*(T∞-Twindow)) and radiative heat fluxes, we can come up with a final answer to the question of what temperature might the window on that side of the car freeze:

The ambient temperature (T∞) which gives a net heat flux of zero (i.e., which can sustain the window at Twindow = 273.15K), for the given assumptions is about 275°K (~35.3°F). This seems like a reasonable estimate, and explains why your car window will frost at above 32°F.

Question 2: Why doesn't the other side of the car frost over? 

So to answer question two: why didn't the window on the side of my house ice over? The answer is simple: those windows didn't radiate directly out to space. Their view factor to the adjacent house was too high, and therefore we had significantly less radiative heat loss (the house was actually radiating its heat to the car as well since they are close). The neighbors house, on the other hand, was too far away to provide the same effect (as it had a lower view factor). 

In the case of the smaller view factor to space (in the limit of zero), the window will not freeze until the ambient temperature reaches freezing (in reality, it will have to be below freezing to cool the window). This is why it's much more difficult for a car to frost when sitting in a garage or under a car port.

Interestingly, previous questions have been asked before:


Saturday, January 23, 2016

First Post

First Post

Hey all, this is my first post. The purpose for this blog is to serve as an outlet for my scientific interests, and to document some of my thoughts on a variety of subjects. An engineer by training, I plan on focusing on quantitative calculations and analyses of things of little importance. I'll apply my skills in statistics, programming, data analysis, electronics and instrumentation, etc. to anything and everything! 

I thought that I would share a bit about myself and my scientific background.

I'm a PhD, chemical engineering, currently working in R&D for the oil and gas industry. 

Quickly, I'll detail a bit about my research from my PhD. I studied thermoelectric materials with Jeff Snyder (who recently transferred to a professor position at Northwestern University). My PhD focused on improving thermoelectric materials, which convert waste heat into electricity. These solid-state devices perform these conversions with no moving parts, and provide reliable transformation for decades at a time. As a result, these materials are often used in conjunction with nuclear power sources for space missions, basically creating a nuclear battery (known as a radioisotope thermoelectric generator, RTG).

Looking forward to it!