c源代码需要帮助 [英] c source code help required

查看:98
本文介绍了c源代码需要帮助的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我需要找到所有线性方程组的解,其中变量的个数都不大于方程的个数.

可以有多个解决方案.

我需要对所有解决方案进行一些计算.

在此先感谢

例如H = [1 0 0 0 0 0
0 0 1 0 0 0 1
0 0 1 0 1 1
0 0 0 1 0 0]


b = [0
0
1
1]


X = [x1
x2
x3
x4
x5
x6


HX = b

如果有四个可能的解决方案,我希望全部解决.

谢谢




I require to find all the solution of linear system of equations where no of variable are more than no of equations.

There can be more than one solution.

I need to do some calculation on all solutions.

Thanks in advance

For example H=[1 0 0 0 0 0
0 0 1 0 0 0 1
0 0 1 0 1 1
0 0 0 1 0 0]


b=[0
0
1
1]


X=[x1
x2
x3
x4
x5
x6


HX=b

If there are four possible solutions I want all of them.

Thanks




Guys ,Thanks for your well meaning advise but I am new to c code and have posted first time on a forum.Basicaliy I am a research scholar trying to implement a paper in matlab.I have implemented most part in Matlab but was struct in this linear function solving,where the no variables are more than the equations.
   I have solved for one solution but am required to find all possible solutions to calculate minimum weight.AS c code can be included in Matlab I am asking help for coding in just this single function.

Thanks

推荐答案

我们不做您的作业:它的设置是有原因的.在这里,您可以考虑自己被告知的内容,并尝试理解它.也可以在那里帮助您的导师识别您的弱点,并将更多的注意力放在补救措施上.

自己尝试,您可能会发现它并不像您想的那么困难!
We do not do your homework: it is set for a reason. It is there so that you think about what you have been told, and try to understand it. It is also there so that your tutor can identify areas where you are weak, and focus more attention on remedial action.

Try it yourself, you may find it is not as difficult as you think!


这篇关于c源代码需要帮助的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆