Decision Optimization

Decision Optimization

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


#Analytics
#DecisionOptimization
#DecisionOptimization
 View Only
  • 1.  Question of WriteSolution() and WriteSolutions

    Posted 03/15/12 05:39 AM

    Originally posted by: SystemAdmin


    Hi,who could tell me how to use the method WriteSolution() in details?
    WriteSolutions( string name )
    

    in what format to write The name of the file ?
    can it been write like this:
    cplex.WriteSolution("../../../../include/ilcplex/1.txt");
    


    it would be better that you can give me some typical exsample!
    thank you very much
    #CPLEXOptimizers
    #DecisionOptimization


  • 2.  Re: Question of WriteSolution() and WriteSolutions

    Posted 03/15/12 07:44 AM

    Originally posted by: SystemAdmin


    There is no CPLEX specific limitation to the file name argument for these functions. Anything that specifies a valid file name is allowed.
    So "../../../../include/ilcplex/1.txt" should be fine.
    Note that relative path names like "../../../../include/ilcplex/1.txt" in your example are interpreted relative to your current working directory (as returned by Directory.GetCurrentDirectory()).
    If you have trouble outputting the file with a relative path then probably your binary runs in a different directory than you expect?
    Among other things you could try specifying an absolute path name or just the file name (without any path).
    #CPLEXOptimizers
    #DecisionOptimization