Multiple linear equality constraints in fmincon
Show older comments
Hi
I am optimising the elements of a matrix X based on an ojbective function. I know what value of sum of row elements and sum of column elements should be. I want to optimize the matrix based on these 2 constraints.
If the size of the matrix is
, for
row and
column,
, for
column,1) sum of column 1 elements:
= known column 1 sum.
This can be done for every column giving n column constraints.
I can represent this in 
where
=ones(1,n) and
=
known vector
known vector2) I need to do the same for row elements too. I have the known
vector.
I'm unable to define one
and
which constraints the row sum as well as column sum of matrix X
Thank you
Accepted Answer
More Answers (0)
Categories
Find more on Systems of Nonlinear Equations in Help Center and File Exchange
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!