How to find value of large area based different values of small area?

2 次查看(过去 30 天)
I am trying to find overall value of wind for large zone where sample points have small zonesand all them have individual values. Also, values depend on size of zones as well. Here, large zone falls partially on other 3 zone while fully on zone 1.
Pressure in zone 1 = P1, similarly pressure in other zones = P2, P3, P4
Yellow color area in zone 1 = A1, similarly yellow color area in other zones = A2, A3, A4; total yellow area (A)= A1+A2+A3+A4
Equation should be this way for the Pressure of large zone ==> P = (P1A1 + P2A2 + P3A3 + P4A4) / A

回答(1 个)

Zahrah Walid
Zahrah Walid 2022-12-9
I'm not completely sure that I got your question but as far as I understand you want to implement this algorithm using MATLAB; if yes, this is a really easy task with various ways, for example if P1=100, P2=200, P3=300, A1=5, A2=10, and A3=15:
data=[100 5; 200 10; 300 15]; %constrcut n*2 matrix with pressures in first column and areas in second column
A=sum(data(:,2)); %total area
P=sum(data(:,1).*data(:,2))/A; %P = (P1A1 + P2A2 + P3A3 + P4A4) / A
  1 个评论
Jigar
Jigar 2022-12-9
Hello Zahrah,
No. Overall area of yellow zone is known, and how much portion of that zone falls in other zones is not known. So I need to create code for that by which I can calculate pressure based on given equation.

请先登录,再进行评论。

类别

Help CenterFile Exchange 中查找有关 Tables 的更多信息

产品


版本

R2022b

Community Treasure Hunt

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

Start Hunting!

Translated by