Initializing help system before first use

# XPRSreadslxsol (READSLXSOL)

Purpose
Reads an ASCII solution file ( .slx) created by the XPRSwriteslxsol function.
Topic areas
File IO, Solution
Synopsis
`int XPRS_CC XPRSreadslxsol(XPRSprob prob, const char *filename, const char *flags);`
`READSLXSOL -[flags] [filename]`
Arguments

prob | The current problem.
filename | A string of up to MAXPROBNAMELENGTH characters containing the file name to which the solution is to be read. If omitted, the default problem_name is used with a .slx extension.
flags | Flags to pass to XPRSreadslxsol ( READSLXSOL):
l | read the solution as an LP solution in case of a MIP problem;
m | read the solution as a solution for the MIP problem;
a | read multiple MIP solutions from the .slx file and add them to the MIP problem;
v | use the provided filename verbatim, without appending the .slx extension;
z | read a compressed input file.

Example 1 (Library)

    XPRSreadslxsol(prob,"lpsolution","");

This loads the solution to the MIP problem if the problem contains MIP entities, or otherwise loads it as an LP (barrier in case of quadratic problems) solution into the problem.
Example 2 (Console)

    READSLXSOL lpsolution

Which is equivalent to the library example above.
Further information
1. When XPRSreadslxsol is called before a MIP solve, the loaded solutions will not be checked before calling XPRSmipoptimize. By default, only the last MIP solution read from the .slx file will be stored. Use the a flag to store all MIP solutions read from the file.
2. When using the a flag, read solutions will be queued similarly to the user of the XPRSaddmipsol function. Each name string given by the NAME field in the .slx file will be associated with the corresponding solution. Any registered usersolnotify callback will be fired when the solution has been checked, and will include the read name string as one of its arguments.
3. Note that when solving with FICO Xpress Global (including non-convex quadratic problems), the a flag always needs to be provided.
4. Refer to ASCII Solution (.slx) Files for a description of the ASCII Solution (.slx) File format.
Related topics
XPRSreadbinsol ( READBINSOL), XPRSwriteslxsol ( WRITESLXSOL), XPRSwritebinsol WRITEBINSOL, XPRSreadbinsol ( READBINSOL), XPRSaddmipsol, XPRSaddcbusersolnotify.
Parent Topic Console and Library Functions

© 2001-2026 Fair Isaac Corporation. All rights reserved. This documentation is the property of Fair Isaac Corporation (“FICO”). Receipt or possession of this documentation does not convey rights to disclose, reproduce, make derivative works, use, or allow others to use it except solely for internal evaluation purposes to determine whether to purchase a license to the software described in this documentation, or as otherwise set forth in a written software license agreement between you and FICO (or a FICO affiliate). Use of this documentation and the software described in it must conform strictly to the foregoing permitted uses, and no other use is permitted.