How to write CVRP (capacitated vehicle routing problem) objective function?

조회 수: 1 (최근 30일)
ANURAG DEEPAK
ANURAG DEEPAK 2020년 11월 21일
답변: Yoan 2023년 10월 25일
Respected Sir/Madam,
Can you please help me in writing this objective function in the script?

답변 (1개)

Yoan
Yoan 2023년 10월 25일
routeLength = @(route, distance) sum(arrayfun(@(n) distance(route(n), route(n+1)), 1:(numel(route)-1)));

카테고리

Help CenterFile Exchange에서 Optimization에 대해 자세히 알아보기

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!

Translated by