Decision Optimization

Decision Optimization

Delivers prescriptive analytics capabilities and decision intelligence to improve decision-making.


#Analytics
#DecisionOptimization
#DecisionOptimization
 View Only
  • 1.  Cplex under C++

    Posted 02/10/09 05:24 PM

    Originally posted by: SystemAdmin


    [Saida said:]

    hello ,
    I have a problem to include cplex to C++ please if any one have already did it HELP !!!
    I have this message errors in console C++ :

    _ilconcert/ilomodel.h: No such file or directory
    - ilconcert/ilosys.h: No such file or directory
    -....

    I have done this header in my program :
    #include <ilcplex/ilocplex.h>
    #include <iostream>
    #include <cstdlib>

    THX,

    #CPLEXOptimizers
    #DecisionOptimization


  • 2.  Re: Cplex under C++

    Posted 02/10/09 05:26 PM

    Originally posted by: SystemAdmin


    [Saida said:]


    Hello,
    Can I use the Cplex under C++ whith out  have all the logiciel?
    #CPLEXOptimizers
    #DecisionOptimization


  • 3.  Re: Cplex under C++

    Posted 02/10/09 07:13 PM

    Originally posted by: SystemAdmin


    [jfk said:]

    Hello,
    I haven't done C++ for a long time but it seems that you didn't set the include path. It is OK to tell CPLEX which .h should be used but where those file are should be supplied in the compiler environment. in cplex there is a c_cpp.html which gives quite detailed info how to do all this. It says:
    "Select C/C++ in the Configuration Properties tree.

        * Select General:
              o In the Additional Include Directories field, add the directories:
                    + <CPLEXDIR>\include.
                    + <CONCERTDIR>\include."
    then for the linking you have to add the libraries. Again the above mentioned file says:
    "Select Linker in the Configuration Properties tree.

        * Select Input and then select Additional Dependencies. Add the files:
              o wsock32.lib
              o <CPLEXDIR>\lib\x86_.net2005_8.0\stat_mta\cplex112.lib
              o <CPLEXDIR>\lib\x86_.net2005_8.0\stat_mta\ilocplex.lib
              o <CONCERTDIR>\lib\x86_.net2005_8.0\stat_mta\concert.lib
          The latter two are only necessary if you are using ILOG Concert Technology."

    may I suggest you that next time you post C++ questions of CPLEX not under ILOG OPL (CPLEX) but ILOG CPLEX? OPL is a language on it own. Folks on that forum may jump on such questions right away... :-)

    sorry, I don't understand you 2nd posting...

    I hope it helps in general
    cheers

    #CPLEXOptimizers
    #DecisionOptimization


  • 4.  Re: Cplex under C++

    Posted 02/11/09 12:25 AM

    Originally posted by: SystemAdmin


    [Saida said:]

    Thank you for this answer,

    please where can I find the .lib files?

    my second question:
    Can I use functionnalies of Cplex under C++ without installing it?  ie: use only the .lib of cplex?

    THX,
    #CPLEXOptimizers
    #DecisionOptimization


  • 5.  Re: Cplex under C++

    Posted 02/12/09 07:52 PM

    Originally posted by: SystemAdmin


    [jfk said:]

    hello,
    1. well, if I put your question into a context like "can I use e.g. windowsXP without installing it?" what would be your answer? So if you are using CPLEX only (no OPL) then the installation means that you get the headers, libs put into some directories which can be referenced in some compilers. If you don't install CPLEX then you don't have directories to reference, then the compiler won't be able to compile and link with them...

    2. the dll's are usually under <cplex installation dir>\lib\x86_windows_vs2008\  (if you use Visual Studio 2008 otherwise use the .net2005)
    here you have mta and mda. the first one is for multithread appli and the mda is to make dll (I think). anyway use the mta library (this is explained in the c_cpp.html in the standard distribution located in the <cplex installation dir>)

    3. btw I forgot to say that with the standard distribution CPLEX provides full VisualStudio projects (or .net projects) under <cplex installation dir>examples\x86_windows_vs2008\stat_mta
    you get lots of examples from there

    I hope it helps
    cheers

    #CPLEXOptimizers
    #DecisionOptimization


  • 6.  Re: Cplex under C++

    Posted 04/18/09 12:10 AM

    Originally posted by: SystemAdmin


    [wuchao_shu said:]

    If I want to use C# to call the functions in ILOG.CPLEX.dll and ILOG.CONCERT.dll, can I just copy the two .dll files from a full version from another one and use them? What else do I need if I can call dll by this way but not enough with only these 2 files?

    Thanks a lot!

    Benni
    #CPLEXOptimizers
    #DecisionOptimization