Skip to content

Commit

Permalink
Bugfix: Wrong intends/spaces #11
Browse files Browse the repository at this point in the history
  • Loading branch information
Jan Schiefelbein committed May 18, 2018
1 parent 6319134 commit 840c0f8
Show file tree
Hide file tree
Showing 3 changed files with 10 additions and 7 deletions.
4 changes: 2 additions & 2 deletions richardsonpy/classes/electric_load.py
Original file line number Diff line number Diff line change
Expand Up @@ -198,7 +198,7 @@ def __init__(self, occ_profile, total_nb_occ, q_direct, q_diffuse,
self.app_load_q = None # Appliance power profile in W
self.loadcurve_q = None # El. reactive power profile (Q) in VAr

self._timestep_rich = 60 # in seconds
self._timestep_rich = 60 # in seconds

if calc_profile:
self.calc_stoch_el_profile(q_direct=q_direct, q_diffuse=q_diffuse,
Expand Down Expand Up @@ -325,7 +325,7 @@ def calc_stoch_el_profile(self, q_direct, q_diffuse, is_sfh=True,
light_load = []
app_load = []

demand_q = []
demand_q = []
light_load_q = []
app_load_q = []

Expand Down
9 changes: 6 additions & 3 deletions richardsonpy/classes/stochastic_el_load_wrapper.py
Original file line number Diff line number Diff line change
Expand Up @@ -88,8 +88,10 @@ def power_sim(self, irradiation, weekend, day, occupancy):
Returns
-------
tup_res : tuple (of arrays)
Results tuple (power_el_total, power_el_light,
power_el_app)
Results tuple (power_el_total, power_el_light, power_el_app,
total_demand_q,
total_demand_lighting_q,
total_demand_appliances_q)
power_el_total : array
Array holding total el. power values in Watt
power_el_light : array
Expand Down Expand Up @@ -125,5 +127,6 @@ def power_sim(self, irradiation, weekend, day, occupancy):

total_demand_q = total_demand_appliances_q + total_demand_lighting_q

return (total_demand, total_demand_lighting, total_demand_appliances, total_demand_q, total_demand_lighting_q,
return (power_el_total, power_el_light, power_el_app, total_demand_q,
total_demand_lighting_q,
total_demand_appliances_q)
4 changes: 2 additions & 2 deletions richardsonpy/examples/example_el_load.py
Original file line number Diff line number Diff line change
Expand Up @@ -72,12 +72,12 @@ def example_stoch_el_load(do_plot=False):

fig.add_subplot(212)
plt.plot(time_array, el_load_obj.loadcurve[0:timesteps], label='El. load P')
plt.plot(time_array, el_load_obj.loadcurve[0:timesteps], label='El. load Q')
plt.plot(time_array, el_load_obj.loadcurve[0:timesteps], label='El. load Q')
plt.xlabel('Timestep in hours')
plt.ylabel('Electric power in W')
plt.xlim([0, 24])

plt.legend()
plt.legend()
plt.tight_layout()
plt.show()
plt.close()
Expand Down

0 comments on commit 840c0f8

Please sign in to comment.