Adjoint-Based Design Optimization
for Unsteady Flows
Adviser: Luigi Martinelli
David E. Karp
Mechanical and Aerospace Engineering
“Once you’ve figured out which direction you want to go, finding cool projects is easy.”
I was a mechanical and aerospace engineering (MAE) major who enjoyed math and wanted to design race cars. By the time I needed to pick a thesis topic, it had become fairly apparent that the natural merger of these interests was computational fluid dynamics (CFD). CFD is a term applied to a group of techniques used to model the fluid flow around (or inside) some object and has been used for the last several decades on everything from fighter jets to oil pipelines. It also has become a bit of a buzzword in the aerospace industry (not quite as bad as “nano-,” thankfully), and at this point it seems that everybody studying aerodynamics uses CFD in some fashion or another. However, as any experienced aero engineer still clinging to a copy of Hoerner’s Aerodynamic Drag will be happy to tell you, there are still a lot of open problems in CFD. I guess the point I’m trying to get across is that realizing I wanted to do a thesis related to CFD is something akin to a history major realizing they’d like to do a thesis on American history.
Fortunately all of the MAE professors have their own niche, and seem to love working a lecture or two about it into whatever class they teach. So in my junior year fluids class with Professor Luigi Martinelli (one of the four classes I would end up taking with Professor Martinelli), he spent some time explaining a method that he and then-Princeton-Professor Antony Jameson had developed that used CFD to perform automated aerodynamic design optimization. The idea was to use concepts from control theory to close the design loop and allow a computer to run intelligently through many design iterations, making fine-tuned adjustments that no human designer could reasonably manage. As an example, Professor Martinelli showed how much more efficient the Boeing 747 could be made by running his code for 45 minutes on an old desktop computer (spoiler alert: It could be made a lot better). I thought this was simply too cool.
I had typically been more interested in the application of CFD than the development of the methods for much the same reasons that I picked engineering over math. Therefore, I did a primarily theoretical thesis on the fundamental mathematics of automated design optimization and am now enrolled in a master’s program in mathematics. I can think of no better way to sum up the experience of the last year of my life.
Flexibility really was the mantra for my thesis. By the middle of October, Professor Martinelli and I had settled on a primary topic (extending automated design to cover unsteady flow problems), but the scope of my thesis varied wildly up until the day I handed it in. Part of this was because of the limitations of my time (senior fall can be a bit crazy with applications for jobs/fellowships/grad schools/MAE 412 “Microprocessors for Measurement and Control”), but a lot of it was because neither Professor Martinelli nor I were sure exactly how the math was going to work out. Professor Martinelli was naturally much more comfortable with the math behind the method and had a sketch in his mind of how the unsteady derivation should go, but it turned out to be not quite so clear cut. What started as a project about merging two FORTRAN codes to implement what seemed to be a simple extension of an existing method became an exercise in figuring out, “How do we deal with that extra term?”
At first this was fairly terrifying. But after a few rather lengthy meetings with Professor Martinelli, it became clear that I wasn’t being (overly) dense; there actually was some serious thought that needed to go into handling a few terms in the unsteady equation that are conveniently absent from the steady form. Our meetings tended to consist of Professor Martinelli explaining his take on the simple way it should work, and then me attempting to show all the complications I’ve found with it and asking Professor Martinelli to stop me when I’d broken the rules of calculus of variations (a fairly common occurrence). I certainly did work on my thesis outside of these meetings, but as far as I’m concerned, this is where my thesis was actually created.
In fairness, the “think alone in your room for a while about a problem and then spend hours working through it on a whiteboard with your adviser” approach is the antithesis of an MAE thesis. I never blew anything up, didn’t use a lathe or end mill all year, and only wrote a few fairly brief MATLAB codes. In general, the theoretical versus experimental (or practical design) choice is probably the most important decision to make when picking an MAE thesis. A theoretical thesis had the advantage (and disadvantage) that if things weren’t working, it was 100% my fault for not thinking hard enough. The experimental option has the advantage of being really cool if you’re into that sort of thing (and if you’ve made it through three years of MAE, you are). There were certainly times when going the theoretical route was a bit disappointing (I had spent most of my time at Princeton explaining to my operations research and financial engineering roommate that MAE was cooler because our textbooks had flames), but I can’t see myself making a different choice.
I think the last thing to talk about—and the one everyone always seems most preoccupied with—is time management for my thesis. Anyone who knew me senior year can tell you that my time-management skills were functionally nonexistent when it came to my thesis. Be very wary of the “procrastinating hard work with easy work” trap, although I imagine my COS 226 “Algorithms and Data Structures” read-mes were far more thorough than they would have been if I didn’t have my thesis to work on once they were finished. In the end, I didn’t sleep for 51 hours prior to binding my thesis (although one of those hours was spent playing an intramural floor hockey championship game—it’s important to keep priorities in order). I wouldn’t recommend this strategy, and if you can find time to make good headway on your thesis before March or (gasp!) in the fall semester, you are better for it. But if sometime around spring break you have nothing written and are still being “flexible” with the scope of your project, don’t freak out too much. Also, keep in mind that all your A.B. friends will be done three weeks before you and will probably want to hang out on the back porch of your eating club 24/7. Factor this in when estimating how much work you can do in the final weeks of your thesis.
Well, I imagine that’s most of what I can share about my thesifying experience. In general, the most important advice I can give is to figure out what you want to get out of your thesis. There is a lot of flexibility in MAE, so really put some thought into the experimental or theoretical decision (and also the group or individual option). Once you’ve figured out which direction you want to go, finding cool projects is easy.
Adjoint-Based Design Optimization
for Unsteady Flows
David E. Karp
Associate Professor of Mechanical and Aerospace Engineering
“David’s thesis is a beautifully written report, and has been a useful reference for one of my incoming graduate students.”
A knock at your door. A student face peeking in. A brief introduction followed by a refreshing conversation on possible topics for an independent work or thesis. This is how the journey of a faculty adviser in the Department of Mechanical and Aerospace Engineering (MAE) generally begins, and like any other journey, it will forever add to one’s life experience in ways that cannot be foreseen.
Professionally, advising a senior independent project, and in particular a senior thesis, is one of the more challenging and rewarding experiences of teaching at Princeton, especially because it is a unique opportunity to share with the students the essence of our chosen profession. Given the breadth of our field, which covers a broad spectrum of disciplines and approaches, our seniors may elect to carry out a practical design project, or they may decide to explore advanced, contemporary topics in applied sciences and mathematics. While advising a design project, I enjoy the balancing act between fostering creativity and requiring that all ideas be supported by scientific data and not just intuition. Advising research-oriented theses, however, provides me the opportunity to reinforce another important aspect germane to engineering. When working toward the solution of new problems, we as engineers are compelled to identify and overcome “bottlenecks,” a task that often requires the development of new enabling technology and sometimes even new scientific discovery.
David Karp approached me in September 2009 expressing a keen interest in doing research in my chosen field of computational fluid dynamics (CFD), a very specialized, interdisciplinary field that allows the analysis of flow phenomena and systems by using high-performance computing. I am generally cautious about taking on theses in CFD because of the steep learning curve that students need to overcome before conducting research in this area. Nevertheless, having taught David a range of subjects from mathematical methods in engineering to fluid mechanics and aircraft design, I knew his potential well and was convinced to give him a chance and let him tackle a difficult and important topic on shape optimization.
Analysis alone can only offer limited guidance to an engineer on how to improve his or her design. The real problem faced by an aerodynamicist is the determination of a feasible shape that meets all of the design requirements with minimal cost. In his thesis, David embarked on the development of automatic shape optimization techniques for aerodynamic devices operating in a nonstationary flow, such as flapping wings or the blades of a wind turbine.
The most challenging aspect of advising such a project was bringing David up to speed on some of the more advanced topics in applied and computational mathematics, which are normally not covered in our standard undergraduate curriculum. This also was the most rewarding aspect since it gave me the opportunity to work with David on a one-on-one basis, allowing me to clarify and refine some of my own thoughts on the subject. I know that I will look back fondly at the hours spent with David at the white board in my office for many years to come.
In his work, David succeeded in framing the optimization problem in a mathematically rigorous fashion, and through the computation of a few model problems he offered important insight for further studies. David’s thesis is a beautifully written report, and has been a useful reference for one of my incoming graduate students, who is beginning research in this field.
So what is the best advice I can give to a senior considering independent work in MAE? Imagine you find yourself at your favorite amusement park. It is the end of the day, the last day of the season. You have time for one last ride: Choose your favorite, latch the safety restraint, and enjoy the ride. It will be the most exhilarating experience of your Princeton engineering education.