Results 1 to 5 of 5

Thread: Programming in C++ and CPLEX

  1. #1
    Join Date
    Jun 2009
    Posts
    3,620

    Programming in C++ and CPLEX

    I started all just in c++ and Cplex. Currently I'm training and I have to implement my mathematical model in c++ using macros that use Cplex solver.

    Binary variables were created: I have a 4-variable index, I would like to know how do I do? I thought to create a table of many dimensions but I do not know how it works and where it should be done if you have any suggestions and/or reading materials, then please help me.

  2. #2
    Join Date
    May 2008
    Posts
    2,297

    Re: Programming in C++ and CPLEX

    Could you provide us an example of what you want to do (not the code, the principle behind)? CPLX must have a good doc on interfacing C/CPLX and hence the associated data structures.

  3. #3
    Join Date
    Jun 2009
    Posts
    3,620

    Re: Programming in C++ and CPLEX

    My goal is to rewrite my mathematical model in visual c++, so I'll create a class called mathematical model, then from there I'd call the solver cplec using macros. My primary function is the creation of binary variables. My variable is an index variable with 4. So the c or I wonder when to declare the variable that is in the constructor or it is in the public creation binary variables and how to declare a vector with many dimensions!

    Basically I want to know how to pass a multidimensional array in c++, a variable representing the cplex. I explain if this is not always so clear: I have a variable dimension 4, for its memory location once the results are displayed, I create a table control unit but how I say to my program Variable No. xxxx represents the variable X_1111 (ijkm with indices that are equal to 1)

  4. #4
    Join Date
    May 2008
    Posts
    2,297

    Re: Programming in C++ and CPLEX

    It's not possible because your variable is in several dimensions and thus it corresponds to a multidimensional array.

  5. #5
    Join Date
    Jun 2009
    Posts
    3,620

    Re: Programming in C++ and CPLEX

    I am beginner in CPLEX. Is that you can point me to the setup of CPLEX and its use? And how I'm doing now for the declaration of my variables to several Measurements? Thank you for helping me

Similar Threads

  1. A problem using cplex with visual c++ 2008
    By divange in forum Software Development
    Replies: 1
    Last Post: 31-05-2011, 08:25 AM
  2. c++ and cplex - model implementing
    By golemmbarbarr in forum Software Development
    Replies: 1
    Last Post: 11-05-2011, 06:57 AM
  3. GUI programming in C
    By Isdel in forum Software Development
    Replies: 3
    Last Post: 30-01-2010, 07:02 AM
  4. Socket programming: Is any new Programming Language?
    By Kushan in forum Software Development
    Replies: 3
    Last Post: 14-11-2009, 11:13 AM
  5. Replies: 3
    Last Post: 13-12-2008, 01:49 PM

Tags for this Thread

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  
Page generated in 1,714,117,514.36174 seconds with 16 queries