SCIP Doxygen Documentation
 
Loading...
Searching...
No Matches

Detailed Description

methods for shuffling arrays

Functions

void SCIPswapInts (int *value1, int *value2)
 
void SCIPswapReals (SCIP_Real *value1, SCIP_Real *value2)
 
void SCIPswapPointers (void **pointer1, void **pointer2)
 
void SCIPpermuteIntArray (int *array, int begin, int end, unsigned int *randseed)
 
void SCIPrandomPermuteIntArray (SCIP_RANDNUMGEN *randgen, int *array, int begin, int end)
 
void SCIPrandomPermuteArray (SCIP_RANDNUMGEN *randgen, void **array, int begin, int end)
 
void SCIPpermuteArray (void **array, int begin, int end, unsigned int *randseed)
 

Function Documentation

◆ SCIPswapInts()

void SCIPswapInts ( int * value1,
int * value2 )

swaps two ints

Parameters
value1pointer to first integer
value2pointer to second integer

Definition at line 10370 of file misc.c.

References i.

Referenced by analyzeConflictOverload(), checkOverloadViaThetaTree(), isConnectedSOS1(), and mod2matrixPreprocessRows().

◆ SCIPswapReals()

void SCIPswapReals ( SCIP_Real * value1,
SCIP_Real * value2 )

◆ SCIPswapPointers()

◆ SCIPpermuteIntArray()

void SCIPpermuteIntArray ( int * array,
int begin,
int end,
unsigned int * randseed )

randomly shuffles parts of an integer array using the Fisher-Yates algorithm

Deprecated
Please use SCIPrandomPermuteIntArray()

randomly shuffles parts of an integer array using the Fisher-Yates algorithm

Deprecated
Please use SCIPrandomPermuteIntArray()
Parameters
arrayarray to be shuffled
beginfirst included index that should be subject to shuffling (0 for first array entry)
endfirst excluded index that should not be subject to shuffling (array size for last array entry)
randseedseed value for the random generator

Definition at line 10412 of file misc.c.

References getRandomInt(), and i.

◆ SCIPrandomPermuteIntArray()

void SCIPrandomPermuteIntArray ( SCIP_RANDNUMGEN * randnumgen,
int * array,
int begin,
int end )

randomly shuffles parts of an integer array using the Fisher-Yates algorithm

Parameters
randnumgenrandom number generator
arrayarray to be shuffled
beginfirst included index that should be subject to shuffling (0 for first array entry)
endfirst excluded index that should not be subject to shuffling (array size for last array entry)

Definition at line 10149 of file misc.c.

References i, and SCIPrandomGetInt().

Referenced by dataReset(), detectMinors(), SCIP_DECL_HEUREXEC(), SCIPreoptApply(), and SCIPreoptSplitRoot().

◆ SCIPrandomPermuteArray()

void SCIPrandomPermuteArray ( SCIP_RANDNUMGEN * randnumgen,
void ** array,
int begin,
int end )

randomly shuffles parts of an array using the Fisher-Yates algorithm

Parameters
randnumgenrandom number generator
arrayarray to be shuffled
beginfirst included index that should be subject to shuffling (0 for first array entry)
endfirst excluded index that should not be subject to shuffling (array size for last array entry)

Definition at line 10179 of file misc.c.

References i, and SCIPrandomGetInt().

Referenced by determineVariableFixings(), performRandRounding(), preprocessCliques(), and SCIPpermuteProb().

◆ SCIPpermuteArray()

void SCIPpermuteArray ( void ** array,
int begin,
int end,
unsigned int * randseed )

randomly shuffles parts of an array using the Fisher-Yates algorithm

Deprecated
Please use SCIPrandomPermuteArray()

randomly shuffles parts of an array using the Fisher-Yates algorithm

Deprecated
Please use SCIPrandomPermuteArray()
Parameters
arrayarray to be shuffled
beginfirst included index that should be subject to shuffling (0 for first array entry)
endfirst excluded index that should not be subject to shuffling (array size for last array entry)
randseedseed value for the random generator

Definition at line 10446 of file misc.c.

References getRandomInt(), and i.