i have an error with the function tomrun.I am running in the simulink in an embedeed blocks.This is the code
Wnl = 1; dw = zeros (2,10); dw = [Wnl Wnl Wnl Wnl Wnl Wnl Wnl Wnl Wnl Wnl; Wnl Wnl Wnl Wnl Wnl Wnl Wnl Wnl Wnl Wnl]; Prob = qpAssign(FF, S, Alpha, b_L(1:7), b_U(1:7), [], [], [], [],... [], [], [], [], [], [], []); Result = tomRun('qpSolve', Prob, 1) eml.extrinsic('extractResult'); dwp = extractResult(Result) dwopt = [0 0]; dwopt = dw wstart = [0.98 0.99]; Wnlop = wstart + dwopt ;%%function extract results
function dww = extractResult(Result) dww = Result.x_k; end
And i am taking this error Embedded MATLAB Interface Error: Size mismatch for MATLAB expression 'dwp'. Expected = 1×2 Actual = 2×1 Block load_sharing (#19) While executing: none.
I tried to change the size but again i'm taking the same error,can someone help me?
Best Answer