线性规划问题
北京2008奥运期间,由清华大学480名学生组成的北京2008奥运志愿者队伍要前往国家体育场(“鸟巢”)进行志愿活动。清华大学后勤集团有7辆小巴、4辆大巴,其中小巴能载1...
北京2008奥运期间,由清华大学480名学生组成的北京2008奥运志愿者队伍要前往国家体育场(“鸟巢”)进行志愿活动。清华大学后勤集团有7辆小巴、4辆大巴,其中小巴能载16人、大巴能载32人.前往过程中,每辆客车最多往返次数小巴为5次、大巴为3次,每次运输成本小巴为48元,大巴为60元.请问应派出小巴、大巴各多少辆,能使总费用最少?
我要详细答案~
很多人争辩究竟是设派出的“车次”呢还是设派出车的“辆数”
但我觉得派出的车辆数和最后总花费是无直接关系的,因为与车费直接相关的是出车的次数 展开
我要详细答案~
很多人争辩究竟是设派出的“车次”呢还是设派出车的“辆数”
但我觉得派出的车辆数和最后总花费是无直接关系的,因为与车费直接相关的是出车的次数 展开
6个回答
展开全部
下面是最小费用的两组解,对应的最小费用为1008元:
{{小巴个数,所跑次数,限载人数,费用},{大巴个数,所跑次数,限载人数,费用},{限载总人数,总费用}}
{{3,2,96,288},{4,3,384,720},{480,1008}},
{{2,3,96,288},{4,3,384,720},{480,1008}},
下面是所有满足情况的解(不排除有些重复解):
{{小巴个数,所跑次数,限载人数,费用},{大巴个数,所跑次数,限载人数,费用},{限载总人数,总费用}}
{{6,1,96,288},{4,3,384,720},{480,1008}},
{{2,3,96,288},{4,3,384,720},{480,1008}},
{{2,4,128,384},{4,3,384,720},{512,1104}},
{{2,5,160,480},{4,3,384,720},{544,1200}},
{{3,2,96,288},{4,3,384,720},{480,1008}},
{{3,3,144,432},{4,3,384,720},{528,1152}},
{{3,4,192,576},{3,3,288,540},{480,1116}},
{{3,4,192,576},{4,3,384,720},{576,1296}},
{{3,5,240,720},{3,3,288,540},{528,1260}},
{{3,5,240,720},{4,2,256,480},{496,1200}},
{{4,2,128,384},{4,3,384,720},{512,1104}},
{{4,3,192,576},{3,3,288,540},{480,1116}},
{{4,3,192,576},{4,3,384,720},{576,1296}},
{{4,4,256,768},{3,3,288,540},{544,1308}},
{{4,4,256,768},{4,2,256,480},{512,1248}},
{{4,5,320,960},{2,3,192,360},{512,1320}},
{{4,5,320,960},{3,2,192,360},{512,1320}},
{{4,5,320,960},{4,2,256,480},{576,1440}},
{{5,2,160,480},{4,3,384,720},{544,1200}},
{{5,3,240,720},{3,3,288,540},{528,1260}},
{{5,3,240,720},{4,2,256,480},{496,1200}},
{{5,4,320,960},{2,3,192,360},{512,1320}},
{{5,4,320,960},{3,2,192,360},{512,1320}},
{{5,4,320,960},{4,2,256,480},{576,1440}},
{{5,5,400,1200},{1,3,96,180},{496,1380}},
{{5,5,400,1200},{2,2,128,240},{528,1440}},
{{5,5,400,1200},{3,1,96,180},{496,1380}},
{{5,5,400,1200},{4,1,128,240},{528,1440}},
{{6,1,96,288},{4,3,384,720},{480,1008}},
{{6,2,192,576},{3,3,288,540},{480,1116}},
{{6,2,192,576},{4,3,384,720},{576,1296}},
{{6,3,288,864},{2,3,192,360},{480,1224}},
{{6,3,288,864},{3,2,192,360},{480,1224}},
{{6,3,288,864},{4,2,256,480},{544,1344}},
{{6,4,384,1152},{1,3,96,180},{480,1332}},
{{6,4,384,1152},{2,2,128,240},{512,1392}},
{{6,4,384,1152},{3,1,96,180},{480,1332}},
{{6,4,384,1152},{4,1,128,240},{512,1392}},
{{6,5,480,1440},{0,0,0,0},{480,1440}},
{{6,5,480,1440},{1,0,0,0},{480,1440}},
{{6,5,480,1440},{2,0,0,0},{480,1440}},
{{6,5,480,1440},{3,0,0,0},{480,1440}},
{{6,5,480,1440},{4,0,0,0},{480,1440}},
{{7,1,112,336},{4,3,384,720},{496,1056}},
{{7,2,224,672},{3,3,288,540},{512,1212}},
{{7,2,224,672},{4,2,256,480},{480,1152}},
{{7,3,336,1008},{2,3,192,360},{528,1368}},
{{7,3,336,1008},{3,2,192,360},{528,1368}},
{{7,3,336,1008},{4,2,256,480},{592,1488}},
{{7,4,448,1344},{1,1,32,60},{480,1404}},
{{7,4,448,1344},{2,1,64,120},{512,1464}},
{{7,4,448,1344},{3,1,96,180},{544,1524}},
{{7,4,448,1344},{4,1,128,240},{576,1584}},
{{7,5,560,1680},{0,0,0,0},{560,1680}},
{{7,5,560,1680},{1,0,0,0},{560,1680}},
{{7,5,560,1680},{2,0,0,0},{560,1680}},
{{7,5,560,1680},{3,0,0,0},{560,1680}},
{{7,5,560,1680},{4,0,0,0},{560,1680}}
下面是按照车费由小到大排序的结果:
{{小巴个数,所跑次数,限载人数,费用},{大巴个数,所跑次数,限载人数,费用},{限载总人数,总费用}}
{{3,2,96,288},{4,3,384,720},{480,1008}},
{{2,3,96,288},{4,3,384,720},{480,1008}},
{{7,1,112,336},{4,3,384,720},{496,1056}},
{{4,2,128,384},{4,3,384,720},{512,1104}},
{{2,4,128,384},{4,3,384,720},{512,1104}},
{{6,2,192,576},{3,3,288,540},{480,1116}},
{{4,3,192,576},{3,3,288,540},{480,1116}},
{{3,4,192,576},{3,3,288,540},{480,1116}},
{{7,2,224,672},{4,2,256,480},{480,1152}},
{{3,3,144,432},{4,3,384,720},{528,1152}},
{{5,3,240,720},{4,2,256,480},{496,1200}},
{{5,2,160,480},{4,3,384,720},{544,1200}},
{{3,5,240,720},{4,2,256,480},{496,1200}},
{{2,5,160,480},{4,3,384,720},{544,1200}},
{{7,2,224,672},{3,3,288,540},{512,1212}},
{{6,3,288,864},{3,2,192,360},{480,1224}},
{{6,3,288,864},{2,3,192,360},{480,1224}},
{{4,4,256,768},{4,2,256,480},{512,1248}},
{{5,3,240,720},{3,3,288,540},{528,1260}},
{{3,5,240,720},{3,3,288,540},{528,1260}},
{{6,2,192,576},{4,3,384,720},{576,1296}},
{{4,3,192,576},{4,3,384,720},{576,1296}},
{{3,4,192,576},{4,3,384,720},{576,1296}},
{{4,4,256,768},{3,3,288,540},{544,1308}},
{{5,4,320,960},{3,2,192,360},{512,1320}},
{{5,4,320,960},{2,3,192,360},{512,1320}},
{{4,5,320,960},{3,2,192,360},{512,1320}},
{{4,5,320,960},{2,3,192,360},{512,1320}},
{{6,4,384,1152},{3,1,96,180},{480,1332}},
{{6,4,384,1152},{1,3,96,180},{480,1332}},
{{6,3,288,864},{4,2,256,480},{544,1344}},
{{7,3,336,1008},{3,2,192,360},{528,1368}},
{{7,3,336,1008},{2,3,192,360},{528,1368}},
{{5,5,400,1200},{3,1,96,180},{496,1380}},
{{5,5,400,1200},{1,3,96,180},{496,1380}},
{{6,4,384,1152},{4,1,128,240},{512,1392}},
{{6,4,384,1152},{2,2,128,240},{512,1392}},
{{7,4,448,1344},{1,1,32,60},{480,1404}},
{{6,5,480,1440},{4,0,0,0},{480,1440}},
{{6,5,480,1440},{3,0,0,0},{480,1440}},
{{6,5,480,1440},{2,0,0,0},{480,1440}},
{{6,5,480,1440},{1,0,0,0},{480,1440}},
{{6,5,480,1440},{0,0,0,0},{480,1440}},
{{5,5,400,1200},{4,1,128,240},{528,1440}},
{{5,5,400,1200},{2,2,128,240},{528,1440}},
{{5,4,320,960},{4,2,256,480},{576,1440}},
{{4,5,320,960},{4,2,256,480},{576,1440}},
{{7,4,448,1344},{2,1,64,120},{512,1464}},
{{7,3,336,1008},{4,2,256,480},{592,1488}},
{{7,4,448,1344},{3,1,96,180},{544,1524}},
{{7,4,448,1344},{4,1,128,240},{576,1584}},
{{7,5,560,1680},{4,0,0,0},{560,1680}},
{{7,5,560,1680},{3,0,0,0},{560,1680}},
{{7,5,560,1680},{2,0,0,0},{560,1680}},
{{7,5,560,1680},{1,0,0,0},{560,1680}},
{{7,5,560,1680},{0,0,0,0},{560,1680}}
附上Mathematica 程序,因为程序很小, 所以没有简化程序.没有剔除重复解.
arr = {};
For[m = 0, m <= Ceiling[480/16] && m <= 7, m++,
For[p = 0, p <= Ceiling[480/16] && p <= 5, p++,
For[n = 0, n <= Ceiling[480/32] && n <= 4, n++,
For[q = 0, q <= Ceiling[480/32] && q <= 3, q++,
If[m*p*16 + n*q*32 >= 480,
arr =
Append[arr, {{m, p, 16*m*p, 48*m*p}, {n, q, 32*n*q,
60*n*q}, {m*p*16 + n*q*32, 48*m*p + 60*n*q}}];
Break[]
]
]
]
]
]
arr
Sort[arr, #1[[-1]][[-1]] < #2[[-1]][[-1]] &]
{{小巴个数,所跑次数,限载人数,费用},{大巴个数,所跑次数,限载人数,费用},{限载总人数,总费用}}
{{3,2,96,288},{4,3,384,720},{480,1008}},
{{2,3,96,288},{4,3,384,720},{480,1008}},
下面是所有满足情况的解(不排除有些重复解):
{{小巴个数,所跑次数,限载人数,费用},{大巴个数,所跑次数,限载人数,费用},{限载总人数,总费用}}
{{6,1,96,288},{4,3,384,720},{480,1008}},
{{2,3,96,288},{4,3,384,720},{480,1008}},
{{2,4,128,384},{4,3,384,720},{512,1104}},
{{2,5,160,480},{4,3,384,720},{544,1200}},
{{3,2,96,288},{4,3,384,720},{480,1008}},
{{3,3,144,432},{4,3,384,720},{528,1152}},
{{3,4,192,576},{3,3,288,540},{480,1116}},
{{3,4,192,576},{4,3,384,720},{576,1296}},
{{3,5,240,720},{3,3,288,540},{528,1260}},
{{3,5,240,720},{4,2,256,480},{496,1200}},
{{4,2,128,384},{4,3,384,720},{512,1104}},
{{4,3,192,576},{3,3,288,540},{480,1116}},
{{4,3,192,576},{4,3,384,720},{576,1296}},
{{4,4,256,768},{3,3,288,540},{544,1308}},
{{4,4,256,768},{4,2,256,480},{512,1248}},
{{4,5,320,960},{2,3,192,360},{512,1320}},
{{4,5,320,960},{3,2,192,360},{512,1320}},
{{4,5,320,960},{4,2,256,480},{576,1440}},
{{5,2,160,480},{4,3,384,720},{544,1200}},
{{5,3,240,720},{3,3,288,540},{528,1260}},
{{5,3,240,720},{4,2,256,480},{496,1200}},
{{5,4,320,960},{2,3,192,360},{512,1320}},
{{5,4,320,960},{3,2,192,360},{512,1320}},
{{5,4,320,960},{4,2,256,480},{576,1440}},
{{5,5,400,1200},{1,3,96,180},{496,1380}},
{{5,5,400,1200},{2,2,128,240},{528,1440}},
{{5,5,400,1200},{3,1,96,180},{496,1380}},
{{5,5,400,1200},{4,1,128,240},{528,1440}},
{{6,1,96,288},{4,3,384,720},{480,1008}},
{{6,2,192,576},{3,3,288,540},{480,1116}},
{{6,2,192,576},{4,3,384,720},{576,1296}},
{{6,3,288,864},{2,3,192,360},{480,1224}},
{{6,3,288,864},{3,2,192,360},{480,1224}},
{{6,3,288,864},{4,2,256,480},{544,1344}},
{{6,4,384,1152},{1,3,96,180},{480,1332}},
{{6,4,384,1152},{2,2,128,240},{512,1392}},
{{6,4,384,1152},{3,1,96,180},{480,1332}},
{{6,4,384,1152},{4,1,128,240},{512,1392}},
{{6,5,480,1440},{0,0,0,0},{480,1440}},
{{6,5,480,1440},{1,0,0,0},{480,1440}},
{{6,5,480,1440},{2,0,0,0},{480,1440}},
{{6,5,480,1440},{3,0,0,0},{480,1440}},
{{6,5,480,1440},{4,0,0,0},{480,1440}},
{{7,1,112,336},{4,3,384,720},{496,1056}},
{{7,2,224,672},{3,3,288,540},{512,1212}},
{{7,2,224,672},{4,2,256,480},{480,1152}},
{{7,3,336,1008},{2,3,192,360},{528,1368}},
{{7,3,336,1008},{3,2,192,360},{528,1368}},
{{7,3,336,1008},{4,2,256,480},{592,1488}},
{{7,4,448,1344},{1,1,32,60},{480,1404}},
{{7,4,448,1344},{2,1,64,120},{512,1464}},
{{7,4,448,1344},{3,1,96,180},{544,1524}},
{{7,4,448,1344},{4,1,128,240},{576,1584}},
{{7,5,560,1680},{0,0,0,0},{560,1680}},
{{7,5,560,1680},{1,0,0,0},{560,1680}},
{{7,5,560,1680},{2,0,0,0},{560,1680}},
{{7,5,560,1680},{3,0,0,0},{560,1680}},
{{7,5,560,1680},{4,0,0,0},{560,1680}}
下面是按照车费由小到大排序的结果:
{{小巴个数,所跑次数,限载人数,费用},{大巴个数,所跑次数,限载人数,费用},{限载总人数,总费用}}
{{3,2,96,288},{4,3,384,720},{480,1008}},
{{2,3,96,288},{4,3,384,720},{480,1008}},
{{7,1,112,336},{4,3,384,720},{496,1056}},
{{4,2,128,384},{4,3,384,720},{512,1104}},
{{2,4,128,384},{4,3,384,720},{512,1104}},
{{6,2,192,576},{3,3,288,540},{480,1116}},
{{4,3,192,576},{3,3,288,540},{480,1116}},
{{3,4,192,576},{3,3,288,540},{480,1116}},
{{7,2,224,672},{4,2,256,480},{480,1152}},
{{3,3,144,432},{4,3,384,720},{528,1152}},
{{5,3,240,720},{4,2,256,480},{496,1200}},
{{5,2,160,480},{4,3,384,720},{544,1200}},
{{3,5,240,720},{4,2,256,480},{496,1200}},
{{2,5,160,480},{4,3,384,720},{544,1200}},
{{7,2,224,672},{3,3,288,540},{512,1212}},
{{6,3,288,864},{3,2,192,360},{480,1224}},
{{6,3,288,864},{2,3,192,360},{480,1224}},
{{4,4,256,768},{4,2,256,480},{512,1248}},
{{5,3,240,720},{3,3,288,540},{528,1260}},
{{3,5,240,720},{3,3,288,540},{528,1260}},
{{6,2,192,576},{4,3,384,720},{576,1296}},
{{4,3,192,576},{4,3,384,720},{576,1296}},
{{3,4,192,576},{4,3,384,720},{576,1296}},
{{4,4,256,768},{3,3,288,540},{544,1308}},
{{5,4,320,960},{3,2,192,360},{512,1320}},
{{5,4,320,960},{2,3,192,360},{512,1320}},
{{4,5,320,960},{3,2,192,360},{512,1320}},
{{4,5,320,960},{2,3,192,360},{512,1320}},
{{6,4,384,1152},{3,1,96,180},{480,1332}},
{{6,4,384,1152},{1,3,96,180},{480,1332}},
{{6,3,288,864},{4,2,256,480},{544,1344}},
{{7,3,336,1008},{3,2,192,360},{528,1368}},
{{7,3,336,1008},{2,3,192,360},{528,1368}},
{{5,5,400,1200},{3,1,96,180},{496,1380}},
{{5,5,400,1200},{1,3,96,180},{496,1380}},
{{6,4,384,1152},{4,1,128,240},{512,1392}},
{{6,4,384,1152},{2,2,128,240},{512,1392}},
{{7,4,448,1344},{1,1,32,60},{480,1404}},
{{6,5,480,1440},{4,0,0,0},{480,1440}},
{{6,5,480,1440},{3,0,0,0},{480,1440}},
{{6,5,480,1440},{2,0,0,0},{480,1440}},
{{6,5,480,1440},{1,0,0,0},{480,1440}},
{{6,5,480,1440},{0,0,0,0},{480,1440}},
{{5,5,400,1200},{4,1,128,240},{528,1440}},
{{5,5,400,1200},{2,2,128,240},{528,1440}},
{{5,4,320,960},{4,2,256,480},{576,1440}},
{{4,5,320,960},{4,2,256,480},{576,1440}},
{{7,4,448,1344},{2,1,64,120},{512,1464}},
{{7,3,336,1008},{4,2,256,480},{592,1488}},
{{7,4,448,1344},{3,1,96,180},{544,1524}},
{{7,4,448,1344},{4,1,128,240},{576,1584}},
{{7,5,560,1680},{4,0,0,0},{560,1680}},
{{7,5,560,1680},{3,0,0,0},{560,1680}},
{{7,5,560,1680},{2,0,0,0},{560,1680}},
{{7,5,560,1680},{1,0,0,0},{560,1680}},
{{7,5,560,1680},{0,0,0,0},{560,1680}}
附上Mathematica 程序,因为程序很小, 所以没有简化程序.没有剔除重复解.
arr = {};
For[m = 0, m <= Ceiling[480/16] && m <= 7, m++,
For[p = 0, p <= Ceiling[480/16] && p <= 5, p++,
For[n = 0, n <= Ceiling[480/32] && n <= 4, n++,
For[q = 0, q <= Ceiling[480/32] && q <= 3, q++,
If[m*p*16 + n*q*32 >= 480,
arr =
Append[arr, {{m, p, 16*m*p, 48*m*p}, {n, q, 32*n*q,
60*n*q}, {m*p*16 + n*q*32, 48*m*p + 60*n*q}}];
Break[]
]
]
]
]
]
arr
Sort[arr, #1[[-1]][[-1]] < #2[[-1]][[-1]] &]
图为信息科技(深圳)有限公司
2021-01-25 广告
2021-01-25 广告
边缘计算方案可以咨询图为信息科技(深圳)有限公司了解一下,图为信息科技(深圳)有限公司(简称:图为信息科技)是基于视觉处理的边缘计算方案解决商。作为一家创新企业,多年来始终专注于人工智能领域的发展,致力于为客户提供满意的解决方案。...
点击进入详情页
本回答由图为信息科技(深圳)有限公司提供
展开全部
AP=AQ时候面积最大
做这种题目,首先根据题目列出所有公式如下:
设置小巴X辆,大巴Y辆时费用最少
公式一:H(费用)=48X+60Y
公式二:16X+32Y=480
公式三:0《X《5
公式四:0《Y《3
1.穷举法:你看Y可取数目只有0,1,2,3,你把这四个数字依次带入公式二,得出整数X,且0《X《3就是有效的。例如Y=0代入得出X=30,这就是无效数字。
穷举结束后得出的有效数字组合代入公式一,得出0-4组结果,最小的就是答案啦
2.坐标曲线法,不好画
做这种题目,首先根据题目列出所有公式如下:
设置小巴X辆,大巴Y辆时费用最少
公式一:H(费用)=48X+60Y
公式二:16X+32Y=480
公式三:0《X《5
公式四:0《Y《3
1.穷举法:你看Y可取数目只有0,1,2,3,你把这四个数字依次带入公式二,得出整数X,且0《X《3就是有效的。例如Y=0代入得出X=30,这就是无效数字。
穷举结束后得出的有效数字组合代入公式一,得出0-4组结果,最小的就是答案啦
2.坐标曲线法,不好画
已赞过
已踩过<
评论
收起
你对这个回答的评价是?
展开全部
求解线性规划问题的基本方法是单纯形法,现在已有单纯形法的标准软件,可在电子计算机上求解约束条件和决策变量数达
10000个以上的线性规划问题。为了提高解题速度,又有改进单纯形法、对偶单纯形法、原始对偶方法、分解算法和各种多项式时间算法。对于只有两个变量的简单的线性规划问题,也可采用图解法求解。这种方法仅适用于只有两个变量的线性规划问题。它的特点是直观而易于理解,但实用价值不大。通过图解法求解可以理解线性规划的一些基本概念。
线性规划问题的数学模型的一般形式
(1)列出约束条件及目标函数
(2)画出约束条件所表示的可行域
(3)在可行域内求目标函数的最优解及最优值
10000个以上的线性规划问题。为了提高解题速度,又有改进单纯形法、对偶单纯形法、原始对偶方法、分解算法和各种多项式时间算法。对于只有两个变量的简单的线性规划问题,也可采用图解法求解。这种方法仅适用于只有两个变量的线性规划问题。它的特点是直观而易于理解,但实用价值不大。通过图解法求解可以理解线性规划的一些基本概念。
线性规划问题的数学模型的一般形式
(1)列出约束条件及目标函数
(2)画出约束条件所表示的可行域
(3)在可行域内求目标函数的最优解及最优值
已赞过
已踩过<
评论
收起
你对这个回答的评价是?
展开全部
先要由题目给定的约束条件在XOY平面里画出可行域;
直线Z=x+y(Z看作常数)沿向量{1,1}方向平行移动时Z增大,沿这个向量反方向平行移动时Z减小;
直线Z=x-y(Z看作常数)沿向量{1,-1}方向平行移动时Z增大,沿这个向量反方向平行移动时Z减小;
根据题目要求是最大值还是最小值,确定直线平移的方向,直到直线与可行域只有一个交点时,便求得了取得最大值或最小值的点(x,y),从而可以求出最大值与最小值。
直线Z=x+y(Z看作常数)沿向量{1,1}方向平行移动时Z增大,沿这个向量反方向平行移动时Z减小;
直线Z=x-y(Z看作常数)沿向量{1,-1}方向平行移动时Z增大,沿这个向量反方向平行移动时Z减小;
根据题目要求是最大值还是最小值,确定直线平移的方向,直到直线与可行域只有一个交点时,便求得了取得最大值或最小值的点(x,y),从而可以求出最大值与最小值。
已赞过
已踩过<
评论
收起
你对这个回答的评价是?
展开全部
若知直线公式是
:ax+by+c=0
,则斜率=-a/b若知道两点坐标(x1,y1)(x2,y2),则斜率=(y2-y1)/(x2-x1)
此类题做法:根据题目所给的3个不等式作图,求出可行域,从而得到所求式子的取值范围
:ax+by+c=0
,则斜率=-a/b若知道两点坐标(x1,y1)(x2,y2),则斜率=(y2-y1)/(x2-x1)
此类题做法:根据题目所给的3个不等式作图,求出可行域,从而得到所求式子的取值范围
已赞过
已踩过<
评论
收起
你对这个回答的评价是?
推荐律师服务:
若未解决您的问题,请您详细描述您的问题,通过百度律临进行免费专业咨询