Created
November 24, 2016 17:42
-
-
Save darthcoder/85774ca356bb10b2aad60e59cf251664 to your computer and use it in GitHub Desktop.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| 1.8658892 | |
| 2.6044703 | |
| 3.7317784 | |
| 3.8483965 | |
| 4.159378 | |
| 4.2371235 | |
| 4.664723 | |
| 5.1311955 | |
| 5.7531586 | |
| 6.1030126 | |
| 6.686103 | |
| 7.1525755 | |
| 7.308066 | |
| 7.6190476 | |
| 8.08552 | |
| 8.590865 | |
| 9.718173 | |
| 9.912537 | |
| 10.379008 | |
| 11.856171 | |
| 13.216715 | |
| 14.305151 | |
| 16.015549 | |
| 16.793003 |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| import numpy as np | |
| import sympy | |
| import matplotlib.pyplot as plt | |
| from math import pi, sqrt | |
| sympy.init_printing(use_unicode=True) | |
| RHO_AIR = 1.225 | |
| RHO_WATER = 1000.0 | |
| D = 0.0254 | |
| R = D/2 | |
| A = pi*(D**2)/4 | |
| g = 9.8 | |
| MU = 8.9e-4 | |
| SIGMA = 7.28e-2 | |
| ALPHA = 0.67 | |
| Co = 1.2 | |
| AIR_EXPT = np.loadtxt("./data/air_standard.txt") | |
| print(AIR_EXPT) | |
| water_arr = np.array([]) | |
| Q_air = AIR_EXPT/(RHO_AIR * 3600) | |
| # print(QG) | |
| QF = sympy.symbols("QF") | |
| Bo = ((RHO_WATER)*g*D**2/(SIGMA)) | |
| v_ts_dash = 0.352 * (1 - 3.18 * (Bo ** -1) - 14.77 * (Bo ** -2)) | |
| v_ts = v_ts_dash*sqrt(g*D) | |
| temp = 0 | |
| for QG in Q_air: | |
| left = QF + (1.34*pi*R)*((Co*(QG+QF)/A)+v_ts)*\ | |
| ((MU*QF/(A*SIGMA*(1-(QG/(Co*(QF+QG)+(A*v_ts))))))**(sympy.S("2/3"))) | |
| right = pi*(R**2)*((Co*(QF+QG)/A) + v_ts) | |
| equation = sympy.Eq(left, right) | |
| Q_water = sympy.solveset(equation, QF) | |
| water = list(Q_water)[0] | |
| temp = water*3600*RHO_WATER | |
| # print(temp) | |
| water_arr = np.append(water_arr, temp) | |
| print(water_arr) |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment