I am building c++ algorithm based on matlab algorithm, and I want to compare the results.
I am using matlab engine to set and get variables from matlab workspace.
When I am debugging inside function of matlab I can't set any variables to function workspace,
a = 5;
When the debugger is in the main function I can get variable a , and also to add another variables using engGetVariable\engPutVariable.
When the debugger is inside My_Func:
get: In order to get any local variable I copy it to base workspace using:
set: When I using engPutVariable(pEngine,"c_local_variable", c_local_variable);
'c_local_variable' apears only in the base workspace and not inside My_Func
How can I compare matlab_local_variable with c_local_variable when the debugger is inside My_Func?