필터 지우기
필터 지우기

Facing Error in CVX_matlab log_normcdf() function

조회 수: 9 (최근 30일)
SAM Arani
SAM Arani 2022년 5월 21일
in MATLAB Version: 9.12.0.1884302 (R2022a)
Using CVX_Matlab:
CVX: Software for Disciplined Convex Programming (c)2014 CVX Research
Version 3.0beta, Build 1183 (dda2109)
I get Error when using this Code:
clc;clear;close all;
% Load Data From team_data.m file in the directory
team_data;
A1 = sparse(1:m,train(:,1),train(:,3),m,n);
A2 = sparse(1:m,train(:,2),-train(:,3),m,n);
A = A1+A2;
cvx_begin
variable a_hat(n)
minimize(-sum(log_normcdf(A*a_hat/sigma)))
subject to
a_hat >= 0
a_hat <= 1
cvx_end
%%
The Error happens when using --> log_normcdf(A*a_hat/sigma) --->
which says:
****************************************************************
Unrecognized function or variable 'vx'.
vx = repmat( reshape( vx, sx ), bx );
Error in - (line 27)
z = cvx_binary_op( P, x, y );
Error in cvx/bsxfun (line 7)
z = func( x, y, varargin{:} );
y = bsxfun( @times, a, bsxfun( @minus, b, x ) );
y = p.funcs{abs(vu)}( vec(x), varargin{:} );
Error in log_normcdf (line 36)
y = cvx_unary_op( P, x );
****************************************************************
Can anyone help me?

답변 (0개)

카테고리

Help CenterFile Exchange에서 Startup and Shutdown에 대해 자세히 알아보기

제품


릴리스

R2022a

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!

Translated by