Hi,
I'm trying to write a function using the Evaluation-Based Representations framework. The basic structure of the file is standard:
switch class(varargin{1})
case 'double'
...
case 'sdpvar'
varargout{1} = yalmip('define',mfilename,varargin{:});
case 'char'
...
I tried calling the code with a 2x2x2 sdpvar, and it didn't match any of the cases. I then noticed that the class was in fact "ndsdpvar", so I added
case 'ndsdpvar'
varargin{:}
varargout{1} = yalmip('define',mfilename,varargin{:});
However, this gives the error
??? The following error occurred converting from constraint to logical:
Error using ==> logical
Conversion to logical from constraint is not possible.
Error in ==> yalmip at 169
if this_hash == internal_sdpvarstate.ExtendedMap(i).Hash
Can the code be adapted to handle multi-dimensional SDPVAR objects?
Thanks.