fraction_of_day = (target_time.hour*60 + target_time.minute) / (24*60)
total_minutes_in_day = 24*60
# use double cos wave for intenisty, but set night time to zero
if fraction_of_day > 0.25 & fraction_of_day < 0.75:
intenisty = cos(2 * 2*pi*fraction_of_day)
else:
intenisty = 0
power = capacity * ( intenisty)
Always nice to do a different function (+ a small test), and then use that function in the two locations
Make random number sin fake data to reflect sun
Detailed Description
Context
Make fake data a bit more real
Possible Implementation
some in here and here
Probably good to do something like this
Always nice to do a different function (+ a small test), and then use that function in the two locations