Calculating average over a year time

Hello All,
This question might be a very simple one but still I couldn't get the idea as how to do it.
I have a time vector and output power vector (Both yearly data) I want to calculate the avg. output power over the year.
Any suggestion is highly solicited !!!!!

댓글 수: 2

José-Luis
José-Luis 2012년 8월 22일
Accumarray sounds like what you might need. What is the format of your time data?
Swasti Khuntia
Swasti Khuntia 2012년 8월 22일
Time vector is in format of [0,3600,..., 31536000] Power vector is [0, 564.34,..., 0] Both have 8760x1 size.
I guess this data is enough.
Thanks

댓글을 달려면 로그인하십시오.

 채택된 답변

Andrei Bobrov
Andrei Bobrov 2012년 8월 22일

0 개 추천

Power_year_average = trapz(Time_vector,Power_vector)/Time_vector(end);

추가 답변 (0개)

카테고리

도움말 센터File Exchange에서 Numerical Integration and Differentiation에 대해 자세히 알아보기

태그

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!

Translated by