Library for working with C81 airfoil data
Project description
c81utils
A Python module for working with C81 airfoil tables.
Usage
c81utils implements a C81 class that handles the C81 data for each airfoil. A few example usages are shown below:
import c81utils
import numpy as np # Works with numpy arrays too
# Use 'load' to obtain data from a C81 formatted text file
with open("NACA0012.C81", "r") as f:
naca0012 = c81utils.load(f)
# Use the 'get' commands to obtain bilinearly interpolated data
desiredAlpha = 5.0 # in degrees
desiredMach = 0.3
desiredCL = naca0012.getCL(desiredAlpha, desiredMach)
desiredCD = naca0012.getCD(desiredAlpha, desiredMach)
desiredCM = naca0012.getCM(desiredAlpha, desiredMach)
# Combine 'get' commands with the 'map' command to operate on lists
desiredAlpha = np.linspace(0, 10, 6)
desiredMach = [0.0, 0.1, 0.0, 0.3, 0.5, 0.8]
desiredCL = list(map(naca0012.getCL, desiredAlpha, desiredMach))
# Data may also be input using arrays
alpha = [0, 2, 4, 6]
mach = [0.0, 0.5, 1.0]
Cx = [[0.0, 0.0, 0.0],
[0.2, 0.2, 0.2],
[0.4, 0.4, 0.4],
[0.6, 0.6, 0.6]]
CL, CD, CM = Cx, Cx, Cx
myAirfoil = c81utils.C81('myAirfoil', \
alpha, mach, CL, \
alpha, mach, CD, \
alpha, mach, CM)
Installation
c81utils is written in Python 3. Use pip to install.
pip3 install c81utils
1.0.7 (2022-09-07)
Fix multiline data recognition.
1.0.5 (2021-07-21)
Ensure mach and alpha arrays have atleast two values.
1.0.4 (2021-07-21)
Ensure mach and alpha arrays are strictly increasing.
1.0.0 (2020-04-25)
Initial release.
Project details
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
Built Distribution
Filter files by name, interpreter, ABI, and platform.
If you're not sure about the file name format, learn more about wheel file names.
Copy a direct link to the current filters
File details
Details for the file c81utils-1.0.7.tar.gz.
File metadata
- Download URL: c81utils-1.0.7.tar.gz
- Upload date:
- Size: 18.4 kB
- Tags: Source
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/4.0.1 CPython/3.9.10
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
92ac7030db6f817082a5a0163aba023d7b899aecfab7dc66d46114177a9c6ed8
|
|
| MD5 |
08be1ab95519642a1dc8828e088c3c4d
|
|
| BLAKE2b-256 |
1b0a6bc894d2792df5229e7e40532a7c29f4b8ff6b762cce50eeeed5171e8534
|
File details
Details for the file c81utils-1.0.7-py3-none-any.whl.
File metadata
- Download URL: c81utils-1.0.7-py3-none-any.whl
- Upload date:
- Size: 17.2 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/4.0.1 CPython/3.9.10
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
4d9242f8f0af5d1491b4e998f7f47ce4088ad64d014b5c459328e62390e304dd
|
|
| MD5 |
d150a259aaee7dcc309dbacfc49bd548
|
|
| BLAKE2b-256 |
c6f652e5455c6e49f9e18fb15db73377bfb5b9815808895b1e4ff7425ce1a7f9
|