lab2 zad3

lab2 zad3



File Edit Packages Windows Help

1 iy

w

n

#


R Console

> lp.transport (koszty, "min", row.signs, row.rhs, col.signs, col.rhs)$solution Error in lp.transport(koszty, "min", row.signs, row.rhs, col.signs, col.rhs) : Error: We have 3 signs, but 5 columns library(lpSolve) library(RODBC) setwd("c:/polu/")

dane <- odbcConnectExcelCstart.xls") koszty <- sqlQuery(dane, "select * from [Arkuszl$]")

Warning messages:

1: closing unused ROD3C handle 2

closing unused R0D3C handle koszty=as.matrix(koszty) row.signs <- rep ("<=", 4) row.rhs <- c(120,120,40,280) col.signs <- rep (">="/ 3) col.rhs <- c(100,100,100) lp.transport (koszty, "min",

Success: the objective function is 1580000 > lp.transport (koszty, "min", row.signs, row.rhs,


1

row.signs, row.rhs, col.signs, col.rhs]

col.signs, col.rhs)$solution

P

0


[,1]

[,2]

[,3]

u,]

100

0

0

[2,]

0

60

60

[3,]

0

0

40

[«,]

0

40

0

> 1

4


Wyszukiwarka

Podobne podstrony:
30vcu11 Ą>- OCON - Mycondoc File Edit View Window Help D
36vbu06 •Jl Microsoft Access - [Table: tblCandidate] **n File Edit View Window Help E® y uf i-J 9
44LSG01 Wais search results File Edit Navigate Window Help Back URL:
44LSG02 Search of /disk1/wais/wais-sources/sci.astro.... File Edit Navigate Window Help Back U
ŁS Zbrodnia Smoleńska - Anatomia zamachu.pdf - Adobe Reader File Edit View Window Help £) ^ 0 ® ®
slide0111 image511 TeamPDM File Edit Ąnaly2e Window Help [Ramie_dociskajace (Ramie_doci-;l aiace. 1)
Pfigs05 ShowString - ShowStl File Edit View Window Help PJ ShowStl Links: Type Update Cancel C: WI
OuickTime Player 7 File Edit View Window Help E3 0 <S> V * <D ^ ■«» 56% New Project- P New
MATLAB Command Window File Edit VSew Window Help o o To get starter!, type one of these: helpwin F

więcej podobnych podstron