How i can create a n+1 column matrix from n column matrix?
1 次查看(过去 30 天)
显示 更早的评论
i have a matrix 10*n, for example, let n=3
a= [ 1 2 3
1 2 4
1 2 5
1 3 4
1 3 5
1 4 5
2 3 4
2 3 5
2 4 5
3 4 5]
i want to create another matrix n+1
b=[1 2 3 4
1 2 3 5
1 2 4 5
1 3 4 5
2 3 4 5]
this is obtained from a as
{1 2 3} and from
{1 2 4}
{1 2 3 4} is created, where no pair must repeat and
{1 2 3} or
{1 2 4} or
{2 3 4}
all pair must be present in a or delete that pair.
please please help me.
i want to know how i can obtain a 4 column matrix from 3 column matrix, if i want 5 column from 4 column matrix then where is the main change in code.
please help me.
0 个评论
采纳的回答
更多回答(0 个)
另请参阅
类别
在 Help Center 和 File Exchange 中查找有关 Resizing and Reshaping Matrices 的更多信息
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!