/home/coin/SVN-release/CoinAll-1.1.0/SYMPHONY/include/sym_messages.h

Go to the documentation of this file.
00001 /*===========================================================================*/
00002 /*                                                                           */
00003 /* This file is part of the SYMPHONY MILP Solver Framework.                  */
00004 /*                                                                           */
00005 /* SYMPHONY was jointly developed by Ted Ralphs (tkralphs@lehigh.edu) and    */
00006 /* Laci Ladanyi (ladanyi@us.ibm.com).                                        */
00007 /*                                                                           */
00008 /* (c) Copyright 2000-2008 Ted Ralphs. All Rights Reserved.                  */
00009 /*                                                                           */
00010 /* This software is licensed under the Common Public License. Please see     */
00011 /* accompanying file for terms.                                              */
00012 /*                                                                           */
00013 /*===========================================================================*/
00014 
00015 #ifndef _MESSAGES_H
00016 #define _MESSAGES_H
00017 
00018 #define EMPTY_MSG_SEND(tid, msgtag) \
00019 { \
00020    int s_bufid; \
00021    if ((s_bufid = pvm_initsend (PvmDataRaw)) < 0) PVM_ERROR(); \
00022    if ((info = pvm_send((tid), (msgtag))) < 0) PVM_ERROR(); \
00023    if ((info = pvm_freebuf(s_bufid)) < 0) PVM_ERROR(); \
00024 }
00025 
00026 #define EMPTY_MSG_MCAST(tid, numtask, msgtag) \
00027 { \
00028    int s_bufid; \
00029    if ((s_bufid = pvm_initsend (PvmDataRaw)) < 0) PVM_ERROR(); \
00030    if ((info = pvm_mcast((tid), (numtask), (msgtag))) < 0) PVM_ERROR(); \
00031    if ((info = pvm_freebuf(s_bufid)) < 0) PVM_ERROR(); \
00032 }
00033 
00034 /*===========================================================================*
00035  * Message types
00036  * 1xx : general messages
00037  * 2xx : messages to/from master
00038  * 3xx : messages to/from tree manager
00039  * 4xx : rest of the messages
00040  *===========================================================================*/
00041 
00042 /* we allow a process to die */
00043 #define YOU_CAN_DIE 100
00044 
00045 #define I_AM_DEAD 101
00046 
00047 /*pretend to die*/
00048 #define YOU_CANNOT_DIE 102
00049 
00050 /* this is a new upper bound */
00051 #define UPPER_BOUND 103
00052 
00053 /* the tid of the master process is going to be sent */
00054 #define MASTER_TID_INFO 104
00055 
00056 /* tells the process to write a log file for a warm re-start in case of crash*/
00057 #define WRITE_LOG_FILE 105
00058 
00059 
00060 /* messages to set up an lp: lp-->master; master-->lp */
00061 #define REQUEST_FOR_LP_DATA 200
00062 #define LP_DATA             201
00063 /* similar for cg */
00064 #define REQUEST_FOR_CG_DATA 202
00065 #define CG_DATA             203
00066 /* similar for cp */
00067 #define REQUEST_FOR_CP_DATA 204
00068 #define CP_DATA             205
00069 /* similar for sp */
00070 #define REQUEST_FOR_SP_DATA 206
00071 #define SP_DATA             207
00072 /* similar for dg */
00073 #define REQUEST_FOR_DG_DATA 208
00074 #define DG_DATA             209
00075 
00076 /* startup data for the TM */
00077 #define TM_DATA             210
00078 
00079 /* miscellaneous tm messages */
00080 #define TM_ROOT_DESCRIPTION              211
00081 #define TM_FIRST_PHASE_FINISHED          212
00082 
00083 /*===========================================================================*
00084  * treemanager-->lp messages
00085  *===========================================================================*/
00086 /* lp-->tm; Describes a particular search tree node */
00087 #define LP__NODE_DESCRIPTION 300
00088 /* lp-->tm; Describes the branching at this node */
00089 #define LP__BRANCHING_INFO 301
00090 /* lp-->tm; The LP is free to process a new node */
00091 #define LP__IS_FREE 302
00092 /* tm-->lp; 2nd phase started, from now on price*/
00093 #define LP__SECOND_PHASE_STARTS 303
00094 
00095 #define LP__CUT_NAMES_REQUESTED 304
00096 #define LP__CUT_NAMES_SERVED  305
00097 
00098 /* tm --> lp;  tm-->lp: this is your new active node, process it. */
00099 #define LP__ACTIVE_NODE_DATA 306
00100 /* tm-->lp: Instruction to the LP process whether to dive or not */
00101 #define LP__DIVING_INFO 307
00102 
00103 /* tm-->lp: The tid of the corresponding cut generator */
00104 #define LP__CG_TID_INFO 308
00105 
00106 /* lp-->tm: the newly sent active node is too expensive, hold it for the
00107             next phase */
00108 #define LP__NODE_RESHELVED 309
00109 /* lp-->tm: the newly sent active node is too expensive, discarded */
00110 #define LP__NODE_DISCARDED 310
00111 /* lp-->tm: timing data */
00112 #define LP__TIMING 311
00113 
00114 
00115 /*===========================================================================*
00116  * lp-->... messages
00117  *===========================================================================*/
00118 /* lp-->master; different msgtypes for a feasible solution */
00119 #define FEASIBLE_SOLUTION_NONZEROS  410
00120 #define FEASIBLE_SOLUTION_FRACTIONS 411
00121 #define FEASIBLE_SOLUTION_USER      412
00122 
00123 /* lp-->cutgen,cutpool; a solution to be checked to find violated cuts 
00124    and the solution is in a default format (userinds and values). Maybe
00125    nonzeros or fractions at this time */
00126 #define LP_SOLUTION_NONZEROS  420
00127 #define LP_SOLUTION_FRACTIONS 421
00128 #define LP_SOLUTION_USER      422
00129 
00130 /*===========================================================================*
00131  * treemanager-->cut/sol_pool messages
00132  *===========================================================================*/
00133 /* notifies cut_pool to wait for a new set of cuts */
00134 #define POOL_YOU_ARE_USELESS 501
00135 #define POOL_USELESSNESS_ACKNOWLEDGED 502
00136 /* tm asks a pool to copy itself into another pool */
00137 #define POOL_COPY_YOURSELF 503
00138 /* a pool reports back that it had finished and how much time it had used.
00139    a pool dies only if every node that belongs to it is fathomed */
00140 #define POOL_TIME 504
00141 
00142 /*****************************************************************************/
00143 
00144 #define PACKED_CUT        600
00145 #define PACKED_CUTS_TO_CP 601
00146 #define CUTPOOL_COPY      602
00147 
00148 #define NO_MORE_CUTS 605
00149 
00150 /*****************************************************************************/
00151 
00152 #define PACKED_COL 700
00153 #define NO_MORE_COLS 701
00154 #define CG_LP_SOLUTION 703
00155 
00156 /*****************************************************************************/
00157 
00158 #define SOMETHING_DIED 1000
00159 #define NODE_DIED 1001
00160 
00161 
00162 #endif

Generated on Sun Nov 14 14:06:42 2010 for Coin-All by  doxygen 1.4.7