# Understanding NACA Airfoil Aerodynamics Using Python

Written on

## Introduction

This article aims to clarify the essential features of **NACA airfoils**, particularly for beginners studying **aerodynamics**. It starts with the basic principles of **airfoil geometry** and then discusses how to implement these concepts in **Python** to compute important **numerical characteristics** for visualizing a NACA **4-Series** 2D wing profile with **Matplotlib**.

**Airfoils represent the cross-sectional shape of wings.** The National Advisory Committee for Aeronautics (NACA) developed a variety of airfoil designs, known as NACA Airfoils. Figure 1 showcases different examples of these wing sections.

The most frequently examined series in introductory aerodynamics include **four-digit** and **five-digit** designs, with some **six-digit** variants as well. This article specifically addresses the four-digit series, such as the **NACA 4415** airfoil.

## Airfoil Geometry

Figure 2 illustrates a sample **symmetrical** airfoil, highlighting key geometric parameters.

**Leading and trailing edges**: The foremost and rearmost points of an airfoil, respectively.**Chord**: A straight line connecting the leading and trailing edges of the airfoil.**x**: The horizontal distance along the chord, starting from zero at the leading edge.**y**: The vertical height relative to the horizontal x-axis.

Figure 3 shows a **cambered** airfoil. **Camber** is essentially the curvature of the airfoil.

**Mean camber line**: This line is located halfway between the upper and lower surfaces, corresponding to the geometric centerline.**Thickness (t)**: The height distribution along the length of the airfoil.

From the diagrams presented, it is clear that two main variables describe the **geometric profile** of the airfoil surface: **camber** and **thickness**.

A crucial element of the design is that the **4-Series airfoil shapes** are derived from analytical equations that define the mean camber line and the thickness distribution of the section. Later families, such as the 6-Series, are created using more complex **theoretical methods**.

## 4-Series Equations

A NACA 4415 exemplifies a member of the 4-Series family, with the digits 4415 characterizing the 2D **profile**.

Equation 1 represents **digit 1**, indicating the **maximum camber (m)** as a percentage of the chord. Thus, the maximum camber for the 4415 airfoil is 4% of the chord length.

**Digit 2** is used in Equation 2 to find the **maximum camber (p)** location from the leading edge in tenths of the chord. Therefore, for a 4415 airfoil, the maximum camber occurs at 40% along the chord length.

Equation 3 employs **digits 3** and **4** to determine the **maximum thickness (t)** as a percentage of the chord. Thus, the thickness of the 4415 airfoil is 15% of the chord length.

Gist 1 includes **Python** code that defines three functions to extract the **numerical airfoil characteristics** based on the NACA four digits.

For a **symmetric airfoil**, the first two digits are zero, e.g., **0015 ? m = 0, p = 0**.

Two equations specify the **mean camber line**, depending on whether the **x** coordinate is less than or greater than the maximum camber position (**p**), as shown in Equation 4.

**It’s vital to emphasize that the equations provided are purely analytical, established by NACA through extensive research and experimentation.**

Gist 2 presents the Python implementation of Equation 4.

**y** corresponds to the **thickness distribution**. The thickness values above (+) and below (-) the mean camber line depend on Equation 4.

The **x** coefficient varies depending on whether the trailing edge is open or closed; for instance, **-0.1036** corresponds to a closed surface, while for a finite thickness trailing edge, use **-0.1015** instead.

**y** is calculated in Python using Gist 3.

Thickness values are added **perpendicular** to the mean camber line, necessitating an angle to indicate the **offset** of the addition.

Taking the derivative of the mean camber line yields the **slope of the tangent line** to the curve. Differentiating Equation 4 with respect to **x** results in Equation 6.

Obtain the **derivative of the mean camber line** using the Python code in Gist 4.

Calculating the **inverse tangent** of this derivative provides the angle **?** to offset the thickness from vertical. Refer to Figure 3 to understand the significance of **?**.

Finally, to determine the **upper** and **lower** airfoil **surface coordinates**, use Equations 8–11, where **?** represents the inverse tangent of the derivative of the **MCL** at **x**, as derived from Equation 7.

Gist 6 provides the code to calculate the final (x, y) values for the airfoil’s upper and lower surfaces.

## Plotting Results

Utilize the resulting values of (**x**, **y**) to plot the **final wing profile**. Figure 4 demonstrates the NACA 4415 plotted using **Matplotlib**.

Figure 5 shows another example of a cambered 4-Series airfoil, the NACA **2412**. Visually compare the geometric characteristics of the 4415 and 2412, paying attention to the y-axis scale.

As mentioned, these analytical expressions are applicable to **symmetrical airfoils**.

Both the mean camber line and thickness distribution align perfectly with the chord, as evidenced in the plot of a **0015** in Figure 6.

## Conclusion

Each equation is **generic** and can be **parameterized** with any four digits to visualize any member of the NACA 4-Series family.

This article has outlined fundamental airfoil properties and demonstrated a method to implement the geometric expressions for plotting the 2D surface profile of a wing.

Thank you for reading! Please let me know if you would be interested in other **aerodynamics** related articles.

## References

[1] **Fundamentals of Aerodynamics**. Sixth Edition. John D. **Anderson**, Jr. Curator of Aerodynamics. National Air and Space Museum. Smithsonian Institution.
[2] **NACA Airfoils** — NASA. *Last Updated: Aug 7, 2017, Editor: Bob Allen*
[3] The NACA airfoil series (AA200_Course_Material) — Stanford
[4] Explained: NACA 4-Digit Airfoil [Airplanes] — Josh The Engineer