Originally posted by: NSopt
Hello.
I'm implementing multi-child branching.(i.e., branch on more than 2 nodes)
For this, I'd like to attach user information to every node.
Also, I want to read attached information from every node.
Here goes short snippet for this implementation.
struct test1
{
int testindex;
int testindex2;
};
struct test1 m;
struct test1 *branch_info=NULL;
branch_info = &m;
branch_info->testindex = 10;
branch_info->testindex2 = 20;
status = CPXbranchcallbackbranchbds (env,cbdata,wherefrom,objval,1,&minmaxj,varlu,varbd,branch_info,&seqnum1);
*useraction_p = CPX_CALLBACK_SET;
status = CPXgetcallbacknodeinfo (env,cbdata,wherefrom,0,CPX_CALLBACK_INFO_NODE_USERHANDLE,(void*)&branch_info);
printf("branch info %d \n",(const*)&branch_info->testindex);
However, last line gives me 'address-like number' such as -126888112 not 10.
Could you please help me for this problem?
Thank you.
Best,
NS
#CPLEXOptimizers#DecisionOptimization