Skip to content

Commit

Permalink
update calcconstant for united keydict access
Browse files Browse the repository at this point in the history
  • Loading branch information
bqpd committed Apr 28, 2018
1 parent e71ff3b commit c8c5e8e
Showing 1 changed file with 2 additions and 3 deletions.
5 changes: 2 additions & 3 deletions solar/solar.py
Original file line number Diff line number Diff line change
Expand Up @@ -533,10 +533,10 @@ class Climb(Model):

def density(self, c):
" find air density "
ft2m, alpha = 0.3048, 0.0065 # conversion, K/m
alpha = 0.0065 # K/m
h11k, T11k, p11k, rhosl = 11019, 216.483, 22532, 1.225 #m, K, Pa, kg/m^3
T0, R, gms, n = 288.16, 287.04, 9.81, 5.2561 #K, m^2/K/s^2, m/s^2, -
hrange = [c[self.h]*ft2m*i/(self.N+1)
hrange = [c(self.h).to("m").magnitude*i/(self.N+1)
for i in range(1, self.N+1)]
rho = []
for al in hrange:
Expand Down Expand Up @@ -633,4 +633,3 @@ def test():
M = Mission(Vehicle, latitude=[15])
M.cost = M[M.aircraft.Wtotal]
sol = (M.localsolve("mosek") if SP else M.solve("mosek"))

0 comments on commit c8c5e8e

Please sign in to comment.