interp2 -strictly monotomus increasing
2 次查看(过去 30 天)
显示 更早的评论
Nm=[0.0366242038216561 0.256369426751592 0.671443736730361 1.03768577494692 1.58704883227176 2.00212314225053 2.53927813163482 2.91772823779193 3.40605095541401 3.84554140127389 4.37048832271762 4.84660297239915 5.31050955414013 5.70116772823779 6.07961783439491 6.32377919320595 6.45806794055202 6.51910828025478 6.55573248407643 6.48248407643312 6.40923566878981 6.33598726114650 6.26273885350318 6.21390658174098 6.14065817409767]
tm=[0.485833678632479 2.97491876894587 5.92553696834441 5.95681051392846 8.98528217489712 8.10274242779360 10.4015267390947 9.17522019607471 11.2522554584995 11.4037507008547 13.2569373682494 13.4685308941754 14.0861325375119 13.8739774388098 14.3517545727446 13.1898905990187 12.1320463219057 11.3801661360874 11.1561990863248 9.75845459943019 9.63848959401710 9.51852629230771 9.39856469430197 9.60254185941754 9.19863248363408]
data=xlsread("ss.xlsm");
rrpm=data(2:end,1);
ttorque=data(1,2:end);
epk_eff=data(2:end,2:end);
[ttorque,rrpm]=meshgrid(ttorque,rrpm)
eff_epk=interp2(ttorque,rrpm,epk_eff,tm,Nm);
%%excel sheet attached for eff_data
4 个评论
Asvin Kumar
2021-3-17
编辑:Asvin Kumar
2021-3-17
It's unclear what you're trying to achieve or what problem you're facing.
Are you seeing any errors? Are you stuck somewhere? What's your question? For the community to help you better, please add descriptions of what you are trying to do.
Have a look at the doc page for interp2 on the 4th and 5th input arguments. You should either change the orientation of Nm or tm. Or you should create a meshgrid out of Nm and tm like you do for ttorque, rrpm.
回答(0 个)
另请参阅
类别
在 Help Center 和 File Exchange 中查找有关 Logical 的更多信息
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!