早教吧 育儿知识 作业答案 考试题库 百科 知识分享

matlab做求大神帮做下四元线性拟合数据为x1=[871.1,912.37,954.28,995.01,1037.20,1046.74];x2=[12413,13568,13635,17230,18003,18311];x3=[27465059,33780554,39180316,43675520,50516743,61556537];x4=[816526,525399,1242672,1630780,2624514,295314

题目详情
matlab做求大神帮做下四元线性拟合
数据为
x1=[871.1,912.37,954.28,995.01,1037.20,1046.74];
x2=[12413,13568,13635,17230,18003,18311];
x3=[27465059,33780554,39180316,43675520,50516743,61556537];
x4=[816526,525399,1242672,1630780,2624514,2953149];
y=[337,382.8,415,449,453,458];
求拟合程序啊
▼优质解答
答案和解析
P = regress(y',[x1',x2',x3',x4']) %需要常数项就在最后加一个ones(size(x4'))