Stay organized with collections
Save and categorize content based on your preferences.
C++ Reference: class RoutingRandomNeighborhoodGenerator
Note: This documentation is automatically generated.
This routing based LNS generator will relax random arcs in all the paths of
the circuit or routes constraints.
Method |
Generate | Return type: Neighborhood Arguments: const CpSolverResponse& initial_solution,
double difficulty, absl::BitGenRef random |
RoutingRandomNeighborhoodGenerator | Arguments: NeighborhoodGeneratorHelper const* helper,
const std::string& name |
Except as otherwise noted, the content of this page is licensed under the Creative Commons Attribution 4.0 License, and code samples are licensed under the Apache 2.0 License. For details, see the Google Developers Site Policies. Java is a registered trademark of Oracle and/or its affiliates.
Last updated 2024-08-06 UTC.
[null,null,["Last updated 2024-08-06 UTC."],[[["\u003cp\u003eThe RoutingRandomNeighborhoodGenerator is a Large Neighborhood Search (LNS) generator used within the or-tools/sat library for constraint programming.\u003c/p\u003e\n"],["\u003cp\u003eIt works by randomly relaxing arcs (connections between nodes) within paths or routes of a given problem's constraints to explore different solutions.\u003c/p\u003e\n"],["\u003cp\u003eUsers can utilize the \u003ccode\u003eGenerate\u003c/code\u003e method, providing an initial solution and difficulty level, to create a neighborhood of solutions for further exploration.\u003c/p\u003e\n"]]],["The `RoutingRandomNeighborhoodGenerator` class in C++ is designed for relaxing random arcs within circuit or route constraints. It features two methods: `Generate`, which creates a `Neighborhood` based on an initial solution, difficulty, and a random number generator, and `RoutingRandomNeighborhoodGenerator`, which is likely a constructor accepting a `NeighborhoodGeneratorHelper` and a name. The core function is generating neighborhoods by randomly selecting arcs for relaxation.\n"],null,["# RoutingRandomNeighborhoodGenerator\n\nC++ Reference: class RoutingRandomNeighborhoodGenerator\n=======================================================\n\n\nNote: This documentation is automatically generated.\nThis routing based LNS generator will relax random arcs in all the paths of the circuit or routes constraints.\n\n| Method ||\n|----------------------------------------------------------------------------------------------------------------------|--------------------------------------------------------------------------------------------------------------------------------------|\n| [`Generate`](https://github.com/google/or-tools/blob/v9.4/ortools/sat/cp_model_lns.h#L613) | Return type: `Neighborhood ` Arguments: `const CpSolverResponse& initial_solution, double difficulty, absl::BitGenRef random` \u003cbr /\u003e |\n| [`RoutingRandomNeighborhoodGenerator`](https://github.com/google/or-tools/blob/v9.4/ortools/sat/cp_model_lns.h#L609) | \u003cbr /\u003e Arguments: `NeighborhoodGeneratorHelper const* helper, const std::string& name` \u003cbr /\u003e |"]]