How to write CVRP (capacitated vehicle routing problem) objective function?
조회 수: 1 (최근 30일)
이전 댓글 표시
Respected Sir/Madam,
Can you please help me in writing this objective function in the script?

댓글 수: 0
답변 (1개)
Yoan
2023년 10월 25일
routeLength = @(route, distance) sum(arrayfun(@(n) distance(route(n), route(n+1)), 1:(numel(route)-1)));
댓글 수: 0
참고 항목
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!