You are on page 1of 208

T0 c

oex
ist
enc
eo fpeaceandharmonybetweenth
edi
ffe
ren
t
MA
n.ABi
sar
egi
sle
redl
rad
ema
rko
f宵 l
eMalhWorks,I
nc
. melodieso
fpeopleeverywhere
T
hisb
ooki
sp巾 l
edo
nnc
id伽 paper.@

C
opy
rig
hl2 2b
@ ∞
yJo
hnW
ile
y& S
ons,NewY
ork
.AI
Iri
ghl
s陀 賠 刊e
d.

P
ubl
ish
eds
imu
lta
neo
usl
yinC
nna
dn.

Nop n
rto fIh
ispub
licll
lio
nmayber e p
rodu回 d,st
oredina問 tr
iev
叫s ystemor1悶nsmi
ttedinnnyf o
rmo r
byanym 回n s
,ele
clron
ic,mec
hanicaJ,pholoc
opying,問c o
rdin
g・scan
ningoro t
herw
ise,ex
ceptas
per
m i
ttcdu nd
erSectio
ns1 0
7or1 08ofthe1 976United,St
alc
sCopyri
ghlA cr,w
irhou
leithe
rtheprior
wri
t t
cnp苦r m
issi
ono fIh
ePubli
sher,orouth
ori7
.3l
ionthroug
hp aym
enloft h
ea p
prop
riul
epe r
-copyfcc10
Ih
eC opy
r igh
lC l
earanceCen
ler,222Ro 揖 W∞ dD r
ive,D n
nver
,百 MA0 1923,(97
8)750・8400,f
nx( 9
78)
750・47
44.R equ田 I
S10IhePubli
she
rf orpermi
ssionshouldbenddre
ssed10thePeml
issio
nsD ep
artmenl,
JohnWil cy& Sons,In
c.,60
5百 i r
dA venue,NewY ork,NY1 01∞
5
8- 1 2,(212
)8 50-ω
11,加 ( 212)
850
-6 008,E-Ma
il:PERMREQ@WILEY.COM.

η首spub
lic
ali
onisdes
igned1
0prov
ideacc
u問lenndau
tho
ril
ali
veinfo
mta
l i
onin冊 E副甘 1
0山esubj
ecl
mat
terc
ove .I
問d tis80l
dwithth
eunde
rslu
ndi
ngIha
lthepu
blis
heri
snolengag
e dinren
d自吋ng
pr
ofe
ssi
ona
lser
vice
s.Ifpr
ofe
ssi
onn
lndvi
ceorot
hcrex
per
ta s
sis
lan
ceis民 q
uir
ed,出es er
vic
esofa
co
mpele
ntpro
fes
sion
alp 。

e n asho
uldbesou
ghl
.

U
bra
ryo
fCo
ngr
essC
ata
log
;lg
I ;
nP"
bl;
cat
iot
lDat
a:

V
enk
oluro
m且n,P.

App
liedopli
miZlll
ionwithMATLAB~ P rogramm
ingIP
.Ven
kala
r百ml
ln.
p
.c om.
“AWiley
-Inte
rsc i
enccpubl
icn
lion
."
ISBN0-471剖 9 58・
.5(1o
c th:al
k.pnp
er )
1.Mn
lhema
l i
caJo pt
imiz
ation
--D
olllproc巴出 i
ng・2
.MATLAB.J.T
it
le
.

Q
A402
.5.V
422
001
51
9.3
-dc
21 2
001
026
938
P
rin
ledi
nIh
eUn
ile
dSl
ale
sofA
mer
icn
.
10987654321

一一一一 巾
6 一
~拍泊当.,“、“由4幽以罰r;r :T,
一 ← 一 十 十
τ-一一-一一 ←

CONTENTS

PREFACE x
ii
i

1 I
ntr
odu
ctl
on 1
1
.1 O
pt i
miz
ationFundamen
talsI2
1
.1.1 Elemen
tso fProble
mFormu
lat
ionI4
1
.1.2 Mathe
maticalModeligI1
n 0
1
.1.3 Natur
eo fSol
utionI1 6
1
.1.4 Cha
ract
eris
ticsoftheSe
arc
hProc
edu
reI20
1
.2 I
ntrod
uct
iontoMA1 1
.As I2
. 5
.2
1 .
1 WhyMATLAB?I25
.2
1 .
2 MATLABI n
sta
llat
ionIssue
sI26
.2.
1 3 UsingMATLABt heFi
rstTimeI27
1
.2.4 Usin
gt heEdi
tor/3 3
1
.2.
5 CreatingaCodeS nipp
e t/37
.2
1 .
6C r
eatingaProgramI40
P
rob
lesI44
m

2 GraphlcalOptlmizatlon 45
2
.1 針。b lemDefin
iti
onI45
2
.1.1 E xample2.
1 I46
2
.1.2 F ormatfo
rlh
eGra
phi
calD
isp
layI47
2
.2 G
raphi
calS
olut
ionI48
2
.2.
1 MATLABHigh-Leve
lGrap
hicsFun
cti
onsI48
2
.2.
2 Example2.I
- Gra
phic
alS o
lut
ionI50
2
.2.
3Disp
layin
gt h
eG r
aphisI5
c 3
2
.2.
4 C
ustom
izingtheFig
ureI54
2
.3 A
ddi
tio
nalExamplesI56
v
l
l
v
l
ll CONTENTS CONTENTS I
x

2.
3.
1 Example2 .
2I56 4
.1.
1 P
roble
mFormulation-Example4.
1 /1
55
2.
3. 3I64
2 Example2. 4
.1.
2Disc
ussio
nofCons釘ain
ts/1 57
2.3 Example2.
3. 4I73 4
.2 Ma
thematicalC on
cepts/1 59
2.
4A dd
iti
ona
lMA 11.
.ABGra
phicsI79 4
.2.
1 S ymbo l
i cComp
utationUs
ingMATLAB/1
59
2.
4.1 Hand
leG raph
icsI80 4
.2.2 Ba~ic Mathe
matic
alConce
ptsI1 62
2.
4.2 Gr
aphic
alU serInt
erf
aceI81 4
.2.
3 T aylor'sTheore
m/Se
ries/169
2.
4.3 GUICodeI84 3 G
4. rap
hica
1Solut
ions/1 71
R
efe
ren
cesI9
1 4.
3.1 Un
constrai
nedProblem/1 71
P
rob
lesI9
m 2 4.
3.2E q
ualit
yC on
strain
edProbl
em/1 7
2
4.
3.3 In
equa
lityCons
traine
dProblem/1 73
3 LlnearProgrammlng 93 4.3
.4 Equa
lit
ya ndIne
qual
ityC
onstr
ain
ts/1 74

3
.1 P
roblemDefi
niti
onI94 4.
4 An
alyt
ica
1C o
ndition
s/1 75
4.
4.
1 U n
constrai
nedProblem/1 7
6
3
.1.
1 S t
andardFor
mat/94
4.
4.2 Equa
lit
yCons 回 in
edP r
oblemI1 79
3
.1.
2 M ode
lingIssu
es/98
4.
4.3 In
equa
lityConst
rainedOpt
imiza
tio
nI18
6
3
.2 G
raphi
calSol
utio
n/1 07
4.
4.4G en
eralOptimiz
ationProblem/191
3
.2.
1 Example3.1 /110
3
.2.
2 C h
ara
cte
ris
ticsoftheS
olu
tio
n/I I
1 4
.5 Ex創npl
es/1 9
4
3
. 3 D
2. i
ffe
rentSo
luti
onTypesI1 14 4
.5.1 Example4.2/ 1
94
4.
5. 3/1
2 Example4. 9
6
3
.3 Nume
ric
alSolutio
n-theSimp l
exMethodI1 1
5
3.
3.1 Fe
atu
resofth
eSimplexMethod/1 15 R
efe
ren
ces/200
3.
3. 2 Ap
plic
ati
onofSimplexMethod/1 17 P
rob
lem
s/2
01
3.
3. 3 So
lut
ionUsingMA11
..B/1
A 20
33.
. 4 So
lut
ionUsingMAT
LA B'SOp
timiz
ati
onTool
boxI123 5 NumericalTechnlques- e
TheOn-DlmenslonalProblem 203
3
.4 Ad
diti
onalExampl
es/1 24 5
.1 P
roblemDef
init
ionI204
3.
4.
1 Example3 .2-
Tra
nsporta
tionPro
blem/1 2
4 .1
5 .
1 C o
nstra
inedOne-D
ime
nsi
onlP
a r
oblem/204
3.
4.2 Example3.3-Equa
lit
yCons
tra
intsandU
nres凶ct
ed
5
.2 S
oluti
ontoth
eP rob
le m/2 05
Vari
able
s/1 30
5
.2.
1 G r
aphic
alSolutio
n/2 05
3.
4.3 Example3.
4- AFour-Va
ria
bleProb
lem/1 34
5
.2.
2 Newton-RaphsonT e
chniq
ue/206
3.
5 A
dditi
onalTopic
sinLin
earProgramming/1
38
5
.2.
3B i
sect
ionTechniqueI2 0
9
3
.5.
1 P r
i m
ala n
dDualProb
lem/1 38
5
.2.
4P ol
ynomia
lA pproxi
matio
n/211
3
.5.
2 S e
nsiti
vit
yAna
lysis/1 48
5
.25 Go
. lde
nS e
ctionMethodI214
R
efe
r芭n
ces/1
51
5
.3 I
mpo
rta
nceo
fth
eOn
e-D
ime
nsi
onlP
a r
oblem/217
P
rob
lem
s/1
52
5.
4 Add
iti
onalExamplesI2 19
5.
4.1 臥a mple5.2-I
l
1us
回t i
onofGe
nemlGolde
nSe
ctio
nMeth
od/21
9
4 NonlinearProgramming 154 5.
4.2 Example5.3ー Two
-Poin
tBoundaryVal
ueProble
mI220
4
.1 P
roblemD
efi
nit
ionI1
55 5.
4.3 Example5.4-RootFindi
ngwithGol
denSec
tionI223
X CONTENTS
CONTENTS x
l

R
efe
ren
cesI225 73.
. 3 Gener
a1iz
edRed
ucedGra
dient(GRG)MethodI297
7.
3.4 S句 ue
nti
alGr
adien
tRe
stora
tionAJ
gori
thm(SGRA)I302
P
rob
lesI225
m
7.
4A d
diti
ona1ExampJesI307
7.
4.
1 ExampJe7 .2-F
Jagpo
JeP r
oblemI307
6 NumerlcalTechnlquesf
orUnconstralnedOptlmlzatlon 227
7.
4.2 ExampJe7.3-BeamD e
signI310
6
.1 Pro
ble
mDefin
itio
nI2 27 7.
4.3 ExampJe7.4ーOptima
1Contr
olI313
.1
6 .
1 Example6.
1 I228
R
efe
ren
cesI316
6
.1.
2 Neces
saryandS
uffi
cie
ntCo
ndi
tionsI2
28
P
rob
lesI316
m
6
.1.
3 Eleme
ntsofaNumerica
1Te
chniq
ueI229
6
.2 Num
erica
lT echniq
ues-N
ongr
adi
entM
eth
odsI230
8D
lsc
ret
eOptlmlzation 318
6
.21 RandomWa
. 1kI230
6
.2.2 Patt
emS e
arch/234 8
.1 C
on ce
ptsinDisc
ret
eProgra
mming/320
6
.2.3 PoweJ'sM
1 ethodI238 .1
8 .1 ProblemRel
axa
tinI3
o 21
8
.1.2 Disc
reteOpt
imalS
olut
ionI322
6
.3 Numer
ica
lT,配h niq
ues-Gradie
nt-Bas
edMethodsI241
'6.
3.1 St
eepes
tD e
scentMethodI2 41 8
.2 D
iscre
teOpti
mizati
onT e
chniq
uesI324
6.
3.2 Con
jugateGradi
ent(F1e
tche
r-Re
eves
)MethodI244 8
.2.
1 E x
hausti
veE nu
merat
ionI326
6.
3.3 Davi
don-FJet
cher-Po
wel
IMethodI246 8
.2.
2 B ran
cha ndBoundI329
63.
. 4B royd
on-Flet
cher-
Gold
fart
トShannoMethodI249 8
.2.
3 DynamicProgramming/336
6
.4N
ume
ric
alTechniques-SecondO
rdrI2
e 51 8
.3 A
dditi
ona
lExampl
esI3 41
8
.3.
1 Exnmple8.
4--1BeumDes
ignI34
1
6
.5 A
dditi
onalExam
plesI253
8
.3.
2 Zero-OneInt
ege
rProg
rammi
ngI343
6
.5.
1 Example6.2-RosenbrockProble
m/2 53
6
.52 E
. x
a m
ple6.3-
Three-
Dimen
siona
lAown 飼raRo凶 n
gDi
skI2
55 R
efe
ren
cesI348
6
.53 ExampJe6.
. 4-
FittingBezie
rP a
ram
etr
icCurv
csI258 P
rob
lem
sI348
R
efe
ren
cesI262
9 GlobalOptlmlzation 350
P
rob
lesI263
m
9
.1 Pr
o bl
emDef
ini
tio
nI3 5
1
7 NumerlcalTechniquesf
orConstralnedO
ptl
mlz
atl
on 265 .1
9 .1 Gl
obalMinimum/3 51
9
.1.2 Na
tureoftheS
oluti
onI354
7
.1 Probl
emDefini
t inI266
o
9
.1.3 Ele
mentsofaNumerica
1Te
chn
iqu
eI356
.1
7 .1 ProblemFormulation-Example71 I266
.
9
.2N
umeri
calT,白h
n i
qu巴san
dA d
diti
onlEx
a am
ple
sI357
7
.1.2 Necessa
r yCon
diti
ons/2 67
9
.2.
1 S i
mul
atedAnne
aling(SA)I358
7.
1.3 ElementsofaNumerica
lT echni
queI269
9
.2.2G e
net
icAlgori
thm(GA)I366
7
.2 I
ndir
ectMet
hodsfo
rConst
raine
dO p
timi
zat
ionI270
R
efe
ren
cesI3
77
7
.2.
1 E x
teri
orPe
nal
tyFunct
ion(EPF)Me出odI2 71
7
.2.
2 AugmentedLagr
angeMult
ipli
er(ALM)MethodI276 P
rob
lesI3
m 78

7
.3 Di
rectM
ethodsforCons住ain
edOptim
izati
onI281
10 O
ptl
miz
ati
onToolboxfromMA B
TlA 379
7.
3.
1 S e
que
nt 1L
ia in
earProgramm
ing( S
LP)I284
7.
3.2 Se
que
ntia
lQ ua
dratcP
i rogramming(SQ
P)I289 1
0.
1 TheO
pti
miz
ati
onT
ool
boxI380
x
ll CONTENTS

1
0.1
.1 ProgramsI380
1
0 .2 UsingProgramsI382
.1
1
0.1
.3 S
ett
ingO
pti
miz
ati
onP
ara
met
ersI384
1
0.2 E
xam
plsI3
e 85
1
0
1
0
.
.
2.
2
1
.
2
L
in
Q
ua
e
d
r
rP
a
at
r
i
ogrammingI3
cP r
85
ogrammingI386
PREFACE
1
0.2.
3 U
nco
nstra
inedO pt
imizati
onI388
1
0.2.
4 C
ons
trai
nedO pt
imizati
onI3 8
9
R
efe
ren
ceI3
91

Index 393 百l
m
c
esu~ject o
a
o
n
s
ag
to
er
fp
s,
r
fo
a
od
p
t
n
u
i

c
m
i
dm
t
z

i
a
t
o
o
i
s
o
ni
te
n,a
sr
v
n
e
e
c

df
e
i
r
v
y
i
i
n
b
n
gs
o
a
e
d
l
ri
o
ye
u

y,t
l
sa
l
s
t
e
h
te
n
.T
es
ti
o
h
u
n仕ome
i
c
si
ce
n
sd
s
g
r
so
i
n
i
ee
r
v
ft
s
e
h
,s
cie
nti
st,
s

nbycompe t
eb usine
s se
i
n
t
on,
e
qua
中 市e
li
t
.
l
ya
g
no
s
r
s
u
in
ranc
g出e
e,

pract
iceo fo ptimizatio
ni snotano ptiond uringcurrenttimes.
Optimiza tionisp racticedt hr o
ughs oftwar芭 programsa ndr equire
ss ignifica
nt
compute rre sour
ces.Th et echniquesofo ptimizationhaven otc hangeds i
gnifi
cantlyin
陀c en
ty ea rs,b uttl
lea reaso fa ppl
icationsh av emushroomeda tas ig
nific
antr at
e.
Success
fu llyembeddingt heu seo fopt im
izationi nprofessionalp r
a c
ticerequiresat
lea
stthreeP 陀 巴quisites.τbeyi ncludem ath
e maticalmo delingo fthed es
ignp robl em,
knowledgeo fc omputerprogramming,a ndknowledgeo fop t
i mi
zationt ec
hniques.
Many s pecial-purposeo ptimiz a
t i
ons oftwarep ackages 白紙 r e
lax 由巳 r equired
knowledge o fprogramming a r
ea vaila
blet oday
. To u se them e ffic
ient
ly,t he
remainingtwoa re
assti
llh avet obea ddressed.
百lerea res evera
le xcellentb ooksont hes ubjec
to fo ptimization,afewo fthem
releas
edr ecently.Mosto fthemc ov巴r thesubjectindepth.whichi sn eces
saryb ecause
th巴mathe maticalm odelsa reno nl
i nea
ra ndr equirespec
ialt echniqu巴s t
hatareusually
notpaはo fa nycorecurriculum.A llof山eb ooksassume白 紙 出er ea
derisfamilia
rw ilh
aprogrammingl anguage,町a ditio
nallyFORTRAN, andrecently,C.A nothera s
sum plion
h芭quentlymadei s白紙 t heo ptimization包c hniqueswi 1
lbeimplemented i na
mainframec omp utingen vironm enl
.S uchac om binationisex 官emelyd iffi
cu1
tf orthe
sel
f-Iea
r nere venw it
henormousm otivation.
Ane xplo sionofinexp en
si vede s
k t
o pcom p
u tingresourcesa idsengineeri
ngd esign
pra
cti印 t oday.P ara
llelingthisd evelopm entis出ea v
ailabi
lityo fextensive陀 sou陀 凶
ont h
eI nternetb
, othforl ea
rn i
n ga n
ddeployment .Thisisj oinedbyt heavail
abilityof
sof抑制官s ystemst h
atpr ovide叩 o pportunityforh andlingma t
h ematics,grap
hics.a nd
programmingi nac onsisten
tm an n
e r.Theses oft war
es ystemsa r
es ignif
icant
1ye asyto
mastercompar 吋 t otheh igher-levelprogrammingl anguageso ft h
ep陀 v iousye 町S.
百lisbookp rimarilys eekst oh arnesst his釘i angulationo fs 巴rvi
c e
st op rovidea
pra
ctica
la pproa chtoth estudyo fd esigno ptimizati
on.百 l ebooku sesMA TI.B@t
A o
i
11us
tratea ndi mp le
me ntthev ariouste chn
iqueso fo p
timization.MATLABi sap roduct
fromMathWorks.I nc.
Thi
sbooka ttemps10a
t cco mplishtwoi mportantobj田 tiv
es.Thef ir
x
lv P
REF
ACE P
REF
ACE XV

ofsymb o
lic.n u
mer ic
al.a ndgrap
hicall
f回 tur
esofMATLAB・l tinteg
rate
s山i sp owerfu
l classrooms et
tingwith ou1computationalc xperienceisa lsofeas
ib1
e.I n由i sc a
set h
e
combinationd uri ng恥 凶n sla
t i
ono fmany a l
gorith msi nt
oa pp1
ied numerical a1gorithm
sc anb eprese n
tedandt hen ur
nericalresul
tsi llu
stra
ted
.Thes enior/g
radua
1e
techniquesf ord esigno pti
mizatio. Th
n ereis ac on stante nhance me n to ft he s1uden
tsi nv ariousd i s
cipi
¥nes.e speci
allye nginceri g,a
n ret het a
rg c
1a udienc
e.
programmings killsthrougho
utth 巴book.Thes ec o
nd0 吋e cti
veisth巴pr im ar ytas
ko f Optimizationt ech
niq ucsa rea ni mportanl1 00
1t os olved csignp ro blemsina l
l
侃 b ook-toc om municat
eandd emonstratevariouslIu merica
lt ec
hni qu est h
ata re profes
sionala re
aso fs tudy
.Manyi l
lustr
ation
sa re仕omt hea reao fm echani
cal
currenlかusedi nt l
teareao l
optimald es刷. engineeringrefl
ectin
g出巴 e xperie
nc eof白eau 白or.
AHo ft h
cn u meric
altechniquesMEsupportedbyMMLABc odea va ila
bleぉ Independentlear
ne l
's,p
articu
Iarlyprofession
alswhon eedtounderstandt h
esubjec
t
c om
pu ter file
s. These f i
le
s a r
e a vaila
bl e on a companion web s i
te ofo pt
imization,shoulda lsofindt hebookv eryu s
e f
u .
lA r eaderwhoh asa cc
essto
www.wilev.comlvenka t
.ltisnecessarytovisi
tt hewebs itetodownloadt hcfi
lesto MATLABs oftwarec 剖 us巴 thebookt oi tsb e
sta dvantage
.The book i sl a
rgel
y
foll
owa l
loftheE Xt
lI
npies-Theboo kwillbee蹴 n削ti
a
叫lly
i n
脚∞
c omple
巴t
.
旬ewi
ωth
削0
o
肌u


凶山tt
』此 hcs
cfile
s. self-c
ontainedandd ev elopsalln cccssarym athemati calc oncep
t s when n ced
cd.
Att hewebs it
eyouw illalsofinduscfullink
s1 0o t
he rr esourc
es,awebcourseon Abstrac
tm athematicali dcasofo ptimi国 tio
n創 芭 i n
t roduccdgraphi
callya ndt hrou
gh
MATLABprogramming ,andu pdatedinformationa b
ou tA ppli
edO ptin t im uo
nw ith i
Ilustr
ativeexamplesi nt hcb o
ok.I nmanyi nstances,t h
eo pera
tiono ft h
cn umcric
al
MAT l.
AB @Progra mming. techniqueis祖 国a tc
dt oshowhowt hed esignischangingw ithiter
ations.Thishas
Thed ecisiont oloc
atet h
ef i
lesonawebs i
tepmvidEsana venuet oshadowt he beenp o
ssibleb e
causeMATLABg raphicsarerichinf ca
tu r
esa ndsimplet oinco叩oratc
.
dynamicc hangesi nMATLAss o
f 1w
areitsc
lf,whichisb c ingtransf
orm edi nam ajor makingUlcmc ff
cctivef orc onvcying出ei dca.I
s ti sf orthisreason出er ead
eris
waya lmosteveryy ca
r.ltprovi
desamechanism1 0correc tbugsi日出ec od ei nat i
mely cxposedt og raphical programming e ar
ly on,i ncIud ing ac hap
t rong
e raphica
l
m anner.Itestab¥
ishesa noppo
rtunitytoim pro
ve自己 c o det hroughreaders uggcst
ions optimi
zation.Tob alancet hcdevelop mentofprogrammings k
ill
sa ndth巴p resen
tatio
n
andpr o
videsawayf or出ea uthor10keept h
crca de
reng a gedw i
thnewd c vc lopm
ents. ofo ptimizati
onc o
nc epts,programming i ssuesa rei ncreme
ntallye xplor
eda nd
I
tdoωcutdownt hesizcofthebooke normousl ybylo cat i
ngal
lo fthep a g 回 ofcode implemented.I nvestme nto ft im
ei nd巴v elopi
ngprogrammings ki
llsi s出em ost
eff
e c
tivewayt oi mbib et h
em.Thca uthorisn Ola wa r
eo fs ho
rtcut
s.S tudc
ntsa r
c
ou
tsidethebook.
Anu nusualfeat
ureo fth
ebooki s由ci n
clusio
no fdi
scret
eo p
timiz
ationandglobal expectedt opr ogrami ndepend
e n
tly.makem istakes, debuge rr
ors
.a n di nco
rporat
e
op
timiza
tion.Tradil
io n
alc ontinuo
u sdesignoptimiza
tiont e
chniq
uesdot a
keupa improve m
e ntsasp紅 to ftheirlearn
i ngexperiencede l
i ver
edt hrough出i sbook.
si
gnifi
cantporti
ono fthebook.C ontinuousproblemsgener
allyallowthealgo
rithms Thebookp roce
edsa tab riskpacet oprovidee xperienccinMATLA8programming
ob
t emathematic
allyd evelopedinac onvin
cingmanncr ,and由民ei deascoudbe向
l andcommunicatei deasi noptimizationinar easonablenumbero fp ag
e s.Th i
sc ou
ld
cor
eo fo r
igina
la 1gorith
msd cvc10pcdbyt her ea
derstoa dd
ressthei
rowns pe
cial notbep os
siblewithoutt akingadvantageo fIheaccompanyingwebs it
e1 0locat
emuch
necd
s.E veryc ha
ptcri ncl
u d
esa ddit
ionalnont
rivialcxamp1es由a toftcnpres
cnta oft hec odef o
ra lg orithms and e xamp
l es
. Merely r unningt hec odew il
ln 01
noveluseorextcns
iono fthcoptimi
zationtechn
iquesinthecha
pte.Th
r emathc
matical signi
fican
tlye 油 田c et her e
ader'
sprogrammings ki
lls.Itisi mp
ortantf orthestuden
t
algori
thms and cxa mplesa r芭 accompanied by MA'礼 ABc odea vail
ableatt he tounderstandthecodea lso.To箇 sistin白i sprocess,thec odecarr
iesI
iber a
lcomments
companionwebsue-Thenumericalt echniq
uesu su
allyi n
cludestronggraph
ical oftencorrespondingt othea lgori
thmt hatisb ei
ngi m
p lemcnted.Thea u出o rexpec
ts
suppor
ttoi l
1us
tra
te出co pcrat
i o
no fthctech
niques
. 出er eadertoh averea d出ec omments .Th eaccompanyingc odeallowst heinstr
ucto
r
D
iscreteandglo
ba loptimi
za t
iontechniqu
esarebasedonv e
rydiffe
rental
goriths,
m toassignbothprogramminga ssig
nm entsasw el
la ss o
and 回 .c
ho fthcm c ane as
ilyj us
tifyf ul
l-fl
edgedi n
d e
pendentcourscsd 叩t
e cd
exclus
ively10thci
rS 1udy
.I nac omprchensivcbooks uch
x
vl P
REF
ACE P
REF
ACE x
vii

approache s,t hei nst


ructorc anc hoos et oincludeo nl
y as ubs
eto fc o ntinuous Thebookwasmadep oss
iblet h
r o
ughsupportfromJ oh
nW il ey叩 dSons,Inc
., 叩d
optimizationa l g
orithmstoa llowt hei nclu
siono f出e sep opul artechniq
ue s.If出e MathWorks,I nc
.S in
cerethanksa reowedt oBobA r
gentie
ri ,senio
re d
itoratJobn
studenthasa cc
esstotheO ptim izati
onT ool b
oxf romMATlAB,白e nitcanb ein te
grated Wileyf oraccep
tingtheproposal,andwhoa l
la lon
gd isp
laye dal o
to fpatienc
ein
into出ec o ursef o
rh andlingt hefin
ald esignp r
ojec.
tThel astc h
apterp rovidesan get
t i
ngthebookmovingforward.Samei sduet oBobH ilbed -
a s
sociatemanaging
overvi e
wont heuseoft heto olbox. edi
toratJohnWiley ,forhisimp 陀ssiveworka tc1ean
ingu pt hemanuscrip.
tB r
ian
Thisbooks tarte
do utu sin gMA TI.
ABV ersion5.Abouth alf wayt hroug
ht hebook Snapp,New Media e d
itora tJ ohn Wiley,c reat
ed 出巴 companion web s it
e
血et ran
sitiont oMATlAB V ersion5. 3wasc omplete.Att hec o
mpletiono ft he (www.wiley.com
lvenkat)a ndw辿 a l
sob ernaint
ainingit
.NaomiFemandes企om
m叩 u scr
ip tMATLABV e rs
io n6wωshippingf orsomet ime
.Aso fthi
st ir
ne,Version MathWorks, In.,
c sawtoit白a t1h adthelate
stversio
no fMATLABa ssoona si
twas
6.1isavailable.Mosti n
stitu
t iona
lMATlABl i
cens
esa reusuallyb asedo nsubscription av
ailabl
e.Myr eg
ardforDr.An g
e loMiele,Prof
essorEmeritus,atRiceU n
ivers
ityis
so白紙 t heyw il
lh ave出巴 l atestv e
rsiono f白es oftwa
re.I nas en se,and出i sist rueof moret ha
nc anbeexpres
sedint h
e eI
s ine
s.Itwash ewhoi ntroducedmet o1h巴subje
cl
al
lb ookst hatd ependonp articularsoftwaresystems,thebookr naya ppe
aro uto fdate ofo p
timizat
ionandd emonstratedthee ff
ecti
venessofs imp
l ep resenu
tion-Iw i
ll
withr es
pec tto白es oftware.T hisisnotr e
allyso
.Whilet heusag eofMATLABf unctions alwaysregardhimasag re
atteacher
.Ofc ourse,myf amil
yd eservesspec
ialrnent
ion

炉羽山
rnayc hangeb et we
env ersions, t
hereshouldbes ui
tablewamingsandi nstru
ctiona bout fo
rp utti
ngupw ithal
lt he“Notnow, "“Later,
"“Howa bo
u tt orno
rrow?"d 町in2

dllpdLY
出ed i f
ferentu s ag
e・Ani m portanti nsuranceisbuilti nt
ot hebook ,particula
rlyt o debugging白ec ode.Sp配 ia
l出 回k saretoA帥 a na阻 dV inay ak,rn
yo ffs
prin
g ,町
i
t


handles uchc hangesiftheya ri
se.Sprinkledt hr
oughou tthebooki stheh abito f由e th
eirp a
tience,und
erstan
ding,andencouragement.Thea u白o ra polog
izesf o
ra ny
using出eo n lin
eh el
p.I nmosti nstan
ces出i swasp ri
mar i
lydonet oe xposeth ereader sh
ortcornin
gso nt h
ep r
esenta
t i
on and welcomes comments ,c ri
ticis
ms,and
su
ggestionsforimpro
ve me
nta ta
llt i
mes.
toalternativeu seofthesamecommand.A not
hers ignifi
cantc ha n
get heman uscript
hadt oe ndur ewas白 el o
sso fa ccesst oaUNIXv ersionb ecauseo fth巴univ er
sity'
s
chang etod is
tribut
edc omp ut ingonPCc lu
ster
s.Thea u
thor'se x
periencew i 白 血e P
.VENKATARAMhN
R
och
est
eれ NewY
ork
earl
yc h
ap terss ugg巴s
18t hatt h
iss houldn otma t
1er
.E xceptf o rexter
nalf ilesa n
d
resources,也巴 u seo fMA TlA Ba si ll
ustra
tedint hebooki si ndiffere
nttot hev ariou
s
operatings y自 由 ( Windows,Mac,UNIX,o rLinux)
.
Thet opicsc hosenforincl usionandt hesimpl
icityo fpresentationof出et opicsare
dir
ectlyr elatedt ot h
ee x peri e
n c
eo ft eachingt h
ec ourseono pti
mizationa tt he
senio
r /g
ra duateleve
li n出eD 巴partmentofM echan
i calE ngi
neer ingforovert enyears
.
Experiencep roved白 atco mpr ehensioni rnpro
vedw iths impleiIIust
ratio
ns, however
complicate dthem athe
m at
i cali dea
s.Ont heothe
rh and, s
traig
h ぜo rwardmathernatica
l
expressionse lici
tednoi nteresto runderstandi
ng.Thee mphasisona ppli
cat io
nwas
importantt ok eepthes t
udents 'atten
tion.Int h
isconnec tio
nt hea uthorwouldl iket
o
出創1ka llh iss t
uden18forpu shi nghinf
r orsimpleexplanations, forprovidingp o
sitiv
e
inte
raction, andf o
rt h
eirc ontributio
no fo ri
gina
la ndu sefulid easint h
ed iscuss


-
・ 圃
1 ・

・・a回. .

tJFJJ-

p
dむ

rh
w主にAbrψr=353thtY4y
INTRODUCTION

Optimizati
onh as become a n ecessaryp arto fd esigna c
tivityi na llm ajor
dis
ciplin
es.Thesed is
cipline
sa renotr es
trict
edt oenginee
ring.Them otivationto
producee c
on omicallyr el
evantp ro
ductso rservice
sw ithembeddedq ualityisthe
princ
ipalreasonf or由i sinclusio
n.Improvedp roductionandd esignt oo
ls,w i出 a
syner
gisti
ct hrustt hroughi n
e xpen
sivec omputationalr e
sources,ha vea idedthe
conside
rationo fo ptimization methods i n new d evelopments,p a
rticular
ly
engineer
ingp roducts.Eveni nt hea bsencco fat angibl
ep roduct,o pt
i mi
z at
ion
idea
sp r
ovidet h ea b
ilitytod efinea nde xp
l or
ep ro bl
emsw h ilef ocusingon
solut
ions出 atsub scri
bet osomem easureo fusefuln
ess.G en
erally, th
eu seo fthe
wordo ptimi
z at
io nimpli巴sthcb estresu
ltu ndert h
巴c ircum
stances.T hisi nclu
des
theparti
cularseto fconstr
aintsont hedevel opmentrcsourc
es,currentknowledge,
marketconditions, andsoo n
.Everyoneo fush asprobablyusedt hcte rmatsome
timetod esc
r ib
e出 ep rimaryq ua
lityo fourworko re ndea
vor.Iti spr o
b ably山e
moslu sedo ra b usedl ermina dv
ertisin
gandp re
sentat
ions.N everthcless,白c
abi
litytomaket heb e
stc hoic
ei sap erp
eluald esi
reamongu sall
.
Op
timizationi sfrequent
lya ssoci
atedw ithd esi
gn, beitap roduc,ts er
vice,or
str
ateg
y.A e
ro spacedesignwasamong出巴 e arl
iestdis
cipl
inestoembrac eoptimizati
on
inasignif
icantwayd r
ivenb yan atu
ra1needt olowerthet rem
endo u
sc ostassociat
ed
withcarry
ingu nnecess町 yweightinaerospacevehic
les
.Minimummasss tructur
esar
l巴
山 n orm.Optimiz a
t i
onf ormspartofthep sycheofeverya er
ospacedesigner.Saving
onfuelthroughtr司jec
torydesignwasa nothe
rp roblemthatsugge
steditsel
f.Ve rysoon
曲巴 ent
i問 engineeringcommunityc ouldrecognize由cn eedtodefineso l
utionsb a
sed
onm e
rit
.R ecognizingthedesireforoptim
izationa n
da c
tua1l
yi mp
le mentingwe 陀 two
dif
feren
ti s
sues
.
2 I
NTR
ODU
CTI
ON 1
.
1OP
TIM
IZA
TIO
NFU
NDA
MEN
TAL
S 3

Untilrecentl
y.f ormuchoft hetime.optimiza
t ionwasu su
allya ttemp
tedo nlyi n m
athe
matic
almode.
lτbedωi伊 .iω
chara
ctc
riza
tion
.四 dit
sci
rcu
mst
anc
esmustbe
tho
ses ituati
onswheret hereweres i
gnifi
cantp enalt
iesf o
rg enericd e
signs.Th e e
xpr
esse
dm at
hem
ati
cal
ly.C
onside
rt h
edesigna
cti
vit
yint
hefo
llo
win
gcas
es:
app
licatio
no fo ptim
i却 tiondemandedl a
rgec o
m p
u tationalr e
sourc
es.I nthen ascent
year
so fdigita
lc omputationthesewerea vail
ableo nlytol argenation
all ab
oratories ;:.~
"
.
• Newconsumcrr e
searc
hi n
dicat
ωthatpeoplelike10drin
kab o
u t0.5lit
crofsoda
andr esea
rchp r o
grams.Theser esource
sweren ecess
a ryt ohandlet h巴n onlinear " popalatimeduri
ngt h
esummerm onth.Th
s efabr
icati
onCOSIo ftherede
signe
d
problems出a t創 芭 assoc
iatedw ithengineeringo ptimi回 .t
io
n.Asar esu
ltoft hese sodacanispro
porti
onalto出巴 sur
facearea
.a ndc anbee s
tima tcdat$1.00pcr
con
strai
n t
s most of t hee verydayp roduct
s were d esignedw ithoutr ega
r dt o squa
remeterofthemate
riaIus
ed.Ac ir
cularcrosssect
ionisthemostp laus
ibl
e
opt
imization.Th i
sincludeseverythi
ngyous 回 ぽo undyouo ruseinyourd ailylif
e.It give
nc ur
renttooli
nga va
ila
bleform anu
fac t
ure.Fora e
stheticr ea
sons,白e
isinconceivable出att henewg ener
ationo frepla c
emen tp r
oducts
.l ikcthec a
r.t he hei
ghtmustbeatlea
sttwicet
hediamet
cr.Stu d
iesi n
dic
ate出a th o
l d
ingcomfor
t
house
.t hed esk
.o r出ep e
ncil.redesigne
da ndm anufact uredtodaya rcnotd esigned req
uire
sad ia
meterbetween6and9cm.
optim
allyi nones enseoranothcr. • Ac antile
verbeamncedstobedcsi
gn巴dtocarr
yap oi
ntl o
adFa tthecndofa
Today.youwouldd e
fmit巴Iyexploreprocedurestoo ptimizey ourinves回lentsby beamofl e
ngthL
.Thec r
ossse
cti
onofthebeamwiIIbeintheshu
peofth巴l巴t
ter
tai
lori
ng your p ortfol
io. You would o ptimizey ourb us
inesst rave
lt ime by I(路 島 町edωas却 I -
b回m )
.Thebeams houl
dmeetp res
cribe
df a
ilu
recri
ter
ia.
appropr
i a
旬I ychoosingyourd csti
nati
ons.Youc anoptimiz eyourcommutingt im巴b y 百e reisa ls
oalimi
toniωde f
I田tio
n.A beamo fminimummassi sreq
uir
吋 t o
choosingyo urtimeandr ou
te.Youc ano pt
imizey ourneces sar
ye xp
enditureforIiving bedesi g
ned.
byc hoosingy ourdaya nds t
oreforshopping.Youc ano ptimizctheu sef
ult imeyou • MyPCCompanyh asdecidcdtoinvc
st$12m illi
oni nacqui
ringsev
eraln巴W
connectto由巳 I ntemetbyd et
c r
miningyourt imeofc on
necti o
n.Youc anbuys oftware Componenl Placem 巴n
l Machines t o ma nu
facture diffe
rcnt kin
ds o f
白紙 w i
llo ptimizeyourc onn
cctiontot h
cl nte
mct.Youc a nbuybookso rreadartic
les mothcrb
oa r
dsf orancwg cnc
ratio
no fperson
alc ompu
lers.Threemodelso f
白紙 t cl
lyou howt op erformt he
sev ariou
so p ti
mizations.Theabovea c
tivit
ics thc
scm achinesareundercon
sider
atio
n.Totalnumbcro foper
atorsav
aila
blei
s
primar
ilyr ela
tcto: ;
crvI
cesors tr
ateg
y.Itisnowa pparcnt白 ate veryactiv
ity,except 100b ec
au s
co ft h
el oc
allabo tA f
rmarke. Ioorspaccc o
nstrai
ntneeds10bc
a巴S出etic,providesthes copeforoptimiz
ation.百l isjusti
fiesl o
okinga t白 estu d
yo f sa
tisf
iedb eca
u s
eo ft h
ed i
ffcr
entdimcnsi
on soft h
csemachines.Addi
tiona
l


ootimiz副o na sat o
ol白紙 c anbea p
plied10av ariet
yo fd isc
ipli
nes.Ifso,themyri a
叫d inf
ormationrcla
tingt
oe ac
hoft h
emachinesisgiveninTable1.
1.Thecompany
of叩
o戸

p

刑tim
凶iz
捌a

叫ti
on
叩吋p仰
叩r
叩obl
愉e
巴m
附n
凶s合ω
o


叩伽I
1
1
削 wishe
st od et
e r
minehowmanyofe achkindisa pp
ropri
ate10maximizet h
e
Thisi
おs曲eemphお a ぬ
s
isoft
由heboo k. numbero fboardsmanufac
turedperday.
The p artn
ershipb etween d巴signand o p
timizatio
na cti
vit
yi so ft
enf oundin
eng
ineering.Thisbookr ecognizestha
tconnec
t i
o nandmanyo fthcproblemsusedf
or Theabovel is
trcpr凶 ent
st h
reep r
oblems山a twiIIbeused1 0def
incformalelement
s
il
lust
ratio
nsandp r
acti
cea refrome ngin田ring,primari
Iym echa
nical,civ
il,and ofanoptimizati
onp r
obl e.Eac
m hproblem陀 quiresi n
formationfromthespec
ificarca
aeros
p aced es
ign.N cverth
el esst hes t
udy ofo ptim
izati
on.p ar
ticu
larl
ya ppli
ed ordisc
iplin
et owhichi trefe
rs.Tor ccogni
zeo rde s
ignth e
sep roblem
sassumes出a t
opti
mization.isn o
tm e xclusivepmpertyofmys ptcin
cd i
sci
purle.
Iti n
volve
sthe 出巴 design
crisc onve
rsa n
twi 白 山ep a
rtic
ularsubj田 tmatte
r.百 lep ro
blemsa r
ek ep
t
dECOVEryanddesignof叫 u ti o
nst hr
oughappro
pr i
atetechni
ques鰯 o c
iatedwitht
he simpl
et ofocusono pt
im i
zationissu
cs.Problemso fsuchv a
rielyareimpo
rtantt o
day
.
formu
l ati
ono fth eproblemi nas p田 if
icmanner.T h
isc anbedonef orexamplein Recenta dv
e r
tisementsi ng e
neralconsumerm agazinesi 1
I u
str
ate山 atAlcoa( a
n
economics, c
hemi s
try,andb usines
sman aluminumm卸 u f
aclur
er)isq uit
巴h appytoh aver cducedLhcw eightofthestandar
d
sodapopc anbyo v
er30%i nrecenlyea
rs.As imi
larc1aimbyt heplas
tic
sindustrywit
h
res
pecttothes ta
ndardm ilkjug(gaI
lon)isal50evi d
entint h
e s
em agaz
ines,althoug
h
in出iscaset h
enumberi s409 .Roofc
る oUapsesin白 cN or
theastd u
e1 0exc
essivesnow
1
.1 OPTIMIZATIONFUNDAMENTALS
T
abl
e1.
1 ComponentP
lac
eme
ntM
ach
ir悶
Opt
imizationcanbea pplie
dt oal
ld is
cipli
ncs.Qua
litat
ively,thi
sa s
serti
oni m
plies
mul
tipledecisi
onc h
oices
;i mp
licit
lyr eco
gnizingthen巴cessi
tyo fchoosingamong M
ach
ine O
per
ablc
a
1tema
tives.Thisbooksdeal
sw it
ho p
tirni
zatio
ninaquantit
ativeway.Thismeansthat M
odel B
oar
dTy
pes Bo
ard
slo
Hur Opemto
rsS
/hi
ft Hour
sIDa
y C
ost
IMa
chi
ne
anoutcomeo fa p
plyingoptim
izationto曲eproblem,d esign.ors e
rvicemustyield
number富 山atwil
ld e
finethesolu
tion.orinotherwords,numberso rvalues白紙 will A 10 5
5 1
8 4
00,0
00
cha
ract
erizethepart
icul
ardesignors e
rvic
e.Q u
anti
tativedcscri
ptio
no f出 巴 回lut
ion B 20 5
0 2 1
8 60,
0 0
00
C 18 5
0 2 2
1 70,
0 0
00
req
uire
saq u
anti
tati
ved e
scrip
tionoft h
eproblemi t
sel
f.Th i
sd es
cript
ioniscalle
da
r
:
:
.
-:
砕 l

'
"

ι

4 INTRODUCTION 1
.
1 OPTIMIZATIONFUNDAMENTALS 5

du
ringt h
e 1998-1999 win
terwillhavestru
ctu
ra1desi
gne
rsa ndh o
meb
uilde
rs des
ign.Thi sissignific
antbecausethee f
for
ti no bt
niningthesolutionv a
riesasan
ex
plori
ng白巴 secondp ro
blem.Th巴vibr
antstoc
km ar
ketinthe
set i
meshasmade int
egerpowero ft h
enumbero fvaria
bles,andthispoweri s1ypca
i 11ygreater山an2.
ba
1anci
ngt h
einvestme
ntportf
oli
omorechal
lengi
ng.Thcthi
rdcas
emays ugg
esta M回 tingther equ
i rementensur
esr e
ducedd i
ffi
cultyinm at
hematicallyexplorin
gt h
c
math
ematica
1modelapprop
riat
eforsu
chdeci
sionmakin
g. sol
ution
.
百l esetofd es
i g
nv a
riab
lesisiden
tifie
da sthed es
i g
nv e
ctor
.百1Isv田 t o
rw i
llbe
1
.1.
1 ElementsofProblemFormulatlon con
sider吋 ac olumnv e
ctorinthi
sbook.Inf a
c1,a
1 1vect
orsarecolumnv ectors切 出E
te
xt.Th elengthof血i sv ect
or,whichisn,ist henumbero fdesignvari油l e
sio曲E
Inthi
ss ecti
on,wew illin凶 duce出ef orma
1e le
me nt
so fthcoptim
izationprobl e
m .In proble.Th
m edesignv aria
blescanc xp
r e
ssd i
fferentdimension
alqu 叩 ti
ti
esin出巴
th
isbook,t het crmp roducta1so問 fer
st oas ervic
巴o ras tr
ate
gy.Its h ouldbe problem,butinthema lhem
aticalmodel,theyaredistingu
ishedby山巴 c hara
c1erx
.AlI
understood出a top 自凶z ati
onp r
esu p
posest h
eknowlcdgeo f由ed esignrulesf orthe ofthetechniq
ueso foptimiza
tioninthi
sbookn reb ascdon出ea bstractmathematica
l
sp配 i
ficpr ob
le m,primar
ilytheabili
tytod es
cribethed e
signinm athematica
1t erms. model.百les u
bscriptonx,f rcxamplc,X3・
o rcp
resentsthethi
rddesignv ar
iable,wh
ich
Theset erms泊cJuded esi
gnv ari
a b
les,d e
signp arameters,andd esignfunctions
. mayb et h
eh eigh
to fano bj
ec1in白ec h釘ucte
rizatio
no fthep ro
d uct
.T hisabs
trac
t
Trad
itiona1designpracti
田,出a tis,desig
nw itho
utr egar
dtoo pti
mizat
ion,incJudesa11 modelisne 回ssaryf ormathema
ticalconvenien
ce.T hisbookw il
lr ef
ert o曲ed esig
n
oft h
esee lements剖 伽ugh血e yweren o
tf ormal
lyr ecognize
da ss u
ch.T hisa lso var
iablesinoneo f出巴 f ol
lowingways:
j
ustif
ies出ep r
er e
quisi飽 th
atyoumustb ec a
pableo fdcsignin
gt h
e0 吋∞ti fyoua re
planni
n gtoappl y出et e
chniqu
cso foptimi四 t
ion.Itisal80agoodi dea10r ecognizc (
1)[
羽-refc町 i
ngt
oth
evc
c10
r0'
1d巴s
ignv
ari
abl
cs
th
ato p
timizationisap roced
urcfors c
arching1hebestdesignamongc andida
t 巴s,cach (
2)X o
rx -r
eferri
ngt oth
cvc
cto
rag
ain,o
mil
lin
g1h
csq
uar
ebr
ack
etsf
or
ofwhichc anp roduceana cc
eptableproduc.
tTheo cedf o
rt hcob
jec1orp r
oduc tisnot c
onvcn
icncci
fappr
opr
iat
e
questi
on e
dh er
e.b utt h
ismayb eduet oad ecisionbased00o ptimi
zationap pliedin
(
3)[
xjx
, 2'・
...,XIl]T_ーi
ndic
ati
ngt h
cv c
clorlhr
oug
hi t
se l
ement
s.N
ole 山e
anothe
rd isc
ipl
in c
.
s
uper
scr
iptt
ran spo
siti
onsymboltoi
den
tif
yita
sacolunmvec
tor
.
(
4)X;.i ,
=12....,
n-r
efe
rri
ngt
oal
loft
hee
lem
ent
soft
hed
esi
gnv
巴ct
or.
DeslgnV arlab les: Designvariabl
esa reentitiesthatiden
tifyapartic
ulardesign.In
出es e
archfor白巴 o ptimaldesign,出e seentitiesw il
lc hangeo verap rc
scribedrange.
Thca
bov
eno
tat
iona
1co
nve
nie
ncei
sex
tcn
dcdt
oal
lvc
cto
rsi
nth
ebo
ok.
Thev alueso fac ompletes e
to ft h
esev a
r i
a blesc harac
tcriz
eas pe
cificd e
sign.Th巴
numberandt ypeofcntit
iesb c
longingtot hi
ss eta revcryimportantinidentifyi
nga nd
se
ttingup出equ 姐 ti
tati
ved esi
gnp roblem.Iti se ssen
tial出鉱山i sc hoi
c ecaptu関 白e DeslgnParameters: I n出isbook,山e seidentifyconst
a n岱 伽1w il
ln otchange凶
essenceo f山 o bje
ctb eingd es
i伊e d叩 da t出esamct imep rovideaq u
antita
tive di
釘e r
entd e
signsa r
ec ompared. Many 1extsu se出巴 t e rmd es
ignp aramete
rs1 0
問prescn
t白巴 dcsignvari
able
swed efinedear
lieranddon otf orm
allyrecogniz
edesign
char
a c
teriza
tiono fthedesignp robl
em.I nap plic dmathematicalterminology.design
para
metersasdef
incdh 問 .T
c heprinc
ipnlreasonistha
tp a
ram et
ershavenor ol
e10play
vari
a b
less e
rvea stheunknownso fthep robl emb eingsolvcd.B orrowingana na
10gy
fromt heareaofs ystemdynami 回 andc ontrolt heory,出e yaree quva
i 1enttod e
fining 泊d eten
凶n ing由巳 optima
1desig.Th
n eyares i
gnifican
tint hedisc
ussio
no fmodeling
thestat
eo fthesystcm,in由i scase,th
cs ta
tco fd esign.Typica
lly,designv ar
iable
sC an is
sue
s.Exampleso fparamet
e r
si ncl
udematcria1pr op
c民y ,appli
edloads.andc h
oicc
bea sso
ciatcdwi t
hd escr
ibing出巴 o bje
ct'ssi zes ucha sit
sl e
ngtha ndheight
.I nother ofshap.Th
e ep ar
a m
ctcrsint h
ea bst
ractmathem a
ticalmodela rerep隠 se
ntcdina
cぉ es,theymayr e
presen1thenumbero fitem s.Th ec hoic
eo fd e
signvariablesisthe si
milarformasthed e
signvec1o,
re x
cep1伽 tweu sethecharact
crp.Th ere
fore
.[ ],
P
resp
o n
sibi
lityo f由ed esignerguidcdbyi ntuition, expe凶se,an dknowledge.百 le民 is P,[P"P2'・.
.. P
q1r e
p隠 se
nt曲ep arameter
so fthep rob
lem.N ote白 紙 白el en
g白 ofthe
afundament a
1r equirementtobemctby山i ss eto fdesignvariab
les,namely,山e ymust par
副n e飽rvecto
risq.Excepti n山cd iscus
siono fm odeli
n g,白epar沼n e
terswillnot
beiInearl
yi ndependentTh
. ismeans出a 1youc an notcsta
blishth巴valueo fonco f出e beexp
lici
tly児島r redto,asthe
yarep ri
maril
yp redet巴rmincdc o
nstan
tsin白巴 d e
sign
.
designvariable
sf rom山ev aluesof出er emai ningv ariab
lest hrou
ghb asicarith
metic
(sca
l i
ngora dditi
on)operation
s.F ore xampl e,inad esi
gnh avingar cctang
ularcross Des句'nF unctlons: D esignf u
nctio
nsd ef
inem ea
ningfuli nf
orma
tiona b
outt he
sect
i o
n,youc annothave由民ev a
riable
sr eprω enti n
g白e lcng,w
出 idth,anda r
ea.Ifthe de
sig
n. Th eya ree va
luatedu s
ingt hed e
signv ar
iable
sa nddesig
np arameters
fi
rsttwoa r巴p rescr
ibed,出et h
irdisa utomatica1lye sta
blish
ed.I ncomplexd esign
s, di
scus
sedearl
ier
.Theye stab
lishthemathe
maticalmodelofthedesi
gnproblem
.T hese
theserelati
onshipsmayn otbev eryapp a
r en.tN everthel
ess,thec h
oi田 o ft h
es etof fu
nct
ionsc a
nr epre
s e
ntd e
signobjec
tive
(s)andlorcon
str
ail
lts.Asiωnamei mpli
es,
designv a
r i
ablesmustmeet由巳 c rite
riono fl inea
ri n
dependencef ora pplyi
ngt he de
sign0肖e cti
ved rive
st hesearchfortheo pt
imaldesig
n.Thes a
tis
fact
ionoft he
technique
so fo p
timizat
ion. Fromap ract
i cnlp crspcc1i
vc,t hcpropertyo fiInear 印 刷tr
ai
llt
se st
ablis
h e
st h
evalidi
tyofthedesign
.Ifnotexpl
icit
1ystat
ed,出ed e
signer
independenceid e
ntif
iesaminimums e
to fv ariablest h
atcunc omplctelyd e
scribethe i
sresp
onsiblcforid巴nti
fyin
gthco bj
ectiv
ca ndcon
str
aint
s.Mi nim
izethemasso fthe
6 INTRODUCTION 1
.1 OPTIMIZATIONFUNDAMENTALS 7

s
tru
ctu
rewi
lltr
ans
lat
eto叩 objec
tivρU1ction.The由 民sinthematerialmustbeless
e ConstraintFunctlons: As d e
signf unc
tions,thes
ew illb ei nf
luenc
ed bythe
t
hanth
eyie
Idstre
nghwi
t 1
ltra
nsl
atetoacon st
rain
tfun
cti
on.Inmanyp roblem,
s i
tis de
signvaria
bles
.Th eforma
tofthesefunct
ionsrequi
resthemtob ecomparedtosome
p
oss
iblef
orth
csamef u
ncti
ontoswitchr
ol estopro
videdi
ffc
rcn
td esignscen
ario
s. num
ericall
yl im
itin
gv al
ue山atisestabl
ishedbyd e
signr e
quirem
e n,
torthedes
igne
r.
Thi
sv al
ueremainsconst
antduri
ngt h
coptimiz
ationoftheproblc
m .Awcl1-des
crib
cd
ObJectlveFunction 向井 Thet ra
ditionald esigno ptimizationpr o
b lemi sd c
fin巴d dc
signp roblemi se x
pectedtoi nc
1ude scvera
ls uchf unct
ions.w hichcanb e
usingas i
ngleo bjectiv
ef uncti
on.百 lef o r
m atoft hisstatemcntisusuallytom inimizc rep
resent
eda sav c
ctor
.Thec omparisonisus u1ys
l
a etupu si
ngt hethre
cs t
anda
rd
ormaximizesomeq uantity白紙 i sc alculate
du singsomcd csignf uncti
on.T his 叫 甜o na
lo pe
rator
s:,=S,andミ .C onside
ro urfi
rstexample
.Le tfimJ(X)repr
ese
nt
functio
nm ustd epend,e xpl
icitlyo ri m
p l
icit
ly,on t hed esignv ariable
s.I nt he 出ef u
nction白紙 c al
cula
testhevolumeo fthenews o
d acanwea red e
sign
ing.百 l
e
lite
rat
urc,出isp rob l
cmi scxp 問ssede xc
1u si
vel y,w i
t h
outl osso fg enera
Iity,asa co
nstr凶ntont h
ed巴signcanbce x
presscdas
minimump roble m.A maximump rob lemc anb 巴r c
castasam inimizationp roblcm
usingthencgativco r出巴 r ecip
rocalo fthcf unctionu sedfortheo bj
ectivcf un
ction.ln ルIIJ(X)=500cmJ
thefir
stexamplei n加 d ucedearlie
r,出co 句e ctivei stom inimizecost
.百l eref
o r
e,恥
desi伊 functionr epre
s印 刷gc ostwilIbet heobj ectiv
ef unct
ion.In由 es econd伺 s ,
e I
ntl
Ies
eco
nde
xam
ple
.le
tβm2(X)b
巴th
efu
nct
iont
hatc
alc
ula
test
hed
efl
ect
iono
fth
e
白 eo b
jectiv
ei st om inimi zema s
s.I nt h
et hirdc ase,theobjectivei stomaximizc beamu
nde
rth
eap
pli
edl
oa.Thec
d ons
tra
intc
anb
est
atc
das
machineu t
ilizat
ion.百l ear国 o fsingleo bject
ived e
si伊 i sconsideredm aturet od
ay.
Nonews olu
tiont echniquesf o
rc l
assicalp roblcm sh av巴becna dvancedf orsomct ime f
t1
1l2
(X ;Imm
):
S
now.T oday.mucho ft heworki na pp l
i edopt imi回 tio
ni sd irc
cteda te xpanding
applic
atio
nst opractica
lp roblems.lnmanyc ase
s.t hishasi nvolve
dc r
cativeu s
eo fthe Thccons回 intfuncti
onscanbec1assif
iedaseq
lla
lit
yconst
rain
ts[ lik
e f
unl(X
)a bo
veJ
solut
iont ec
hnique s
.I n由巳 a bstr
actm at h
e maticalm ode
l .theo bjec
tivef unctionis orineq
ualit
yc ons町出 n
ts[likef
un2(X)]
.
reprose
ntedbyt hesymbolfToi n
dicateitsd epe ndenceont hed esignv a
riabl
e s
.itis Problemsw i
th o
utconst
rain
tsaret c
rmcduncon
strai
nedproblems.Ifcon
str
aint
sa r
e
f陀 q
uentlyc xpressedぉ f(x"x 2.... •x .A m
n) orec onc
i s
c陀 p rcse
nta t
i o
ni sj{X). pre
sent,thenm eeti
ng them is more p創司mount 山 a no p
timizal
ion.C on
strai
nt
Singleobjec
tivep roblcmsh aveo nlyonef unctio ndcnotedbyfI tisas ca
Iar( nota sat
isf
actio
nisn ecessarybefo
rct hedcsignesta
bli
shedby白巴 c u
rrcntvalueoft h
e
V民 tor
).Notc山a taltho ughtheobjcctivef unct
iond ependsonP( parametervector)
.it des
i伊 v ar
iablesisconside
redv a
lidanda cc
epta
ble.Ifcon
strain
tsa renots姐sfi,
ed
i
sn otexpl
icit
l yinc1udedi nthef orma.
t the
nt he
reisnos o
luti
on.Af ea
sibledesigni
sonei nwhichallofthec o
nstr
aint
sa r
e
Mu
ltiob
jectivea n dm ulti
discipl
inaryd 巴sig
nsa rci mport
antd evelop mentst od
ay. sa
tis
fied
.Ano ptimalsolut
ionison e出ath a
smett hedesignobjec
tive.Ano ptim
al
Multio
bj∞t i
ved esign,ormultip
leobjectived e
sign.r efersωusingsevcr
aIdi仔e re
ntd es
ign dcsi
gnm ustb efcasi
blc
.Thed e
signs pac
cc n
closc
dbyt hcc on
strai
ntsiscall
edt h
e

llY 2 44円仁 yfJ


funct
ionsto命的巴曲es 田 町hf orop 曲n a
ld ωign.Gene ra
Ily,山e ya reexpec舵dωbe fea
sibl
ed oma
i n.Dcsignspaceisdescrib
edafewp ara
graphsbclow.
conf
lict
ing0同c ctive
s.Th eycouldalsob e∞o pcr
a tingobjecti
ves.百l ecurrentapproach
to出es olu
tiono fthesep roblemsinvolvess tand
ardo p
timizati
onp roced山首 a pplicdtoa
sing
le(田o nstructedo bjec
t i
veo ptim
iza t
i o
np robl cmb asedont h
ed iff
e r
entm ulti
ple EqualltyConstralnts: E qual
ityconstra
intsa remathematica
llyn eata ndeasyto
obje
ctiv
es.Apop 叫a ra pproachistou seas uit
ablyw e
ig h
包d lin伺 rcombina t
iono f出巴 handlc.Numerically,出e yJ叫u
1 ir
emoree ffor
ttos at
isf
y.Theya realsomorer es
tric
tiv
e
multi
plcobj
ectives.Ap ractica
llimit
ationw i白 血isa p pr
oachis也. ech
oi回 o fweightsus吋
ontlIedesignωtheyl imittheregionfromwhicht h
es o
lutioncanbeo btained.The
inthemode lT
. hisa pproachh a
sn otbe enc mbrace dw id
ely.Ana lte
mativea pproachof symbolr e pr
e s
entingequalityconstra
intsint heabstrac
tmodeli sh .The remayb e
recogn
izingap rcn抑 制e ct
ive,ands olvingas inglco b
jectiv
cp roblemw ithadditio
nal moret ha
nonee quali
tyc onstr
aintint hedesignp roblcm.A v ec
torr epre
sentatio
n
cons
trai
ntsbasedon血 児 問ningo 同制ve釦n ctionsc a
nu sua
llyg ene峨 岨a ccep帥 le for叫 u a
lityconstr
aintsisint r
oducedt h
rought hefollowin
gr epr
esenta
tion.[ ],
8 hl,
[
solu
tio
n.Inm ultiobjec
tivep roblen h2,.... .andhk:k=1
h,
] ,2,....1arewayso fidentify
ing出ee quali
tyc o
nstrain
ts.百le
depe nden
c eont h
ed es
ig nvaria
blesXi somittedforconvcnien
ce.Notc出a tthelengt
h
ofth evectoris1
.Ani mportant陀 箇onf ordistinguish
ingthee q
ualityandi neq
ualit
y
constra
intsis山a tt heya rcm nnipul
at eddiffe
rentlyint hes e
nrchf ortheo ptim
al
solutio
n.Thenumberno fdesignvariable
sin出cp roblcmm ustbeg re
atcr出 叩 t h
e
numbero fequal
ityconstra
ints1 f
oro p
t i
mizationtot a
kep l
ace
.l fnisc qu
alt o.
1t he
n
恥 p roblemw i
llbes olvedwithoutreferen
cet otheobjec
tive.lnm a
t he
maticalt er
ms
thenumbero fequa
tionsm atches白enumbero fu nknowns.Ifnislessthan1,thenyou
havea nov erdet
ermineds c
lo frel
atio
nswhichc o
u ldre
sultinani n
consis
tentp rob
lcm
defi
n i
tion
.Thes c
to fcqual
ityc o
nstra
intsm ustbel in
earl
yi ndcpenden.
tBr o
a dy,
l thi
s
8 INTAODUCTION 4
自 1
.
1 OPTIMIZATIONFUNDAMENTALS 9
F

i
mpli
es白紙 y oucannotobta
ino neofthecon
s町ain
tsf romelemen
taryarithm
eti
c DesignSpace:ηled e
signs pace,出es p
ace白a twi ¥
lb es e
a rc
hedf oroptim
al
o
pera
tion
so nth
er cm
ainin
gcons
trai
nt.Thi
s sser
ves10ensur
ethatthemat
h e
matica
l desi
gn,ist heE u
clide
ano rC artesia
nn -dimens
ionals pacegeneratedb yt h
en
s
earchfo
rsolu
tio
nw i
llnotfa.T
il h
esetcchn
iqu
esarebasedonm eth
odsf romI
inca
r indep
endentd esignvari
ablsX
e .T hisisag e
nera1i
zatio
no fthet hr
ee-dime
nsion
al
a
lgeb
ra.Inth
estan
dardfor
matforopt
imi
zati
onprobl
ems,th
e叫 u a
1it
ycons町ain
tsar
e phys
icals pacew ithw hich we a refamiliar
.F ort e
nd 巴sig
nv a
riab
les,itisa
w
ritt
enwitha0ont h
eright
-han
ds i
de
.Thismeans白 紙 山eequa
litycon
str
aintinth
c ten-
dimensio
nals pac
e.Thisisnote asytoi magin
e.Ilisa1sonotcasytoex pr
essthi
s
f
ir
stexampl
ewil
lb eexp陀sse
das info
rmation 白r oughaf ig
ureo rg raphb ecauseo ft h
eI imita
tiono ft h
e
thre
e-dimens
ionalw o
rld.However ,if也ed 巴:
sig
nv a
riable
sareindependent,出enthe
h
l(X
):f
unl
(X)-500 0 = l
1-dim
ensionalconsid
erat
ionsarem ereextra
p o
latio
nso fth
e由民e -dimensiona
1real
it
y.
Ofcourse,wec annotgeomet
rica1lydefi
n巴t hemthoughwew il
lb eworkingw it
hthc
I
npr
act
ica
1pr
obl
ems,
equ
ali
tyc
ons
tra
int
sar
era
r官I
yen
cou
ntc
red
. numbe
rs.Thes ideconst
rai
ntsIm
ii tthesearch陀 gio
n,im p
lyingth
atonlysoluti
ons山at
l
iew ith
in ac 巴rt
ainregionw i
llb ea cce
p ta
ble.T heyd efi
nea nn-dimensio
nal
rec
tangu
larregion( h
yperc
ube)f romw hich白ef easi
bleando p
timalsolu
tionsmustbe
Ineq ualltyC onstraints:I n叫u a1it
yco n
s 釘ai
ntsapp回 rmorenatur
all
yinp ro
b l
cm
chos
en.Lat e
r,wewi ¥ls白 血att hem at
hemat ica
1m odelsinoptim
izationareusual
ly
formulati
on .Inequali
tyconst
raintsa l
sop r
ovidemoref l
exi
bili
tyindcsig
ns e
lec
tion
.
des
cribe
db yn onli
nearrelationshi
ps.τ1
1 es ol
utio
nst os uc
hp roblemsc anno
tb e
Thes ymbolr epres
cnti
nginequal
ityc ons釘'a
int
sintheabst
ractmodelis8
.T her
emay
ana
1yti
callypredict
ed鎚 t heyaret ypi
ca1lygovemedb y由eu nderlyi
ngn umeri
cal
be more 出 叩 o nci n珂u a
1it
yc ons
train
ti nt h
ed esignp rob
lem. The vector
t
ec加i queusedt osolv
et h
em.Itisn ecc
ssaryt o(田町ictthesolu
tionstoana cc
eptab
le
repr巴sent
at i
onf o
ri n
equa
lityconstr
aintsi
ss imil
artowhatweh av巴seenbef
ore
.Thu s, reg
ion
.Thes id
ec ons
tra
intsprovides readym echanismf o
ri m
plementingthi
sl i
mit
.
[G),[ 8
1, 82,..・.81,a
/
] ndめ :j=1 ,2,..., ma r
cw aysofi d
enti
fyin
gIheineq
ualit
y Caremustb eta ke
nt h
atthcselimitsarenoti mposedo ver
zeal
ously.Thcrem ustbe
cons 甘ai
nts
.m r eprωen
ts出enumbero fi nequa
1it
yconst
raint
s.AIldesig
nf un
ction
s rea
sonab
l espacefor出巴 numer
ica ltechni
q u
e s10oper
ate.
expl
i ci
tlyo rimpli
cit
lyd ep
en dont hedesig
n( orinde
pende
nt)v a
riab
leX.8isusedto
descrihob o出 l o
ssthunorc qual10恒)朗dg rea
lcr白 山 0"e
1 qul
ll10(と)con
stra
lnts
.
TheStandardFormat:Theab
oved
efi
nit
iosa
n 1l
owu
stoa
sse
mbl
eIh
ege
ner
al
Stri
ctlygre at
er出叩(>)a ndstri
ctl
yI cs
st h聞(<)a renotusedmuchi noptim
izatio
n
a
bs回 .
c
tmat
hern
ati
calmode
las
beca use出巴 s olut
ionsare凶 u a
11ye xp
ectedt oli
eat出ec o
nstra
intbound
ary.Int h
e
standardf ormat,al
lp robl
emsa rce xpr
essedw i自 由eSr e
lati
ons
hip.Moreover,th
e

1
l
,,‘、
、‘.,
right-hands i
deo f出eSs igni s
O.百 lei n
equali
tyconst
rain
tf romtheseco
ndexam p
le M
ini
miz
e f
(x.,
x2,..
.,xn) •
ftm2(X)iss etu pas
S
ubj
ectt
o
: hl(x"X
2・・

・ ,XII)=O
h2
(x.,
x2,
.. xn)=0
., (
1.2
)
8
1(X
):ルn2(X)-1三O
h
/(X
I'X
2・・
..,
XI
I)=0
I
n由巳 c aseo fineq
uali
tyc o
ns tr
aint
sad ist
inc
tionismadca stow hetherthedcsign
var
iabl
esli
eont h
econst
raintb oun
daryorin出巴 int
eriorofth
er egi
onboundedby白E
8
.(X
"X・
2・.
.,Xn)壬O
con
stra
i .I
nt ft hesetofd 巴signv ar
iabl
esl i
eo nt heb ou
ndaryo f白ec on
s t
rai
nt,
math
ematic
a lly,t
hi
se x
presses出ef actth
atcons
trainti
ss a
tis
fiedwithst
ric
tequali
ty, 8
2(X
I'X
2,・ ,Xn)S0 (
1.3
)
白紙 is,g =O .Thec o
nstrainta c
tsl i
kea nequalit
yc ons
traint
.I noptimiz
atio
n g
m(I・
X X
2・・
..,Xn)SO
term
inology,血ispart
icula
rc ons住ain
tisrefer
redtoasa nacti
vec o
nstr
aint
.Iftheset
ofdesi
gnva r
iable
sdon otli
eont h
eb ou
ndary,th
atis,the
yli巴insid
e出er egionofthc
con
str
aint
s,t heyarcconsid
e 陀 dinac
tiv
ec o
nstr
aint
s.M athema
ti ca
1ly,
出ec onstr
aint lSXjSxi,i 1
x ,=
2,
..
.,n (
1.4
)
s
atis
fis出er
e cla
ting<O
o .Ani ne
qual
itycon
sU'a
intc anther
cforebeeith
eractiv
eo r
l
llaJv
ct e. Thesamep
rob
lemc
anb
eex
pre
sse
dco
nci
sel
yus
ingt
hef
oll
owi
ngn
ota
tio
n:

SldeConstral
nts:Sidecon
s釘ai
ntsareanecessarypar
tofthes
olu
tio
nt e
chni
qus,
e M
ini
miz
e f
(x.,
X2,
...
,X)
n (
1.5)
es
戸cia1l
yn u
meric
alonc
s.Theyexpresst h
er angef o
rt h
edesi
gnvar
iabl
cs.Each
de
signvar
iab
lemustb
eb ou
ndb yn
umcricalva1uesforit
slowe
randupperI
imit
.The S
ubj
ectt
o
: h
k(t,
x X
2・・ ,Xn)=

・ 0,k=1
,2,.
. I
., (
1.
6)
de
sig
n e
rmakesthi
sch
oicebase
donh i
sa n
tici
p a
tionofanacce
pta
blede
sign
. め(
X 2,
"X • ..
,XI)S0,j=,
12,
...
.m (
1.7)
画幽画面孟副
d

10 I
NTR
OOU
CT0N
1 1
.
1OP
TIM
IZA
TIO
NFU
NOA
MEN
TAl
S 1
1

xlsxjSxれ i=1
,2,
.. n
., (
1.8
) d
E
xpl
oit
ingv
ect
orn
ota
tio
nth
ema
the
mat
ica
lmodeli
s

M
ini
miz (X),
e j [
X]. (
1.9
)

S
ubj
ectt
o: [
h(X
)1=0
] (
1.10
)

匂(X)
]nS0
t (
1.1
1) h
X10wSXSX
up (
1.12
)

Theabovemat
hem
atica
l model e
xpre
sses恥 f o
llo
win
gst
and
ardf
orm
ato
fth
e
op
tim
iz岨 onp
robleme
xpre
ssedinnat
ural
lan
gua
ge:
F
lgu
re1
.1 E
xam
ple1
.1-De
sig
n01anewb
eve
rag
eca
n.
Minimizetheob
jec
tiv
efu
nctio
n,
js u
bje
c o1
tt eqa
u¥i
tycon
str
ain
ts,
min
cqu
ali
ty
con
stra
ints,wi
th山end esi
gnv a
ria
ble
sIyin
gbetwee
np rω
cribe
dl
,o
werand
upperlim
its
. ,~
ma
tcri
alo fthec an
?Whata rclheassumpt
ionsf o
rthcdcsignproblcm?Oneo fth
e
p

ass
umplionscouldbel hatti ssmal
lcnought ob eigno
redint h
cc a
lculat
iono fth
c
J
:
<:

百letechni
qucsin出isbookw i
llapplytothcp roblemdescri
bcdin出cabovcf o
r m
at
. volumeo
fs odain出ec an
.A no t
herassumpt
ionistha
t由em a
teri
al陀 qui
redforlhecani
s
Tosolveanyspec
ificdesi
gnproblemitisrequirc
d10r efun
nulatcth
ep roblcmi
nt he on
lythecy
lindr
icalsur
fac巴 宙 開τ
.'hetopandbotlo
mo ft
hccanwi
llbefit
tedwithcndcap
s
abovemanners o白紙自己 m ethodscanb ea ppl
iedd i
rec
tly.Alsoi nthi
sbook ,the 白atw泊p rovide出emechanismbyw hichthesodacanbcpow 叫.官邸 i snotpartof白i
s
tec
hniqu
esa redevelopedprogr
essiv
elybyc onsider
ingt hestand
ardmodelwi 出 dc
signpro
b l
em.I nth
e白百ta ttem
ptatdcvel
opin
gt hema
thema
ticalmodelwec o
uldst
ar
t
向ducedelemen
ts.Forexample,t
h巴u n
constr
ainedp roblemwi¥
lbee xpl
o問 dfi
rst
.The ou
tbyc o
nsiderin
g由equ 叩 titie
siden
tif
ied曲 ov
ea sde取1v
s ar
iabl
es:
eq
uali
tyc on
s回 int
sa 陀 co
nsider
edn e
xt,followedbyt heinequ
alit
yc o
nstr
ain
ts.叩 d
fi
nal
lythecompletemodelT
. hisr e
pres
entsan at
uralprogre
ssionasprio
rknowledge D
esi
gnv
ari
abl
es:d,
h,t
i
su sedtodevelo
pa ddi
tio
nalcondi
tions白紙 n eedt obes a
tisf
iedbyt h
es o
luti
onin
白隠ei nst
ance
s. R
eviewingthestaleme
ntofthedesi
gnp r
o bl
e m,oneo fthepar
ametersisthecostof
m
ater
ialperuni
ta r
ea白紙 isgive
nasl tp
( ersqU8I官 c
entimete
r.τb
isisidenl
ifidぉ C
e .
Du
ringthesearchfortheop
timalsol
utio
n出i sq uant
itywillbeh c
ldc o
nstantat出e
1
.1.
2 MathematlcalModellng g
ivenv a
lue. Note th
atift h
isv al
ucc hanges,l hen 出ec osto fthcc anw i
ll
c
orres
pondin
glyc han
ge.Th i
siswhatwemeanbyad esignp釘 am
eter.Typicaly,
l
I
nthi
ssec
tio
n,出ethr
eedes
ignpro
ble
msi d
附'O u
cede
arl
ierwillbe佐a
nsl
ate
dto出e
c
hangeinparamete
rswi¥lca
usethesol
utionto民 間c omp
uted.
s
tan
dardf
orm .Them
at ath
emati
calmode
1wi
llf
irs
tbei
den
tifi
ed.These
condpro
ble
m
re
qui
resin
for
mat
ionfro
mac o
ursei
nmechan
icsa
ndm
ate
ria
ls.T
hiss
hou
ldb
ewi
thi
n
D
esi
gnp
ara
met
er:C
血.
epurvi
ewofmoste
ngine
erin
gstu
den
ts.
Thedes
ignfunct
ionswillincl
ude白ec omp
utationoft
hevolumeenclo
sedbythecan
Example1
.1 Newconsumerr
ese
arc
hin
dic
ate
s山a
tpe
opl
eli
ket
odr
inka
bou
t0.
5 andt
hes u
rfa
cea r
eao fthecyl
indr
icals
ectio
n.Thevolumeinthecaniπc
s f2h
14
.ηle
li
te
ro fsodapopa tat imeduringthesummerm ont
hs.Thef a
bri
c a
tio
nc os
to fthe su
rfa
ceareai
s1td.Th
h ea e
sthc
ticcon
str
aintreq
uire
s出ath~ 2d.Thesideco
ns甘ain
ts
rede
signe
ds odacanispropo
rtion
al10t h
esurfa
ceareaandcanbee stim
aledal$1.00 on山 d ia
meterarepres
crib吋 in出ep r
oblem.Forcompl
el巴ne
ssthesidec
onst
rain
ts
persqua
rem et
e roflhemat巴ri
alused.Ac i
rcul
arcros
ss e
ctionisthemostplausi
ble on恥 o t
hervari
ableshavetob epre
scr
ibedbyt h
edes
igne
r.Wec anforma
llysetup
give
ncurren
tloolingava
ilab
leformanuf
aclu
re.F o
raest
heti
cr ea
sons,t
l
1eheightmust th
eopti
mizat
ionpr o
b le
m硲
beatl e
asttwicetl1ediame
ter.S tu
diesindi
cate血ath old
ingc omfortrequir
esa
diam
eterbetween6a nd9cm.
Figur
c1 .1showsas ket
cho ftl
1ecan.Inm ostprod
uctd es
igns,par
ticu
larlyin ,
ht
Minimize f(d : C7
) rd
1z (
1.13
)
engi
n巴eri
ng,themodeli seasi
ertod ev
elopusingafigu
re.Th ediametrda
e ndthe
hei
ghtha resuffi
cien
ttod cs
cribetl
1esodacan.Whata boutthet
l1ick
nessto f出e S
ubj
ecl
lO ,
: hMh,
t
): 7
rd2
/14-500=0
/ (
1.14
)
掴 一
一ーー
ーー

ぜ3
12 INTRODUCTION 1
.
1 OPTIMIZATIONFUNDAMENTALS 13

一戸/

ー吋
g
M.h
.t: 2d-hSO
)

I
¥¥¥¥¥¥開制
4
可制

V
6Sds9; 5s/
ts20; O.OOIStsO.Ol (
1.15
) L

-1
In
tuit
ively,t he
rci ssomeconcemw itht hep roble
ma se xpres
sedby E q ua
tions

-
(1
.13ト(1.15 )e venthough山巴 descr
iptionisvali
d.Howc ant h
ev a
lueoft hedesign

-
var
iabletbee s
tab1
ished?Thevariati
onintd oesn o
ta 仔'e
ctthedes
ign.Changingt he
valu
eo ftd o
e snotchange,
fhl ,
orgl・Hence ,i
tcannotbead esig
nv a
riabl
e.(Note:the ,

var
iati
oni ntmaya ff
ecttheval
ueo fc.)lf山isw ercap r
acti
caldesignproblcm,then
出巴 cansh avet ob edesignedfo
ri mpacta nds t
ackin
gs tre
ngth
.I n白紙 C凶 e,tw ill
prob
ablybeac r
iti
caldesignva
riabl
e.T hiswillrequ
ires ev
er心a d
ditiona
ls 凶 clu
ral
co
nstra
intsi nthep ro
blem.Itcouldserveasa ninte
resti
nge x
tensi
ont othi
sp roblem

d
fo
rhomeworko rp ro
ject明l eop
timizationproblemafterdroppigt佃 de
n xpr
essing
[d
.h]ぉ [ XI・X2]becomes:
lg
F u
re1
.2 E
xam
ple1
.2 a
-Cnl
lle
verb
eam
.

M
ini
miz
e f
(XI,
X2
):c:町内 (
1.16
)
lntui
tive
ly,出el ar
gertheva
lueo fF.thegrea
t e
ris山巴 cα
ro
田s
鴎8
-S
総ec
叫l
li
on
叩 a
叫l
陥 are

官潤
=a
泊necωs紅 v
S
ubj
ecl
lo: h
l(l・
x Xv:ru弘/4-500=0 (
1.17
) ω
t0h
. a
肌nd
仙lei.1
t1棚ca
叩 恥e蹴捌均
nb i砂
lyconc
lu ded山伽a
飢ti
げfFw 悶 a d
伽ω
巴叩
si
b巴 selatit
sl owerlimt,a
i 8lhemasso fthebeamw i
llb edirec
llyproporti o
nal1 0由e
g
l( ・
ズlXU:2x1-X2S0 (
1.18
) areao fcro
S88cc(
Iun.Not ech
niquesarer叫u
, iredfo
.rlh
isconclus
io..Byo
n .urd e
finition,
Fi sago o
.dc andid
ateasap ar創neterrather白 肌 asad esignv a
ria
ble.S im i
larly, th
e
largerthevalu
eo f,
L 白eg 問ateri
st hemoment白紙 Fg enerat
esa bo
utt hec anti
levered
6SX)S9
; 5SX2S20
end.百l iswil
lr equi
rea nincr
easei n山ea reao.fcros
s-sec
tion.The r
e f
ore, Lisn o ta
goodc h
oicefo
.r山ed esi
gnv a
riab
l eeithe
ra stheb e
stc hoic
ef o
.ri
tw illb ci 臼lo
. wer
Theproblem問 p
rese
nldbyE
e qua
tio
.n
s( 1
.16)一
(1. )i
18 s恥 m a
thema
ticalmode¥fo
.r i
Imit.Tor epr
escntmater
ialasadesignv a
riabl
e.wen ecdtou seit
sSlru
C l
uralp ro
pcrties
th
巴d e
signpro
b l
emexpr
ess
edintheslan
dardformat
.Fort
hi
sp ro
blemnoext
ranco
.u
s in出ef orm
ulalionoftheprob
lem.T ypi
cally.am a
leria
lisc ha
r a
cleri
zedbyi t
ss pec凶c
inf
orma
lio
.nwasn 田氏dtosetup出ep roble
me xc
eptfo
rsomegeome
tric
alrel
ati
ons
.

Ex
ample1
.2 A c
ant
ile
verbeamn
eed
s10b
ede
sig
nedt
oc紅r
yap
oin
tlo
adFa
lth
e
endo
.ft ebeamo
h .flenglhL.Th ecros
ss e
ctionofthebeamwi I
Ib einthes hapeo fthe b
t
le
tte
r1( ぉferredtoa s阻 1 ・b回 m).百 lebeams houldmeetp rescrib
edf ail
urecriter
ia. I~ 'l
Thcreisalsoai Imitoni tsdeflec
tio
.n.A beamo fminimummassi s閃 quired1 0b e
dωigncd.
Figure1.2showsas idev i
e wo
.fthebeamc arry
ingt h
el oadandF igure1 3at
. y p
ical


cro
.s
ss目 白n ofth巴b e釘n.Th eI -s
hapedcros
ss ec
tionissymmetr ic.Th esymbol sd,tw.
br,
andrtco
.rrespondtothedep 出.ofthebcam, th
icknessoftheweb ,w
idt hofth巴fl an
ge,
andthickne
sso.fthef la
nge, r
espect
ively
.Thes 巴quantit
iesares uffi
cienttodefin e出E 4 t
-W
cro
.s
ss ect
ion. A handbo o
.ko rt e
xtbo
.ok on strcngtho fm a
terialsc ana i d 白e
d巴velopmento
.fth巴d esi
gnf uncti
ons.Ani mport
anta ssump
ti onforthisp rob
le mis白紙
wew ilbewo
l .r
k in
gw ithint heela
stici
Imito fthcm ate
rial, wheret hereisai Inear
re
lat
io
.nshipb et
w een血es tressandt h
estrai
n.AlIo
. fthevariablesidentif
iedinF igure 生
1.
3w il
ls 回 nglya ff
ectthes olu
tio
.n.Th eyaredesignv a
riable
s .Thea pp
liedf o
.rceF
w
S
i
l
t
la
e
c
l
li
sod
sd
i
c
r
f
i
e
n
c
i
t
t
l
ya
el
f
ys
f
e
u
c
p
tt
cr
h
i
ep
o
.r1
r
.
ob
0c
l
o
.
e
p
m
p
.Sow
erfo
i
rt
l
li
h
t
sl
ebe
o
a
c
m
ati
.S
o
.
h
nL
ou
.Ho
l
. wa
dF,L,a
bou
n
t由巳 m
dthem
at
a
e
t
r
e
i
r
a
i
l
a
?
l

pro
.p
erti
esb einc l
udedasd esignvariabl
es? F
lgu
ro1
.3E
xam
ple1
.2-Cr
oss
-se
ctl
ona
lsh
ape
.
町長良民ルおhFdf
15

託彰も m
14 INTRODUCTION 1
.1 OPTIMIZA
TIONFUNDAMENTALS

伊佐山↑ JdJiJdh

,t y .E.i Thisisanexamplew i
thf ourdesig
nv a
riab
les,t
hre
ei n
equa
litycons
tra
int
s.a n
d



weigh itsvalueofthemoduluso felast
ici
ty tsmoduluso fri
gid
ity.G.it
sy ie
ld

hおbMUFF 一正訴訟記訟や払
lim
iti ntens i
ona ndcompr凶 sion
.σyie
'd.i ω
yieldins h閲兵 τyi
el
d.itsulti
matestreng白 noequal
itycons
train
ts.Oth crvcrs
ionsofthi
sproblemcane a
silybeformu
lated
.
inten
s ion
.σult.andit
sultimat
es tr
engthinshea
r.τu
ll・Optimi却 l
iontechnique
sidenti
fy I
tcanbereducedt oatwo-variab
lcp ro
blcm.Stan
dardfai
lur
ec r
iter
iawithres
pect
dif
fe陀 ntva 1uesoft h
ed esignvariab
les.IfE ist hev a
riabl
eu sedto閃 p re
sent出E tocombinedstre
sscsorp r
i n
cipa
1s tr
csse
scanbcf orm
ulate
d.Ift hecan
tile
vere
d
mate
ri aldes i
g nvar
iabl
ei nap roblem.t he
nitisp oss
iblethes ol
utio
nc an問 quirea endisb ol
te,t
d h
ena dd
itiona
1d esig
nf un
ctio
nsregar
dingboltfail
ureneedtob e
mate
ria 1白a tdoesnotexist
,白a ti.ava
s 1ueofEs t
il
lu ndis
c o
ver芭d.Fora11int
entsand exa
r凶ned.
p凶pos es.也i sisbeyondt hes copeoft hedesig
ner.A g
ain.m at
e ia
r 1asap arameter
makesal otof.sens
e,and血eo ptimiz
ationp roblemshouldber ein
vesti
gatedifF,ム Exam
ple1
.3 MyPCCompanyh
asd
eci
dedt
oin
ves
t$12m
ill
ioni
nac
qui
rin
gse
ver
a1
orthem ate
ri a
lc han
ges.C o
nclu d
in gfrom出i sdiscuss
iononm odeling
.t hefollow
ing ncwComponentP 1aceme
ntM achine
stom anufacturedi仔eren
tkin dsofmo 出eぬoards
i
Istcanbee stabl
ishe
df o
rt h
isexample: fo
ranewg en
erationofpers
onalcompu
ters.Thre emodelso ft
hesem ac
h insa
e reunder
con
sider
ation.Tota1numberofo per
atorsavail
ableis1 00b e
causcof出el oca
ll a
bor
.A f
market lo
ors pac
ec ons
train
tn eedst ob es ati
sfi
edb ecauseo f血ed if
fer
ent
D
esi
g 釘 祖1
np e
隠te
胞 r
肱s ム
ぶ F..{
L y
.
芯 ιG
.叫σY
'e
ld
'
τ1
悶y
:ie
l
d'円

σu
陪州'九
1
1 τ
E
1
:凶
dimensi
onso f恥 s em ac
hines.A ddi
t ina
o 1i nformati
onr ela
tingt oe acho f白e
D
esi
gnv
ari
abl
es: d,
tw'糾
b'
r今
If machinesisgiveninTable1.1
.百 ecompanyw i sh
e stodetermi
nehowm叩 yo feach
kindisappro
priatetomaximizcthenumbero fb oa
rd smanufactu悶 dperday.
Inthed ev巴l opmento fthem a
th e
maticalmodel,s t
andardtechni
cald ef
initio
ns紅巳 ltisdi
ffic
u1ttouseaf i
gureinth
ispr oble
mt osctupo urmathematicalmode.
lThe
used
. Mucho ft hei nf
or m
at i
onc anb eobtainedf romam echan
icale n
gineerin
g numbero fma c
hineso fcachmodeln ecdstobed eterm
ined.Thi swillserv
ea sour
handbook.Th 巴f ir
std esignfu n
ct i
onis出巴 w eightoftheb e
a m.Thisisthep rod
ucto f desig
nv a
riabl
es.L e
tXIr e
prese
ntth巴n umberofComponentP l
ac ementMachinesof

i!i
y,L,andAc, whereAci s出ea r e
ao fcrosssect
ion.Themaximums l
res
sduet ob end
i ng ModelA .Similar
ly,X2wi1
lbea sso
ciatcdwithModelB, andX3w ithModelC .
σ""
ndc anbec al cu
lateda st h
ep r od
ucto fFLd I2
1c・whereιist h
cmomenlo fine
rtia
aboutthcc
m凱 imums
c
h
n
e
t
a
roi
rs
do
tr
e s
ft
si
hec r
n出巴 c
os
r
ss
os
e
ss
c
e
t
i
c
o
t
na
io
l
ni
on
se
gt
xpr
h
ea
ess
x
e
i
sp
da
a
sF
r
Q
a
l
c
l
l
e
l
lt
c
ot
w,
1
hef1an
whercQci
ge
.The
sfi
rst
D凶 i
gl
lva
riu
ble
s:x・
X2,
X,
3

momento far eaabou tthecen 位。idparall


cltot h
cflang
e.Themaximumd eflec
tion(~) Thei nf
onnati
oninT a
ble1.1isu s
edtosetupt h
ed e
signfun
cti
onsint er
mso f出e
ofthebeamwi 11bea tt heendo fthebeamc alcula
tedbyt heexpres
sionFL 3
/3El'Ac
c ヲ
ィf
des
ignvaria
bles
.Ana ssump
lionismadeth
atal
lm a
chinesar
erunforthr
eesh出s.The
ofthecrosss e
ct i
ono ft h
ebeami s2brtr+Iw( d-2tf.Thef
) i
rstmomcnto fa reaQcc a
n s
co
sto facq
uisi
tionofthemachi
nesisthesumo f出ec o
stpermac
hi n
em u1
tipl
iedby
bccalcu
lateda s0 .5bft
f(d-t r)+0 .51w (
0.5d -tf
)2
. F
inall
y.出 c momcnt of i
nertiaιi
s 出巴n umberofmachi
n e
s( 'Th巴 m
g1
) ach
inesmustsat
isf
y山ef l
oors
pacccons
trai
nt(82
)
obtai
nedfrom( b凶112)ー ( (br-t w) (
d-2 tf)3
/12.I
) n山 f ollow
ing,forconvcnience, whichisd e
finedwithou
td e
tai
lsinE .(
q 1.23
).Thec o
nst
rai
ntont h
enumbero f
wew il
lc ontinu etou seAe ,Q c'andιinstcado fd e
tai
1ingt h
eirdepende n
ceon曲e opemto
rsist h
reetimcs白巴 sumof曲ep rodu
cto fthenumberofmach
inesof伺 ch
desig
nv a
1ues.A ssoc iati
n ,
gx w ithd,X2w it
ht w'X3withbr,andX4withlr,so白 atX= modelandtheoper
atorspersh
ift(
g3'Theu
) til
iza
tionofeac
hm a
chinei
sthenumber
[,
x・X2・X
3'x 1,
4 白 epr oblemi ns tand
ardf orm
ati s ofboardsperhourt i
mesthenumbero fho
ursthem achin
eo p
era
tesperda
y.Thc
opti
mizat
ionproblemcanbeassembl
edin山巴 fol
l o
wingfor
m:

Minimize .
ft
X:Y
) L
AC (
1.
19)
Ma
瓦im
izef
(X)
:18 x55xxl+18x50x~+2Ix50xx3 (
1.2
1)
S
ubj
ectt
o: g(
X) ,,
x
L
:F /
21c
-σy
ie
'd~ 0
(
1.2
0) o
r
g
2(均
α
x) .
x
:FQJ1
ぬ:
x
巧2-τ
1
:i
y
眼e
e刷

g
3メ
(X
):FL可
3
, ιc 由 3m凪 ~O
'/3El T Minimize f(X):-1
8x55xx ,
-1
8x50Xx2-2
1X50xX
3
0
. ,
01~ x ~ 0
.25
; 0
.001~ X
2~ 0
.05
; ゆc
Su tt
o: g(
X) ,
:400,
OOOx +6
00.
00,
0
X2+700,
000
X 2,
3~ 1 0肌 000 (
1.2
2)
0
.01~ X
3~ 0
.25
; 0
.001~ X
4~ 0
.05
g
2(X
) ,
-
2+X
:3x X 3~ 30 (
1.2
3)

Tosole出i
v sprob
le ,Fmustbcp
m r
esc
ribed(0,
1 000N),Lmustb egivcn(3m
). 8
3(X
):3
xI+6
X2+6
x3~ 1
00 (
1.2
4)
Ma
tcr
ia1mustbcse
lecte
d(s
te1:γ=7860kglm3
e ;Oy
"id=250E+06N/m
e
l 2;τ
yic
ld=1
45
E+06N/m2)
.A1soth t
emaximumdc1e
cti
onispr
cscrib
cd(amn~ =0
.00
5m ). X
I~ 0; X
2~ 0; X
)~ 0
γ
61'甲山岨臨調ø.1.Y:.iK.~甘通
一 阻 止 一-

Eri-522JJyd罫おなおミ
1
6 I
NTR
ODU
CTI
ON 1O
1
. P
TrM
IZA
TIO
NFU
NDA
MEN
TAL
S 17

Equ
ati
ons(
1.21
)ー(
1.2
4)e
xpr
ess恥 m
ath
ema
tic
alm
ode
loft
hep
rob
lem
.No
te伽 t
in
t
hisproblemther
eisn oproductbcin
gd csigne
d.H ereastrate
gyf orplac
ingorde
rfor
恥 n
u mberofmachinesisbeingdct
ermined.Equatio
n(1.21)illus
国 防t hetr
ans
lat
ion
ofthem蹴 i miz
ationobjecti
vei n
toa n叫 u iv
alen
tm inim
i zingo ne.Thei ne
qual
ity
co
nst
rain
tsinE qua
tions(1.22)ー(
1.24)arediffe
rentfromthep revioustwoex剖npl
es.
He隠 th
er igh
t-handsideoftheSo pera
torisn onz
ero.Similar
l y,thesid
econst
rai
nts
ar
eb oundont hel o
wers id
eo nly
.T hisisd onedel
iber
ately.The reisas i
gni
fic
anl
di
ffer
encebetween出isp roblemandthepreviou
st wo
.Alloft hede s
ignfunc
tio
nshere
ar
eline
ar
.T hisproblemisc1ass
ifi
edasal inea
rprograrnm
in gpr o
b le
m.Thes o
luti
ons
1
0t he
set ypc
so fp roblemsa reveryd i
f f
ere
ntt hanthcs oluti
o n10t h
cf i
rs
tt wo
cxam
pl巴s,whicharere cog
nizedasnonlin巴arprogrammingp r
ob l巴ms.

1
.1.
3 Natureo
fSo
lut
ion

百le出向ecxa
rnpI
巴si
n出cprev
iou
ss e
cti
onar
cusedtodi
scu
ss出enat
ureofs
olu
tio
nsω
th
eopt
imi
zat
ionpro
ble
m.Exa
rnp
les1.1and1.
2d c
scri
be血enonl
in田rprogr
amming
pro
blc
m,whi
chform
sthem
ajorp
artof山isb
ook
.Exa r
npl
e1.3i
salin
ca
rprogr
ammin
g 9
p
roblem,whichisverysig
nif
ica
ntindcci
sionscic
nccs,bu
tra路 i
np ro
ductde
sign
.It
s
i
n1u
c si
o nhere,wh
ilen e
cess
aryforcomp
lctcne
ss,isalsoimp
orta
ntforunder
stan
din
g
c
ontem
p or
aryo p
tim
izatio
nt e
chn
iquesfo
rnonlin
earprogrammin
gp r
oblc
ms.Exarn
ple
s
5 6
1
.1and1.2a回 de
al
twithft
rS
t.Bet
w ee
nthelwo,wenoti
cetha
tExar
nple1.
1isqu
itesi
mpl
e
r
ela
ti
vetoExarnpl
e1.2.Secodt
n
, hef
ourva
riab
lesinExample1.
2makeitdif
fi
cul
ttous
e F
lgu
re1
.4 G~叩hl伺I r
epr
ese
nta
tio
n01E
xam
ple1
.
1.
lu
i
1 s
tra
tiontoest
abl
ishsomeofthcdi
scu
ssio
n.

SOLUT10NTOEXAMPLE 1 .1 Thcs impl


cstd eterminationo fnonli
near
ityis bo山o fthes
cf u
nctions
.百 le叫 u al
ityconstr
aintglisl i
nc
ar
.l nE quatio
n( 1
.18)出isis
throughag ra
phical陀 P陀 sentat
iono f出cd c
signf u
nctionsi nvol
vedi nthcproble
m. evi
dentb∞ausethedesi伊 variablesappcarby出emselveswithoutbeingraised10apow c
r
百lisc anbed onc回 si
lyf orO Deo rt wov aria
bles
.I fthef UDCti
ODd oesnotplotasa o山町出回1.Aswed evelop白et e
chniquesforapply
ingoptim
ization,出isd is
tinct
ioni
s
str
aightlin
eorap lan,出e
e nitisn onlincar
.F igu隠 1.4s howsat hree
-dimcns
ionalplo
t impo
rtanttok eepi nm ind.I ti sa ls
os ignif
ican
t白紙 g raphi
calr epresentati
onis
ofEx amplc1.1
.Thef igureiso b
taine dusingM A
T LAB.C hapter2willprovid巴dct
ail
cd ん
量まー typ
icall
yrestr
icte
dt ot w
ov ariables
.F or出r eev a
riab
les,wen eedaf ourthd im
e n
sion
ins
tructio
nsfordrawings uchplotsfo rgraphic
aloptimizatio.Thet
n hre
c-dimc
nsion
al 10resolvethei nformaIo
l na n dt hree-
dimension
alc onlourplotsa ren ote asyto
与一式
配 EZ白羽

問pr凶 e n
tat
ionofExarnple1 .
1i nFigu re1.4doesnotreal
1 ye n
ha n
ceo urunde
rstandi
ng i
IIu
str
ate.Thep owero fimagina ti
onisn ece
ssarytoovercome自己s ehurdles
.
ofthep rob
lemort h
esolution.Figure1 .5isanaltemater e
p 陀scnt
ationoftheprobl
em. 百1 巴probl
emr ep
rcsent
edi nFi gu
re1.5p ro
vidcs叩 oppo
rtun
itytoi d
entifythegrap
hica
l
Thi
si sth巴 on
ee ncouragedi nthisbo ok.Thch orizo
ntal蹴 i srep陀 s
cntsthediamet
er sol
ut
ion.Fir
st,t
hefeasib
lere gionisiden
tif
ied.InFigur
e1 .
5山i si
s出E叫 u alityco
ns回 in
t
(X
I),a nd出巴 v e
rti
cala xi
s由eh eight( xu.1 nFigure1 .5t heequali砂c on
strai
ntis [~
abovetheincq
uali
tyc ons回i ntB
. o
thf eωibl
ea ndo p
limalmusto ccurfro mthi
s陀 :g
ion
.
mark cdappr
opri
atelyash1.Anyp 創r o
fv aluc
so n出i slinewillgiveav olumeof500 5 Anys ol
utio
nf r
o m出isr eg
ioni sa nacceplab
le(仰s i
ble)sol
ution
.T herea r
eu sua
llya
cm3• Theinequa/
ityconst
raintisshowna sg1.Th epairofv alue
so nthisli
neexac1
ty lar
gen umberofs uchsolutionsー infini
lesolutio
ns.Ifopti
m iz
ationisi nvolved,thc
n
sa
tis
f ie
sthcaes山eticrequi陀 ment.H as hline
so nthes i
deo ftheinequali
tycons
trai
nt thes
cc hoic
esm ustb er cduce dtot heb es
to new it
h陀 spcctt osomec rite
riaーt h
e
cs
tablishthedisallow
e d陀 gionf ort hedes i
gnv a
riable
s.百l econstr
aintsaredrawn obj
ecliv
e.1nthisproblemlfigur e,t
hes mall
cstv al
ueo ff
isd es
ired.Thel owes
tv alu
c
thi
ckerf o
remph 凶 is
.Thes caled0匂' ecl
iveルn Cl
i o
ni sr e
,pr
ωen 句dt hr
oughsevcr
al offisj us
tlesst h
ant hec ont ourvalueo f3 08
.ltisa t山ei n
tersect
iono ft het w
o
lab
el cdcont
our.E
s achc ontourisa ssoc
i at
edw itha白x e dv a
lueo ft h
eo bj
ccti
ve con
strai
nts.Whilet hev alueo ffn eedst ob ecalc
ulate
d,t heoptimalv aluesoft h
e
fun
ct io
na ndt h
esev aluesa reshowno nt h
ef igu
re.百l er angeoft het woaxes desig
nv ar
iabl
es, r
eadf romt hef i
gure,areabout6.75and1 3,
5
.r espec
tiv el
y.A nother
es
tablishe
sthesideCOll
Stra
ints.Theo bje
ctivefunctionfandt heequa
lilycons
trai
nth1 sign
ifica
nti t
emo fi n
formatio no btain
edf r
o mFigure1.5i s白紙 g li sa nactiv
e
創'
cn online
arsinc
ct he
yd on otplotII
Ss tra
ightlin
es.RcferringtoEquations(1.
16)and cons
trai tW
n. hi
l et her
ea rei nfin
itef ea
siblesolut
ions10t hcpr oblem, th
eo ptima
l
(1
.17), t
hi
sissubs
tantiate
db yt hepl'OduCI
So fthetwou n knowns( de
signvar
illb
les
)in solu
tionisUlt
ique.
18 INTROOUCTION 1
.
1 OPTIMIZATIONFUNOAMENTALS 1
9

20
8
3(X
):3
xI+6
x2~ 70 (
1.2
8)

X1~O; X2~0

Ani n
teres
tingobservatio
ni ntheaboves etofe quat
ionsis山a tthereareonly
two designv aria
blesb utt hr
eec ons
train
ts.T hisi s av al
idp roblem.I fthe
con
strain
ts were e q
ualityc o
nstr
aints,出ent his would notb e an acceptab
le
problemd ef
initio
na sitwouldv iolate白 er el
ationshi
pb etweent h
enumbero f
vari
ables and the numbero fe qua
lityc ons
traint
s.T herefoe,t
r he numbero f
{EHU}-Z司

ineq
ualiηconstraint
sa renotrela
tedtot h
enumb 巴rofdesignvaria
blesu s
ed.This
fac
ta lsoa p
pliest ono n
linearconstr
nint
s.F igure1 .6isas cale
dp loto fゆc

Jtub//drιvdrfLbト
34

func
tions(1.25)ー(1.
28).Choosingt h
ef i
rs
tq uadrantsat
isfi
esthesideconstr
aint
s.
τhel
' in
eari
tyo fal
lo ft h
ef un
ctionsisindicate
dbyt hestra
igh
t-lin
ep lot
sont h
e
fig
ure.Again,sever
alc ont
oursoffareshownt oaidt h
er ec
ogniti
ono f
th esol
utio
n.

ff/yJX
Alloft h
ei ne
qualit
iesaredrawnw ithh ashmarksi ndica
tingthenonfeasib1
es id
e
oft h
ec onstr
ain.
tThef easi
bleregionise nclosedbyt hetwoa xesa longw i
th
con
strain
tsg2andg3'Theo bjec
tiveistoincre
as巴 thevalueoff(whichisindicat
ed
byt hecontourl e
vels
)w ithoutleavingthef e
asibleregion
.Thes ol
utionc anbe

H137
5
6 6
.5 7 7
.5 自 8
.5 9
d
lam
ele
r(c
m)

Agure1
.5C
onl
ourp
lo
l01E
xam
ple1
.1
.

SOLUTIONTOEXAMPLE1 .3 Inc o
ntra
sttoExample1 .1,a
llo ftherela
tion
ship
s
in恥 m a
themati
calmodel,e xpre
ssedbyEq uat
ions(1 .
21)ー(1.24),areline
ar.The
wordequatio
nisgener
allyusedtodesc
ribetheequival
enceo ftwoq uan
titi
esone i
ther
sid
eo fthe= sig
n.Ino p
tirn
izat
ion,wecomea crossmostlyi nequa
liti
es.百】eword
equ
atio
llwillbe出 edtoi n
cludebothofthesesitu
atio
ns.I nExample1.1,出ena 随時

ofsolut
ionwase xp
lainedusingFigu問1.5 .InExample1 .3,t hep閃 se
nceo fthr

desi
gnv a
riabl
esdenie
s山i sapproac
h.I n
steadofd es
igninganewp roblem,suppo
se
白紙 thecompanyp毘 s i
denthasd配 idedtobuyf ivemachin eso fthethi
rdt y
pe.The
mathem
aticalmodel,withtwod es
ignvariab
lesXla ndX2'isr econs
tructe
du sin
gt h
e
info
rmationth
atX3isnowap a
rameterwiththevalueo f5.S u
bstituti
ngforx3int h
e
modelforExample1.3,andcleani
ngupt hefir
stcons回 in:
t

M砿 i
miz
e j
(X)
:90XXI+9 xX2+5
9 250∞ (
1.2
5)

S
ubj
ectt
o lぽ):O
: g .4l+0
x .6x .
5 (
1.2
6) 5 1
0 1
S 20 2
5
2~ 8 n
umb
er0
1Mo
delA

g2(X):3
xI-X2~ 25 (
1.2
7) F
lgu
re1
.6C
onl
ourp
lo
l01m
odl
lle
dExa
mpl
e1.
3.
20 lNTRODUCT10N 1
.1 OPT1M1ZAT10NFUNDAMENTALS 2
1

spot
tcdatthei nt
ersecti
ono fconstr
aintsg2叩 dg 3.Th ev a
lue softhedesignvari油 Ics o
fthes
earc
hpr
oce
ssf
orl
ine
arp
rob
lcm
swi
llbee
xpl
ore
dus
ingEx
四 l
ple1
.3and
atthesolutioncanb er eado fffromt hcpl .I
ot tisn oto veryet.Beforeproceeding F
igu
re1
.6.
furt
herilisneccssaryt oacknowledgct ha
tas olutionof6 .5machinesf orModelB
isunaccepta
ble.Thes olu
tionmustb eadj u
st e
dt othen carestinteg
erv alu
e s.I n Nonll nearProb/ems:Exceptf oraf ewc1assesofp roblcms,sol
utionstonon1inear
aCl
ualp rac
tice.t h
isa djustmcnth ast obcmadew ithoutv iola
tinganyo ft he problemsa r
eo b
t ainedt hroughn umericala nalysis
. Through c omput βrc ode,
con
strain
ts.Then eedf orintegervariablesisa ni mportantc o
nsider
ationind csign. numerica1a n
alysi
sbecomesn umc ricaltechniques.Them etho d
so rt echniq
uesf or
V回 a b
les白 atar巴 飽quiredtoh aveo nlyintegervaluesb elongto白 et yp
eofv ariables fi
nd i
ngt hesoluti
o ntoo ptim
izationp rob1e msarec al
leds earchmethods.I napplied
cal
leddiscr
etev a
riable.τ
s hi
' sbookmost 1yc onsid
er scontinuousvaria
bles.Almosta 11 mathematicsa ndn umericalt田h niq u
est hese創買う refer
redt oasi te
rati
vet ech
niques.
ofthem athematicsa ne ng
i n田 rencounters,especiallyacad emic
ally,belongt o曲E Impli
cit
1yt h
ismeanss evemlt rie
sw illben ecessaryb eforct hes o
lutionc a
nb e
domaino fcontinuousvariab
les.Thca ssumptiono fcontinuityprovidc
sv eryfastan d ob
ta i
ned.A 1soimp liedisthatcac htryors earchise xecutedinac onsist
entm anner.
cff
ici
cntt ech
n iq
uesf ort hes earc
ho fc onstrainedoptimums oluti
ons,aswew ill Informationfrom山 p reviousiteratio
nisu til
izedint h
ec omputationofv alue
sint he
developint h
ist x.
etManyr ea
l-i
Ifcde si
gns, espe
c ial
lyt hoset h
atu s
eo ff-t
he-shelf pre
s e
nts equenc
e.T hisc o
nsistcn
tmannero rp r∞essbywhichthesearchi scarrie
do ut
mat
erialsa ndc omponents,d etermined i
scretem odels.D iscreteprogramminga n d and恥 s olu
tiond eterminedi sc a¥
1ed叩 a lg
orithm.T hist erma 1soreferstot he
int
egerprogramminga red iscip
linesthata ddresst hesem odels.Then atureo f出巴 t
r佃 slati
ono ftheparticul
arsearchp rocedurei n
toa nordereds 叫u enceofstep-bys
・tep
sear
chm ethods,出a tis,metho dsus e
df orse a
rching出eo pti malsolu
tion,indiscrctc act
ions.Th ea dvantageisd erivedm ostlyi nthec onversiono fthesesteps,through
prograrnmin
gi sveryd i
fferentf rom山a tinc ontinuousp rogramming.Manyo ft h凶巴 somec omp uter1anguage,intocod e出a twi1
le xecuteon山ec omputcr.D eveloping山E
methodsa reb ased on t hes canning and r eplacemento ft hesolutio
nst h r
ou gh a
1go rithma ndtra
n s1
atingitintoc odethatwi l
¥e xecuteinMATLABwi l
¥beas t
andard
exha
uslives e
a rc
ho ft hed esignsp a
cei nt hed esignr e
gion.I nt h
isbook, disc陀 tc approachin白i sb ook.
problemsarctypica
llyh andleda siftheyw erec ontinuouspr ob
l e
ms.Thec onversion Thes ea
r c
hp ro
c essisstar
tedty pic

1ybyt ryi
ngt oguessth巴initi
aldesignsolutio
n.
to由ed iscr
ctes o
lutionisthef in
alp a
rto fthed esigne f
fortandi susual
lyp erforme d Thed esignerc anb aset h
iss electio
nonh i
se xperience
.Ons evcm1o ccasio
nst he
byt h
ed esignero u
tsid巴o fa nyoptimizationt echniquewed evel
opi nt h
isb ook. successofo pti
mizationmayh ingeonh isabilit
yt ochooseagoodi n
itia
lsoluti
on.The
Chapter8d i
scussesd iscr
eteo ptimizatio
nw i
t hexa mples. searchmethod, e
v enwhenu sedc on
sistent
1y, respondsd if
ferent
1yt othep a
rticula
r
pro b
le m出a tisb eings ol
ved.Thed egreeandt ypeo fnonline
aritymayf requent
1y
Gettingb ackto出el inearprogrammingp roblemjus
td iscu
s sd,
e itsh ou
lda ls
ob e cause 白e method t of a
il,a ssurningt herea re no i nconsi
stencie
si np roblem
notedthatonlytheb o
undaryo ft h
ef ea
sibl
er egio
nw il
la ff
ectthes o
lution.He 陀 i
sa formu1at
ion.O ften,出巴 numbero fdesignva r
iables,出enumbero fc ons回 int
s,aswe¥1
wayt h
atw i
llmake白i sappar cn.
tNotethattheobj巴ctiv
ef u
nctioncontoursar官strai
ght as ab adi ni
ti
alg uessp 1ay ap a
rti nu nex p
e c
te db ehavioru nders ta
nd a
rd
li
nes
.Ad if
feren
to b
jectiv
ef uncti
onwillbed is
playedbyp ara
llelli
neswit had i
ffer
ent imDlementationo ft hem ethod.T hish asl edt ot h
ec reationo fs evemld i
ffercn
t

pd 山
引 γ yd
techniquesforo p
t imiz
ation.P r
actica1ex p
e rie
nc ebasa 1sos u
ggested白 atac lasso f

eIin

sl
ope.I maginethes esont h
ef i
gureinstea
do ftheactl
lalobjec
tive.Note出a tthe
sol
utiona l
waysa pp
earstolieatth巴intcrs
ectio
no ftheconstr
aints,th
atis,th巴corners 吃
d
ydp
d pro bl
e msrespondw elltoc e
rtaina1 g
orithms.
Them cthodsf r出es
o ea
rch,o rit巴mtivem ethods.a recurrent
1yt heon l
ywayt o
d
尚一

ofthed巴signspacc
.S o
lutionc annevcrcom 巴frominsideofthefcasib
le陀 g ion,un
like

位三 huuk xydyM

inthen onl
inearprogramming p roblem,which accommodates s olution on the imp lementnumericals olu
tionston onlinearprobl ems,ir
respec
tiveofthediscipl
inein

boundarya ndfromw it
hinth efeasi
bleregi
on.R ecognizingthcn a
tu問 o fsoluti
onsis w
hi cht h
esep roblemsapp 回 r.百1凶 ep roblemsa rep1enti
fu1i ndesigno p
t i
mization
.
同号 dr ぉ

impo
r t
anti nd ev
elopingas earc
hp roce
dure.F orexample,i nl in
earp rograrnming optimalc ontr
o1.s tru
ctura
la n dt1uidm echanics.quantump h
ysics.a nda st
rono m
y.
Wh i
1eoptimizati
o ntechniquesarea ppli
ed回 a l
lo fthen o
tedd is
cipli
nes.in回 ditiona
l
i

problems,atechniqu
eemploycdt osearc
hf orth
eo ptimald巴sig
nn eedo nlysearchthc
boun
d a
ries,p ar
ticu
larl
yt hei ntcrs
ecti
ono ft heb ound
a r
ies,w hereas泊 n onl
inear design
problems,thesear
chp roc
edu recannotignoreinte
riorvalue
s. 予

1
.1.
4 CharacterlstlcsoftheSearchProcedure

百l
ese
arc
hfo
rth
eop
tim
als
olu
tio
nwi
lldependon出en
atu
reo
fth
epr
obl
emb
ein
g
s
olv
ed.Fornonl
inea
rprob
lems,
itmustcons
i d
erthef
actt
hatso
luti
oncoul
dliein
sid
e
t
hefeas
iblereg
ion
.Example 1
.1throl
lghF i
gurc1.
5w i
llp r
ovide出ec on
textfo
r
d
isc
ussin
gt h
escar
chpr
ocedu
refornonl
incarpro
blem
s.Sim 1
i
arIy,
thec
hara
cte
ris
tic
s
22 INTRODUCTION 1
.1 OPTIMIZATIONFUNDAMENTALS 23

2
0 a
tad i
stan四 s S
..T hispointsat
is
fie
st h
ec o
nst
rain
th .A出i
. rds岡 崎Yw ouldbeto
ch
ooscX .,・Thi
sl i
eso nthecons
trai
ntb o
undaryofg..ltist ob en otedtha
tall出向E
sa ren
:
r
;
-
:.
ch
oice otfeasi
ble.Whichp oi
ntischoseni
sd c
ci de
db yt her u
lesofap a
rti
cul
ar
al
gori
thm.Assumep oin
tX )isthenextpoi
ntin出isdiscussion .
Poi
ntX )nowb ecomes恥 newp oi
n x
o
t ・Anew剛 氏hd ir c
cti
o n~ isde匂nnin回.
Po
intX2is10伺 旬d.Ano th
ぽ S明u enc
eofcalc
ula
tion
slocat郎 X3 • 百le n
extite
rat
io
nyiel
ds
白esolu
tion
.Thee ss
e n
ceo fupda
ting曲ed e
si伊 duri
ngs uc偲 s siv
ei te
rat
ionli
esintwo
ma
jorc o
m p
utations,thcsea陀 hdi
rec
tio
ll8/andstep
sizeα.百l Cc hangein由ed esi
gn
ve
cto,
rdefin
氏I as.6
X,w h
ichr ep
res
ent
s出巴 veclo
rdiffcre
nce, f o
re x創nple,X2- X.,i
s
{ESEmgz

ob
tain
eda sα
S/.F oreachiter
ati
onth
ef ol
lowi
ngs珂u e
nc eofact ivi
tycanb eide
nt
ifi
ed:
8
tep0
: ChooseXo
S
tep1
: Id
ent
ifyS
Det
ermin

AX=αS
XM W=Xo+.6X
StX
e o←Xn en
GoToStepO
Theaboveisthebas
ics t
ruc
tur
eo fatyp
ica
lo p
timi
zationalgorit
hm.Ac om
plete
onew i
llindic
ate出巴 m加 nerinwhichSa ndαarec omputed
.I lwil1inc
Ju d
et e
st
s,
5
whi c
hw il
ld ete
rmincif山巴 solut
ionhasb ce
nr eache
d( convergen
ce),o rifthe
6 7
.5 日 8
.5 g procedur
en e
edstobesuspende
dorrest
art
ed
.Thed if
fcre
nttech
niq ue
stob 巴expl
orcd
d
la
mo
le
r(c
m) i
nt hi
sb ookmost
lydif
ferin出ewaySi sest
abli
she
d.Ta kealookatFigure1.7aga
in.
F
Jgu
re1.7 At
yp
ic
als
sar
chm
eth
od. AtXot he
reareinfi
ni
techoice
sf o
rt h
es ea
rchdir
ect
ion.Tor eacht h
es olu
tionin
民 邸o n
abletimeanacc
epta
blealgor
ithmwi
lltr
yn o
ttosearc
ha l
o ngdir
ecti
ons白紙 d o
noti m
provethecur
ren
td e
sig.百l
n e
rearemanyw aystoaccom
plis h出isstrat
egy
.
i
ni
tia
ls tartin
g伊 e ssis白ep o
intm arke x
o
d ・Remember白紙 whens o lvi
n g山
o
ptimiza
ti onprob
lem.suchafiguredoesnot目 is
t.Ifi
tdid,血e nwec aneasilyo bt
ai n L
inearProgrammingProblem:I
twa
spr
evi
ous
lym
ent
ion
ed白紙 t
hes
olu
tio
nto
t
hes o
lutionbyi n
spec
tio
n.百l i
sstatemen
tisespcci
allytrueif出 eea
r r
emoret ha ntw o 白巴sepro
ble
msw o
uldbeont h
eboun
daryo
f白巴 fea
sib
le陀 gio
o( a
lsocal
ledthe
v
ariab
les
.I ntheeventth巴陀 aret wovaria
bles,自己防i sn or e
asonn ottoo btai
na j面倒ib
led
oma
in) nF
.I igu
re1.6
,出e蹴 esa
ndsomeofth
ec o
ns回 in
tsdete
nnin
et h
is
g
raphicals olu
tion(Chapt
er2 )
.Thcm ctho
dsi no pti
m i
zationr el
yo nt hcd irc
ct reg
ion
.Thel
alt
eri
sdi
sti
ngu
ish
edal
soby出ep
oint
sofint
ers
cct
ionofth
econs
trai
nLs
e
x凶 p o
lationoftheconce
ptsandi dea
sde v
elo戸 df o
rtwov ariab
lestoa nyn umb ero f amongthemse
l vs,出eo
e ri
gin,and白einters
ecti
onofthebindi
ng(ac
tiv
e)coost
rain
ts
d
esignvariable
s.Thatisthereasonwew illuset wovariab
lestod is
cussa n dd es
ign wit
htheaxe
s.T hesearev
ert
icesorco
rnersofthequ
adri
lat
eral
.Esse
nti
allythedes
ign
mo
sto fthea lg
orithm
sandm et
hods.M oreover,us
ingtw ovariab
les,自
己c onc eptscan impr
ovesbym ovin gfromoneo fth
esevert
icestothenextonethro
ughi mprov
ing
a
lsober e
i n
for四 dusin
gg e
ometry.Thed es
ignatt h
ep o
intXoi snotf e
asib
le.l tisnot fe
asi
bledes
ign
s.Tod oth
atyouhavetost
artatafea
sil巴c
b omer.Thi
swil
lb eexplo
red
u
sefultod iscu
ssw heth
eritisa no p
timalsoluti
on.A tleasto n
emorei tera
tionis moreful
lyinthechapt
eronlinea
rprogra
m ming ti
.I stobeemphas
ized出 atonl
yw i
th
n
ecessar
yt oo b凶 nthesol
utio
n.C onsi
der出en extsol
utionatXI .
Mos tm etho dsin twovari
abl
esc anwea ct
ual
lyseethegeometri
ciIu
I st
rati
onofthetech
nique,白紙 is,
o
ptimiz
ati o
nw i
llattem
pttomovet oXI byfi
rs
ti d
entif
yingas e
a r
chd i
rection,S1・This th
eselec
tio
no fver
ticesa
sthes o
lut
ionconve
r g
es.
i
sav ec
tor( samedimens
ionasd e
signvariab
lev c
ctorX)p oi凶 略 的mX oloXI ・百e Thi
spartofChapte
r1h asd
eal
twiththeintr
odu
ctionoft
heop白泌却t i
onprob
lem.
a
ctu
ald istanc
ef rom t oXI ・c
ax
o
l
li tXoX..issomem ult
ipleo fSI's町 α SI・X10 nce Whil
eitwa sappro
achedfromanengin
eeringdes
ignp e
rsp
cct
ive,th
emath
emat
ical
a
gainisn o
tf eas
iblealtb
oughiti sani mpro v
em e
nto n s x
o
inc
eits atis日 目 白E modl,i
e nabstr
actters,
m i
snotse
nsi
tiv
et oanyp 町tic
ul
ardis
cip
lin
e.Af ewde
sign
i
ncqua
lilyc on
str
ainlg ly
l( inginlheinle
rio
ro f出ec on
strai
nt).Alt e
mately, usinglhe ru
le
sw i
thr es
p回 ttospe
cif
icexamp
lesw ereexamin
ed.TIl
es t
anda
rdmath
emat
ical
sa
m escac
l
' hdirc
ctinS1,
o ano
thertechniq
ueJme 出odmayc hooseforit
snextp oint,X1', mode
lf o
ro pt
imiza
tionprobl
emswase s
tabli
she
d.Twob r
oadcJas
seso
fp r
obles,
m


一一一
.1"
"':
-..
.
一..
.,,
1:一
一 n' … 可 ' 一 ー

2
4 I
NTR
ODU
CTI
ON 1
.2 I
NTR
ODU
CTI
ONTOM
A11
.AI
I 25

linea
ra ndnonline
ar.w erei ntro
duc凶.T hegeome 汀ic
alchara
cte
risti
cso ft hesol
ut ion 1
.2 INTRODUC
TlONTOMATLAB
forthes
cp roblemswe res h own血r ough白巴 g raphic
ald e
scrip
tionof出ep roblems.An
overviewo f出es e
archt echn
iquesf o
ro btai
n ingthesoluti
ontot hesep roblemsw ω MATLABisi ntroduccdb yMathWorksInc.,asth
elangu
ageforte
chn
ica
lcomput
ing.
alsoiI
Iustra
ted.I tw asa 1som entioned出a t白es ol
ution
sw er et ob eo b
taine d Borro
wingf romt hed escr
ipt
ionin叩 yo neofit
sm anua
ls,MATLABi n
teg
rat
es
numericalか
,.primari
l yt hroughdigi
talco m
puta tion
. ∞mputation,visualizatio民 間dprogramminginaneas
y-tou
・seenv
ironm
entwhere

JAγ22一円//一 J1
Thenumericalm e
t hod susedin山i sareaarei te
rat
ivemethods
.N umeric alsolu
ti ons prob
lemsa nds olulionsa r
eexpre
sse
dinf a
rni
lia
rmat
hemat
icalno
tat
ion
.Thet y
pic
al
involvet w
oc o mpo
ne nts:白附,叩 a lgorith
mt ha
tw i
ll巴s t
abli
sh出巴 i terativ
es e
to f use
sforMA T
I
..ADi nclud巴

引けす
calcu
lati
ons.an dsecond.t hetransl
ationoft hea lg
orithmint
oc omputerc odes.usi ng
aprogrammingl ang凶 'g
e.T hisfinis
hedc odeisr ef
err
edto箇 s oft
ware.U nt
i lrec
en tly • Mathandcomput
ation
i
p
ne
red
n
o
g
i
m
n
i
e
n
e
a
r
n
t
in
ge
l
yF
d
u
O
R
c
T
a
R
ti
A
ona
Nw i
sw
t
e
hai
l
la
It
tl
sp
ePa
r
s
a
c
c
t
a
ic
la
e
.t
n dC
h
ecompu
.Thec o
旬r
m
put
l
a
a
n
t
g
i
u
o
a
n
g
a
eo
le n
fc
vi
h
r
o
o
i
n
c
m
ew
en
a
ti
s
n
・ A1g
ori
tllmdevel
opment
• Model
ing,sim
ulat
ion,an
dpr
ototyping
whi c
hitw asdeliver
e da ndp ra
cticedwお 山emai ψ'amecomputingsystems.Today,
由es ceneisve rydif
f e
re n.I
t ndi
vidualpersonalc omputers伊C s),runningWindows, • Dataan
alys
is,e
xplo
rat
ion
.andvisualization
Macintosh,LINUX,o ro therflav
orso fUNIX,o peratin
gs yste
msa renowt heme an s ・Scientificandengineeringgraphics
fortech
nica
lc omputing.The ypossessmo rep owerthantheoldm a
i n合a mec omputer s • A
ppl
ica
tio
nde
vel
opm
ent
,in
clu
din
gGUIb
uil
din
g
andt he
ya reinexpen
s iv
e .Thep owero ftheg raphic
alu se
ri n
terf
ace( GU I),出eway
出eu serinte
ractswi白t h ec omputerand山es o ftw
are,hぉ revol
utionizedth ecre
atio n TheuseofMA T
I..
ABhase xpl
odedrec
ent
lyandsohaveiω
feat
ures
.Tbisco
nt in
uous
ofs oftwar
et oda. New programming paradigms,抑制a11
y y 0匂' ec
lo r
ien ted e
nhancementmakesMA T
I..
ABanid
ealveh
icl
eforexp
lori
ngproble
msinald
l i
scipli
nes
programming ,h a
vel edt onewa ndi mpr o
v edw ayst od e
velops oftware.T oda y, t
hatmanipu
1atem athematica
lc ont
entT
. h
isa bi
1
ityismult
ipli
edb yapp
licati
on-
cnginc
crings oftw
arcisc rc
atcdbyB uchg cnc l
'a
lp rogramminglanguagc sI
lS C,C++ , s
peci
ficsolu
tion
st hr
ought oo
lbo
xes.Tol ea
rnm o
rea bo
utthelate
stMA T
I.
.AB
.its
Java,Pas
cal,an dVisualB asic
.Manys of t
warev endorsdevelopthei
rowne xt
ensiol1s f
eatu
res,th
et oolboxe
s,c oll
ect
ionofu se
r-s
uppo
rtedarch
ive
s,i n
form
ati
ona bout
tothestand
ardl angu
a ge,providingac o
m ple1e巴n vir
onmentforsoftwared e
v巴l opmen t Us
enetacti
vit
ie
s,otherf orum
s,info
rmat
ionabou
tb oo
ks,and80on,vi
si
tMATLAIla1
by出eu se
r.T hism akesi tv eryc onvenientf oru se
rswhoa ren otn eces
saril y h
up:/w
l w
w.ma1hwork s
.c om.
programmerst oget白e irj obdoneinar ea
s o
na b1ysho
rtt i
me.
Ones uc
hv endorisMa 出Wo 此s ,wi山 t h
eirf la
gshi
pp rodu
ctMA TLABa10 ngwit ha
1
.2.
1 WhyMA
11.
AB
?
complementaryc ollectiono ft oolboxes 出a td eli
vers pec
ifi
cd i
scipline-or
iente d
infor
mation
.I n血i sb∞k,MATLABi su s
ede xclusivel
yforn u
mericalsupport.Nop rio r MATLABisas tandardtoo
lf orin佐'oduc
torya ndad vanc
e dc o
ursesinm ath
ematics,
f
amiliar
itywithMATLABi sexpected,thoughf amil
iari
tyw it
hthePCi sr equire
d.L ik e eng
ineer
ing,ands c
ienc
einmanyu n i
ver
siti
esa round曲巴 world.Inindus
try,i
ti
sat oo
1
al
lh ig
her-1cvcllan
gu a
ge s,effec
tivenes
sw itht hi
snewp rogrammingr esourcecom e s ofcho
iceforre
s 悶 悶h,developme
n t,andana
lysis
.I n山isb ook,MATLAB'Sb a
sicarr
ay
witheffo
rt,frequencyo fu se
.o r
igina
lw o rk,a ndac o
nsiste
ntm annero fapplica
tion. elem
entisexpl
oitedtom a
nipulat
ev ector
sa ndmatricesthatarenat
uraltonumeri
cal
Byt hecndo fthisbo ok,itish opedt h
e問 a derw i
llb everyfamilia
rw itht hcu tec
hniq
ues.Int hen extchapte
r,i t
sp ower
fu lv i
suali
zationf e
atu
resa reusedf or
gra
phic
alo p
timizat
ion.In出er estoft h
isboo k,theinte
ractiv
ef e
atu
rl凶 佃 dbui
lt-i
n
supp
ortofMATLABa reutil
izedtot ra
nsla
tea1 g
orithmsi nt
of unc
tionin
gc ode,ina
fra
cti
onofthetimen eede
dino t
herl a
nguageslikeCo rFORTRAN.Toward白 eend ,we
wil
lin町oducetheu s
eo fi
tsOptimi回 tio
nT oo
l box.
Mostb ookso no p
timiz
ationp rov
idee x
cell巴ntco v
erageo nt e~回hniques a
h n d
a1g
orith
ms,andsomea 1soprovid
eap rinte
dv ers
iono fthecode.Thec odei
s民 qui陀d

tobeusedinmainfmmEorl egac
ye nvironmentsthatmus tsuppor
tac ompile
rint he
langu
age出ec odeisw ri
tte
n,w hichisp redomina
n t
lyF ORTRAN.Eachs t
uden
t出e n
釘ansl
ate
st h
eo rint
edc od
ei n
toaf o
rrnsui
tableforc om
putation.百 lenextste
pist o
compil
et heco de,debugc omp
ila t
ione r
rors,r u
n出巴 p rogram,a ndt r
oublωhoot
exec
utioncrr
orsb e
foreusef
ul隠 sult
sc anbeo bt
ained
.Ani m
portan
tc on
sider
ationis
白紙 thestude
ntise xp
ectedtobec onversa
ntw i由 thep r
o gramminglangua
ge.W h
i le
FORTRANwasf ormall
yt au
ghttoe ngin田rsseveraly 回rsa go,自isisn olonge
rtrue.
』竺7
十竺一一ー -
一一一
一一一
』 信配
T

1
.
2IN
TRO
Duc
nONT
OMATl.AB 27
2
6 I
NTR
ODU
CTI
ON

Manye lectr
ica
le n
g inee
ringde partme
ntshavestartedtoe mbraceCa ndC ++.PCsa r
e
gr
eatfort heuseofr ead
y-madea pplic
atio
ns,es
peciallyt ho
sew i
thGUI ,
butitsu sefor
programm inginFO RTRANhasy ettotakeof
f.
MA TI.
.ABsu
ffer
sv eryfewoft hesedis
adv
anta
ges.Its∞d eiscompac t釦 di ti
s in
ωitive
t
ol eam.Tomakep r
oblemsw orkr equ
ire
sf ewl i
neso fc odecomp aredt ot ra
ditio
nal
la
nguages.Inst
eado fprogrammin gfrom白eg r
o undu p,s
tan伽r dMA T
I..
ABpiecesofc ode
canbe由民a dedtoge出e rωimplem entthenewalgorithm.Itavoid
st hes包n dard鉛 :pr
u:
ヨ飽
∞mpilationandlinks叫 uencebyusing叩 i nt
e
.叩r et
er.Ano therimp
or tant隠 asoni scode
po巾 b
ilit
y.官 le∞d ew ri
tte
nf or出ePCv ers
ionofMA TI.
ABd 田 snoth avetob ec hange
d
fo
rtheMa cint
oshort h
eU NIXsystcms.百li
swil
ln otbet r
ueifsystem-dependentr e
source
s
mωedin白ec 吋e.Asa niIu
l strati
onofMA TI
.AB'Sl eamin
ga g
ili
ty ,bo出 MA TI.AB叩d
ap
pliedoptimiz
ationare∞v ere
di nthi
sbooks
, o
me thingverydiff
ic凶t 旬 a∞omplishwi出 ,
sa
y,FORT RANandoptimiza
tion,orC++叩 do pti
mization.F
l 町出e rmo
r e,恥I
A'百
..A
B,l ikeCo r
FORTRAN,isaglob
allyr e
lev
antp roduc.
t

1
.2.
2 M
ATL
ABI
nst
all
ali
onI
ssu
es
1g
F u
re1
.8 MATLABo
pen
ingv
ie
w.
Thisb ookd oe
sn o
tC areify ouarer u
nni ngMATLABo nani n
dividu
a lPCo rMac,a
networkedPCo rMac, orindivi
dualorn etw orkedU nixwork
statiols
J .MATLABt a
kcs h
'
m
.
careofthisissu巴.Theb o okassumesy ouh av eaw orkinganda pp
ropriate
lyIicensed cre
atefile
s(orcode )an o
therg rap
hica1windowi sn巴eded.Thisis山eMATLABM・f il
e
copyo fMATLABi nt hem achinein合o n to fy ou
.Ony ourpersonalm achine,for editor
/debugg
erwindowa n disshowni nF igu偲1.10 .Thee di
torusesc o1
0rf o
r
ins
tall
ingMATI .AB,f ol l
owt heinstr
uctio
nst h
ata ccompani巴dtheb o
x .Typically白e enhancingcodereadabili
ty.E achof山the
s弱ewindowsspawna dd
ition
a1d i
a10gboxes(i
f
systemadminist
r atorh andlesn e
tworkinstallat
ions
. n
附e
回c側 町均)if
伽ω
o
ぽrs
民c



日川.t
ω

則同
t
in
略1
唱g
fi
蜘e
伺a
側t
瓜 ur
附附e
邸sd町
削 叫
u
I
r


げi
i
r
Th
isb oo kusesMA Tt.
ABV ersio
n5 .2(untilC ha
pt e
r4 )andV ers
io n5.3(山er e
st
). workspacebrowser.
Version6h asb e e
ns hippingsincethefallo f2 00
0.MA 礼 ABversion5.0a nda bove Whileth
isi
sn otsomucha sa nin
stall
atio
ni ssue,i
two u1dbeappr
opri
alelodis
cuss山e
shouldwork.IfMA TI.ABhasc hangedanyb uilt-i
ncommandsi nn ewerversions血佃 way仙 胸kp laI1stow r
i包 a ndexec雌 MA TI.ABC峨 Gen 叫 y ,出erearetwoway sto
theone凶 e dint heb ook,itshouldprovidei nformationonthea v
ailabi
lityofn ewer wor k明 白 MATI.
AB:i nter
activelya
ndt h
ro ゆ 附' pts
.Ininter
act
ivemode.自己∞rnn1a nds
versi
ono f山 commands( orl hr
owa ne rror,ar arecase
).TheMATLABc odea nd areent
e陀d 田 d郎 氏u tedonea tatimeintheMA T
t.ABcOrnn1an
dw indo
w.Once出巴 s e
ss10n
examplesw erec r
ea tedo na nInle
lP ent iumP ro2 00r unnin
gt heWindowsNT4 isoverandMA Tt.Be
A xite
d
,t her
eisn oinformation1也tainedon尚早 se
tofcommands白紙
f
.
opera
tings ysl
em .Thee arli
ercodesw erea lsotest
edo naDECAlp haserverru n
ning wereu seda n
dw h atw ork ed( u
nle
ssac hoicew asmadet osavethesessi
on.L
) arge
OSFlV 4.TheMA T
I .
.ABversiononthes erverwas5 .1. 詑e
s a
叫ue
叩n隠 sofcOrnn1aI
1dsa reu s
uall
yd i血c u
凶1u
ω.ok 伐 P釘回ac
依kof泊 加 in
加E

低e
臨r
ac
凶Uv
刊巴 s
e
白ss
劉10
n.
I
no r
ganizat
i onsa ndi nst
iluti
onsMA Tt.ABs oftwareisu sua
llyl icense
do na 入
ぷ4

…o
伽 o
∞飢

p
叫i帥
t

subsc
riptionbas
i s.U se r
st heref
oreh av巴t he1 a
tes
tv ersio
no fthes oftwa
rei nt h
ese 白
印畠f
il
einMA
TIAB
. ・
Thisi
sca
lldas
e cr
ip
tm -
f
tl
e
.MostMATLABfi
l郎 町 田lldm-
e f
tle
s.The
sit
uati
ons.Ins u
c hac asethenewv ersi
on( at出巴 t imethebookisfir
stp u
blishe
d ),wi
ll misam eex t
BIES
ionusuallymservedfo
rMA-
I-L
AB.A
nycodechangEsmemadethmu sh
beV e
rs i
on6( orR el easeR1 2).Thisbooki sba s
edo nV er
sion5( ReleaseRI1).百l e 山eedit
or.thechang
esto出ef il
es a
ved,an
d山efil
cex
ecu飽dinMATt.
ABag
ain
.Ex巴伐c
u
凶』
胤t
in

E
昭g
code胡 d由巳 p rogr am minginstruc
tion
si nt heb ooksh o
u1dexecutew it
hoUlp roblem M
肱ATt.
A凶B
t
叫l剛 ghs
氏ふ

cd


叩似

p州
t

巾m
伽l
ω
白加es


削帥お
切p
i
s
叩 r
叫e
吋do
叩m

側1
l
泊i
n
i
nt h
enewv ersion.I nt h
enewR eleaseR12,o nt hePCp 1atform,thed efa
ult t
ωo
re
芭verttω
oi n
ter
act
ivemodea n ytime
.
appearanceofMA TI
..ABisac ompositeofs everalwindowsp res
entingd i
ffere
ntp ie
ces
ofinform
ation.T hisisshowni nFigure1.8.T hisc回 b ecusto
mizedt hroughthemenu
b釘 byV iew→D esk topLa yout→CommandWindowO nly,whicha l
socoπωponds 1
.2.
3 UsingM
ATL
ABtheF
irtT
s ime
o山ep
t reviou
s問 1 ease.Itisshowni nF igure1.9.百l isviewi ss implean dl e
ss
dis
tracti
ngforge tt
in gf a
milia
rw i出 MA Tl
..A.N
B ote白紙白eMA Tt
.ABcommandp rompt MATωw i
¥
lb eu s
edinte削 ive
1yin 出issec
tio
n. The au.
tho
rv ery叩 n 斜y
s>
i >.T hi
s windowd elive
rss tanda
rdo peratings ystemcommands f ors avin
g, r
ecornn1e
ndsahand
s-onappro
achtou
nder
stan
dingMATtAB
. ・Thismeanstypmgt
te
1
prin
ting,openingf iles,a ndsoo n,lhroughmenusa ndacommandb ar.Ino rderto c
odesy ou
rse
lf.I
ta1s
oin1u
c desund
ers
lan
dingth
es y
nta
x巴r r
or,
s an
dd eb
ugginga
nd
28 I
NTR
ODU
CTI
ON 1
.2 I
NTR
ODU
CTI
ONTOMAl UB 29

re
ctちr
i ing白ec o
de.Theaut
horisn o
tawareofasin
gleexamplewhereprogramming
waslearne
dwithoutt
herea
derty p
ing叩 de
.ln出isb∞k,MATLABcodesegmentsare
cou
rierfontw
ith出eb ol
ds t
ylelIsedfo
remphas
izingcommandso roth
erpiecesof
inf
ormat
ion.A n
ythingel
sei sr ecom
mendat
ions,sug
gesti
ons,ore x
erci
ses. The
pla
ceholde
rforcommandisinit
alic
.
百 i
sisaCla
sstoo
mLice
nsef
Otins
ttuct
iona
lus
eon
ly.
R
eseat
cha
ndcom
且etci
alusei
spt
ohib1
ted. さl

BeforeWeS
tar
t o¥
:Theflowingp
unc
tua
tio
n卸 ds
pec
ialc
har
act
ersa
rew
ort
h
Toqets
tat
ted,s
ele
ct"HAT
LABH
elp
"ft
om.
theH
elpm
enu
. no
ting
:

者 A¥
lt e
xta f
tert he% s ignisconsidereda
comment . MATLAB i gn
oresa nythin
gt o
ther i
g h
to ft he% s i
gn.Commentsa r
e
usedl iber
allyi nt h
isbookt oindicat
e
why'sandw hat' so fcommando rcode
usage.Don oto verlookt he
m.Youdon o
t
A havet ocodethemi n,however ,prob
a b
ly

計 twoweeksl ateryouwi ¥
ln otremember
F
lgu
re1
.9 MATLABCommandw
lnd
ow.
whyyoud evel opedt ha
tp ar
ticula
rp iec
e
ofco d
e .

.
J >> Thisist h
ed efaultMATLABpromp .
t
¥
h
.
U

As e m
i colonatt hee ndo fal i
neprevents

住宅志野
MA 礼 ABfrome choi ngtheinform
ationyou
ent
e ront hescreen.

Ft主主島知
A commaw illc a
u set h
ei nform
ationt o
echo.D ef
aultisacomma.
As uccessiono fthreep e
riodsattheendo f

J-

thel ineinfo rmsMATLAB白紙 codew il
l
continueωthen extline
.Youc anno
ts p
lit
av ariable name a cross two lines.You
cannotc ontin ueacommentona nother
I
in巴.
vl院

O
ptm1z
i ati
on官 1ほ1 ~IATtAB Youc an試sto
'pMATLABe xecutio
na ndg et
c 叩
A
主rEYHHιEJ民r

IJ
'
i o
hn~iley
も D
t.P
.Ve
nka
ta;a
J m
enl back出th巴∞comm! 削mdprom pt句
戸 bytyping^ c
(C凶l
佐 -C) 一b句yh加01
凶din
昭gdown

og
酔e出eぽr
.
pL耐震主訟叫世主ド

>> help command_name WilId isplayi nformationont hevarious


wayst hecommandc anbeused.Thisisthe
quickestwayt ouseh elp
.
>> helpwin Opensah elpt extwindowt hatprovides
i

morei nformationona llo ftheMATLAB


resourcesinstalle
dony oursystem
.
1g
F u
re1
.10 MaUabE
dit
or/
Deb
ugg
erw
ind
ow. >> helpdesk Providesh elpu s
i ngab rowserwindow.
30 I
NTA
ODU
CTI
ON 1
.
2IN
TAO
DUC
TlONT
OMA
TlA
D 3
1

Forthos
eo fyouprogrammingforth
ef i
rs
tt i
me,th
eequ
altosi
gn(=)hasaverys
peci
al r
el e
vanc
einmat
hema
ticsora
nywh
ereel
se 1u
.Wewi
J s
cital
oti
nth
ene
xtc
hap
terf
or
meaninginal
lprogrammingl a
nguages,i
ncJudi
ngMATLAB.I
tiscal
ledthea
ssig
nment g
ClIer
ati
ngda
taforg
rap
hic
alop出凶za
tio
n.
ope
ralor
.百 lev a
riab
leont hcIcft
-handsideofthesi
gnisas
s i
gnedtheval
ueof山e
rig
ht-ha
nds i
de.Thcactule
a qll
allOop e
rationi
nMATLABisusual
lyaccomp
lishedby AnI ntera
ctl veSe sslon: S也氏 MA 礼 AB.On恥 PCp rcsstheStartb u
tto
n.Pres
sthe
adoublecqualtosig
n( =
=). Programb utto.P
n r
csst h
cMATLAB針。' gra
mG rou
p.P ressM A TLAB.TheMATLAB
Commandwindowo pe n
supa ndaf
tersomci n
trod
ucto
rym e
ssages白E悶 w i
llbeaMATLAB
SomeA
ddi
tio
nslFeatures promp
tindi回 悦db ydoubleforwardarrow.百lisi
s叩 i nd
icati
on白 紙 MATLABi srea
dyto
aαeptyour∞ mmands.Ont henetworkeds也tio
ns,t
ypingma tJ
aba tthewindowp r
ompt
shou
lddot hes ame
.N o t
et h
attheMATLABp rogrammustb einthep a出a sdefmedi
n出e
• MA礼 ABisca
sese
nsi
tiv
e.Anai sd
iff
ere
ntt h
anA.Thi
sisd i
ffi
cul
tfo
r
.I
oginor.ωh 代 fil
e.As kthelabas
sist
antforhe
lp.Thωe紅巳 s tand
a rdUNIXp r
occd
町民・
p
ersonswhoarcu
scdtoFOR
TRA
N.Allbui
lt-
inMATLABcommandsarci
n
凶t 陀知r natthee ndo f出el i
ncorb ef
o問 山ecommen tTh
. ecommcntsr cl
at
ctow h
atis
l
owerc
ase
.
bein
gt y
ped加 dw hatisdisp
layedi
nt h
eMATLABcommandw indow.F I
田 1frc
cω町 y our
• MATLABd oe
sn o
tn e
cdat y
ped e
fin
iti
ono
rad im
ens
ionsta
tem
enttoi
ntr
oduc
e ownvaria
tios.I
S nfa,t t
c ounde岡 田d andreinf
o詑巴白巴 c ommands,itis問 commended白 紙
va
riab
les.I
ta u
toma
tica
llycr四 t
esoneonfi
rs
tenco
unte
rincode
.Thetypei
s youmakeupy ourowne xample
soften
.
ass
ignedincont
ext
• V
arial巴 namess
b t
ar
twithal
et
te
ran
dco
nta
inupt
o31c
bar
act
crs(
onl
yIc
tt
巴rs, >>a 1.0; b 2.0; c 3.0,d 4.0; e 5.0
d
igi
ts,andunde
rsc
orc)
. >>苦 why did only c and e echo on the screen?
>> who 者 lists all the variables in the workspace
• MATLABu
scssomeb
uil
t-i
nva
ria
blen
ame
s.Avoidu
sin
gbu
ilt
-inv
ari
abl
enamω.
>> a 者 gives the value stored in a
• Al
lnumbersa r
cs to
rcdi n
tern
all
yu singthelongfor
matspc
cif
icdbyIEEE >>A 1.5 ; 告 variable A
f
1oat
ing-
poi
ntstan
dard
.The senumbershaveroug
hlyapre
cis
ionof16d
eci
mal >> a,A % case matters
d
igi
ts.Theyran
ger o
ughlybetween1 0E
- 3
08and1 0
E+308
.Howeve丸山巴yare >>one a; two b; three C;
di
splaye
ddif
fer
cntl
yd ep
endingont hecont
ext
. >>苦 a ssigningvalues to new variables
• MATLABu se
sc on
ven
tio
nald
ecima
ln ot
ati
onf ornumbersus
ingd e
cimal >>four d; five e ; six pi; 者 valueof pi available
po
ints and le
adi
ngsig
nsop
tio
nally,f
or example,1,-9,+9.0,0.0
01, >> A1 [ab c ;'d e f ] 者 A1 is a 2 by 3 matrix
99.
9999. >> % space or comma separates columns
>> % semi-colon separates rows
• S
cie
nti
ficn
otat
ioni
scx
prc
sse
dwi
tht
hel
et
tre
e ,
forc
xam
ple,
2.0
e-3,1
0 .07
e23,

1.732e
+03. >> A1(2,
2) 者 accesses the Matrix element on the
• l
mag
ina
rynumbersu
see
ith
erio
rjωas
uff
ix,
fore
xam
ple,l
i,3.
- j,
l4 3
e5.
i >> % second row and second column
>> size(A1
l gives you the size of the matrix

Operators:Thef
oll
owi
nga
rct
hea
rit
hme
tico
per
ato
rsi
nMATLAB. > > 者 (row,colu mIls
l
>>AA1 size(A1l 者 What should happen here?
> > 者 f romprevious sヒatement the size of A1
+ Additi on(wbena ddingm atricc
s/ar
rayssizemustm a
tch)
> > も c ontains two numbers organized as a row
Sub 釘action( samea sab ove) > > 告 m atrix. This is assigned to AA1
* Multiplication (the subscripts ofarrays must be consistent when >> size(AA1l も AA1 is a one by two matrix
multiplyingt hem) 五
" >> A1' 者 this transposes the matrix A1
/ Div i
sion >>B1 A1' も the transpose of matrix A1
Power > > 者 i s assigned to B1. B1 is a three by two matrix
Complcxc o吋uga t巴transpose( 山0町 a yt ra
nspo
se) ' A1 *B1 者 SinceA1 and B1 are matrices this
>> C1 "
> > 者 i 8 a matrix multiplication
Intheca
seofa
rra
ys,ea
cho fthe
seope
rat
orsca
nbeuse
dw i白a per
iodpref
ixedto白e > > 巷 S hould this multiplication be allowed?
ope
rato,
rfo
rcxampe,
l (.*) r(•^)o
o r(1).明白 h
asaspe
cialmeaninginMATLAB.I
t > > も c onsidermatrix multiplication in C or
impi
1es巴le
men
t-by-
eleme
nto pe
rat
ion.I
tisus
cfu
lfo
rq ui
ckc om
putat
ion.Ithasno
3
2 I
NTR
ODU
CTI
ON 1
.2 I
NTR
ODU
CnO
NTOMAn.AD 3
3

>> % Fortran > > 者 the index ranges from 1 to 20 in steps of


> > 者 thepower of MATLAB derives from its > > 者 1(default)
> > も a bilityto handle matrices like numbers > > 者 t he loop is terminated with "end"
>>C2 81 * A1 も How about this? > > 者 t heprompt does not appear until "end" is
>> C1 * C2 も What about this? > > 者 e ntered
>> % read the error message >> plot(sin(0.01*f),cos(0.03合 f
))
> > 者 i t is quite informative >> xlabel('sin(O.Ol*f)') 者 strings appear in single
>>D1 1 2]' 苦 D1 is a column vector
[ > > 毛 q uotes
>>C3 [C
1 D1] 者 C1 is augmented by an extra column >> ylabel('cos(0.03*f)')
>>C3 [
C3 C2(3, :)]告 Note is an assignment >> legend ('Example')
> > 告 m eans do the right hand side and overwrite the >> title ('A Plot Example')
> > 告 o ld information in C3 with the result >> grid
> > 告 o f the right > > も T heprevious set of commands will create plot
> > 告 h and side calculation > > 告 l abel axes,write a legend,title and grid the
> > 告 On t he right you are adding a row to current > > 告 p lot
> > 者 m atrix C3. This row has the value of the third >> exit も finishedwiヒh MATLAB
> > 告 r ow of C2 -Notice the procedure of
> > 奄 i dentifying the third row. The colon Th
iscompletesthef
ir
stsessi
onwi t
hMATLAB.Ad
ditina
o 1commandsandfe
atu
reswi
ll
>> % represents all the columns beencou
nteredthrou
g h
outthebook.In出isse
ssio
n,i
tisevi
dent白紙 MA礼.ABa¥ows
l
>>C4 C2 * C3 も permissible multiplication ea
sym a
nipulati
onofm a
trice
s,defi
nit
elyi
nrel
ati
ontooth
erprogramm
inglan
guag
es.
> > 告 N ote the presence of a scaling factor Pl
otti
ngisnotdif
fic
ultei
the
r.The sead
van
tage
sar芭quit
esubs
tant
iali
nth
es u
bje
ctof
> > 者 i n the displayed output op
timi
zatio
n.1 n出巴 n ex
ts es
sion,wewil1usetheedit
or10I1c
comp
lis
h出esame
>>CS C2 * C3 告 seems to multiplyl thr
oughscr
ip
ts.Thissessio
ni n
troduc
ed
> > 告 I s there a difference between C4 and CS?
>> % The * represents the product of each element • MATLABCommandwindowa
ndW
ork
spa
ce
> > 者 o f C2 multiplied with the corresponding ・Variableassignment
> > 者 e lement of C3 • B
asi
cma
tri
xop
era
tio
ns
>>C6 inverse(C2) % find the inverse of C2
• A
cce
ssi
ngr
owsa
ndc
olu
mns
> > 告 a pparently inverse is not a command in MATLAB
> > 者 i f command name is known it is easy to obヒain • S
upp
res
sin
gec
hoe
s
> > 者 h elp ,
• whoinv
ersecommands
>> lookfor inverse 告 this command will find all files • .
*mu
lti
plic
ati
on
> > 者 w here it comes across the word "inverse" in
> > 者 t he initial comment lines • B
asi
cpl
ott
ingcommands
> > 者 T he command we need appears to be INV which
> > 告 s ays Inverse of a Matrix 1
.2.
4 UsingtheE
dit
or
>> % The actual command is in lower case. To find
> > 告 o ut how to use it -Now I
nth
iss
ect
io,
nwew
il
lus
eth
eed
ito
rto
α回 t
e叩 dr
unaMATLABas
cr
ip
tfi
l
e.Norma
1y,
l
>> help inv % shows how to use the command 出ee
dit
ori
sus
edt
oge
ner
atet
wok
ind
sofMA Bf
百.A i
le
s.百1凶 ef
il
esa
ret
erm
eds
cri
ptf
tle
s
>> inv(C2) 者 inverse of C2 an
dfun
ctio
nft
le.A
s I出oughbo出ofth巴s
efi
Iesc o
n凶 nMATLABcommandsl ik
e山e ones
>> for i "' 1:20 wehaveused
,theseco
ndtypeoff
i
Iesneed
st obeorgan
izedinaspe
cif
iedforma.
tBo 曲
f(i) i
"'2
;
f
il
ety戸 ssho
uldhavetheexte
nsi
on.m.Althoughthes
ef i
le
sareASCIIt e
xtfiI凶
,山e
end ge
nerc.ms
i h
ouldbe凶 edb
eca凶eMATLABs 国 民hesfo
r也i se
x蜘 sion
.τhisext
ensio
nis
> > 告 T his is an example of a for loop 山首quetoMA百.AB.百1csc
ri
ptfi
leco
ntai
nsaIis
tofMA TLABcommands白紙 areexe印 隠d
i
ns e
quen
ce.Thi
sisdiff
ere
nt告。mt h
einte
rac
tiveses
sio
no fth
eprevi
oussect
ionwhere
34 I
NTR
ODU
CTI
ON 1
.
2IN
TRO
DUC
TIO
NTOM
ATL
AD 35

MAτ1.AB悶卯ndedt o回 chconunandi mmediate


l .Th
y escri
ptfileismoreu se
fulwhen init
senti
rety
.P rio
rtorun
ningthes
cri
ptyouwil
lhavetosav
et h
escri
pteachtime50
therear巴m anyconun 叩 ds白紙 n eedt ob eex釘 utedtoa c∞mplishsomeobjective,like 白紙 t hec hange
si n由巳fiJea r
er ec
ord
edand thechange
sa recurrnt
e .Another
runningano ptimiza
tiont e
chnique.Itisimportanttoremembert htMATLABa
a I
l owsyou recommendationistod
elib
era
telym
isり'p
esomes t
ate
mentsandatt
empttodebugthe
toswitchba ckωinteracti
vemodea tan ytimebyj u
stt y
pingcommandsi n白eworkspace err
orgeneratedby白eMATLAsdebuggerduri
ng回 目 u
tion
.
windowl ikein曲ep 問v io
uss ec
tion.
MATLABp rovidesane di
torf orcreatingthesefil
esont h
ePCp latform.T hiseditor C
rea
tin ,tM

gtheScr -・.
fl
le(Thef
oll
owi
ngw
illbet
ype
dls
av吋 i
naf
i
l巴.
)
usesc ol
ort oidenti
fyMATLABs tatem
en t
sande le
m e
nts.Itp rovides白ec urr
entvaIu e
s
ofthev ariable
s( aft
er白 eya rea vailabl
ei nthew orkspa ce)whent hemousei sov er も example of using script
thev ar
iablenamei nthee d
itor.Th el官邸官 t wowayst oa ccess山ee ditorthrought h
e A1 [1 2 31;
MATLABCommandwindowont h
eP C.5 t
artMATLAB.T hisw illopenaMATLAB A2 [4 5 61;
Commando rWorkspacewindow.I nt h
iswindowt heeditorcanb es tart
edbyu sin
g も the commands not terminated with semi-colon will
themenuo r血et ool
bar.On t heF ilemenu,c l
ickonNewandc hooseM- f
iIc
. も display information on the screen
Altemately, c
lickont heIeftmosticonont h
et oo
lbar(出et o
oltipreadsNewF ile)
.The A = [A1; A2]
iconf o
rt h
ee ditorcana Is
obep lacedont h
ed esktop,inwhichc asethee di
torc anbe B [A1' A2']
starte
dbyd oub
l e
-clickingt h
ei con.Int hi
se vent,aMA TlABCommandw indoww il
l C A*B
notbeo pened.Th ee d
itorp rovidesit
sownwindowf orentering出巴 s cr
iptstatements
.
Atthisp o
intwea r
er eadytou set h
ee dit
or.Makes ureyou即 ad出巴 commentsand も now re-create the matrix and perform matrix
understandthem, ast hes
ep rocedu問 sw i
llbeu s edoften.Usingt hee dit
ori m
plieswe 者 multiplication as in other programming languages
wil
lbew orkingw ithm -
files. 者 example of for loop
Thecommandsa r巴 出es amea sin1h巴i nt
eracti
ves essio
ne xceptthereisnoMATLAB for i 1 3 者 variable i ranges from 1 to 3 in
promptp refixingtheexpressions.Toe xecut
et hesecommandsyouwi Ilhavet osa v
e も steps of 1 (default)
themt oafil巴.Let u
sc a
llt ef
h ilesc
riptl.m.The.me xtensionn eedno tbet ypedifyou a1(1,i
) i;
areu sing由巳 MATLABe d
itor.Youc ans avet hef i
leu singt heSaveo rSaveAs end 告 loops must be closed with end

commandfrommoste di
tors.Itisi mport加 ttoknowt hefullpa 曲t o白i sfil
e.Le tus a1
assumet hep athfor出ef i
leisC:¥OpCbook¥Chl¥ s c
riptl.m.Note出 創 出epa 白h ereis
specifi
eda saPCp athd es
cription.Th er ea
sonwen e
e d山i sinformationist oinfo r
m for i 6:-1:4 も note loop is decremented
MATLABwheret ofind白ef i
le
.Wedo出i sin白eMATLABCommandwindow. a2(1,i-3) i; も filling vector from rear

Thisimplieswes h
ou dhave白eMATLABCommandwindowo
l pe n.OnPCswes tar
t end
MATLABt hrought heicons
.I nt h
isbookwew illa ccomplishmostt asksbyt ypingin a2
theCommandwindowo rthr o
ughp rog ramming.lnmanyi nstances山e rearea ltem
a t
e
者 creatingmatrix A and B (called AA and BB here)
waysu s
ingmenui temso r白et oolb
ar.T hisisl e
ftt other eadertoe xp e
rimenta nd
for i 1:3
discove
r.I nt heMATLABCommandwindowu s巴山ea ddpathcommandt oi nform
AA(l,i) a1(1,i); も assign a1 to AA.
MATLABo fthel oca
tionoft hefil
e:
AA(2,i) a2(1,i);
BB(i,1) a1(1,i);
>> addpath C:¥Opt_book¥Ch1¥ BB(i,2) a2( 1,i);
end
Thes
cri
ptth8
1wi
llbecr
eat
edands
ave
di ,t
nSCT伊 l
.mcanber
unbyt
ypi
ng(
not
eth
at
も the same can be accomplished by AA (1,:) a1
出eext
ensi
oniso
mit
ted
)
者 without the for loop
AA 巷 print the value of AA in the window
>> scriptl
BB
who も list all the variables in the workspace
Tounderst
andandas
soc
iat
ewitht
heprog
rarnm
ingconc
eptsembeddedin
.thescr
ipt,
者 consider code for Matrix multiplication
pa
rti
cula
rlyforpe
rso
nswihI
t im
itedpr
ograr
nminge
xperien
ce,i
tisrecommendedto
% which Matlab does so easily
runth
escrip
taft
erablo
ckofst
ate
men
tshavebeenwr
itte
nr a
山erthantypi
ng山ef il
e
36 I
NTR
ODU
CTI
ON 1
.2 I
NTR
ODU
CTI
ONTOMA礼 AD 37

告 multiply two matrices (column of first maヒrix must • C


lea
rst
ale
men
t
者 match row of second matrix)
szAA size(AA) も size of AA
szBB size( BB); 1
.2.
5 CreatlngaCodeSnlppet
if (szAA(l,2) szBB(l, l
) )
告 only in column of AA match the rows of BB Int h
iss ec t
ion,wew ille x aminet h e0山e rt ypco fm-fil巴 whichisc al
1e dt hefuncti
o n
for i ~ l:szAA(l,l) m-fil
e.F ort hosef amiliarw i lho therprogrammingl a
ngua g
esI ik eC,J ava,o r
for j 1:szBB(l,2) F'ORTRA N,出e sefilesr epresentf unctio n
so rs ubrout
i nes
.Theya repr imarilyuscdt '
O

CC(i,j) 0.0; 苦 initializevalue to zero handles '


Omes pecifi
ct ype
so fc alculations.Thc ya l
s opr'Ovideawayf orthem odu
la r
for k 1:szAA(l, 2) de ve
l op mento fco dea sw ellぉ c od ereuse.T hesec o d
em odulesa r, u
巴 sedbyb eing
CC(i,j) c CC(i, j) + AA(i,
k)*BB(k, j); callc
do rr ef
crredino thers ectionso ft hecodc, sayt hroughas crip
tf ilewel ooke
da t
end も k -l oop ea
r l
ier.Thec odet ha
tc allsthcf uncti onm-fileisc a
lledt hecallin
gp rog ram/ c
ode.The
end も j - loop essen
ti a
lp ar
a mct
c rsind cvel'p
O ingt hef unct
ionm -filcarc( 1)w h
a tinp u1isnecessa
ry
end 苦 i - loop fort hec aIculati
ons,( 2)w hats pecificc alculatio
nsmustt akep lace,a nd( 3)wha t
end 者 if - loop inform ationm ustber e tumedt ot hec alli
ngp r'
O gr
am .MATLABr equi
r est heSlru
cture
CC of出ef unctionm・f i
let of ollowap rescribedf ormat
.
者 Note the power of MAT~B derives from its ability to Wew illu se1hee di
1 0r10d evel'OP afunc1ionm -fi
l etha1wi I
1p crfor map olynomi
al
も handle matrices very easily curve
f tI
i. Irequiresas eto f砂 d ata, represen1in
gac urvet ha
tn eedst ob efi1,10
ge1her
者 this completes the script session wi出 t heo rdero fthep ol ynomialt ob efit
.T hi sexerciscisc allcdc ur v
ef iuin
g.In
Chapt cr6 s uchap robl emw illb ei den
1ificda s ap ro blemi nu nco n
strained
Savetheabov
efi)e(sc
rip
tl.m).Addthedir
ect
orytotheMATLABpat
h凶 ind
icat
ed optimization.F ornow,t h eca l
cul a1ionsn ecessaryt oa ccomplisht hee xerci
sea re
be
fore
.Runt hesc
riptfi
lebyt yp
ingsc
ripJa
t tthecommandpromp tThccommands
. consid eredk nown.Iti nvo
l ve
ss olv ingal ine
are quationw ith出enomtalm atrlxanda
sho
uldallexe
cutea ndyoush o
uldfmall
ys e
etheMATLABp romptinth
cCommand right
-h 佃 dv cctoro btainedu singt hed a
tap oi
nts.τ' heou tputf r
o mthem -
fi l
ew i
llb e
window. 山e coe 鉦i cie
ntsr epresenting白ep o lynor
nial.
Note: You ca
na lw
aysr cver
ttot hei n
tcr
act
ive mode bydire
ctlyen
teri
ng Befo rewes ta
rttod evelopt hec ode, th
ef i
rstl i
neo fthisfilemus tb efor mat
teda s
commandsin出eMATLABwindowa f
terth
epromptI
. ntheCommandw indow: specifiedb yM ATLA B.I nt hefi
rstl ine, t
hef i
rs
tw'Or ds ta
rtir
ig合um出ef i
rstc ol
u m
ni s
山cw ord function.Iti sf ollowedb yt heseto frelump ar a
me ters(r etumva l)
.N ext,
>> who 山en ame( mypoly
f it)'Ofthefunctio nw iththepar ametersp assedtothcf unctionwithi
n
>> clearC % discards thevariableC fromtheworkspace p抗 仙e ses(X,YN).明 l efilemu stb es aveda sname.m( mypolyfi
t.m).Thecomme 略
> > 者 use with caution. Values cannot be recovered be 1w
e ent h
efirs
1l inea ndt hefirs1e xecutablcs tatementwi I
1a ppc釘 i fy ou1 yp
eh e
l p
>> help clear Ia
l me ( he l
pm ypolyfi t)i nt h
c Command w indow. The r easonf ort hcn ar
ne
>> exit mypol yfi tm i
. sthatMATLABh asabui 司1tinf unclIonp oly
fit.Opent hee ditor10creat
e
thefilec ontainingthef oll ow
in gin formation
:
Thi
sse
ssi
oni
l
1us
tra
ted
:
function returnval mypolyfit(XY,N)
• Usco
fth
巴ed
ito
r 寄 者
・Creatingascript も

These comments will appear when the user types
helpmypolyfit in the Command window
• R
unn
ingasip
cIt
事 This space is intended to inform the user how to
• E
rro
rde
bug
gin
g(recommcndcda
cti
vit
y) も interact with the program,what it does
・Programmingconcepts 苦 what are the input and output parameters
. Lo
opc
ons
tru
cts,
ifa
ndf
orl
oop
s も Least square error fit of polynomial of order N
者 xy - Data found in XY
・Loopv
ari
abl
ean
din
cre
men
ts 告 returns the vector of coefficients starting from
・Arrayaccess % the constant term
~.
i '~ S~-:t'~!{j!'ょに:it吋よ,~\.J\".'l\"~' ~ ,~ f:,~', , . j,~ ;'刊;夜長翻最麗~革担躍盟E
司..

\U! t:J.\i. ~~t・n::日九り~!,;:)_.~,r..i:1 1


:・'
. : j'J I¥

1
.
2IN
TRO
OUC
TIO
NTOMAl1.AB 3
9
38 l
NTR
ODu
cnO
N
end 者 end i 100p

も i f the x-points are distinct then inverse is not a
まor i 1:N+1
a(i) = 0.0; も initia1ize the coefficient to zero も prob1em

end
returnva1 inv(A)*b';
sz size( XY);
NDATA sZ(l, l); 者 number of data points - rows 0王
S
avethefi
l sm
ea y
polyfu
.m.Tousethefunc
tionwewilln eedt
ocrea
tesomex
ydat
a
阻dthcnca
llthemy
polyf
itfun
cti
on.S凶 MA 1LABi
n白cd i
rec
toy伽,tm
r ypol
yf
it
.m
者 xymatrix
r
esi
desin
.oraddthedir
ect
orytoth
ep a
th.IntheM A11.ABCommandwindow
:The
if NDATA == 0 f
ol
1owingco巴i
d stype
dinthecommandw indo
w.
fprintf('There is no data to fit');

-
reヒurnva1 a; 者 zerova1ue returned

a

o

.,.,
10‘ J )
ryy
ι

oX2
a﹀
return; % return back to ca11ing program

4



xxx

1・

=噌・晶司 4

司 , 白 勾 ム 吋 ,u
end




‘,
1・

==



E

x
x
*

*
+

n
1

A
X
2J


U


if NDATA < 2*N

J
3
n
e
fprintf'(,

品M
Too few data points for fit
')
returnva1 a;
reヒurn >>coeff mypolyfit(XY1, 3)
end >>告 ac ubic po1ynomia1 was de1iberate1y created to
>> % check the results. You shou1d get back

The processing starts here. >>者 t he coefficients you used to generate the curve
‘usmuadu 色 古 島 市

The coefficients are obtained as solution to the >>者 t his is a good test of the program
Linear A1gebra prob1em [A][c] [b] >>者 L et us create another examp1e
Matrix [A] is the Norma1 Matrix which contains
the sum of the powers of the independent variab1e >> XY2(:,1
) XYl(:,1);も same first co1umn
O

[
A] is symmetric >> XY2(:,2
) 2,0 + exp(XY2(:,1
))

>>者 n ote the power of Mat1ab - a vector fi11


for i 1:N+1; >>者 an ew set of xy-data
b(i) 0.0;
for 11 l:NDATA; 100p over al1 data points
も >>coeff1 mypolyfit(XY2,3) 者 cubic po1y. again
者 variab1e is "11" (e1)(e工) >> helpmypoly 王it
b(i) b(i) + XY(11,2)*XY(11,1)^(i-1); >>者 y ou shou1d see the statements you set up
end も 100p 11 >>も I n the next exercise we wi11 create a script
>>も f i1e that wi11 run a program for po1ynomia1
for j 1:N+1; >>者 c urve-fittingwe wi11 save XY2 so that it can
if j >= i 者 ca1cu1atingupper diagona1 terms >>者 b eused again
power (i-1) + (j・1);
A(i,j
) 0.0 者 initialize
﹀﹀﹀
﹀﹀﹀

save C:¥Opt_book¥Chl¥XY2.dat -ascii ・doub1e


for k l:NDATA; 告 sumover data points 者 this wi11 save the fi1e as an ascii text fi1e
A(i,j) = A(i,j) + XY(k,l)^power; も withdoub1e precision va1ues
end 苦 k loop
end 告 c10se if statement
T
hi sc o
nc1u
d e
s白ee xerc
isew h
ereacod
es凶p阿 W凶 w r
itt
ento回 l
c叫ate出E
Aけ,i ) = A(i,j) 昔 exp10itingMatrix symmetry
end 苦 end j 100p
∞fficientsofthepolynooualusedt
C of
i
tac
urv巴t
osome砂 d
at
a.百 et
ypeoffi
l
cist
hc
40 I
NTR
ODU
CTI
ON
1
.2I
NTR
ODU
CTI
ONTOMATLAB 4
1

f
imct
ionm-
fi
le
.Itn民 地 ωbeuse
dinace
rta
inway
.百lec o
dewas臨 t
edus
ingacub
ic 苦 the stri叩 variab1epath wi11 have the path
po
lyno
mia
l.Nonpo
lynomia
lda
tawcea
r 1s
otes
te
d.Thed
atawer
esav
edfo
rla
teru
se
. も information the defau1t directory pointed wi11
者 differdepending on the p1atform
1
.2.
6 Creatlngaprogram
if isstr(file) 者 if a fi1e is se1ected
10adpathfi1e ['load', path fi1e];
h 出i
ssect
ionaprogra
m白紙 will陀 ad砂 datc

a ur
vef
itth
edatausin
gap oly
nomia
l, a
nd
者 1 0adpathfi1e is a stど ingvariab1e concatenated
∞mpare恥 or
igi
nalandf
i臨 dda泊 伊p ru
回llywillbede
velo
ped.Th e也 t
awil
lber e
ad
も with three s trings "10ad, " path and fi1e
us
ingaUserIn低出国(UI)windowa ndad i
alogbox
.Th ecodewil
lb edeve
lopedぉ a
者 n ote the space after 10ad is important
s
cri
ptfi
l.Thi
c sgive
susa nop
port
un i
tytorev
is
itm o
stofthec o
deweu s
ed回 rl
ierfo
r
問info
rceme
ntWcw
. il
la l
sous
ethcf u
nct
ionm-f
iIecre
ate
din由巳 pre
viousex
erc
ise
. eval(10adpathfi1e);
百l
er
芭出窓 s
eve
ralw
aysf
ory
ouo
rth
eus
erst
oin
te
ra
ctw
itht
hec
odey
oud
eve
lop
.百1巴
も eva1uates the string enc10sed -which inc1udes the
b
asi
cme
tho
dist
opr
omp
tus
ersf
ori
nfo
rma
tio
nat恥 p
rom
pti
nth
eCommandw
ind
ow.
も Mat1ab command 10ad. This wi11 import the xy-data
司自i
s出eq
uic
kes
.
tTisi
h spr
oba
blyw
haty
ouw
il
lus
ewhend
eve
lop
ingt
hec
ode
.Once
告 the data wi11 be avai1ab1e in the workspace as a
te∞d
h eh asbeentes
t,d
e
d ep
encli
ngonu s
efuln
essi
tm ig
htb erel
eva
ntωconsid
eru si
ng 者 variab1ewith the same name as the fi1ename
moresoph
istic
atedcustomeIemen
tsiIk
ei n
putboxesandfil
esele
cti
onbox
es.百lisbook 告 without the extension (this assumes you se1ected
wi
llconti
nuetouset h
eseelement
st h
rougho
utasappro
priat
e.Wh il
eth
ei n
puteleme
nts も the xy-data using the fi1e se1ection box)
us叫 i
n山i scodearcncwcommands, there
stoftheprogramwil
lmostl
yusecommands
伽t havcbccnintro
du田d 回r l
ie
r.Ins叫uent
ialord
ertheevcn
lsin出 sprogr
amare
:( )t
1 o newname strrep(fi1e,'.dat',");
re
adthe砂 d a
tasa v
edear
lierusin
gaf i
lcsc
lecti
onb o
x,(2)torea
d曲eo rd
eroffi
tu s
ing も newname is a string variab1e which contains the
anInputdialo
gb ox,(3
)t ousethemypoly
fitfuncti
ondcvelope
dinthela
stsect
ionto 告 string file stripped of the .daヒ extension. Thi白
obt
a泊t hec田 f
fic
iens,
t (
4)too b
tain白ec ∞必i na
凶 o fth
ef i
tt
cdc町 v
e,(5
)togra
pruca
lly 苦 is a string rep1acement command
compa
re血巴 o r
igi
nal叩 dfit
t凶 data

a nd(6)ω 氏 陣ton白ef it
te
da∞uracyon曲e fi
思m
i
tse
l五百巴 n ewscrip
tfil
ewillbecall
edprog.
.
.J
1弘m
j . x eval(newname); 昔 assigns the imported data to x
者 just for convenience. The above step is not
S
tar
tth
ecd
ito
rtoc
rea
tet
hef
il
cca
lldp
e '
可 者 necessary

告 program for fitting a po1ynomia1 curve to xy data NDATA length(x(:, 1)); 苦 numberof data points
者 from clear path 10adpathfi1e newname
告 App1iedOptimization using Mat1ab 者 get rid of these variab1es to recover memory
者 Dr. P.Venkataraman end

者 Chapter 1,Section 1.2.6 者 Note: if a fi1e is not se1ected, nothing is being
者 The program 100ks for a fi1e with two co1umn ascii % done
者 data with extension .dat. The order of the curve is 者 Use of an input dia10g box to get the order
者 obtained from user. The origina1 and fitted data 者 of po1ynomia1 to be fitted
苦 are compared with re1evant information disp1ayed on PROMPT {'Enter the Order of the Curve'};
者 the same figure. The program demonstrates the use 者 PROMPT is a stringArray with one e 1e
r時抗
も of the fi1e se1ection box,an input dia10g box, 告 note the curlybrackets
者 creating specia1 text strings and disp1aying them TITLE 'Order of the Po1ynomia1 to be Fitted';
者 as tring variab1e
[fi1e,path] =uigetfi1e('*.dat','A11 Fi1es',200, 200); LINENO 1 ; 苦 a data variab1e
者 uigetfi1e opens a fi1e se1ection box
者 checkout he1p uigetfi1e getva1 inputdlg(PROMPT,T工TLE,LINENO);
者 the string variable fi1e will hold the filename
42 I
NTR
ODU
CTI
ON 1
.
2IN
TRO
DUC
TIO
NTOM
ATlA9 43

者 the input dialog captures the user input in getval 告this places the string errstr2 which is obtained
告 ge七val is a string Array 者bycombining the string 'squared error' with
者 check help inputdlg for more information も the string representing the value of the error,
者 wherever the mouse is clicked on the plot.
no str2num(getval{l, l}); 者 moving the mouse over the figure you should
者 the string is converted to a number- the order 告 see location cross-hairs
clear strorder titlestr errstrl errstr2 a y x i j
clear PROMPT T工TLE L工NENO 者 deletingvariables clearNDATA no coeff XY2 file err2 getval
grid
% call function mypolyfit and obtain the coefficients
者 This finishes the exercise
coeff mypolyfit(x, no);
Runt heprogr四 b
a yfir
strunningMATLABi n由巳 di
rect
orywherethese削e sar
e.or
generate the fitted curve and obtain the squared

addin
gt hep 柚 to1 ∞ate白 白 血 At白ecommandprompttypeproLP耐.The
告 error programshouldE XEcut
er equ
iringuserinputt h
roughthetil
eselect
ionbOLinput
err2 0.0i '
dia
log,andfina
l1yd i
splayi
ngF i
gure1 .1
1.百lea ppe釘ancemayb eslig
htlydiff
ere
nt
for i 1: NDATA 者 for each data point depe
ndingo n恥 p laぜ'ormMATLABi sbeingru
n.
for j l:no + 1
MT hisfinishe
st heMATLABs ectio
no ft h
ec hapter.
Tlms ec
tionlIa
si ntrodu
ced
a(l,j) = x(i,l)"(j-l);
A
TLABi nar obu
s tmanner.A b roadmng 巴o fprogmmminge xperie
nceh asbeen
end ml
tlat
edi nt h
isc hapter -
A Hm wcommandsh av
eheni de
ruincdw it
hab def
y(i) a*coeff; 者ヒ he data for ヒhe fitヒedcurve
ex
plana
tionin白巴 c omments.Itisi mpo
rtant白紙 youu setheOPP t
Olunitytotypein
err2 err2 + (x(i, 2) -y(i))*(x(i,2)-y(i));
出ECodEy ou
rs e
lf;Thatistheonlywayt heuseofMAT1ABw i
llbecomef amiliar
.The
者ヒ he square error
p
ract
icea1sow i
llleadtof ewersyntaxerr
o瓜 T hewrit
ingofc od
ew il
ls i
gnif
ican
tly
end im
provey oura bi
1itytod ebuga ndt ro
ubles
hoo.Wh
t i
le白isc hap
t e
re mployeda
者 plotting
plot (x(:,1),x(:, ),
2 ,ro',x(:,1),
y, ,
b-');
% original data are red o's P
oly
nom
ialc
uref
v I
tofo
rde
r3o
ffi
leX
Y2.
dat
告 fitteddata is blue solid line 5
xlabel(,x')i
ylabel(,y');
strorder setstr(num2str(no));
者 convert the order of curve 七o a string
巷 same as getval if you have not cleared it
者 setstrassigns the string to strorder
titlestr ['polynomial curvefit or order',
s七rorder, 'of file',file)i
者 the three dots at the end are continuation marks
者 the title will have the order and the file name
title(titlestr)
legend('original data','fitted data');

errstrl num2str(err2);
errstr2 ['squared erど or errstrl]
gtext(errstr2); x
F
lgu
re1
.1
1Or
ig
ln
ala
ndf
ll
le
dda
la
.
t
¥
2
J:;
!
. l
;'
fl
. ω」i44uuム凶1uωi即位kJt:iム幽必泌叫抽融柏崎州附
草山記

2
44 INTRODUCTION

s
eoa
rat
ese
cti
onont h
eu s
eofMATLABoutofn 町 民s
it,sub叫 uentchapmMe
y
CMa伽 iz
edbyacompl仰 向r at
ionof
theu
sm ofMA.
関巴叩 T
官TL
AB
o
pti
miz
匂a
低t
i
ぬo
n.

u
ruu
z;z
tm
PROBLEMS

叩:;官官 官l
r
ι;
叩::
;
t; a
mathe
matic
almodeJ.
1
.2 Ide
ntifys
ever
alpos
sibl
eop
tim
izati
onp
roble
msrel
ate
dωanairc
raf
t
.F ore
ach
problemide
ntif
yalめed
l i
sci
pli
nes白紙 w
illhe
lpesta
bli
sht
hemathe
matic
al GRAPHICALOPTIMIZATION
mode l
.
1
.3 Id
由巴nt
仲 s総ev巴叫 p
刊 oss
ibl
e叩0pti
miza
p
戸m
帥油
0b
州ふi
l 耐d
白e凶匂 a
叫1侃
thed
血i
也叫
s
ci
増p
lin
巴s削
郎 w
叫i
ll
け凶

h
恥川
e



1如
l
叫pe
s ぬ
酬 i

sl
h恥 ma
闘l
a伽 n
削a
t
山i
L
比刷
modeJ
..
1
・4 Id
ent
ifysev
era
1pos
sib
l巴opt
imi
zati
onpro
blemsre
lat
edt
oamicro
syste
rnu s
ed
fo
rcontr
ol.Fo
rBa
chprob
lemide
nti
fya
llthE
dis
cIP
lin
est
hatw
illhel
pesta
blis
h
Thisbooki nclu
desal argenumbero fcxamplesw ithtwov ar
iabl
es.T wo
-variable
出em
ath
ema
tic
a .
lmodel problemscanb ed ispla
yedg raphic
allyandt h巴 s
olutiono bta
inedbyi n
spectio
n.
1
.5 De
fineap r
ob l
emwitIr
1 espe
cttoyourinv
estmen
tinthest
ockmark
et.Des
cribe Along w itht heu se
fulnesso fo b
tainingt h
es olutionw ithouta p p
lying
血en atu
reofthem
athematic
almodd- math巴matic
alc ond
itions,theg ra
phicalrepresenta
tiono ftheproblemp rovidesan
1
.6 Defin
e由巳 p roblema n
de stab
lis
h由巳 m athe
matica
1modelf ortheI-beam oppo
rtunitytoe xploretheg eometryo fmanyo ft hen umericalt e
chniqueswe
hold
ingupa nindep
endentsin
gle-
fami
lyhome. examinelat
er.Thisisn e
cessa r
yf o
ri nt
uiti
velyu nd
er st
a n
dingt h
ea lgo
rithmandi t
s

川叩日山島町や P U 1川
1
.7 Definethep r
oblema ndident
ifythemathem
atic
a lmodel f
ora noptimum prog
resst owardthes ol
ution.Inp ra
c t
icalsi t
uati
onswhichu suall
yi nvolveover
s,

2 世話白川
o
verhang
ingtraf
fi
cl i
ght
. twovariab
le thereisnoo pportun
ityf o
rn ea
tg raphicalcorre
latio
nb ecauseofthe
1
.8 Def
ine血ep r
o blemandiden
tifyamathem
atca
i 1modelf
ors
che
dul
inga
nd I
imitat
ionsofg ra
phicalrepresent
ation.Itwil
1ben ecessarytoreviewt h
enumbers
oo
timi
zatio
no ftheda
ilyro
utin
eact
ivi
ty. todecideonc onvergenceort helackt h
ereof
.Whath appensw it
hmanyv ariabl
es
ωD
叫ne 出ep 州 emf oral am
in
i
sa ne
twov
x
a
r
t
i
e
a
n
b
s
l
e
i
s
onoft h
eg
.A goodi
eo
m
m
a
e
g
t
i
ri
n
a
cf
ti
e
o
at
ni
ur
sa
e
st
ne
ha
ta
s
r
s巴n
eo
t
ia
b
lt
se
o
o
rv
lf
edi
o
np
rth
r
e
o
s
bl
ep
em
r
si
obl
n
e
m
vol
v
sw
i
i
n
t
g
h
命i
v叩
灼 gi
venasp配
e
:e
i
出白c卯
pump.
manyv ari
ables
.

110 D
efineac h
emica
le n
ginee
ringproblemt
omixv釘 i
ousmix
turesof1
im
ite
d
引が
19日U

Contourp lot
sp rovidet heb estg r
aphicl陀 p
a resentat
iono ft heo p
timizati
on
a
vai
lab
ili
tytomakespec
ifi
e om田 ts
dcompoundst pec
ifi
edd巴ma
nds.
problemintwov ar
iable
s.Thep oi
ntso nanyc ontour(orcurve)havet h
esamev al
ue
ofthefunc
tion.Severalso抗w arepackagesa r
ea vail
a b
letoc rea
tea nddisp
layt he
se
1
m
pl
ots
.M ATLAB.M athematica Maple,andMathcada
, r
eamong出eg ene
ral-puqJO
se
soft
warepackages白紙 c andrawc on
tourp l
ots
.I nthisbook, wewilluseMATLABf o
r

自 gra
phica
1o pt
imizat
ion.

2
.1 PROBLEMDEFINITION

Thestan
dar
dform
atforopt
imiza
tio
npr
obl
emswase
sta
bli
she
dinC
hap
ter1
.lti
s
re
in町o
duc叫 he
reforc
onv
enien
ce:
4
6 G
RAP
HIC
ALO
PTI
M'Z
ATI
ON 2
.
1PA
OBL
EMD
EFI
NflO
T N 4
7

M
ini
miz
e f
l
.x
,JX
2,.
• •,
Xn) (
2.1
) F
igure2
.1iI
Ius
tra
testh
egra
phi
cals
olu
tio
nto白ispr
oble
m.百l
efig
ureal
sod
isp
lay
s
a
ddi
tio
nalinfo
rmati
on,rel
ate
dtotheine
qua
lit
ycons佐a
ins,p
t lac
edo ni
taft
erth
e
S
ubj
ectt
o
: h(
x ,
2,
"X Xn)=0
• ••, p
rin
cip
algrap
hicinfo
r m
ati
onwasgen
era
tedanddi
spl
aye
d.

h2
(x,

X2・
・.
.,x
,,)=O
2
.1.
2 Formatf
ort
heG
rap
hlc
alD
lsp
lay
h
t(I,
X X
2・・
...X,
)=0
, (
2.
2)
Theg rap
hicals o
lut
iontoE xample2 , a
.
1 ss eeninF ig
ure2 , i
.
1 sgenera
tedu s
ing

gl(X"X2・.
..Xn)三o MA T
I.AB[1.2]ex∞:p
tfortheide
nti
fi伺 t
ionofth
ei ne
qua
litycon
str
ain
ts.Alline
quali
ty
co
nstrai
ntsaredisti
nguis
hedb yhashmarks.Theh as
hedsideind
icat
estheinfe
asib
le
g
2(X
I.X
2・・
.
., Xn)SO re
gion.InMA'
τ1.AB5.2,出ereisnofeatu
retoins
ertthe
semarksthroug
hp rogr
amming.
g
lll
(X"
X2・
・.
..x
,,)SO (
2.
3) Ana dd-onpr o
gramcalle
dMatdraww asusedtocrea
tethehashi
Inesinthefig
ure
.It
canb edownloadedf ro
mt heMathworkssit
e.Beginningwi山V ersi
on5 3t
. h
ereisa
x
:gx
i三X
7 2,
. i=I, .
.
.,n (
2.4
) fi
gure(plote
di)巴d
t it
or白紙 w il
la ll
owy outoin
sertadd
itio
nalgrap
hicelemen
tsto出E
fi
g町e .百 l
es tu
dentcanal
sop 叩 c
ilin由民eh ashtine
safte
robtain
ingthepri
ntoutI
tis
I
n山ischap
ter,whi
lea d
heri
ngtotheforma
t.theneces
sit
yforzeroont herigh
t-ha
nd t
ob en ot
e d出atthegraphi
cals o
lut
ionisincomplet
eiftheineq
uali
tyc o
nst
rain
tsa r
e
s
id sr
ei ela
xed.百 isisbeigd
n on
e fo
r conven
ience a
nd 1
0 a
idcompreh e
nsion.百 l
e no
td isti
nguish
ed,orifth
ef ea
sib
ler e
gionhasnotbeenesta
blis
hedinsomem an
n e
r.
r
ight
-ha
ndsidecan a
lso h
ave n
umeric
al valu
es o
ther1ha
n ze
ro. Th巴 fi
rs
t examp
le
c
hosenfri
o llus
tr
ati
onisas im
pleon E
us i
n gelem
entaryfun
ctio
nsw ho segmp1
2ica
l
n
atur
eiswelk
l nown.Thissimp
lee xamplewil
lp e
rmitexa
rnin
ntiono ftheMATLAB
c
ode白atwilg
l en
crae曲ec
t urve
sa ndthesolu
tio
n.Itwi
llaloa
s l
lowu stod e
fine山E
fo
rmatf
orthedis
p1ayofsol
uti
ontothegraphi
calopti
miza
tionprob
lcm .
1
0
2
.11 Example2
. .1 g

Thefi
rte
s xa
mpl
e,E
xam
ple2
.1,
wilh
l a
vet
woe
qua
liyc
t o
nst
rai
ntsa
ndt
woi
neq
ual
ity
B
con
str
amt
s:

M
ini
miz
e .XI'X2)=(XI-3
f
l )2+(
X2-2
)2 (
2.
5)

S
ubj
cctt
o
: h
l(x
l.X
2):2
x1+x2=8 (
2.6
a)

h2
(x"XU:(
XI-1
)2+(
ゐ -4)2=4 (
2.6
b)

gl(X"X
2):X 2S7
l+x (
2.7
n)

,XU:XI ー 0.25~SO
g2(x. (
2.7
b) 震
芸 3

oSXIS10; OSX2S1
0 (
2.
8)

nt
I heabovedcf
mi1ion,wehavet os
w t
rai
ghtli
ne.t
s wocirc
ls,
e nndapar
abo
la.Note
t
htt
a woequa
litycons回 in
tsa ndtwov ar
iabl
esi m
ply 伽 t出E isno sc
ope f
or

o出凶z at
io. l
n
回 i

n
t
ep
sar
ei
ro
In
b
e
l
e
a
rl
mw
yi
i
l
n
l
d
b
e
e
p
d
e
e
n
d
t
e
c
n
r
t
m
i

n
w
e
h
i
db
c
y
hi
出巴司
stru
ei
u
al
i
nt
1
h
yc
se
i
o
n
x
s
n
t
ra
叩l
r
i
n
e
tspr
o
.Thi
v
se
id
x
a
e
d
mp
t
h
l
e
e
。 2 3 4 5 6 7 s 1
0
twoc
ons 1v
x a
lu国

wa
sα凶 1 d1
e 0helpunde
rstand由巳 cod
cinMA'礼 AB山atw
illbeuse
dtodrawgra
phi
cal
s
olut
iosi
n nthsb
i o o
k. 円g
uro2
.
1 G
rap
hic
als
ol
ut
io
nfo
rEa
xmp
le2
.
1.
48 G
RAP
HIC
ALO
PTI
MIZ
ATI
ON 2
.
2GR
APH
ICA
LSO
LUT
ION 49

Int hegra
phicaldisp
layo fsoluti
ons,only血eo bj
ecti
vef un
ctionisdrawnf o
r m-f
ilef or山ef ir
stexample.Thef o
llowingi nt
r o
ducessomemoreu se
fulI nform姐o n
sev
eralcon
tourssotht白ed
a irect
ionfor白eminimumc anbeiden
tif
ied
.Eachcquali
ty abouttheu seofMATLAB ・
8high-
Ievc
lg raphicsfunctions.
:
.
L
con
str必ntisdrawnasas ing
lec urvefor出en um
ericalv a
lueont herig
ht-
handsid
e. Thetwomaing raphica
le leme
nts白紙 a r
ct ypi
callyc o
ntroll
edu sin
gt hehigh-Ievel
Theyshouldbeiden
tif
ied
.Eachi nequa
litycon
strIn
a tissim
ilar
lydrawnforavalueon grap
hi c
sf u nct
ionsarethefigu陀 andthea xe
s.U singH andleG r
aphicsyouc ancontrol
出er ig
ht-h
andsid
e.Theyn eedtobeident
ifi
cdtoo
.Theh ashmarksar町 lr
awn
/penc
i l
ed mosto fth eothergraphica
le leme
nts,w hichincludeelem 巴ntsusedint h
eGU I.These
inonthefi
gurcoraprin
toutof出e fi
gu陀 .Theext
entofthedcsig
nregioni
sesta
blish
ed oth
ere le mentsa r
et ypica
llyc h
ildrcno f山ea xeso rfigur
e.Thef ig
uref unctiono r
andthesol
utionid
enti
fiedonthefigur
e.Thereleva
ntr e
gioncanbezoomedf o
rbette
r commandc reat
esaf igur
ewindoww ithanumbers tartin
gato ne,orwillcreat巴a new
accu
racy.百四 d a
tafor白 eplotareobtainedus
ingMATLAB'Sm atrixope
rat
ionsafte
r fig
ure window i nc
rementingt he window c ount by o ne.N ormallya l
lg raphics
est
ablis
hin
gt heplolt
ingm e
s h
.Thi se xpl
oit
sMA TI
.AB'Snal
urals p
eedform a
trix fun
ctionsa retarge
tedtot hec町r e
ntf ig
ur芭 window,whichi sselectedbyc lickingit
ope
ratio
ns. wit
ht h
emouseo rexecutingthecommandf igure( number),wh e
r enumberi st he
numbero ft hefigur
ewindow山a lwillh avelhef ocus.AIlcommandsa r eissuedi n
commandwindow.G raphicsf un
ctionso rcommandsw i
lla utom
aticallyc reatea
2
.2 GRAPHICALSOLUTION windowi fn oneexi
sts
.
Invokeh elpcommandnamea tt heMATLABpromptt oknow morea boutt he
MATLABp o
ss凶 sap owerf
ulv isu
aliz
atio
ne nginet h
atp e
rmitsthes olu
tionof白e fun
ctionso rcomrnands.Thewordh andlea pp回路 o nm加 yp l
aぽo rmsandi nmany
two-
variableoptim
izatio
np roblemb yi nspecti
on.T herea r
et hre
ewayst ol ake ap
plications, p
artic
ularlythosetha
td ealwithg ra
phics.Theya r
ew idelypre v
al e
nti n
advanta
geo ft hegraph
icf eat
uresofMA TI.AB
.百 】ef ir
stisl h
eu seo fMA TI.
AB'S obj
ect・orientedprogramming p rac
tice. MA TI
.AB・sv isual
izati
ons yste
mi so bject
hig
h-Iev
elg raph
ingroutin
esf o
rd a
tavisua
liz at
ion.Thiswillbe山巴 p rima
rywayt o or
iented.Mostg raph
icale l
ementsarec onsi
dereda sobject
s.The“h andle"i nMA TI.AB

solv
eg raph
icaloplimi
zationproblemsint hisb ook.Thiswi l
1alsob e出eway10 i
sas y 印 刷o ftwarecreatednumber白紙 c ani dent汀'ythespeci
ficg rap
hico bjectI
. f
inco
rporategrap
hicalexplo
ralionofn ume
r icalt echn
iquesin出eb ook.F ormo 隠
th
isha ndlei savaila
ble,山e np r
oper
tieso ftheo bj
ecls u
cha slin
es ie,
z marke rtype,
pre
cisecontroloverthed i
splayofd a,
a MATLABa
t llowsus巴rintcra
ctio
nt hrough co
lor,an ds oonc anbev iewcd,se
t,orr e
setifneccssary.InMATLAB, Handl eGra p
hic s
programming usingano bjec-
torie
nteds yst e
mi dent
ifie
di n MA T
I.ABa sHandle s出ewayt
i oc us
torni
ze出eg raphi
cale leme
nts.I nhi gh
-Ieve
lg r叩h ic
sf unctions出 s
Graph
ics.Th ethi
rduseoftheMATLABg raphicse ngin
eistou s
et h
eH andleGraphic
s
i
su s
e dinal imi
tedw a
y .Inthi
sc hap
ter,wew illuseiti nam inimalwayt oc hange出E
ch
arac
t c
rist i
cso fsomeo ftheg r
aphicalelementsont hefig
ure.
systemtod e
velopaG r
aphicalUserInter
face( GUI )forth
ep rogramo rm-
file
.Th i
s
To u nd erstandt hec oncepto f" handlcs" we w il
lr u n 出e f oll
o wingc od e
cre
alesafaci
lit
yf o
rsophis
licat
eduserinte
raction.MOSlo ftheplo
ttingneedscanb e
in
ter
actively.Itd ea
lsw ithcreati
ngap lo
t,whichwasi ntrodu
cedi nChapt er1.Th e
melbyt hehigh
-Iev
elgraphic
sf un
ction
sa v
ai lab
leinM ATLAB.
bo
ldfacecommentsi nt h
ec odes egmenti ndica
tet henewf ealur
est ha
ta r
eb ein g
emp
has ized.
2
.2.
1 M
ATL
ABHigh-LevelGraphlcsFunctlons Sta武M ATLABandi nter
acti
veLyperf ormthefollowing:

ceo
aey
eyv
xv
vc
con
tr・
rat
eヒ

et--

rh

0

τ'erearet h
reeu se
fulwindowsd uringat ypic
alMATLABs c
ssio
n.Th efir
stis白e >>X O:pi/40:2*pi;

L
h

cp

ex
rl


也電也電
MATLABCommandwindowt hr
oughwhichMATLABr ecei
vesinst
ruct
ionanddispl
ays >>y X.合 sin(x);

e
c
o
r
D
>> plot(x, y,


'b-');


alphanu
merici nform
ation.百l es econdwindowi sthet e
xl-e
dito
rwindoww here
m-fi
Iesarec o
de d
.Thet hi
rdist h
eF igurewindoww herethegraphi
cel e
mentsare >> grid;
dis
playe
d.T he
r ecanbemore白a nonef ig
urew indo
w.Thef igu
rewindowis出巴 tar
gel >>h plot(x, y,'b-') 者 h is the handle to the plot
ofthehigh-
leve
lg raph
i c
sf u
nctio
ns. > > 告 anewp lot is overwritten in the same figurewindow
Theg raphi
csf unct
ionsinMATLABa llowyout oplotin2Do r3D.Th eyallow >>苦 an umerical value is assigned to h
cont
ourplotsin2Da d3D,
n mesha n
ds uばaωplots, b
ar,ara,
e piechar
ts,
h i
stogra
ms, > > 者 We can use the variable name h or its value
>>告 t o refer to the plot again
animat
ion,andg rad
ientplot
s.S ub
plotsc analsobedisplay
edu s
ingthes
ef un
cti
ons.
Inaddit
iont h
eyp ermitoperati
onw ithimage sand3Dm odeling.Theya l
lowbasic >>
con
trolo fthca ppe
ar阻 ceo fthep l
ott hroughcolo,l
r inestyl
e,andm arkes,蹴i
r s >> set(h, 'LineWidth', 2); も this should make your plot
告 t hickerblue
rang
es,and鎚 pe c
tratioofthegraph.
τ' heypermitannot
ationofthegraphinsev
eral > >

ways.Someo ft he
sef un
ctio
n swil
lb eusedi nthenextsec
tionwhenwed e
vclopthe >> set(h,'LineWidth', 3,'LineStyle',':'
, 'Color','r')
50 GAAPHICALOPTIMIZATION 2
.
2 GAAPHICALSOLUTION 5
1

>>者 The handle is used to refer to the object F


il
e:Ex21.m
>>も whoseproperty is being changed
>>者 Usually Property information occurs in pairs of 者 Chapter 2
: Optimization with MATLAB
>>者 property-namejproperty-value %Dr. P
. Venkataraman
>>も property-value can be a text string or number 者 Example 2_1 (Sec 2.1-2.2)
>> 者
>> get(gca) も this will list the property of the axes もgraphicalsolutionusingMATLAB (twodesignvariables)
>>者 of the curren七 plot. Note there are a significant 毛 the following script should allow the display
>>者 amount of properties you can change to customize 苦 of graphical solution
>>者 the appearance of the plot 苦
>> も Minimize f(x1,
x2) (x1・3)**2 + (x2・2)**2
>> set(gca,'ytick',[
-5ー
,2.5,
0,2.5,
5]) 者 h1(x1,
x2) 2x1 + x2 8
>>告 youhave reset the ytick marks on the graph 者 h2(x1,
x2) (x1-1)^2 + (X2-4)^2 4
>> set(gca,'FontName','
Arial','FontWeight',.
.. 告 gl(X1,
x2) x1 + x2 <= 7
>> 'bold','FontSize',
14) 告 gl(x1,
x2) x1 - 0.25x2^2 <= 0.0
>> 苦
>>者 Changes the font used for marking the axes % 0 <= x1 <= 10 0 <= x2 <= 10
>> set(gca,'Xcolor','blue') 者
>>も c hanges the x-axis to blue も NOTE: The hash marks for the inequality
>> % concludes the demonstration of handles も constraints must be determined and drawn outside
者 of this exercise and on the printout
Fromthese
ssio
na bo
veitisevi
dent白紙 tofin
e-tu
netheplo
tyoucre
ate,you 者ーーーーー---・・白ーーーーーーーーーーー-- ーーーーーーーーーーーーーー"・ー・"ーーーーーー--
n
eedt ofi
rs
tide
nti
fytheobj
ecthand
le.Youu seth
eh an
dletoacc
ess白eo bje
ct x1=0:0.1:10i 者 the semi・colon at the end prevents
p
rop凶 y.Youchangeaprop
ertybysett
ingit
sval
ue.Wew il
lseemoregraph
ics % the echo
f
uncti
ona sweobtai
nt h
eg r
aphi
calsolut
iontoExample2.1in由巳 follow
ing x2=0:0.1:10i 者 these are also the side constraints
s
ectl
on. 者 x1 and x2 are vectors filled with numbers starting
苦 at 0 and ending at 10.0 with values at intervals
告 of 0.1
2
.2.
2 Example2
.1ー-Gr
aph
ica
lSo
lut
ion
[
X1 X2] meshgrid(x1, x2)i
Figu
re2.1istheg rap
hicalr e
presentatio
no fExample2 .
1.Ther angefortheplo
ts 者 generates matrices X1 and X2 corresponding to
matche
st hesidecons
traintsforthep roble
m.Thei n
ters
ectio
no fth
etwoe q
uali
ty % vectors x1 and x2. It is a mesh of x1 and x2 values
者 at which the functions will be evaluated
co
nstra
intsidenti
fie
stwop oss
ibl巴 solut
ionstot h
ep roblem,appro
ximately(2.6,
f1 obj_exl(X1, X2)i告 the objective function is
2.
8)a nd( 1,6 ). The i neq
ualityc onst
raintg 2 makcs thep oint( 2
.6,2 .
8)
者 evaluatedover the entire mesh and stored in f1
una
ccepta
ble.P oint(, 6
1 )isa cc巴ptablewithr e
s p
ecttob othconst
raints
.Thc
者 MATLAB will compute the values for the objective
sol
utio
ni sthereforeat(1, 6).Whilet heo bj
ectivefunctio
nwasn otu sedto
も througha functionm file called obj_exl.m
dete
rminethcsolutio
n, co
ntourso ftheobjec
tivefuncti
onaredrawni n
dicatin
g白巴

ineq1 ineconl(Xl, X2)i 巷 the inequality gl is


di
recti
onfor出eminimumo ftheo bj
ectiv巴func
tion.Thesolutio
nc a
nb eident
ifi
ed
者 evaluatedover the mesh
byinspec
tiono ftheass巴mbledp lot
sw ithoutrefe
r e
ncetot h
et er
minologyorthe ineq2 inecon2(Xl, X2)i 者 the inequality g2 is
tech
niqucsofoptimiz
ation.Recall,however.thatthi
sisonlyp o
ssibl
ew ithoneor も evaluatedo ver the mesh
twodesignvariab
lesint heproblem. eq1 = eqcon1(Xl,
X2)i 者 theequalityh1 isevaluated
Thec odefor血ise x創 n
plei nvolv
ess i
xm -f
ile
s:as cr
iptm-file白紙 willinc
¥ude 者 over the mesh
th
eMATLABs tateme
ntst ocreateandd ispla
y出 ed ata,andfivem-fi1国一onef or eq2= eqco n2(X1,
X2)i 告 theequalityh2 is evaluated
cachfunctio
ni nvo
lvedi n Example2 .1
. Web eginw itht h
es cr
iptm-file- 者 over the mesh
E
x2_
1.m
.
52 GAAPHICALOPTIMIZATION
2
.
2 GAAPHICALSOLUTION 5
3

[C1,han1] contour(χ1,x2,ineq1,[7,7),'r-')i 凪鑑on1.m


も a single contour plot of gl (or ineql) is drawn for
者 thevalue of 7 in red color as a continuous line function retval inecon1(X1,X2)
も duplicationof the contour value is necessary retval X1 + X2i
も ford rawing a single contour も X1,X2 are matrices
者 han1 is the handle to this plot. This handle 者 retval is the value being returned after the
者 canbeusedtochange theplotdisplaycharacteristics 告 computation
告 Cl contains the value of the contour 者 Since X1 and X2 are matrices retva1 is a1so a
告 matrix
clabel(C1,han1)i 者 By this way the entire information on the mesh
も labels the contour with the values in vector C1 者 is generated by a sing1e call to the funcヒion
者 contour(x1,x2,ineq1,[7,
7],'r-') will draw the contour 者 inecon1
告 without labeling the value 凪血血2.m
hold on 告 allowsmultiple plots in the same figure
告 window function retva1 inecon2(X1, X2)
gtext(,gl')i retval Xl - 0.2S*X2.^2i
も will place the string 'gl' on the plot at the spot 者 Note the use of ^ operator for element by e1ement
苦 selectedby a mouse click. This is a text label 告 operation. That is each e1ement of the X2 matrix
者 this procedure is repeated for remaining 者 is squared. Without the dot the imp1ication is a
も constraints 者 matrixmultiplication -between matrices whose
者 innerdimensions must agree. Similar operators are
[C2,han2] contour(x1,
x2,
ineq2,[
0,],
0 ,
'r-ー )i 告 defined for element by element mulヒiplication
clabel(C2,han2)i 者 anddivision
gtext('g2')i 盤姐Lm

[C3,han3] contour(
x1,
x2,
eq1,[8,
8],'b-')i function retval eqcon1(X1,
X2)
clabel(C3,han3)i retval 2.0*Xl + X2i
gtext(,h1')i
魁迎且2.m

[C4,han4] contour(x1,
x2,
eq2,[
4,],
4 'b--')i function retval eqcon2(X1,X2)
clabel(C4,han4)i retval (X1 -1).*(X1 ・ 1
)+ ( X2 - 4).*(
X2 -4
)i
gtext(,h2')i
曲 U叫 掴
[C,han] contour(x1, x2,f1,'g')i function retval obj_ex1(X1,X2)
告 contourof ' f'i s drawn in green color. The number retval = (X1 -3).*(X1 - 3
) +(X2 - 2).合 (
X2・ 2
)i
苦 of contours are decided by the default value
clabel(C,han)i
xlabel('x1 values', 'FontName','times','FontSize',12,
. 2
.2.
3 D
isp
lay
lngtheGraphics
'FontWeigh,
ヒ ,'bold')i も label for x-axes
ylabel('x2values', 'FontName','times','FontSize',
12, Al
1oflhcfi
le
srequ
iredforgr
aphica
ld i
spl
ayoft
hep
roblemhavebee
ncrc
alc
d.Inth
e
'FontWeight', 'bold')i Commandwindow,lypeaddpatbfollowdby出ec
e o
mplel
epathfort
hcdi
rec
tor
y山at
grid ho
ldsthes
efil
es
.Att hep rompt,typ
et h
cnameofth
cs c
rip
tf i
lefo
rtheexamp
le
hold off wi
thou
tthe.meXlen
sion
Thef
unc
tinm-f
o i
Iesa
re
: >> Ex
21
54 GRAPHICALOPTIMIZAnON 2
.2 GRAPHICALSOLUTION 55

Thef i
rstcontou
rp l
otw i
lla pp
ear.Movet hemouseo verto白ep l o
ta ndac ros
sh ai
r 1
0
app
ears.C l
ickingont heplotwi1lplac巴thest
ring"gl"att hecrosshai
r.Thes e c
ond
contourplo
ts houl
da ppearandt her
eisap ausetoplac
巴出et e
xtlabe.
lA f
terthef ou
r
cons住aint
s,出eo bj
ectivefunct
ionisplott
edforseve
ralcontourvalues
.F in
allytheplo
t
shouldapp伺 rωinF igure2.1w ith
outtheh a
shm arks( a
n dwi山 y ourchoiceof白B
loc
ationforcons
traintlab
els)
.Youc anins
ertthehashmark sthrougheditin
gt h
ep lo
t
di
rectl
y(V ersin5.
o 3onw 釘ds).明記 s olut
ionforthepro blemisat,1
(6 ),wheref ou
r
pl
otsinters
ec.
tThev a l
ueo ftheobjec
tivefunc
tionis20鉱 山es ol
ution.
Iftheplotisacce
p ta
ble,youc anpri
nttheinform
alionont hefigurebyexpo 凶n gi
t



(us
inga nappropr
iatee xtens
ion)1 0af ileandl at
eri ncorpo
ratingiti na nothe
r

=官
、,J
tYouc ana

広説
documen . l
sos enditto出ep r
inte
rf romIheprintcommandont heF il
e
menu.T ypinghelppr i
ntint h
eCommandwindows h
ouldiIstasetofcommandsyou
canuset osave曲ef i
le.

>> print -depsc2 plot_ex_2_1.eps

wi1
lc路 a
tethelev
el2c o
lorpost
scr
iptfil
ecall
edplocex_2_l
.ep
sinthework
ing
di
rec
tor
y.Ac omp
letepat
hnames houl
ds a
vethefi
leto白espec
ifi
edd
ire
cto
ry.You
canthenexec
utestan
dardoper
atingsystemcommands1 0dumpthefil
c10出e
ap
plic
abl巴p
rin
tcr
.Youc anals
os av
et h
efigu
re(ex蜘 sio
n.fi
g)andl
at
eropeni
tin 。
。 2 4 6 s 1
0
MATLABusi
ngthefi
lcopencommandfrommenub 釘 ort
oolba
r. Xva
lue
s
1

2
.2.
4 CustomlzlngtheFlgure lg
F u
re2.2 C
ust
omi
zed両
日U悶 f
orE
姐 m
ple2
.1
.

I
nt hi
ss ec
tionthcb asicfigur
ea ndplo
tsc rea
tcda bov巴 wil
Ib ec us
t or
nizcdusingt h
e
gt儲 t('gl');
HandleGraphicscommandsf ir
stexplo陀d inS巴cti
on2 .
2.1.A llofthep l
otsdesc
rib i
ng
k1 gtext(, gl');告 k1 is thehandle tothe text element
白ec on
strai
ntswillh a veal i
newidt
ho f2p oi
nts.百l eob j
e c
tivef u
nctionwillha vea
set(k1,'FontName', 'Times','FontWeight','bold',
lin
ewidthof1p oint
.Thet ex
tlabeswi
l 1
lbei nthe"Tim es"font.ItwilIbeinb o
ldface
,FontSize', 14,'Color','red')
wit
haf ontofsize1 4a ndin白ec olorofthecons回 in.
tTh ex叩 dYt ic
kmarksw i
l lbe
changedtoe s
tablishab r
oadergri.Th
d ex叩 dyl abe
1sw illi nc
ludeas ubscri
p .
tA
..clabel(C2,
han2}i
two-rowtextwi1
lbei nser
tedatthepoin
ts ele
ctedthrought hemou s
c .Thencwf i gu
re set(han2,'LineWidth',2)
i
sshowni nF igu
rc2 .2. k2 = gtext('g2');
Firt∞pyt
s hefilein出ep re
viousexercis
ea ndrena meit.羽lerenamedf i
lewi
l lbe set(k2,'FontName','Times','FontWeight','bold',
usedωmakethen 配 e ssarych
佃 gesto出ec o
de.Th e
sec han g
esi nc
1udeb othnewc ode ,FontSize',14,'Color','red')
aswe la
I sre p
lacemen tofexist
ingline
so fcode.In出ef oI
lowingo nly白ec hangesto clabel(C3,
han3);
出巴c odearei1
Iustrated.Th eori
gina
lc odeisshowni nt h
ei ta
licstyleandi d
entifi
ed set(han3,'LineWidth',2)
wit
ht hr
eeellip
sisp o
ints(.. .
)at出巴 beginningoftheline.Thec odetobei n
sertedor k3 ~ gtext('h1');
rep
l a
cementcodei sshowni nnorm 叫styl巴.I
fnoreplacemcnti sa pp
ar e
nt,thentheold set(k3,'FontName','Times','FontWeight','bold',
codeisused10d e
f inethelocat
ionswhe 回 目ew∞d eisa ppended. 'FontSize',14,'Color','blue')
clabel(C4,
han4);
{Cl,
hanl} contour(xl,
x2,
ineql,{7,7},'r-'};
set(han1,'LineWidth',2); 者 sets 1ine width of the gl set(han4,,LineWidth',
2)
も contour to 2 points k4 ~ gtext('h2');
56 GRAPHICALOPTIMIZATION 2
.3 ADDlTIONALEXAMPLES 57

set(k4, 'FontName','Times', 'FontWeighヒ 'bo1d', !


(xI'X2)= 町î+bx~ 一 cco中川)ー d c
os(
qx -c+d (
2.9
)
2)-
1
,FontSize', 14,'Co1or', 'b1ue')
c:label(C,han);
w
ith
set(han, 'LineWidth',1)
.. xlabel( ,xl values', ,FontName','times',
x1abe1(' x 1 va1ues','FontName','times',,FontSize',
12,
. a=,
1b= c=
2, 0
. d=
3, 0
.4p=
, π,
3 q=4π
,FontWeight', 'bo1d')i
y1abe1(' x 2 values', 'FontName', 'times',' Fig
urcs2.
3-2.7ar宮 山eg ra
phic
aldispl
ayofsolu
tion
s泊 出issect
ion
.Thef ig
ure
sin
FontSize', 12,'FontWeight', 'bo1d')i th
ebookbein
gr e
s凶c tedtoblac
ka n
dw h
itewi
llnot∞n v
ey也 eimp
actofcol
orima
ges
set(gca, ,xtick',[0 2 4 6 8 10]) 者 set xticks youwil
lseeont hes c
ree
n.Thc rearetwofi
lesass
ocia
tcdwit
ht h
eplot
s:thesc
rip
t
seヒ(gca, 'ytick',[0 2.5 5.0 7.5 10]) 昔 set yticks m-f
iIe(e
x2.
-2.
m )andt h
cf un
ctinm-f
o iIe(o
bLex2.m
).
k5 gtext({'Chapter 2 : Examp1e 1 ',
'pretty graphical display'}) 盟主..z.m
者 the above gtext describes a string array
も string array i s defined using curly braces 者 Chapter 2: Optimization with MATLAB
set(k5, 'FontName','Times', 'FontSize',12, 者 Dr. P.Venkataraman
,Fontweight', 'bo1d') 者 Examp1e 2.2 Sec.2.3.1

(at the end)
c1ear C C1 C2 C3 C4 h h1 h2 h3 h4 k1 k2 k3 k4 k5
壱 get rid of variab1es from the workspace 間1
1
ωIA
bc l
o
dCo
nl凹 g
d
ef
au
llc
Glc
r
Runtheprog
rar
ntosec曲ef i
gur
einF i
g山 宮 2
.2
.Oncet heplo
tiscustomIzedtoyour
sa
tis
fac
tio
n,youcanmakei
t白巴 sta
ndardforoth
erplot
syouwillpr吋 U四 inMA 礼As.
Th
isfil
ecouldal
sobeatempl
ateforgene
ralcontourpl
ott
ing
.N ot
e白a ta lf
1 unct
ion
in
forma
tionisob
tain
edthro
ughfunct
ionm-fi
I e
sw hic
ha r
ec od
edo uts
idethescri
pt
f
il
c.S c
tti
ngupncwp rob
lemsore xamplcso nl
yr equ
ire
sa dding
l c
hangin
gnew
fu
ncti
onm- f
i
1ω.

2
.3 ADDITIONALEXAMPLES

明岨固岡田、,
Thef01
l0wingadd
itio
nalex 創npleswi
lls erv
etoiI
lus回 tebo
白o ptim
izat
ionproble
ms鎚
wel
lasaddit
ion
algmphicalfcat
u r
esofM ATLA白血atwillbeus
efulind巴v
elopin
ggrap
hica
l
sol
uti
onstoopt
imizat
ionp rob
lems.明 lCgrョphi
calrouti
nesi
nMATLABa repower
ful叩 d
回SYtouse.Theyc ng
a rョp
, hica
llyd i
splaytheproble
ms副 総v em1waysw i白verysimp
lc
∞mm阻 d s.Theusefu
ld is
playis,however,detcn
ninedby血eu se
r.Thefir
stexamp
lein
th
issect
ion,Example2 .2,isap ro
bl eminu ncon
s回i nedopt泊前回t i
on.明記 s eco
nd
cxampl
eisastru
ctum1enginee
ringprob lcmofrea
sonabl
ccompl
cxity
.百l C白 凶 ex
ar即Ic
demons回 飽sopti
mizat
ionint h
ca re
ao fheatIa
rnsf
crdcsi
gn.

2
.3.
1 Example2
.2
-
0.5 O 0.
5
Th
iscxamp
lciI
Ius位置tss
e cvc
raldi
ffc
rentwaysofg
mphic
aUydisp
layin
gafu
nct
iono
f Xv
J
alu

twov
ari
abl
es.Thep r
oblemwasuscdtoiI
Ius
lra
teg
lob
alopt
imi
zatio
ninRe
fere
nce3
.
Thes
ing
lcobjc
cti
v efun
cti
onis 円g
u開 2
.3F
il
le
dco
nlo
ursw
it
hco
lor
ba.
rEx
amp
le2
.2
.
58 T
GRAPHICALOPTIMIZAlON 2
.3 AOOmONALEXAMPLES 59
2DCon随 町
w
ithGr
ndi
.nlV,酎:10悶
82-gJ

.
-05 o 0
.5
Xv a
lue
s !V剖u
X
: es -
1
1 X1v
alu
es
円g
ure2
.4 C
ont
ourw
lt
hgr
adl
entv
ec
to
rs
:Exa
mpl
e2.
2. F
lgu
re2
.5 3Dc
onl
ourw
ih∞l
l or
barE
. x
創 叩l
e2
.2
.

graphicalsolutionusingMATLAB (twodesignvariables)

f1 obj_ex2(X1,
X2); the objective function is

もUnconstrained function illustrating global minimum 1

書y't
. evaluated over the entire mesh

も Example will introduce 3D plots,3D contours,filled 者 filled contour with default colormap
も 2D contours with gradient information 者 helpgraph3d gives you the choices for colormap
者・ーーーー・・・・・・ーーー・ー・ーーーーーーーーーー------・ーーーーーーーーー------ーー-- [C1,han11 contourf(x1,x2,f1,
x1=・1:0.01:1; the semi-colon at the end prevents
も [0 0.1 0.6 0.8 1.0 1.2 1.5 1.8 2.0 2.4 2.6 2.8 3.01);
" the echo
x2=-1:0.01:1i 巷 these are also the side constraints 者 specific contour levels indicated above
者 x1 andx2 are vectors fil1edwith numbers starting clabel(Cl,hanl);
苦 at -1 and ending at 1.0 withvalues at intervals of colorbar 告 il1ustrates the default color scale
者 0.01 set(gca,'xtick',[ -
1 -0.5 0.0 0.5 1.01) も custom ticks
set(gca,'ytick',[・1 -0.5 0.0 0.5 1.01) 者 custom ticks
[Xl x21 = meshgrid(x1,x2); grid
者 generates matrices X1 and X2 corresponding xlabel(' X_1 values','FontName','times',
者 vectors x1 and x2 'FontSize',12);
者 reminder MAT工~ is case sensitive % label for x-axes
ylabel(' x 2 values','FontName','times',
60 GRAPHICALOPTIMIZATION 2
.3 ADOmONALEXAMPlES 6
1

CO
!U
'SCMeshP
101 C
oa。S
問 ur
fa
ceP
lo
t
ω
lor
map・目。1 ∞lon
nn
p-j
cVd
ef
nu
lt

4
4

3
.5 3
.5
3
3
2
.5
2
.6
2 2
2
1
.5
.
15
1
.5

0
.
5
a
m
w
u

0
u

0
.
5
0
.6
。 。 0
.
5
心5
0.
. 5

v
x
X va
lue
s -
1 -
1


-
1 -
1

a
X va
lue
s

HM
2 Xv a
lu凶 2
1

F
lgu
re2
.6 3Dm
eshp
lo
twl
thc
ol
or
ba
r:E
xam
pl自2
.2
. F
lgu
re2
.7 3Ds
u巾 ω
plo
twi
thd
efa
ultc
olo
rb:
arE
xam
ple2
.2
.

clabel(C2, han2)

FontSize',
12);
[GX,GY] gradient(f2,0.2);
title({'Filled Labelled Contour',
'...
default color map'},'FontName',ヒ
,imes',
'FontSize',
10) % generation of gradient information see help gradient
hold on 者 mulヒiple ploヒs on the same figure
quiver(Y1, Y2,GX,GY);
者 a new figure is used to draw the
者 d raws the gradient vectors at grid points
も basic contour plot superimposed with gradient
も see help q uiver
告 information
告 also information is generatedon a coarser mesh to hold off
者 keep the figure tidy. grid is removed for clarity set(gca, 'xtick',[-1 -0.5 0.0 0.5 1.0])
set(gca, 'ytick',[-1 -0.5 0.0 0.5 1.0])
figure 告 a new figure window is drawn xlabel(' x_1 values', 'FontName','times',
y1 -1:0.1:1.0;
,FontSize',12);
ylabel(' x 2 values', 'FontName','
ヒ imes',
y2 ー1 :0.1:1;
'FontSize',12);
[Y1,Y2] meshgrid(y1,y2);
f2 obj_ex2(Yl, Y2); title({'2D Contour', 'with Gradient Vectors'},
[C2,han2] contour(y1,y2,f2,
,FontName','times','FontSize',10)
[
0 0.5 0.75 1.0 1.5 1.75 2.0 2.5 3.0]);
6
2 G
RAP
HIC
ALO
PTI
MIZ
ATlON 2
.
3AO
Orr
tON
ALE
XAM
PLE
S 63

も A final example of contour information is a 3D ,FontSize',12);


% contour plot -or a stacked contour plot ylabel(' x_2 values','FontName','times',
figure ,FontSize',12);
colormap(spring) set(gca,'xtick',[-1 -0.5 0.0 0.5 l.0])
contour3(x1,x2,f1, set(gca,'ytick',1-1 -0,5・0.0 0.5 l.0])
[
0 0.3 0.6 0.8 1.0 1.5 1.8 2.0 2.4 2.6 2.8 3.0]); title({'Coarse Surface Plot'‘
,colormap -jet/
set(gca,'xtick',[-1 ・ 0.5 0.0 0.5 1.0]) default'},'FontName','times','FontSize',
10)
set(gca,'ytick',[-1 -0.5 0.0 0.5 l.0 ])
grid
も change colormap and set colorbar
者 changing color for display is easy by selecting Q祉 s謡.m
者 among some colormaps providedby MATLAB
function retval obj_ex1(X1,
X2)
colorbar
も Optimizationwith MATLAB
xlabel(' x 1 values','FontName','times',
者 Dr. P.Venkataraman
,FontSize',12);
者 Chapter2 . Example 2.2
ylabel(' x 2 values','FontName','times', ...

,FontSize',12);
も f(x1,x2) ョ a*xl""
2 + b*x2^2 ・c合 cos(aa*x1)ー
tiヒle({'Stacked (3D) Contour', :colormap -spring'},
も d*cos(bb*x2)...
,FontName','times','FontSize', 10)
も+c+ d
grid a"'1 ; b 2・ c 0.3; d " ' 0.4; aa
苦ヒ he next two figures w
i.l
l display 3D plots 3.0*pi; bb 4.0*pi;
者 ヒ he first is a meshplot of the function 者 notematrix operations need a dot operator
者 oncemore coarse data is used for clarity retval a*X1.*X1 + b*X2.*X2 -c*cos(aa*X1) ー
figure d*cos(bb*X2) + c + d;
colormap(cool) 苦 anothercolormap
Theb
rie
fcommentsi
nth
eco
des
hou
ldp
rov
idea
nex
pla
nat
iono
fwh
aty
ous
eeo
n
mesh(y1,y2,f2) 者 using information generated earlier
巳f
由 i
gu
re
.Fi
gur
esc
anbef
urt
herc
ust
orn
ize
dass
ecni
n血ep
rev
iou
sse
cti
on.Froma
n
set(gca,'xtick',[-1 -0.5 0.0 0.5 l.0])
set(gca,'ytick',[-1 ・0.5 0.0 0.5 1.0]) op
tir
nizat
ionperspe
ctive,F
igure2.4p rovidesthcbestinf o
nnationabou
tt hcnatu
reo f
colorbar th
eproblem.The2Dc ont
ourcurvesi den
tifythene ighborhoodofthe10伺 lrnin
imum .
xlabel(' x 1 values','FontName','times', 百legradi
entvectorsind
icatc山巴 directio
no f出ef unct
ionss te
epes
trisea1出巴 poin,t
,FontSize',12); so戸 松sa ndv al
lcyscanb cdistingui
shcd.Thec o ntou悶 thern
selve
sc anb ecolo
re d
ylabel(' x_2 values','FontName','times',... wit
houtbeingfil
lcd
.
,FontSize',12); Thcq u
iverp l
p1showni nF igure2. 4alsop ro
v i
d e
sam echan i
sm1 0indic
ate白e
title({'Coarse Mesh Plot','colormap -cool'}, fe
asi
bler e
g i
onwhend ealingwi thi neq
ualityco n
straint
ss incct h
eyi ndic
atc出e
,FontName','times','FontSize',10) di
rec
tioninwhi c
h由巳 c o
nstrai
ntf uncti
onwi Ii
I n
cr,伺se
.I fsever
alfunctio
nsa r
ebcin g
合司wn ,白ent hccIut
terprodu田 db y白ea rrowsmaydぜf use白ec Iar
it
y.Th eu s
eri s
grid enc
ouragcd10usethe.pow
erfulgraphicalfeatu
resofMATLABt ohisbene
fitatal
lt i
me s
者 ヒhe final plot in this series wit
houtlosin
gs igh
to f出eo bje
ctiveo fhisc f
for
t.MATLABg ra
phicshasmanym or e
者surfaceplot with default colormap fe
atu
resthanwillbec over
e din出i sc h
aptc
r.Thee x p
os 山冠 inth
ischaptershouldb c
figure su
ffi
ci
entfor血E隠晶d e
rωconfiden
t lyexplor
emanyo therusefu
lg r
aphω ∞m
i mands.
colormap(jeヒ} Thc3Dmesha n
ds ur
faceplo
tsh avel i
mitedusefulne
ss.Th eseplo
tsc anbeuscdt o
surf(y1,y2,f2) 告 usingold information re
info
rcesomeo fthefea
turesfoundi nFigure2.4
.Thei nfonnat
ionintheseplot
smay
colorbar beimprovedbych o
osingac ameraangle白紙 emph ぉlZCS釦me aspe
ctoftheg r
aphi回 I
xlabel(' x 1 values','FontName','times',
. de
scr
ipti
on.Thise x
plora
tionisle
ftt o出C陀 a derasa nexerc
ise.Usinghelpv ie
wint he
MATLABCommandwindows hou
l dgety oustart
cdi n出isd i陀cti
on.
64 GRAPHICALO
PTI
MIZ
ATI
ON 2
.3A
DDI
TIO
NALEXAMPLES 65

2
.3.
2 Example2
.3 Y(
' m
ater
iaJde
nsi
ty)
:7860kglm3

FS(fa
cto
rofsaf
ety
):2.5
百l
ene
xte
xam
plei
sacomplexonefroms
tru
ctu
rale
ngi
nee
rin
gde
sig
n白紙 i
sre
lev
ant g(g
ravi
tat
ion
alacc
ele
rati
on)=9.1m
8 l
s2
i
ncivil
lmech
anica
llaero
spacecngin田 ri
ngapp
lica
tion
s.Ita ppea
redasap ro
blcmin
R
eferc
nce4.Itisdcvelopedindet
ailhere
.Thep roblemistor ed
esignthebasi
ctal
l F
ort
hea
cro
dyn
ami
cca
lcu
lat
ion
sth
efo
llo
win
gar
eco
nsi
der
ed:
f
lag
polcinviewoft h
ephe no
m e
nali ncr
easci
nwinds pcedsduringextremeweathe
r
c
ond
itio
ns.Inr e
centcatas
佐'Oph
ice ven
ts.thewinds p田 d
si nt omad
o cshaveb cc
n p(st
anda
rdairde
nsit
y):1.2
2 5kglm3
m
easuredatove
r350m ilesperhour
.Th esehig
hs pe
cdsapp 伺 rt
ob ethenormr a
ther Cd(合唱 coe
ffic
ientofcy
lin
der):1.0
曲叩佃 u nusualcven.
t Wp(fl
agwindloadat8m):5000N
Vw(windsp
eed):350mph( 156.6m
4 ls
)
DeslgnProblem: Minimizethemasso fas tand
ardIO-m tubu
larfla
gpol
ct o
wit
hsta
ndwindgust
sof350m il
esperho
ur.Thef lag
poewi
l ¥lbemadeofstru
ctu
ral Thegeome
凶 cp
ara
met
ersa
rな

s
tee.
lUseafact
orofsa
fetyof2.
5for白cs t
ruc
turJd
a e
sig
n.百 lCde
fle
ctio
nofthetop
ofthef
lag
pol
es h
ouldno
te x
ceed5cm.Thep rob
le mi
sdesc
ribedinFig
ure2.
8. L
p
:thelocationofflagwindload(
8m)
L:len
g白o f
thepol
巴(10m)
Ol
I
l:
lperm
iUedde
flec
tio
n(5cm)
MathematicalModel: The mathem
atical modcl isd ev
elope
di nd etai
lf or
comp
leten
cssandt oprovid
ear c
viewo fusefu
ls 凶 ct
ura
l( 5
)a nda e
r o
dynamic
re
lati
ons[6
).Therel
ati
onsareex
prcssedinori
gin
als y
mbolsrat
herthaninstand
ard DeslgnV
al俗b
i l
es:Thed
esi
gnv
ari
abl
esshowni
nFi
g2.
8ar
e
for
matofopti
miza
tionprob
lemstoprovid
ea nins
igh
tintoprobl
emf o
rmul
ation.
do:ou
tsid
ediam
eter(X)[N
I ot:x
e '
sar
eno
tus
edi
n山em
ode
l]
dj:i
nsi
dedia
meter(
.x
2)
DeslgnParameters:Thcs
tnl
ctu
cals
tce
l[5
]ha
sth
efol
1owingm
ate
ria
lco
nst
ant
s:

E( mo
dulusofcl
ast
ici
ty)
:200E叫 9Pa GeometricRe 伺u on
s:Th ef
ol
1owingr
elation
swil
lb eus
efuli
nlat
ercJc
a u
lat
ion
s:
σ
011(all
owabl
cnormaJs岡崎):250E+06Pa A:areaofcross
却 ctio
n=0 .25吋 *(d~-df)
1
:01(a
llowa
blesh
carstr
ess
):14
5 E+06Pa :d
1 iame甘i
calmomento fin
ert
ia=π* (d~ -dt)/
64
Ql
t:f i
rs
tmomcnto fareaabovet
hene
utral蹴 isdiv
ide
db yth
ick
ness
=(d~ +dodi+dr)/6

Obj
ectiveF
unc
tio
n: Theo
bje
cti
vef
unc
tio
nist
hew巴i
ghto
fth
e IO-mu
nif
orm
f
lagp
ole
:

8m

A
10m

。s
8ct
lonA・,A
Constra
ca
Icula
te
的t
da
s
Fu
nct
ion
s:・百l
Weight

Fo=0
.
:

ewind l
o
j
{

5*
xl

dp
e

P*
ru
n

V~
:L*
'X2)

i
A*

tl
en
Y*
'

g
t
g

h (F
D) o

*Cd*do
nt
hef
lag
pol
eis
(
2.1
0)

Thcbend
ingmomenta
tth
eba
seo
fth
epo
led
uet
o白i
sun
ifo
rmwindl
oadont
hee
nti問
pol
eis

円g
ure2
.8 F
lag
pol
ede
slg
n:E
xam
pla2
.3
. Mw=0.5*Fo L*L・


f

66 G
RAP
HIC
ALO
PTI
MIZ
ATI
ON 2
.3A
ODI
TIO
NALE
XAM
PLE
S 67

Th
ebe
ndi
ngmomentduet
oth
ewindl
oadont
hef
1agi
s Tod
isc
our
ages
olu
tio
nswheredo<d
,j wew
illi
ncl
udeag
eom
etr
icc
ons
tra
int
:

M~= W
F-""n
""
P'L_
D
AJ ,
84(X1X2
) 。
d,ー叫ミ 0.001 2.
( 14
)

Bending(
non
nal
)st
res
satt
heb
aseo
f白 ep
olei
s
S
ideC
ons
tra
int
s:・百l
i
sde
fin
est
hed
esi
gnr
egi
onf
ort
hes
ear
ch.
σ
'b
cd=
n 0
. l
5ホ (Mw+MF)場 di

Nonnals
位es
sduet
oth
ewe
igh
tis 2cmSdoS1
00cm; 2cmSdiS100cm (
2.1
5)

σ
wei
ght='
Y事 g地 L
MATLABC ode:The m -filesf ort his example a reg ivenb elow. An i mp
o r
tant
Tota
1nonna1sU芭sse
st oberesi
ste
dfordesig
ni s白esumo f由巳 nonna
1s t
res
ses observ
a t
ioni n出isproblem ,ands t
r u
ctur
ale ngineerin
gp robl e
msi nparticula
r, i
s白巴
computedabo
ve.Incor
por
ati
ngt hefa
cto
ro fsaf
etyandtea
h 1lo
wablest
res
sf rom ordero fm agnitudeo ft h
eq u
antitiesint hec on
straining珂 u ation
s.百l es tre
ss
mate
ria1va
1us,
e th
efir
stin
叫u a
1ity∞nsU湿in
tcanbesetupa
s coos釘泊n t
sa reof出 eordero f108 +06, w
hi l
et hedisplacemeotl ennsareo f山eo r
der
of1 08-0
2.Mostn umerica
1t echniquess凶 g gletoh and
l ethisrang
e.T yp ica
1ly,such
problems0田 dt obenonna 1ize
db efor
eb eiogs oIved'Iti se s
sentia
1i na p
p l
ying
gl(XI'~): σbcnd +
σwc
igh
tSσ
nUI
FS (
2.1
1)
numericalt e
chniqu
esu s
e dino p
timization
.
Thi
sexamplei sp l
ottedintwop紅 1 5.Int h
ef i
rstpart,eachi ne
qua1ityCOI首位置i n
tis
Themaximums
hea
rlo
adi
nth
ecr
osss
ect
ioni
s
inves
tigateda1on
e.Twoc urv
e sareshowlIf o
re achcons甘凶 nt.Thisav oidsclu
tte
r.τ'he
sideforthelocat
ionoftheh a
s hmark00t heconst
raintisd e
te nnin
edbyd rawingt he
se
s=WF+Fo"
'L C町 Vωinc olo
r.百l ebluec olorindicate
st hef e
asibled i
rectio
n.A ltemate l
y,quiver
plo
tsc anb eused
.Thes e c
ondp ar
ti s山ec onsolidatedcurves hown.Thec onsolid
ated
Themaximums
hea
rst
res
sint
hep
olei
s curveh ast ob edrawn by r emovingt he comments on someoft hec ode加 d
commentingt he∞de出a tisn otneeded.S ince出eo ptima
1s olut
ionc annotbec 1ear
ly
τ=S*QI(I 取 t
) estab
lished,山巴 zoomf e
a t
ureofMATLABi su sedton arrowdownt hes olut
ion.

Th
ese
con
din
equa
1i
tyc
ons
tra
intbωedonh
and
lin
g由e油 田rs
tre
sse
sint
hef
1agpole 皐
芯2.
:.J
...
.且ー(the main script file)
1
8 も Chapter 2: Optimizaヒion with MATLAB
も Dr. P.Venkataraman
g2(X ,,~): τgτ:aIJIFS (
2.1
2) も Example 2.3 Sec.2.3

百lethi
rdpr
act
ica
1co
ost
raio
tisbase
d00thedef
1e
cti
ooo
fth
eto
pof血ep
ole
.τ'
his も graphicalsolutionu6ingMATLAB (twodesignvariables)
d巴f
lec
tio
oduetoaun
ifonnwindl
oadont
hepo
l ei
s 苦 Optimal design of a Flag Pole for high winds
告 Ref. 2.4
w=Fo
o 0
1
<
4
L/
(8場 E*乃 者ーー'・ーーー・岨ー・ーーーー----・ーー・ーーー・ーー・ー司司・・ーーーー-----ーーーーー・・"
も global statement is used to share same information
f
Thede1e
cti
ona
tth
eto
pduet
otef
h 1agwindl
oa tらi
da s % between various m-files
global ELAS SIGALL TAUALL GAM FS GRAV
global RHO CD FLAGW SPEED LP L DELT
=2ゆ WF'
OF ( 市3
"L _ WF L'
"L"
'Lp
)/(
E'"
乃 も-ー----------ーー・・・ーーーーーーーーー"・・ー-ーー・ーーー----ーーーーーーーーーーー"
も Initialize values
Thet
hir
dco
ost
rai
ott
ran
sla
test
o
ELAS 200e+09i も Modulus of elasticity -Pa
SIGALL = 250E+06i % allowab工e normal stress -Pa
C3(X1X2)
・ o
w+OFSO.u (
2.1
3) TAUALL =145e+06i 告 allowable shear stress - Pa
I l i 叩 肺 判 明 判 明 附 問 問 削7
l 岬 榊 糊 州 側 刷 叫 州 出 印 刷 山 品 川I
I
I剛山市酔 一 一 一 1
E

68 G
RAP
HICAlOPTIMIZATION 2
.3 ADDITIONALE
XAM
PLE
S 69

GAM= 7860; 者 densityof material ・ kg/m3 ylabel{'inside diameter','FontName','times',


FS 2.5; % factor of safety ,FontSize',12)
GRAV 9.81; 告 gravitational acceleration grid
者ーーーーーー・ーーーーーーーーーーー- 告 hold on
RHO l.225; 者 density of air ・ kg/m3
CD l.0 ; % drag coefficient figure も a new figure window
FLAGW 5000; 者 concentrated load on flag -N contour{x1,x2,ineq1,[glval,glval],'r-');
SPEED 156.46; 老 町I
/S hold on
者ーーー"ー同情ー・ーーーーーーーーー- も draw another contour at 10者 the constraint boundary
LP 8; 者 location of drag load on flag -m contour{x1,x2,ineq1,[O.l*glval,O.l*glval],'b-');
L 10; も lengthof pole set{gca,'xtick',[0 0.2 0.4 0.6 0.8 l.O])
DELT 0.05; 者 allowable deflection - m set{gca,'ytick',[0 0.2 0.4 0.6 0.8 l.O])
告ー-ーー・ーーーーーーーーーーーー- xlabel{'outside diameter','FontName','times','...
glval SIGALL/FS も right hand side values FontSize',12);
g2val TAUALL/FS 告 for the constraints ylabel{'inside diameter','FontName','times','.
g3val DELT FontSize',12);
g4val 0.001 hold off
者--喧・--ー・・ー・ーーーーーーー'ーーーーーーーーー司ー・ーーーーーーーーーーー-ーーーーー----- grid
x工田 0.02:0.01:1; 者 the semi-colon at the end prevents
告 t he echo も the following code maybe usefu1 for the consolidated
x2=0.025:0.01:1; 告 these are also the side consヒraints 者 figure. Not used here __ uncomment below
t x1 and x2 are vectors filled with numbers 者 [C2,han2] contour{x1, x2, ineq1,[glval,glval],'r-');
も note a way to avoid x1 x2 者 clabel{C2, han2);
[X1 X2] meshgrid{x1,x2); 者 set{h2, 'Linewidth',1)
宅 generates matrices X1 and X2 corresponding to 苦 k2 gtext('gl');
も vectors x1 and x2 者 set{k2,'FontName','Times','FontWeight','bold',.
者 FontSize', 14,
奄, Color',,red')
f1 obj_ex3(X1, X2);
者 the objective function is evaluated over the entire figure
者 mesh contour(x1, x2,ineq2,[g2val,g2val],'r-');
hold on
者 Constraints are evaluated contour(x1, x2,ineq2,[0.1*g2val,0.1*g2val],,b-');
ineq1 ineq1_ex3{X1, X2); set{gca, 'xtick',[O 0.2 0.4 0.6 0.8 l.0))
ineq2 ineq2_ex3(X1, X2); set{gca, 'ytick',[0 0.2 0.4 0.6 0.8 l.0))
ineq3 ineq3_ex3{X1,X2); xlabel{'outside diameter', 'FontName','times',
ineq4 ineq4_ex3(X1,X2); ,FontSize', 12);
ylabel{'inside diameter', 'FontName',
[C1,han1] contour{xl,x2,f1,[0,10000,50000, 'times', 'FontSize', 12);
100000, 150000, 200000,250000,300000],'g-'); hold off
clabel(C1,han1); grid
set(gca,'xtick',[0 0.2 0.4 0.6 0.8 l.O])
set(gca,'ytick',[0 0.2 0.4 0.6 0.8 1.0)) 者[
C3,
han3] contour(x1,
x2,ineq2,[g2val,
g2val],'r--');
xlabel('outside diameter','FontName','times', 者clabel{C3,
han3);
,FontSize',12); もset(h3,'LineWidth',
1)
70 G
RAP
HIC
ALO
PTI
MIZ
ATI
ON 2
.3A
OOI
TIO
NALE
XAM
PLE
S 7
1

者k3 gtext('g2');
者seヒ(k3,'FontName','Times','FontWeight','bold', も the equality and in~quality constraints are
, FontSize',
も 14,'Color','red') も not written with 0 on the right hand side.
もIf you do write them that way you would have t 。
figure 者 0,
include [ 0
] in the contour commands
contour(x1,X2,ineq3,[g3val,g3val],'r-');
hold on 1neal ex3
.
.
..m (the first constraint)
.
contour(xl,x2,ineq3,[0.1*g3val,0.1*g3val],'b-'); function retval ineq1_ex3(Xl,X2)
set(gca,'xtick',[
set(gca,'ytick',[
0 0.2 0.4 0.6 0.8 1.0])
0 0.2 0.4 0.6 0.8 1.0])
xlabel('outside diameter','FontName','times',

者 global statement is used to share same information
between various m-files
global ELAS SIGALL TAUALL GAM FS GRAV
,FontSize',12); global RHO CD FLAGW SPEED LP L DELT
ylabel('inside diameter','FontName','times',
,FontSize',12); AREA 0.25* pi*(X1.^2 - X2.^2)i 者 matrix
hold off INERTIA = pi*(X1.^4 ・ X2.^4)!64i 者 matrix
~rid FD 0.5*RHO*SPEED*SPEED*CD*X1i
MW 0.25*FD*L*L.*X1.!INER T1Ai
者 [C4,han4] m contour(x1,x2,ineq3,[g3val,g3val],'b-'); MF 0.5*FLAGW * LP*Xl.!INERT1Ai
者 clabel(C4,han4);
者 set(h4,'LineWidth',1) SIGW GAM合 GRAV*Li
告 k4 = gtext('g3')i
も set(k4,'FontName','Times','FontWeight','bold', retval MW + MF + SIGWi者 SIGW is added to al1 matrix
も, FontSize',14,'Color','blue') % elements

figure 1nea2 ex3.m (the second constraint)


contour(x1,x2,ineq4,[g4val,g4val],'r-')i function retval ineq2_ex3(X1,X2)
hold on 者 global statement is used to share same information
contour(x1,x2,ineq4,[0.001*g4val,0.001*g4val],'b-')i 者 betweenvarious m-files
set(gca,'xtick',[0 0.2 0.4 0.6 0.8 1.0]) global ELA8 8IGALL TAUALL GAM FS GRAV
set(gca,'ytick',[0 0.2 0.4 0.6 0.8 1.0]) global RHO CD FLAGW SPEED LP L DELT
xlabel('outside diameter','FontName','times',
,FontSize',12)i AREA 0.25* pi*(X1.^2 - X2.^2)i
ylabel('inside diameter','FontName','times', INERTIA ~ pi*(X1.^4 - X2.^4)!64i
,FontSize',12); FD 0.5*RHO*SPEED*SPEED*CD*X1;
hold off 8 FLAGW + (FD 合 L)i
grid o (X1.*X1 + X1.*X2 + X2.*X2)!6.0i
retval 8.*0./工NERTIA;
も [C5,han5] contour(xl,
x2,
ineq4,[g4val,
g4val],

者 b--')i ineaヨ白1t:L.m (the third constraint)
も clabel(C5,
han5)i function retval ineq3_ex3(X1,X2)
も set(h5,'LineWidth',1) 者 global statement is used to share same info幻nation
者 k5 gtext('g4')i 者 betweenvarious m-files
者 set(k5,'FontName','Times','FontWeight','bold', global ELAS.S工GALLTAUALL GAM FS GRAV
者, FontSize',14,'Color','blue') global RHO CD FLAGW SPEED LP L DELT
72 G
RAP
HIC
ALo
pnM
IZA
TIO
N 2
.3 AD
DlTI
ONA
LEX
AMP
LES 73

AREA 0.25* pi*(Xl.^2 - X2.^2);


INERTIA pi*(Xl.^4 ・ X2.^4)/64;
FD = 0.5*RHO*SPEED*SPEED*CD*Xl;
dw FD*L^4./(8*E 凶 S合 INERTIA);
df (2.0合 FLAGW*L^3 - FLAGW*L*L*LP)./(ELAS*工NERTIA);

retval dw + df;

in自 白4 ex3.m (the fourth constraint) ,~


function retval ineq4_ex3(Xl,X2)
retval Xl ・ X2;

Figure2.9di
spla
ysthegraph
icalorcons
ol id
atedsol
utionto由巳 pr
oblcm.百le c
odc
i
savaila
ble泊 lhem.fil
ea bov
e( bycommentingt hecode
s白紙 c real
ct h
enewf igur
e
windowsandr emo
vi n
gt h
ecommentsont hecodc白紙 isc ur
rcnt
lycommentcd).Thc
opt
imals o
luti
onisn o
tv eyc
r 1ear
.F igu問 2 .
10iso b
tain巴db yzoominginn e
ar出e
neigh
bor h
oodof0.6.Sechelpz o
o mforin附 ucti
ononi t
su s
e.ltcanbea ch
icvedby

F
1l
lgP
ol
c戸。b
lc
m
0
.5
80.
60.
620
.6
40.
660
.6
80.
70 .72 0.
76 0
.8
out
sid
edia
mCl
cr

ig
F u
re2
.10G
rap
hic
als
olu
tlo
n(z
oom
ed)
:臥 :
amp
le2
.3.
0
.81
- φ

t
ypi
ngzooma
tth
ewo
rks
pac
epromptandu
sin
gth
emouset
odr
agar
ect
ang
lea
rou
nd
曲er egi
onthatn民dstobee n
lar
ged.FromFigu
re2 .1
0出cs olu
tionisarou
ndt h
e
outs
idcdiam
eterof0.
68m 胡 dtll
cinsi
dedi
ameterof0.65m.Typingzoomin出巴
aoa

﹄叫︼

unu

workspa
c eag
ainwi
lltog
gle白 白 伊 回 ba
cktononnaJst
at
e.InFigu
re2.10,山 tic
k
UES唱曲沼包-

marksarepl
acedonth
efigu
rethr
ough出ecommandwindowf orb
cttc
rint
e中肉t a
tio
n
ofthes
olu
tion
.
Theg ra
phicsin由ea boveex副nplewerecre
atedusingthesamestat
emen
ls
enc
ounte
redprev
iou
sly.C
olorco
ntour
swereuse
dtoest
abl
ishth
efeas
ibl
ere
gion.
τhe

zoomfeat
urewasemploy吋 t
oobta
inabet
tcres
tim
atcoftheso
lut
ion
.

2
.3.
3 Example2
.4
0
.2
Thisexampleis合um出ea rcaofheattr
ans
fer
.Thep roblemistodesignatria
ngul
ar
fi
no f白巴 smalle
stvolumet ha
tw i
llatleas
td e
live
rs pe
cific
df i
neffic
ien
cies
.The
gra
phic
alit回 t
u陀 ofthi
sc odeisverysimil
artoExample2 .3
.l n山isc xample,t
he
0
.2 0
.4 0.
6 0
.8 in
equal
itycons
train
tsarecomputedandretumedfromas in
glefunc
tionm.fi
lerath
er
ou
tsi
ded
iam
ele
r
山ans ep
aratcfi
lescon
sideredintheprev
iousexample
.A notherncwf ea
lur
ei nth
is
F
lgu
re2
.9G
rap
hlc
als
ol
ul
io
n:E
xam
ple2
.3
. exampleistoi nvo
kespec
ialm at
hemat
icalf u
ncti
ons,thesesse
If un
ction
st h
ata問
74 GRAPHICALOPT
lMIZATION 2
.3 ADDITIONALEXAMPLES 75

ava
ilab
leinMATLAB.百世sexamplea loi
s I
1us
tr官民sap rob
l e
mwheretheopti
mizat
ion
problemcanbea deq
uatel
yd ef
ine
db utthesolu
tioniseas
ilydet
ermine
df romthe
equ
alit
yands idecons位a
int
s.Inothrwords,
e t
heproblemcaneas
ilyaccommodate
add
itio
naldemandingcon
stra
int
s.Inlar
gecomplcxmathemat
icalmode
lsw i
thmany
dcsi
gnvari
ablcsi
tisnoteasytoen
suretha
tatleas
to n
eo fthci
neq
uali
tyconst
r瓜nts
Sa
I c
tiv
e.

Des 勿'nProblem: M凶 凶z e由巳 amounto


fm a
ter
ialuse
din出edωi 伊 ofasc
ric
s b b
ofide
ntic
altri
ang
ula
rfi
nst
hatcov
erag iv
cnar
eaandope
ratea
torabovct
hesp
eci
fie
d F
Jgu
re2
.11 F
lnd
esl
gnf
orh
eatt
ra
ns
fe
r:E
xam
ple2.
4.
c
f f
icicn
ciω.

Cons
train ,ns:Thc h
tFunct
幻 e
att r
ans
fere
qua
tionsfort hefi
na r
ca va
ilab
lein
MathematlcalModel:T hi
st y
peo fpro
ble
ms ho
uldbeabl
etoaccommodate Re
ferenc
e7.Finsar
ety
pic
all
ymountedonas
pec
ifi
ed紅 白 . 明1
efi
rs
tcons
回i nti
sone
se
vera
ld c
signvar
iab
les
.I nth
issec
tin,出ep
o rob
lemiss
etuptoh
avetwod e
sign onare
a:
va
ria
bl邸.百1efinmat
eria
lisalum
inum.

h
(b,
L):Af 0
.01 =
5m2 2.
( 17
)
DesignParameters: Foraluminum
Not
e:山isc o
nstr
aintess
enti
allyfix
estheva
lueofb.In山eg ra
phthi
scon
strai
ntwil
¥
=
h 50W/m 2[co
nvec
tionc
oef
fic
icn
t] beastr
aig
htlin
eparal
lelto出c La
xis.lf血i
swcretohappeninaprob
lcmwithscv
era
I
k 1=
77W/m-K[ th
erma
lcond
uct
ivit
y) desi
gnvar
iabl
es,i
twouldb eprudentt
oelim
inat
e出isvaria
blcfro
mthemath
e m
atica
l
=
N 20[numberoffi
ns] modelbyident
ifyi
ngitasad e
signpa佃 l
r e
te
r.
W=O.1m [
wid
山of
thef
ins
) 百 eeffi
cienc
yo fasingl
efincanbeest
abli
shedぉ

F
ingapi
st巴s
h amca
sth
eba
sel
eng
tho
fth
etr
ian
gul
arf
in
. η =
r (
l/mL)1(
2mL
)lI
o(,
2
mL)
w
her
e
DesignV
ari
abl
es
m =(
2,
/
h肋 )
112
b
:ba
seoft
hetri
ang
ula
rfin
L
:he
igh
tofth
ctria
ngu
larf
in 叩 d出el
'sa
reB
ess
ele
qua
tio
nso
fth
efi
rstk
in.Thef
d ir
sti
ncq
ual
ityc
ons
tra
inti
s

F
igu
rc2
.11i
lu
J s
佐at
ω 山egeom
巴町yof自己 f
in
s. ,
b,
g( L): ηf~ 0
.95 2.
(18)
Theo
ver
allc
ffi
cie
ncyf
ort
heh
eatt
ran
sfe
ris
GeometricR
elat
lons:Th巴fol
low
ingaresomeo
fth
巴ar
eac
alc
ula
tio
nst
hata
reu
scd
l
ate
rinthedcv
elopm
cntof山ccons
佐ain
ts: Jo=l-N*叫ん41)(ト 叩
T

Af=(2N-1)*b叫V fo
otpri
ntof出ef i
nandg a
p Thef
ina
lin
equ
ali
tyc
ons
tra
inti
s
Ac=2*W*[2+(
L !
b2)
2
]11
2 f
ina r
eaforhea
ttran
sfe
r
Ab=(N-l)*b*W gapar伺
g2(b,
L):T
Jo~ 0
.94 2.
( 19
)
A=
t N*Ac+Ab to
talareafo
rheattr
ans
fer
SideC
ons
tra
int
s:Thes
idec
ons
住ai
nts釘 芭
O
bje
cti
veF
unc
tio
n: Thet
ota
lvolumeo
fma
回ia
lfo
rth
efi
nis
0
.00
1SbSO. 5 ∞ (
2.2
0)
j
(b,
L =
) O.
5*N*W*b*L 2.
( 16
) 0
.01SLS0
.03
76 G
RAP
HIC
ALO
PTI
MIZ
ATI
ON 2
.3A
DDI
TIO
NALE
XAM
PLE
S n
MATLABC ode:S im
ilarto由eprevi
ousexample.thehashm arksont h
einequ
alit
y eq1 eq1_ex4(X1,
X2); 苦 the equality constraint
cons佐ai
ntcanb ees
tab
lishe
dbyplo
ttin
gtwov a
I u
esoft h
econstr
aint
:theli
mitvalu
e
andav a
luehigh
er.Once出巴yhav巴beendeter
mined.the
nt h
econsoli
datedfi
gur
ecan [ineq1,ineq2] ine~ex4(X1 , X2);
beesta
blish
ed.Th
巴c odeshownher
ewilldrawaIlth
ef u
ncti
onsinsepar
atewindo
ws. 者 inthe above note that the two inequalityconstraints
Fortheconsol
idate
dplotthi
sco
den ec
dstob eedit
ed.Iti
sl e
fttothestud
ent錨 m 者 are obtained simultaneously. Keep in mind
ex
ercls
e. も that each constraint is a matrix

盟主ムmThemains
cri
ptf
il
e 者 ready for the plots
[
C1,han1] contour(x1, x2,f1,[0.00001,0.00002, ...
もChapter 2: Optimization with MATLAB 0.00004,0.00006,0.00008,O.OOOl], 'g・');
% Dr. P.Venkataraman clabel(Cl,han1);
% Example 2.4 Sec.2.3 set(gca,,xtick',[0.001 0.0015 0.002 0.0025 0.003
者 0.0035 0.004 0.0045 0.005])
者 graphicalsolutionusingMATLAB (twodesignvariables) set(gca,'ytick', [0.010 0.015 0.02 0.025 0.03 0.125]);
者 Minimumfin volume for efficient heat transfer xlabel('fin length', 'FontName','times','FontSize',12);
も material Aluminum yl油 el('finwidth', 'FontName','times','FontSize',12)
者ーーーーーー-----------・・・・・------ーーーーーー・ーーーーーーー--ーーーーーーーー grid
者 global statement is used to share same information % hold on
者 betweenvarious m-files
global N H K W AREA figure も open a new figure window
者・"・----ーーー司--ーーーーー-ーーーーーーーーーーーーーーーーーーー一一ーーー・・ーー回・ー--


! も p10tting the equality constraint
も 工nitializevalues contour(x1,x2,eq1,[h1val,h1val], 'r-');
N 20 告 number of fins set(gca,'xtick',[0.001 0.0015 0.002 0.0025 0.003
W 0.1 者 widthof fins 0.0035 0.004 0.0045 0.005])
日 50.0 者 convectioncoefficient W/m*m set(gca,'ytick',[0.010 0.015 0..
02 0.025 0.03 0.125]);
K 177.0 者 thermal conductivity W/m-K
AREA 0.015 者 available fin foot print area xlabel('fin length','FontName','times','FontSize',12);
者・・ーーーーーーーーーーーーーーーーーーーーーーーーーー・・ーーーーー-------ーーーーーー・ーーー・ ylabel('fin width','FontName','times','FontSize',12)
者 right hand limits for the functions grid
h1val AREA;
glval 0.95; ,
I
'
t
' も plotting the first inequality constraint
g2val 0.94; figure
もーーーーーーーー---ーーーーーー・ー・ーー・・ー・・ーー・・四ーー・ーー・・ーーーーーー・・ー・『ーー- contour(x1,x2,ineq1,[0.968,0.968],,r-,);
x1=0.001:0.0001:0.005; hold on
x2=0.01:0.001:0.03; も x1 and x2 are vectors filledwith contour(x1,x2,ineq1,[0.969,0.969],'b-');
者 numbers set(gca,'xtick',[0.001 0.0015 0.002 0.0025 0.003
[ X
1 X2] meshgrid(x1,x2); 0.0035 0.004 0.0045 0.005])
も g enerates matrices X1 and X2 corresponding to
も v ectors x1 and x2 set(gca,'ytick',[0.010 0.015 0.02 0.025 0.03 0.125J);
xlabel('fin length','FontName','times','FontSize',12);
f1 = obj_ex4(X1,X2);
ylabel('fin width',, 陪
FontNar, ,'times',,FontSize',12)
も the objective function is evaluated over the entire hold off
者 mesh
grid
も Constraints are evaluated 者 plotting the second inequality constraint
78 G
AAP
HIC
ALO
PTI
MIZ
ATI
ON 2
.4 AoomONAlM
ATl
.ADG
AAP
HIC
S 7
9

figure
contour(x1,x2,ineq2,[g2val,g2val],'r-');
1
m
hold on
contour(x1,x2,ineq2,[1.01*g2val,1.01*g2val],'b-');
set(gca,'xtick',[0.001 0.0015 0.002 0.0025 0.003
0.0035 0.004 0.0045 0.005])
set(gca,'ytick',[0.010 0.015 0.02 0.025 0.03 0.125]); 0
.0
45
xlabel('fin length','FontName','times','FontSize',12);
ylabel('fin width','FontName','times','FontSize',12)
hold off
grid


1 l

i
O 悶

nb.Le組担割l
eob
jec
tiv
efu
nct
ion

function retval obj_ex4(X1,


X2) 0
.0
25
者 volume of the fin
global N H K W AREA
retval 0.5*N*W*X1.*X2

量qlJ雄.mThee
qua
lit
y∞ 田 佐 直i
nt
1
.
5 2 2
.5 3 3
.5 S
function retval eql_ex4(Xl, X2) f
inb
ase
(m) x
10-
3
も the equality constraint on area
global N H K W AREA 円g
ure
2.1
2 G
rap
hlc
als
ol
ul
io
n:E
xam
ple2
.4
.
retval (2.0合 N - 1)*W*Xl;

旭叫~ Theinequ~lity c
ons
tra
int
s 2
.4 ADDITIONALMATLABGRAPHICS

function [retl,ret2] ine~ex4(Xl , X2) Thiss ectionprovidωab rie


fe xposuretoa dditionalf e
atur
eso fH andleGraphics,
者 returns both the inequality constraints inc
1ud in
gd evelop
m en tofaGUIi nM ATLAB.Th ec ov
erageisv erym ode
s ta n
di s
global N H K W AREA inc
1u dedh crefort hcs akeo fcomplctenessasweh aveaccomp lish
cdo urgoalo f
c 2*sqrt(2.0)*sqrt(日/K)*X2./sqrt( X l); grap
h ic
alo ptim
izatio n泊 山ep reviouss ect
ion s.T hiss ec
tionc a
nb ea voided,
retl (besseli(1,c
)../((0.5*c).*besseli(O,c))); postponed,o re mphas izedfort hepr o
jectsin也ec our
se,asi th asnoa ddi
tiona
l
Ae 2.0*W*sqrt((X2.*X2 + .25*Xl.*X1)); info
r mationf rg
o raphicalo p
timizat
ion.I tdoesc ontainreasonablcinfonn
ationin
Ab (N-1)*W*X1; E
undcrstandingMATLABg r
aphicsa n
dp rogrammin g.Ther ead
erise ncour
agedt otake
At N*A e + Ab; somct imeg et
tingfamiliarwith出ev ersionofMA TI.ABin
stal
ledo nhismach
ine.Th ere
Ar Af./At; ,
.
. areusuallys ign
ific
a nte nhancementsi nnewcrv ersionsofM AT LAB.Fore xample,
ret2 (1.0 -N *Ar.合 (1 - ret1)); MATLABV 巴rs
ion5.3(出i sbooki sbasedonV ersio n5.2)allowsyo utocust
omizey our
plta
o nda ddannotationstoit白r oughadditio
na1ed itingi
t回1町民o f由巳自仰向 w in d
ow.
Thea bovesc
rip
tfil
esshoul
dd isp
layeachfun
ctio
ninas cp
ara
tefig
urewindow
. Youdon oth avetoc ustomizeyo u
rf igu
ret h
roughc odealon
e.I nthisse
ctin,
o wew il
l
Theinequ
alit
yconst
nli
ntfig
uresshouldco
ntaintwocont
ourswih山cb
t luecon
tour a
1sob ede vel
opingt heGUIu s
ingMATLABH and leG raph
icss o白紙 weh av emore
ind
icat
ing白ef e
asib
lereg
ion
.F ig
山な 2 .
12disp
lay
sac omp
ositeplo
tTh esol
uti
onis expe
r ien白 w i血 MA TI.ABHandleGraphics.MA TI.ABd oωprovidcaGUIc reati
ont o
ol,
detc
nninedbythee
qual
ityco
nstr
aintandth
el o
werI
imiton白 ef
inlen
g白ぉd i
scu
ssed ,
11
<' guide,出a ttheuserisrecommendedt oexplo
re.
pr
eviou
sly. nt
I hep revio
uss ectiontherew ereonlyt wod e signvar
iable
s.Anc q回lIys pace
d
vect
o rwaso b
tainedf ore a
chv aria
blcb asedon由巳 s idcconstr
aint.A m巴shgridwas

."
,'
80 GRAPHICALO
PTI
MIZ
ATI
ON 2
.4A
OOI
TIO
NALMA BG
T¥A R
APH
ICS 8
1

出eng e
nera
ted.AlIfunc
tionswercevaluat
edont hi
sg r
id.Contourplo
15weredrawn ob
j田t.百巴回凶 o bjωti ntumhast h
el in
e,tex
t,andimageobject.All0対e c
tsin
f
orthefunct
ionsrepr
esent
ing出巴 obje
ctiveandc o
nstra
ints
.E xc
eptfort h
eobje
ctiv
e MATLABcanbea s
soci
atedwi白 ase
tofp r
oper
ties白atisusua
llybasedoni1
5f u
ncti
on
fu
nctio
nwhichd ispla
yeds e
vera
lc on
t ou
rs, t
heconstr
aintswereo n
lydrawnf ora oruse
ful
ncss
.D if
fere
nto bj
ectty
peshaved i
ffer
entset
so fpr
oper
ties
.Eacho fthc
s巴
s
ingleva
luc
.T hi
sp r
oceduresugg
eststhepos
sibi
lit
yo fautom
ation
.U serinpu
twil
lbe prop
e凶esisd e
scrib
cdthroughapai
ro frel
atedinfo
rmati
on( name,val
ue)
.百 ef i
rs
t
ne
cessar
yforselc
ctig出巴悶 ngcf
n orthevari
ablesaswellasthcfunc
tions出 a
twi
llbe elem
ento fthi
sp ai
rist henamcf ort h
ep roper
tyand t h
es econdisthev al
ue
p
lott
ed.
cor
respo
ndingto恥 p r
operty
.When出eo 同e c
tiscreat
ed,i
tinhe
rit
sallofthede
fau
lt
Inth
isscct
ion,wewillcrea
teplo
ttingfac
ili
tytoincludeaGUIt ha
tw i
ll
prope
凶es.Fore x
ample:

• O
bta
in白 enumbero
fpl
o15 plot(,
ヒ sin(2*ヒ),'-go',
. Th
era
ngeandi
ncr
cme
nto
fth
ede
sig
nva
ria
ble
s ,LineWidヒh',2,
• Useafi
lese
lec
tio x/u
nbo ti
li
ty出a
tth
eus
erw
illu
s巴t
oid
ent
ify出ef
unc
tio
nto ,MarkerEdgeColor','',
k
bepl
ott
ed ,MarkerFaceColor',[0.49 1 0.63],
,MarkerSize',12,)
• Promptt
heu
serf
ort
henumbero
fco
nto
ur百f
ore
achp
lot
・Allowselectionofcontourlevels Thelas
tf o
ur1inesabovcr ep
resen
tf ourprop
erti
eso f出ep lotte
dl in
ethatisbeing
・Creatctheplot c
u
h
n
i
a
n
t
ge
sa
d
r
.Th
einp
ep
oin
r
t
o
s
p
ertyn
.Thec
a
o
r
l
n
o
凶 o

rv a
n山eI
lu
ei
cf
tc
sarowv
anbee
c
cto
a
ro
si
lyu n
d
f出向巴 c
er
o
l
s
o
to
rv
od
a
.百l
lu
e
ef
sbet
o
r
w
m
e
a
e
ts
nz
i
e
z
r
e
o
百l
eex
crc
isew
illr
equ
irctwom
-fi
les
:on
e10s
etup出eGUIa
nd山eo
白巴 rt
oas
sis
tin andoncreprese
ntin
gt h
er d,
e gr
een,andb l
uev a
lues,res
pect
ively.Therearesevc
ral
t
hepl
ott
in.Th
g euse
rwillbeabl
etotw
eakth
cploti
ntheCommandwindowa
ftri
e t ot
h巴rprope而e soft h
ep lo
ttedlinewhichw il
lb esctatt hci
rd efa
ultvalue
s.Th c
i
sdra
wn.Thef ol
lowin
gs u
bse
ction
spωse
ntabr
iefin
tro
duc
tio
ntoHan
dlcGra
phics MATLABonlinercf
erenc
es houdI
l is
tallobjec
15andt h
cirprope凶es.
an
dGUIc on
tro
lsinVersion5
.3. Ingene
ral.objec
tp r
oper
tiescll
nb ec ha
ngedbyu singthes rf
e un
ctiontochange
th
eirv
alue
s.S im
ilar
ly,obj
ectprope
rtiesc佃 bercadbyt h
eu seofthegetfun
ction
.To
in
quir
ea b
outt h
epropert
yo fan0附田t:
2
.4.
1 HandleGraphics
get(handle,'Property Name')
MA T
I.
.AB HandleG raphicsr efertoac ollec
tiono flow-levelg r
aphicr outinest hat
geヒ(h_1,'Color')
act
uallygeneratcorcarryoutgraphicalc hang
esyous 田 i nthcMA百.A Bfigurewindow.
Forthemostp a
rttheseroutinesaretra n
sparen
t阻 dt ypical
lyu s
ersn cedn o
tbea wa rc I
nth
eab
ove,
h_li
s出eh
and
leo
fth
eob
jec
twhosec
olo
risd
esi
rcd
.Si
mil
ary,
l
ofthem.I nfa,
cttounderstandoptimizationandtop rogramt h
et echn
iquesi nMA T
I.
.AB,
i
tisn otn ece
ssarytoknowa boutHan dleG r
aphicss inc
eu singtheh i
gher-lev e
lp lot seヒ(handle, 'Property Name', 'Property Value')
commandss uchasplotandc ontouriss u
ffici
enttog e
tthejobd one."Th
es ccommands set(h_l,'Color','r') or set(h_1,'Color',[1 0 0])
act
uallyk ickins c
vcralo f白eHandleG r
aphicsr ou
tines10d isp
lay白 ep lo
tont he
fi
gure.A notewor 註lyf eatu
reo fMA TI.
.ABgraphic
si s白紙 i tisi mp l
e mente d泊 佃 i
nt h
eabove出巴 valueofColorfortheobjcc
trepre
scn
t叫 bythehand
lch_lisse
t10
obj
ecto
圃 riente
dm anncr.Wh atthi
smeansi st h
atm ostoft he印 刷e syous eeont h
e r
cdintwow ays.Thes ccondspecifiωthecol
orredthro
ughthevect
orval
uc.I
tis
fig
urc,I
ikea xs,l
e abes,
l tc
x,
t andl ines,arcal
lo bj
ec15.Thismcanst hatmosto ft h
e 蜘 e
xpectc
dthattheob
jectide
ntif
iedthrou
ghh _1sho
uldhav
eaC o
lorprop
ert
y.MA T
t.A
B
gra
phicali temsont hefigureh avepro p
ertie
s白紙 C組 b echa nged出r ou g
hprogram w
illinfo
rmyouo fth
ce r
rorincaseyouareassi
gnin
gaprop
ert
y/val
ue伽 tisno
tvali
d
cod
e.I nt heprevio
uss ecti
onsweu sedt hi
stom anipulatecolor,fon
ts ie,
z li
n 巴wid,

f
ortheobje
ct.
andtheIike.
Ino rdertoc hange出ep rope凶e so fobjecs,
t itisn e
c凶 sarytoi d
entifyo rr e
ferto
thcm.Obj ect
si nMATLABa reident
ifiedbyau niquenumberr eferredω asah andle
. 2
.4.
2 GraphlcalUserI
nte
rfa
ce
Handlesc anbea s
signedtoallo b
jec15whent he
ya rccrc
atcd.Someo b j
ec15紅 巴 p artof
oth
ero b
jccts.Objectsthatcontainothero bj
ec15arcreferre
dt oascontainero rparent Themosts i
gnifi
can
tf e
atur
co fsoft
waredesig
nandd evel
o p
men ttodayisthe
利 回 民 . Thereisad ef
initch ie
rarch
i 叫 s 回 ctureamongo bj
ects.
τ' her ooto fa l
l obj
ect
-or
ien
tedd e
signpara
digm白紙 wasb r
ief
lyiI
Ius
trat
edin出ep rev
ioussec
tio
n.
MATLABg raph
ic0切回1 5is出ef igu
reo bj田t.Th efi g
ure0同e ctforexamplec a nho l
d Thecomb
inati
o nofth
eabovewithe
vent-
dri
venprogrammingisbothanatu
ralanda
se
vcralGUIc ontr
ols,whicha reknowna su i
contro
lo bj
ec15.It31socontainst he蹴 es 陀 q
uir
edfca
turcincur
ren
tsoftw
arcprogr
ams.Ins
tea
do ftheprogra
m scon
trol
ledby
82 G
RAP
HIC
ALO
PTI
MIZ
ATI
ON 2
.4A
DDI
TIO
NALM
ATL
ABG
RAP
HIC
S 83
E苦 J

ap redeterminedp rocessings 叫u enc e( ba


tchp rocessing),t od
ay '
sp roc
essingi s 'Position',[2.5,0.1,0.7,.
2],
govemedbyt heusert hroughsomed ir
l田 tedmousec lick
sa ndb uttons.Th e
s euser 'BackgroundColor','red',
sel
e c
tionscausec e
rtaineventst h
atinstru
ctthes o
ft w
aret ocarryoutsomea ct
ion.The ,String',,EXIT',
o句 民 俗 伽1f ir
e血eevenωareu suallyreferre
d1 0ぉ u se
ri nt
e巾叩 e lcmc附 . Itis 'Callback','close');
importanttou nderstandt hatt h
csamee vc
n t
sc anb et r
iggeredbyo b tai
ningu ser
responsctos c隠e np romptsa lt hecommandl in
c( unattr
activ
c).U sin gb u
tt o
nst o Int
heabo
vcIinesofc
odc
.Hpushisth
ehand
letoth
epush
-but
tonob
jec.
tI
tiscre
ate
d
achievet h
esamer esu
lti 5moreg la m
oro u
sa lthoughi tu s
esmorecompu 旬t io
n叫 byusi
ngth
ef u
ncti
onuic
ont
ro.
lTh
i si
sth
efunc
tio
ntha
twillc
rea
tetheu
serin
tcr
fac
e
陀 s
ources.lnf a
c,
tf orco m
me rcialsuccessitisn配 essa
r ytoi n
cludet h
ismechanismo f elements.Th esamef unc
tionisu sedt oplacesevera
ld i庄erentuserint
erfacee lements
userintr
e.
actioninth esoftwarep r
o du tAl
c. s
o.u s
erse xpecttheseel emen ts10b ehave thr oughtheselecti
ono fthestylep r
o p
e rt
y.I ntheexampleb elow.t h
esei n
c ludelabel
inas tandardw ay.T herea remanye lements白紙 t h
eu se
rc anu set oi nter
actw ith box csandu sere di
ta b
letexlb oxe
s.S eve
ralp aramete
rsi denti
fyL h
et yp巴o f巴l emcnt
program5.Manya pplicat
ionsa cr
ossse v
eraldisci
plinesh avcnowd e finedaminimum UEatisc rea
tedandt heproper
t ie
sU Eatn eedtobeset.Eachp ro p
e n
yi ssett hrougha
5tanda
r dcolle
ctiono f出e seelements.MATLAB必5 0providcst hem.Th eo rg
anization propertynamelproper t
yvaluep ai
r.Hfiιlin恥Ii ncso fc odea bovc児 島 内 t ot he
of山e seelemenlsa ndt h
eirpresentat
iontot heuserinag raphlc
almanneri sidentif
ied hand l
eo fthefigurewindowi nwhicht hiselementwi Ubep lace
d.Thet ypeo fe lement
as出egr ョphlcaluseri n
terf
a田 .A n umbero fGUI-basedt ∞ 1
s .釦n ct
i on
s.催 芭 a v
a ila
ble createdisap ush-but t
one lementc s
tablish吋 t h
ro u
gh恥 S tylepropertys凶n gname
attheMATLABs i
te. ‘push."TheU nitsu sedtos i
zeandp ositionthep ushb u
t t
onisi nc
hes.TheP osition
T h
iss ectio
np rov
i desonlyab ri
efin t
roductio
nt o出ee le
m e
ntsu sedi nthee xample. propertyisarowv ec t
oroff o町 valuesg ivingtheLe f
t
.B ottom.W idth.Heig hto fthe
Th巴see lcmentsarep rimar
ilyu sedt hroughMATLABH an dlcGraphi csp rogram ming. elementi ntheU nitssclecte
de ar
lier
.Thed efaul
tl oca
tiono ftheorigi
ni stheb o tto
m
Considerthec ascofab u
tton白 att h
eu sercanp ushtoc ausesomea ction.referredto lc
ftcomero fthefigu問 window.TheB ackgroundCol o
rf orthebutto
nisscttor ed.Th c
asap ushb uttonint hcsubseq u
entd isc
ussion.Att heo ut
set.thereru官 t wop r
i nci
pal labelthatwil
¥beont hefaceo fthep ushbuttonisEXIT.T hisistheTCXlp ropertyo f
requiremcnts山a tarec xpe
ctlo
叫 ft h
ep ushb ut
ton.Firs,
tt he凶 erm ustb eablet osee thep u
sh-buttono b
je c.
tTh cCal l
Ba ckpropertyoft h
ep ushbuttonis白 estri
ng“ c
lose."
it
.Second.whcn出eu s
erclicksonit( si
ngleversusdoub leclic
ksc anb ed isti
nguished Thiss t
ringwillbet hcparameterint heevalf u
nction出atisc all
edwhen出巴 p ushlclick
inmanys oftwarede velopmentc ode
s)t heb ut
tonmust飽 spondwi 出s omee xpected eventi st ri
gge陀d.MATLAB commandc losew illb ee xecutedint h
eCommand
act
ion.InMA TLABthep ushbuttonisag ra
phicalot羽田t.Ith asmanyp rope 両国 t hatcan wor kspacewhent h
ep ushb uttni
o sp問 s sed.Th lswillc ausel h
ef igur
ewindow
beu sedtodescribeitsapp回 r an
ceont h
cs cr
ecn.InMA'τ LAB.al
lg raphicalo bj
ectsc an displayingthepu s
hb u
ttontoc1 o
sc.
onlyappe 釘 inaf igurcwindow.Hencc,af ig
urewindowi se sse
ntialt od isp
l aythc Onlyafewe lementsareu sedin出i ssccti
on.TheCal 1Backs trin
gsarea lsoq uit
e
pushb utto
n.百 i sf igurewindowactsωac ontai
nera ndca nco ntainmanyu ser s回 ighばorw 副 .B efo redcvelopingt hcc o
de.itisu sef
ult oo b
serve恥 h lerarchica
l
int
erfacee l
cmcnts.C onsideringt hep r
esentati
ono ft heb utt
onont hcs crccn,itis orderinw hicht heg rap
hicalo bj
ectsi nMATLADa reorg a
n iz
ed( repro
ducedfrom血e
ne∞ssaryt odccidewheret hebuttons h
oulda pp回r on出efigw 沼w indow, howb igit MATLABd ocumentation)inF igure2.13.Th er oo
ti mpl
iest hestar
tingresourcef oraI
l
shouldbe, whatlabelits h
oul dhave( ty
pical
lyi n
dicates血巴k indofa ctionitisl ik
ely graphicdisplaysinM ATLAB.Itsh andleu sua
llyh asav alueofO.Ther oota lsos erv
es
ωcause), 加ds oon .S incct h
ep ushb uttonisag raphicalobjec,t mucho ft hese asac ontain
erf oral
lo ft h
ef igur
ew in dows.A notherexprcssionfor山isr elationshi
p
prope凶e sc叩 b esetifthercisah andleavailab
leforIhep ush-buttono bjcct
.Oncet he i
sth a
taf igur
ewindowi sthech il
do fther oo.
tFromt hehierarchyi
tisessent
ialωnote
graphl
伺 1a ppearancei st ak 白 紙 出eu se
ri nte
rfacee le
ments.uiconヒrolo ruimenu,c 叩 o n
lye xis
tw i出i na

R
o+o
t

U
lco
ntr
ol Ax
es Ulmenu

Image L
lne Patch Surface Text l
igh
t
Hpush uicontrol(Hfig_1,'Style','push',
'Units','inches', 1g
F u
re2
.13H
ler
arc
hic
als
lru
clu
rel
orMA
TlABg
rap
hlc
alo
bj
ec
ls
.
8
4 G
RAP
HIC
ALO
PTI
MlZAnON 2.
4 A
DOI
TIO
NALM
AT
LA
DGR
APH
ICS 8
5

f
igu
rewind
ow.80a
l50the蹴 e
5obj
ectI
. nth
efoll
owi
ngcodeea
chint
erf
aceele
men
t ,BackgroundColor','white',
i
sfi
rs
tass
oci
ate
dwi白 ahan
dle50出創出ep ro
per
tyofth
eeleme
ntcanbe陀 f
en吋 t
o ,String',',
i
fnec
ess
ary
.Thisi
sespe
cia
llytr
ueofth
etex
tentr
yboxestoinv
ok巴theCal
l8ac
k 'Callback','Np str2nUm(get(Ht_2,"String"))i');
s
凶ng5.
HLX1L uicontrol(Hfig_l,
2
.4.
3 GUICode 'Style','text',
'Units','inches',
百l
efo
llo
win
gco
dewi
1g
l e
ner
atet
heGUI
.Th
eui
wai
t陀 q
uir
est
ha
l山i
swi
ndo
wbe 'Position',[0.1,0.8,0.5,.
2],
c
los
edb
efo
res
ubs
equ
entp
roc
ess
ingc
ant
akep
lac
e(o
ruiresume b
euS
edi
n白E 'String','x1(min)')i
∞d
e).
HT_XIL uicontrol(Hfig_l,
.
Gll
旦..
yl 'Style', 'edit',
'Units', 'inches',
も GUI for Plotting facility 'Position',[ 0.7,0.8, 0.7,.],
2
も Dど . P.VenkataramanApplied Optimization Using MATLAB 'BackgroundColor', 'white',
者 'String',",
%Ch.2 Sec. 2.4 'Callback', 'xlmin str2num(get(HT XIL,
'

,String', ))i')j ー

者 GUI is createdwithin a figure window


告ーーー------ーーーーーーーーーーーーーーーー-ーーーー司ーーーーーーー・・・・ーーーーーーーーーー HL_XIM uicontrol(Hfig_1,
Hfig_1 "
' figure; 者 Hfig_1 is the handle to the 'Style','text',
も figurewindow 'Units','inches',
'Position',[1.5,0.8,0.6,.
2],
set(Hfig_l,'Color',[ 0.3,0.6,0.], ...も set color
5 'String','incremenヒ')i
,NumberTitle','off', 告 nowindow title
,Name', 'Set Range for Design variables', HTX1M uicontrol(Hfig_l,
'Units','inches', 者 inchesused to layout 'Style','edit',
%o ther controls 'Units', 'inches',
'Menubar','none', 'Position',[ 2.2,0.8,
0.7,.],
2
'Position',[4,4,4.4,1.5]); ,BackgroundColor','white',
,String',, ,
告Positionpropertyis [left,bottom,width,height] in 'Callback', 'x1inc str2num(get(HT_X1M,
'
者 Units selected ,String', ))j')j

Ht_1 uicontrol(Hfig_1, HL_X1U uicontrol(Hfig_1,


,Style', ,text', ,Style',,text',
'Units', 'inches', 'Units','inches',
'position',[ 0.1,1
.1,2.4,.2], 'Position',(3.0,0.8,0.5,.
2],
'String','Number of Functions to Plo
,ヒ ); 'String','xl(max)')j
--,
t
c


o''o


n''n
o
H'86
1


4'''
t

・ es
ulti
H

ztno

r・

sL''
f

HT_X1U uicontrol(Hfig_l,
1 ・ 'l
qd ・
可ムい﹂ hU

'・ n
e

-・・ 1
sup

'' ・1

--CI
Gn'
yi

'Style', 'edit',
--'

e ・

'Units', 'inches',
﹄↑

]
s

'Position',( 3.6,0.8,
0.7,.
2],
u
氏J
弓L


,也
8
6 G
RAP
HIC
AlO
PTI
MIZ
ATI
ON 2
.4 A
DDI
TIO
NAlMA
11A
IiG
RAP
HIC
S 8
7


BackgroundColor','white', 'Position',[3.6,0.5,0.7,.],
2
String',
, ,, 'BackgroundColor','white',
'
Callbac,
屯,
l 'x1max str2num(geヒ(HT_X1U,
, ,String',',
,String',)); ,
); , ,
Callbacl屯,'x2max str2num(get(HT_X2U,
'
,String',)); ,
);
E
江,_X2L uicontrol(Hfig_l,
,Style',,text', Hlabel uicontrol(Hfig_1,
'Units','inches', ,Style', ,
text',
'Position',[0.1,0
.5,
0.5,.
2), 'Units','inches',
'string','x2(min)'); 'position',[0.1,0.1,2.2,.
21,
'BackgroundColor','y',
HT_X2L =uicontrol(Hfig_l, 'String','After enteringvalues please press
,Style', ,
edit', EX工T');
'units','inches', Hpush uicontrol(Hfig_1, 'St
yle',
'pu
sh',
'Position',[ 0
.7,0.5,0.7,.),
2 'units', 'inches',
'BackgroundColor','white', 'Position',[ 2.5,0.1,0.7,.1,
2
,String',,, ,BackgroundColor', 'r
e d',
'Callback','x2min str2num(get(HT_X2L,
' ,String', 'EXIT',
,String',)); ,
); 'Callback','close');
uiwait
HL_X2M uicontrol(Hfi9_1,
,Style',,text', I
ntheabovecode出es tate
menl
SshouldbecωYt oin
terpretM
. ucho fth
ec odec叩 be
'Units','inches', e
dit
凶 aft
erc op
ya ndp邸 t
eoper
ati
on.Thelastcommanduiwait i n
st
ruclSMATLAB
'Position',[1.5,0.5,0.6,.
2), t
oh o
ldoffexecut
ionunti
ltheuserclos
es出eGUIw i
n dow.Figu陀 214s
. howsthe
'String','increment'); ima
geoftheGUIぉ i ta
pp回rsinMATLAB.百letex
tb o
xesa rcin
it
ia
liz
.edwi
thn oval
ues
fo
rci
ng血eu sertosetvalue
s出e r
ebyc a
usinga1o
l ft heC a
llBackstri
ngstob e
HT_X2M uicontrol(Hfig_1, ev
alu
ate
d.Ina d
diti
on,t
h巴d a
taent
eredbytheuse
risas 甘ing
.Ithastobeconvert
edto
,Style','edit', anum
ber.T he∞dehe 印 i
sb a
si
c.Itdoesnotver
ify也att heuse
rd i
de n
teran u
mber.
'Units','inches', 百isv e
rif
icati
onc anbed oneb ye xt
ending血eC a
l lBackstri
ngo verm u
lti
ple
'position',[2.2,0.5,0.7,.),
2 st
atem
enl.T
S h
isisle
ftぉ anexer
ciseinprogrammin
gf ortheus
er
.
'BackgroundColor','white', Thesc
riptm-f
ileusedtose
lec
t佃 dc r
eat
et h
ep l
0lSi
sa sfoll
ows.
'String',',
'Callback','x2inc str2num(get(HT_X2M,
' 目盛m.m
,String',));'); 者 Script file to gowithContourplotting
宅 Dr. P.Venkataraman,AppliedOptimizationUsingMATLAB
HL_X2U uicontrol(Hfig_1,
'Style','text',
',' ',
'Units inc
'Position',[
h
3
e
.
s
0,0.5,0.5,.
2],
-・・・・幽画圏直幽画趣醤岨血畠圃・・・・
亡コ
'string','x2(max)'); 圃 圃 E二コl1li圃 E二コ匝圃仁二コ
HT_X2U uicontrol(Hfig_1, 園圃仁二コ圃圃仁二コ固圃仁二コ
'Style','
edi
t',
'Units','
inche
s', 関宮島睡眠融担醐暢腫酷謹繭 置璽置E
F
lgu
re2
.1
4Im
ageo
fGU
I.
88 G
RAP
HIC
AlO
PTI
MIZ
ATlON 2
.
4AO
DIT
ION
AlMA11ABG
RAP
HIC
S 89

も Ch. 2,Sec 2.4 for Mp10t l:Np


も text1 ['The function which is being p10tヒedmust
も script M fi1e for 20 Contour P10tting of functions '¥nbe a MATLAB'
% invo1ved in optimization '¥nfunction M - Fi1e. Given a meshed matrix input'
者 A11 functions are expected to be avai1ab1e as '¥nit must return a Matrix'
者 MATLAB function m-fi1es '¥nP1ease se1ect function name in the dia10g box .
昔F unctionswil1bese1ectedthroughthe input se1ection and hit return¥n '1;
も box % this prints the text to the screen in the command
告Function input parameters wi11 be meshed matrices も windowand serves as a prompt
告 basedon the range of parameters avai1ab1e from GU工 者 the ¥n is a new 1ine command

も The Number of p10ts and range for the p10t fprintf(texヒ1
)
も are obtained from running the
告 user interface script GUI2_4 prior も using the uigetfi1e dia10g box
者 to the ca11 to P1ot20.m [fi1e,pathl uigetfi1e('c:¥*.m','Fi1es of type
者 MATLAB m-fi1e',300,300);
も check if fi1e is string
GU
工2 4 も call the GUI
者 strip the .m extension from the fi1e so it can be
者 ca11edby the program
告 X工nfo,Ylnfo are introduced for introducing default if isstr(file)
者 values functname strrep(file, '.m',");
Xinfo [xlmin x1max x1inc1; e1se
も the va1ues x1min,x1max,x1inc are avai1ab1e in fprintf('¥n¥n')
者 the Command workspace due to Ca11Back text2 , [ You have chosen CANCEL or the fi1e was
'¥nnot accepヒab1e'
if isempty(Xinfo) '¥nThe program needs a Fi1e to Continue'
Xinfo [
-4 4 0.051 告 defau1t '¥nP1ease ca11 P1ot20 again and choose a fi1e OR '
end '¥npress the up-arrow button to scro11 through
fprintf('¥n') '¥nprevious commands ¥n¥n'
l
1
:
r ,Bye 1'];

2

Yinfo [x2min x2max x2inc1; error(text2);


11

if isempty(Yinfo) end
Yinfo ・4 4 0.051
end c1ear text1 text2; 告 c1ears the variab1es text1 .
fprintf('¥n') も and text2 for reuse
xvar Xinfo(1):Xinfo(3):xinfo(2); % xl vector c1ear Fun maxva1 minva1 strcon conva1ue oneva1ue
yvar Yinfo(1):Yinfo(3):Yinfo(2); % x2 vector 1abcont 1abcontU
[X1,X21= meshgrid(xvar, yvar); も matrixmesh
Fun feva1(functname, Xl,X2);
maxva1 max(max(Fun));
も set defau1t number of p10ts to 1 minva1 min(min(Fun));
if isempty(Np)
fprintf('Thecontourranges fromMIN: 昔12.3fMAX.
Np 1 ; も12.3f ',minva1,maxva1);
end fprintf('¥n');
c1王 ; 奄 c1ear figure
strcon input('DO you want to set contour va1ues ?

90 G
RAP
HIC
Alo
pnM
IZA
TIO
N R
EFE
REN
CES 9
1

[no]:','S'); labcont input(, 00youwant labelledcontours ? [...


strconU upper(strcon); no]:', 's');
if strcmp(strconU, 'YES') Istrcmp(strco 凶, 'Y') labcontU upper(labcont);
fprintf(' Input a vector of contour levels ,); if strcmp(labcontU,'YES')Istrc 即 (labcontU,,
Y')
fprintf('¥n') [C,h) contour(xvar,yvar,Fun,ncon);
fprintf('between 者10.2f and 巷10.2f ',minval,maxval); clabel(C,h);
fprintf('¥n') else
convalue input( ' Inputcontourlevel asaVector : '); contour(xvar,yvar, ,
F山 lncon)
labcont input('Ooyouwant labelledcontours ? end
[no]:',, s');
labcontU upper(labcont); end
if strcmp(labcontU,'YES')Istrcmp(labcontU, 'Y') end
[C,h] contour(xvar,yvar,Fun,convalue); if Np > 1
clabel(C,h); hold on;
else end
contour(xvar,yvar,Fun,convalue); Hf gcf;
end end

else figure(Hf)i
ncon input('Input number of contours [ 20] :'); grid
if isempty(ncon) hold off
ncon 20;
labcont input('Oo you want labelled contours ? Inthea bovetheplot
tingcommandsh avebeenusedbefo
re.ThenewMATLAB
[no]:', ,s') commandsa r
eisempty ,clf,isstr, strrep,max,min,upper, strcmp ,an
d
labcontU upper(labcont); fprint.Uset h
eh e
lpcommand1 0lea
rnmoreaboutth
ese
.Runt hescri
ptfie叩 d
l
if strcmp(labcontU,'YES')Istrcmp(labcontU,'Y') unde
rstan
dt hes叫u en
ceo fact
ionsaswell俗 曲epromptsreg
ardin
gthec o
ntour
.In
[C,h] contour(xvar,yvar,Fun,ncon); 白isexamplethefun
ctio
ns白紙 c r
ealeth
eplotdon
otneedglo
balval
uesforca
lcul
atio
n
clabel(C,h); 釘 佃sfe
π'e
df rom白ecommandw orksp
ace.Inoth
erwordsthefu
ncti
ons白紙 a r
etobe
else pl
otte
dc a
nb ecalcu
late
din d
epen
dentl
y.
contour(xvar,yvar,Fun,ncon);
end
elseif ncon 1 REFERENCES
onevalue input( 'Input thesinglecontourlevel ');
labcont input( '00youwant labelledcontours ? 1
.MATLAB The Langooge ofT
ecl
lli
1 c
alC
omp
lui
ng:U
sil
l ,V
g MATLAB e
rsi
on5

[no]:', ,s') Ma山Wo北s Ic
n.,19
98.
labcontU upper{labcont); 2
.MATLABTeLa
h nguageo
fTe
chn
ica
lCO
岬 u
lin
g:U
sin
gMATLABG
rap
his,
c V
ers
ion5

if strcmp(labcontU,'YES')Istrcmp(labcontU, 'Y') M
ath
Wor
ksInc
.,1
996.
[C,h] = contour(xvar,yvar,Fun,[onevalue,onevalue]); 3
.Bo hac hevsk,
y1.0.,10hn80n,M.E.,andSle
i n,M.L.,Ge
nera
lize
dS im
ulate
dAnnea
lin
g
clabel(C,h); f
orF u nci
LonOpti
mization,Tecl
mometriムVo
c .2
l 8,
No.3,1986
.
else 4
.Aro ra, J
.S.,ln
trodu
c l
ion10Oplil
llu
mD esign,McGraw-H ,
I
i NewYor k1
, 98
9.
contour(xvar,yvar,Fun,[onevalue,onevalue]); 5
.Be,

附'
阜れ
rF
釘 .P.,andJ
ゐ0加s蜘ω,
目E .R,
.可J
r
end Yo r
泳k,1 99
2.
else 6
.Fo x, R.W. ,
andM cDonal ,
d A
.T.,ln
t r
oducl
i o
n10F l
uidMecha
nics,4由 e
d.,W
iley,
New
Yo rk ,199
2.
7
.Ar paci,V.S.,Con
ductiollHeatTral
lSf
er,Addis o
n-Wesle,
yReadig,
n MA ,
196
6.
92 GRAPHICALOPTIMIZATION

3
8
.Hansel
man,D.,a
ndLt
itl
et
ie
ld,
B.,Mas
ter
ingMat
lab5,ACompr
ehe
nsiveT
uto
ria
la n
d
Refe
ren
ce.泊 施 M
A'τ'
LABC ur
ricul
umSer
ie,P
s ren
tic
e-Ha
Jl,E
nglew
oodCl
iff
s.NY.
1
996
.
9
.Buil
din
gGUIsw i山MATLAB.o n
lin
eref
ere
ncei
npdffo
rma
t.Math
WorksInc
.
.1 9
98.

PROBLEMS

(Manyo ftheg r
aphica1enhancementsarenowp os
sib
lethrou
ghplot
edi
tf e
atu
resi
n
l
a包r r
eleas
eso fMA 1LAB.Thefo¥
lowingp ro
blemsarej
ustsu
gge
stio
ns.Thesugge
ste
d
prob
le m
su s
ea ddi
tionalgraph
icaleleme
nts.anda1sor
叫u i
redel
eti
nghand
les.Pl
eas

co
nsultMA T
I.
.ABdocumentatio
n.)

2
.
2
.
1 P
l
2 P
r
o
o
tt
d
u
h
c
eba
巴a
1l
na
i
n
i
s
即 位a
ma
te
je
dd
i
c
t
s
o
p
l
r
y合oms
ayo
ft
i
1
1
mp
let
w
巴館司j
e
o
c
-
d
t
o
i
r
m
e
y
.
ns
iona
1m田 h
ani
cs. LINEARPROGRAMMING
2
.3 C
reat
eat w
o-di
mension
alp rogr
amt h
atwil
ldisp
layarandomfi
r i
ngl
oca
tio
n
an
d arandom ta
rgetloca
tio
n.A llow th
eusertochooseini
tia
1velo
cit
y
m
agnitu
deandang
le.Plo
thist吋e
r c
toryandca
1cu
lat
ehi
serro
r.
2
.4 C
reat
eat h
re・d
巴 i
mens
iona
lprogram出atw i
lldis
pla
yarandomfiri
ngloc
ati
on
a
nd arandom ta
rge
tl o
cat
ion
. Allow 出eu se
rtochooseini
tia
1v el
oci
ty Them ajorp a
rtoft hisbookd ealswithm nthemntica
1models血n tn r
ec hn
rncteriz
edby
ma
gnitu
deanddir
ect
ionan
gle
s.Plo
thistra
jec
tor
yandc
alc
ulat
ehiserr
or.
nonlinea
re quati
o n
s.I ikemostof由巳 examplesu sedf oriI
Iustr
atio
n白u sfar.The
2
.5 Drawtheb
oundaryl
ayerp
rof
ileo
flami
narl
10wov
eral1a
tpla
te.Drawl
ine
s presenceo fas inglen onlineare q
uationint hemodeli ss uff
icien
tt oi d
entif
yt he
in
dic
ati
ngvel
oci
typr
ofi
lea
ttenpo
int
sinth
ebou
ndaryl
aye
r. problemf r omthec lasso fn onl
inearprogramming(NLP)p roble
ms.M athematica
l
2
.6 Cr
eat
eap r
ogram出atwi
llpl
ot白巴 v
elo
cityp
rof
ilef
orus
er-
spe
cif
ici
npu
ts. programmingi sano 出e rt ermt h
atisusedtod escr
ibes uchmodelsa nd白e irsol
utio
n
Al
Iowth
eusert
oex
pres
shisi
npu
tsth
roug
hadia
10gbo
x. 飽chniques.Mosto fe ngine巴ringdesignfal
lsinthi
sc ate
gory.Havingr e
presente
ds uc
h
problemsg raphica
1 1
yi nt hep revio
usc hap
ter.itapp 儲 r
s白紙 t hegradientandt h巴

C町 va胞reo f血巴白n cti


onsi nt hemathematicalmodelhadas igni
fica
nti mpacton
iden
tifying血es olution,eventhoughnoe ffo
rtwasmadet opointout白i sf ea
ture
sp即 if
ica
lly.I nf actg
, raphicals olu
tion waso btainedb yi nspe
ctionr ath
ert ha
n
determinedbym athe maticalrelati
onsorentit
ies
.
Thereisanequ a
llyimpo 民 組tcIas
so fproblemswhos 巴mathemati
calmodeli smade
upex c
Iusivelyoff unctionst h
ata r
eo nlyI
inear,suchasExample1 .3,
鎚 modeledi n
Equ姐 o ns1.21-1.24.Thesameexamplewぉ m odifiedinEq ua
tion51.25-1.2850伽 t
agraphicalsolutionc ouldb edi5cu
sSed.Itisapp釘e nt合om血巴 g raph
ica1descri
ptio
n
inFi g
ure1 .6白a t出 町 巴 isnoc u
rvatureevidentin白ef igu
re.The sepr obl
emsa r
e
旬 m 巴dl inearprogramming ( LP)p roble
ms .Theya ren a
turalin出es ub
jecto f
operat
ionsr ese
arch,whichcoversav astvarie
tyofm odelsu sedforsevera
lk in
dso f
decisi
onm aking.Ex 創nple1 .3doesrepresentadecision-makingproble
m .Typica
lly,
LPc anbeac our
s ebyi tsel
f( orsev
eralcoursesfor伽 tm a
tter)
.As ig
nifica
ntportio
n
ofs uchac o町民 w ouldb etod evelopmathe m
atica1modelsfromd if
feren
ta re
aso f
appl
ications,ast h
erei su sua1
1yonen ume
ricalt ec
hn i
que白a tiscommonlyu sedto
solveLPp ro
blems.I tisca l
1edt h
es imple
xmethodandi sb as
edont hea lgor
ithmby
D佃 包i g[ 1. The method i
] nvolv
esm ostlye lementary row operat
ionst ypic
al
1y
encounteredi nG auss-eliminationt ypem巴白o dst ha
ta rep arto fthen umerica
l
93
94 L
lNEARPROGRAMMING 3
.1 PR08LEMD
EFI
NIT
ION 95

techn
iquesusedinl in
earalgeb
ra.In出ischapt
er,onlyalimi
led,bu
tu s
efuldisc
ussion 出ec
onst
rai,
ta
n r
erequ
ire
dtobepos
iti
ve(>0)
.In山eprob
lemdefi
ne nE
di qua
tio
ns
isp問sent
ed.Fir
st,itisimporta
nttounders
tandLPp roble
ms,出巴 modelin
gi s
sues,and 3.
(1)-
(3.
4, t
) hecha
nges出atmustbecar
rie
do u
tin
clu
dec o
nve
rtin
gtheo
bje
cti
ve
the
irsoluti
on,as白e ya redif
fere
ntfrommosto f出eo the
rp roble
msi nthi
sb ook. fun
ctionto脱 o ppositetype ,andt ra
nsformingtheconst
rain
15t o恥 e qual
ityt y
pe.
S配 ond,m佃 Yo f由巳 c urre
ntn um
erica
lt ech
niquesforNLPp robl
emso bt
aint h
eir Thev紅i ab
lesXJandX2, re
pres e
ntingthenumbero fComponentP la
c em
entM achines
sol
utionbyl inear
izingt hesolut
ionatthec ur
rentdesignpoint
.The selineari
zed ofmodelAa ndB,r esp
ectivel
y,c anbeexpectedtobesemiposi
tiveP-0),白紙 is,eit
her
叫u at
ions回 nb esolve dby白emeth 吋 Softhi
sc h
apter
.百l e陀 a
d e
risdir田 t
edto却 y somema ch
ineswillbeo rderedo rnomachinesw i
llbeo rd
ered.Note白紙 t hedisαete
ofthebooksonLPf oramored eta
ile
dd e
scri
ptionofthemodelsandt h
et ec
hniques mωreo ftheprobl emisbeingi gnor
吋, as3.75m achinesofTypeAi snotsomething
asthep回s e
ntat
ioni n山i sbookissimp
lea ndbr
ief
.R ef
erences1-3areusefu
lfort h
is th
atwouldbeo rdered.Th eso l
utionwil
lb er oundedtoas u
itabl
ei nt
ege
r.τ1tereare
pu中o s
e. ext
ensivedisc
ussionsindisc問胞 a ndint
egerprogrammingl it
era側隠 tos ug
gest白紙
白ismayn o
lbe白eoptimumv alue.Thej us
tifi
cati
onf o
rr oundin
go ffis白紙 i tis
conv
enient10dos oatthi
sj unct
ure.
3
.1 PROBLEMDEFINITION Intheo bj
ectiv
ef u
nctionj(x),出巴 c o
effic
ien1
5990a nd900a r
ec alle
dt hecost
co
e.伍cien
15.Eachc oef
fici
ent白紙 i sasso
ciatedwi白 ad esig
nv ar
iable陀:pre
sen15自己
Example1.3wi
llbeu s
edtod e
fineth
et e
rminol
ogya ss
ociat
edw i白LPproblem.百 l
e
inc
reas
e( de
c胞a s
e)inc os
tp erunitchangeintherelate
dv a
ria
ble.百les im
plestwayt o
modi
fiedvers
ioDofthep r
oblemisused10develo
p出ef ormatofth
eLPp r
oblemso
紅白lsform山 o切e c t
ivefunctiont o山er equ
iredformatistomultiplyal
lo ftheterms
由atwec anfoll
owthroughwith曲eg r
aphic
alsolu
tion.Them at
hema
ticalmodelh a
s
by-1.Therefor
e,出enewo bject
i v
ef u
nctionis
twod es
ignvaria
blesxJ・X2 t
halrepr
esent白enumbero fComponentP lacemen
t
Machinesofty
peAandB .res
pect
ive
ly.Theobjectiv
eis10maximizethenumbero f
t M
ini
mize j
(x)
:-990XJ- 900X2- 5250 (
3.5
)
boar
dstobemanufact
ured.Const
rain
tglr e
pr民 間ts白ea cqu
isiti
ondo]a
J r
sa v
aila
ble
.
InE quati
on( 3.
5), 山 cons
t an
tt ermont her ig
ht(-5250)c a
nb ea bs
oぬe din t
ot h
e
Con
strai
ntg2 repr
esen1
5白ef loorspac
ec on
strain.
tC o
nstrai
ntg3 rep
resen
15白e
numbcrofoper
ator
sa v
aila
blc
. lefl-
handsidebydefini
nganewo bjec
tivefunctionL(x
)w i
thoutaffe
cting曲e op t加al
va1uesforthedesignvari
ables.ltcanbeo b
se r
ved出a tincre
asingthev a
lueso ft h
e
varia
bleswillmaket heobjectiv
emoren egat
i e,
v whichisgooda swea retry i
ngto
Maximize j
(x:990XI+900X2+5250
) (
3.1
) makej (x
)a slowa spos
sibl
e.Ifap a
rtic
ularcostcoe
ffic
ienthadap osi
tives i
gn, th
en
incre
asingtheamounto fthecorrespondingvaria
blewouldl e
adtoa nincreaseo fth
e
S
ubj
ectt
o: g
l(x
) 4XI+0
:0. .6X2S8
.5 (
3.2
)
objec
tivefunctin,
o whichisn o
ld esi
rableif白 efunc
tionneedstobem in
i mized.T h
is
ideaisexpl
oitedin出 eSimplexmethodp res
entedlat
er
.
g2(X):3XJ- X2S25 (
3.3
)
The泊。q ual
ityc o
nst
rain
t shavet obet ransfor
medtoan叫 u al
ityco 田 町aint
.The
simples
twayωachievet h
isc hang巴istoin
回 d uceanaddi
tiona
ls e
mipositivevariab
le
g
)(x
):3XJ+6X2S70 (
3.4
)
foreachinequa1i
tyconst
raint
.T halwillcrea
te出E∞ 町 田p o n
dinge q
ualityc o
n s甘剖nt
inas tr
aightfo
rwardway.Consider出ef i
rs
tc ons凶 nt
:
x
J~O; X2~0

百l
epr
obl
em.d
efi
ne nE
di q
回ti
ons(
3.1
ー(
) 3
.4)i
san
atu
ralr
epr
ese
nta
tio
nof山 g
J(x
) 4xJ+0
:0. .6~ S8
.5 (
3.2
)
mathem
atica1modeli nengine
eringdesi
g nor血 yo therdis
cipl
ine
.Bya llo
win
g
叫u a
lit
y( =)const
J泊015組 dgr田ter山ano req凶 1()c
注 o
nstr
ain1
5t h
ep r
oblemcoul
d sc
τ五i a
nbet
ran
sfo
rme
dto
accommodateanym a
themati
calmodel白 a
tischara
cteri
zedbylinea
rfunc
tion
s.Thi
s
ncanbec
r
a
e
l
p
r
t
e
h
o
s
u
e
n
g
ta
hi
li
ti
o
sno
te xp
陀s
o
s
n
e
s
di
i
dere
n由es
dt
t
h
a
ei
nd
a
n
r
e
q
d
u
f
a
o
l
i
r
t
m
yf
atf
o
o
rmo
rth
ft
eLPp
h
em
ro
a
b
t
l
h
e
e
m
m
.
atica
lmodel
g
J(x
) 4x
:0. J+06~ +x
. 3 8
.5 = (
3.6
)

Thenewv aria
bleX3 isreferr
edt oast h巴s lac
kv ar
iabl
e.Th edefinit
ionisq uil
e
3
.11 S
. 旬 ndardFormat
}
露 appro
priat
eb ec
auseittake
supt heslackoftheorig
ina
lc ons
住ainttermswhenitisles
s
由加 8 .
5.τ1teslackwi1
lbep os
itiveas出ef rr
sttwot erm
sw i
llbeless也佃 o r珂 u a
lto
Thestand
ardform
atoftheLPproblemi
ncl
udeson
lyequa
lit
yc o
nst
rai
n15
.Itiss
ctup 8.
5( fo
rconst
raintsat
isf
actio
n)fr om山eo ri
ginaldef
init
ioninEqua
tio n(3
.2.I
) nothe
r
as aminimiz
atio
np roble
m (somcaut
hor
sp rc
fer amaxim
izationprobl
em)
.l n words,i
tisthediffer
encebetwecn山 c o
nstr
aintlimi
t(8.5
)a nd恥 f i
rsttwote r
mso f
ad
diti
on.al
lo fth
evaria
ble
sin也emodel町 ee x
pecte
dt obesemip
osit
ive注
(0 )or thecons
trai.
ntIftbevaluesofXIa ndX2c a
us ethecon
stra
inttobea ti1
5limitvalue
.
non
negativ
e[ 4
].F
ina
lly,th
econs位置i
ntl
imi
15,出equa
ntit
yont herig
ht-h
andsi
deof 出e nX3wil
lb ezero.Thi
sist h
er easo
nitisdetinedtobesemip
osit
ive.Byd efini
tion
.
96 UNEARPROGRAMMING
3
.
1 PR08LEMDEANmON 97

t
her
efo
re,3i
X ssim
ila
rtoth
eorig
ina
Jvari
abl
esi
nth
eLPprob
lem.Tr
ansfo
rmi
ngthe wh
ereall=0.4.a12=0.
6.al3=1.Bec
a u
seth
erearefi
vedes
ignvar
iab
lesin山e
pr
oble
md e
fin
itin,a
o d
dit
ion
alter
mswi白血巴 foll
owingc
oef
fic
ien
ts,a
'4(=0)and
r
e
a
r
m
e
ain
ingco
nst
rai
ntsinas
imi
larmann
er,th
eco
mpl
etee
qua
tion
sinsta
nda
rdfor
mat
al
5(=0
).ar
einclud
edi
n山ee xp
res
sio
nforg(x
)witho
utchan
gingi
tsme
aning: ,
g(
x) , ,
:alX +a
' 2+a
2x ' 3+a
3x ' 4+asx
4x s 8
.5 ,=
M
ini
miz
e j
(x)
:-990x 9
00X
2-5
25,
0- (
3.5
)
百l
eco
nst
rai
ntg
2()c
X a
nbes
imi
1ar
lye
xp隠 s
seda
s
S
ubj回 tt
o
: 8'
(X)
:0.4x,+0.
6X2+X
J=8.
5 (
3.
6)
g
2(X
),
:z
Gx,
+auろ +a2
3x3+a2
4x4+匂s
Xs=2
5
8
2(X
):3X,-X2+X4=25 (
3.
7)
ec
Th o
e田c
ien
tsi
nth
eab
ovee
qua
tio
nca
nbe回 s
il
yes
tab
lis
hedb
yco
mpa
ris
onw
ith
8
3(
X):3x,+6X2+Xs=70 (
3.
8) Eq
uati on( 3.7)
.Le tt
in
g白erig
ht-h
ands
idevJu
a e
softhec
onst
rai
ntsbere
pre
sen
tedb
y
b"b2, ・・・ , bm • 出e s
t血 血r
dfor
matinE
quat
ions(3
.5
)ー(3
.9)c佃 be位 叩s
lat
edt
o

x~ 0
; ~~0
; x3~ 0
; x4~ 0
; Xs~ 0 (
3.9
)
M
ini
miz
e j
(x)
:cT
x (
3.1
0)
Equ
ati
ons(
3.
5)ー(
3.
9)e
xp
rl蹴 t
heLPp
rob
lemi
nst
and
ardf
orm
at.Ani
nco
nsi
ste
ncy
canb eobservedw i由r es
p田 tto曲ef o
rmatoftheproblemsprevious
lyd e
finedinthe S
ubj即 日0
: g
(x)
:Ax=b (
3.1
1)
book
.Namely 8
,(")w asr eservedωdefi
nei n
equaJi
tycons位置in
tsw hi
leh(,)d
, ef
ined
珂u aJiy∞m釘a
t ints
.H ere,8(
X)isaJsobein
gu s
edforequaJi
ty∞n s住ain
ts.Thischange S
ide∞n柑 a
int
s:"~ 0 (
3.1
2)
i
sa cc o
nunodatedi n白isc ha
ptero n
ly.Insubseque
ntc ha
pterstheprio
rm eaningfor
thes ymbolsisr e
stor
ed.A ct
ually,symbolsarenotrequir
ed創 出ec onst
raintunder xrep
rese
n tsthec o lumnve
cto
rofdesig
nvari
abl
es,in
clud
ing山es l
ackva
ria
bles,lx
"
dis
c凶 s i
on伺 na 1sobe児 島r rd1
e 0byequati
onn um
ber.Thef ormu1at
ioninE quat
ions X
2 ・
・...x,,]Tσm戸田entst he佐ans
posi
tio
nsymbol
).c陀 pre
sent
st h
ecolumnv e
cto
r
(3.
5) -(
3.9
)c a nb ee xp問sseds ucc
inct1
yb yr es
orti
ngt oam a
trixn otat
ion.ηlis ofco
stcoeffi
cient s.[ "C2.・
c C,
.• ,JT
.br ep
res
ent
s曲ec olumnvect
orofth
econs
t r
ain
t
conversio
ni sq ui
tes t
raight
forward
.B efor
ee mbarkingon山i st ran
sforma
tion,the i
Imi
ts.[b"b2• • • • ,b
m]T.Arepr
ese
ntsth
emxnm atr
ixofcons
tra
intco
eff
ici
ents
.In
repr
e se
ntati
ono ftheobje
ctivefuncti
onneedstobechang巴d
' ag
ain.Thec o
nstantterm 山isbooka l
lvec to rs眠 c olu
mnvect
orsun
les
so I
tl
erwi
seide
nti
fie
d.

-
、aM,

川MIN

i
sb roughttother igh
l-han
ds ideso白紙由巳 o bj田 ti
vefuncti
on伺 nb eexpres
s 叫 wi

-B

-

1
c・
ι1h ・
a

r'EBEEE'EEEEEEaEEE

r -EE E -E E -EEEa--
ムU ムU . L U
rEEEEEEEEEEEEEEEEL


12m
12m
term
so n
lyi n
v o
l vi
ng出ed es
ignv ar
iabl
esont h
er i
gh.T h
isiss howna sL(x)below.

EEEEEEEE'EaEEJ
t

Elli--J
-

-

l
・c・

aa


aaj

h
.

J
l
A
Oncea gainforconveniencethesames ymbo
lj(x)i
su sedi
np lac
eo fth
isnewf unc
tion


hu

X
副剛


p

l
.c
t,

l
i
ns u bse
quentd isc
ussio
ns.T hesee xt
ras y
mbolsh avebeent hrownint ok eepthe



-W
der
ivationdisti
n .T
ct hisisas mallpric
efortheabil
ity10d e
velop血er n
athemat
icaJ

リ﹂
mode linan a
t u
m lwaya nd陀 constr
ucti
ttoc o
nf o
rmtot h
es ta
ndardrep陀senta
tionin


mostr e
feren
ces.T h
erefor
e: Co
mpari
ngEq
uat
ion
s(3
.10
)an
d(3
.11
)wi
thE
qua
tio
ns(
3.
5)ー (
3.8
)由ev
ect
orsa
nd
m
atri
xare
M
ini
miz
e L
(x)
:jx
()+5
250=-990x 9
00~ ,
- (
3.
5)
c=[
-99
0-9
0000O
]T
Th巴fol
lowin
gdefi
nit
ion
sa r
cu sedtor ewrit巴
tIl
eproblemusin
gmalr
ice
s.Letth
ec o
st
co
eff
ici
ent
sb erep
rωe
,nt
edb yc・ ,
C2,• .• ,c
"
.Thec o
effic
ient
sin出ec on
str
ain
tsare b=[
8.
5257
0]T

A
zh
?i:
!

re
pres
ente
db y山esym 加1 a
ij(usingdo ublesub
scr
ipt
s).百lefir
stsu
bscr
iptid
ent
i自民
自巴 c
onst
rai
ntn um
berwh i
1et hese co
n dc on
str
ain
tist hesameasthevari
abl
eitis
mu
lti
plyi
ng.Iti
saJsous
efu1t oide
ntify出巴日r s
tsubsc
riptwithth
er o
wn umberand
th
esecondsub
scr
iptwi白t hecolum nn um b
erto∞r respo
ndw i由opem
tions伽 tuse
i
Ine
aralgeb
m.F o
re x
ample,the∞ 田 町a in
t8(,x)wil
1ber ep
陀s e
nte
d邸 ThefoU
owi
ngaddi
tionaJde
fin
iti
onshav
eb e
enu s
edinthesta
nda
rdforma.ni
t s出E
numb
erofd
esignva
riabl
es佃 dmis白en umberofco
nst
rai
nts
.Intl
teexa
mple,
n=5

g(
x) ,
" x +a
:a ' 2+a
2x ' 3=8
3x .5 andm=3.Nol
eItl
atthesla
ckvar
iab
lesar
einclu
dedinth
ecountf
orn.
98 LINEAAPAOGRAMMING
3
.1 PAOBLEMOEFINJTION 99

NegatlveValuesofDesignV arlab
les:T heLPs ta
ndar
dm a
the
matia
c1model the
mselvesc a
nb ei g
nored.Thesecoe
fficiens,w
t hicharep re
sentasv ec
torsora
all
owsonlyfo
rnonne
gativ
edesi
gnvar
iab
les
.Thi sdoe
snotlim
it白eap
pli
cat
ionofLP ma回x ,canbem an
ipulatedtoyie
ldsol
utionsusingconce
ptsf romline
aralge
bra.
i
na nyway.Ther
eisastan
dardpr
oce
duretohandleneg
ativ
evalu
esfo
rvar
iab
le.I
s fa Al o
o katthegra
phicalsol
utio
ntoth
eLPp ro
b l
ems u
ggeststha
tt h
es o
lut
iontoth
e
de
signvari
abl
e,sayx
..iscxp
ect
edtobeunres
lrIct
edinsin,
g 出eniti
sde
fine s出e
da prob
lem, i
fi
te x
ist
s, m
us tl
ieonthecon
straintboundarybecausethecurva
tureofth
e
di
ffere
nc巴oftwononn
egati
vevar
iab
lcs o吋ect
ivefunctio
niszeroeverywhe
re(i
ti
sl inea
r)
.F urth
ermore,thesol
utio
nto恥 LP
pro
blemisp ri
maril
yi nflu
encedbyEqua
t ion(3.11.B
) ei
ngai Inearequa
tion
.t o
pic
s
x
. =x
-1 .
I-^J
.
;-^
x1
J (
3.1
3) fro
ml i
neara lge
braaren ece
ssarytounderst加 ds omeo f出ei mpl
icati
onsof白e
m
athema
ti c
alm ode
l.
wher
ex~ a
ndx~ a
reacce
ptab
leLPvar
iab
les
.Ifth
elat
te
rishig
herth
anth
eform
erx
,J I
fn=m ,白atis,
then umberofunknownsi sthesameast henu mb
ero fva
riab
les
.
ca
nh av
enega
tiveval
ue.E
s qu
ati
on(3.
13)i
su s
edtorep
lac
ex i ,
nt h
emath
抑 制cal t
h
p
r
e
o
r
ec
vid
a
nb
e
do
enos
nee x
i
c
s
t
o
s
'
pef
.I
o
nt
ro
h
pt
ef
i
m
o
iz
1o
l
a
t
w
i
i
o
n
g
sE
na q
.manyo
u
a t
ion(3
f白巴 c
.1
1
o
)w
nc
e
i
p
l
t
ld
sa
et
r
e
ec
rm
x
i
p
n
l
a
e恥 s
i
ne
o
dt
l
h
u
r
t
i
o
o
u
g
n
.
h
modelN
. otet
hat白isproc
edurca
lsoi
ncre
ase
sthcnumberofdes
ignvar
iab
lωint
he
mode.
l s
implegraphic
alillus
tra
tin,
o o
rb ycon
sideratio
no fsimplee x
amples.T he
ym ost
ly
d
ealwithexamplesoft wovari
abl
es(x"X2).Fore xampl,
econsid巴rtwocons釘ain
ts
TypeofC o
nstrai
nts: Theless白 anore qu
alto(::
:
:
)c on
stra
intw ashandl
ed
g
l: xl+Xz=2
n
a
t
e
a
t
c
u
h
r
a
n
dba
n
l
i
q
l
yi
u
l
s
nd
efo
ob
e
ro
v
e
b
ep
l
t
a
o
o
i
s
p
n
i
t
i
n
i
n
i
gt
gt
v
h
h
et
eLPs
es
h
o
r
l
o
u
u
g
t
t
i
h
a
o
o
nd
a
nr
u
r
e
q
tI
.
dm
ui
r
ft
a
t
e
h
e
he
st
r
m
h
a
ei
at
ica
lmode
t出es
sac
l
o
n
a
c
s
kv
t
ra
a
i
n
l
.
r
i
百l
ab
l
es
e
t
sb
t白紙 i
an
d
ep
sr
a
o
e
r
s
iv
qu

dn

i
r
u
e
e
m
e
t
r
o
s
dt
i
t
c
a
a
r
ob
l
t
e
g
2: -x1+
Xz=1

m
aintai
nedabo
veas p
eci
fie
dv a
lue,f
orexam
ple F
igu
re3
.1ill
us
tr
ate
sth
egrap
hic
als
olu
tio
ntothepr
oblem
.Theso
lut
ioni tx =
sa 0
.5, ,
a
ndX2=1 .T
.5 hisi
sinde
pend
ento
ftheobj
ect
ivefun
cti
on(w
hate
veritmayb
e)
.ln
m
atr
ixf
orm.Aa n
dbare

g(x):a , 2x
" x +aJz+a'3x3~ b, (
3.1
4)

斗U
--
﹃│﹁

-
r

-


-・
-EAt-
-
A

lE‘

-
A


t
heni
tapp
e紅sna
tura
ltointr
oduc
ean
ega
tiv
esl
ackv
ari
abl
e-X4t
och
ang
eEqu
姐on

EE -L
-

LU
-且


(
3.1
4)t
oaneq
ual
itycon
str
aint
:


g(
x) ,
lX +a
:al 2x
l 2+a
'3x3-x4主bJ
百l
w
ee
i
t
x
i
hr
s
o
t
e
w
nc
巴o

son
fas
l
o
yf
l
o
r
u
t
c
i
o
n
o
nd
ve
e
p
n
i
e
e
n
d
n
c
so
e
nt
)
h
er
.If
t
o
w
h
so
fA(
ero
o
w
rc
o
so
lu
m
fAa
nso
r
fA-wew
elin
ear
l
il
ld
yi
nd
e
a
e
p
l
en
den
t,t
henth
ere
i
sau n
iqueso
lut
iont
o白es ys
temofequ
ati
ons
.
Whil
eiti
sposs
ibletoch皿 ge血es i
gnonX4bymul
tipl
yingwit
h-1白r o
ughout
,白is
c
aus
es白er ig
ht-
handcon
strai
ntlim
ittob
enega
tiv
e,whic
hs h
ouldb
eavo
ided
.Ins u
ch T
hDefinean
otherprob
lemasfol
lows(on
lycha
ngingb 食omth
eabov
eexamp
le)・
enewproble
mis
c
ass,
e ano
thervar
iabl
e,xs,i
si n
clud
edinth
eexp胞ssi
on
.I nth
isca
se,
twoaddi
tion
al
v
ari
abl
esarenowpartofthemodel
:
g:
, x,+ろ =2

g(
x)
:a ,
" x +a
' 2+al
2x 3x3-x4+Xs=bJ g2
: 2xl+2x2=4

τ
'ev
h a
ria
bleXsi
sca
lle
d剖 a
rti
fic
ialvar
iab
le.A
rtf
iic
ia
lva
ria
ble
s創芭 al
soin
trod
uced Thenewf unct
iong 2rep
rese
ntstwice出ev alueo fgl・Thisme a
nsg 2canbeob t
ained
f
or回 c
hequ
ali
tycon
str
ain
t白紙 isn at
ural
lypr
esen
tinth
emode .T
l heus
eo fth
ese 加 m8 J'Th e
refo
re ,82i
ss ai
dtod ependon8 1・T e
chni
cally,出etwo巴q uations釘 e
v
ari
abl
eswi
1b
l ei
ll
ust
rat
edla
te
rt hro
ughan巴xa
mple. lin
earか
,d e
pendent一 白ea c加叫 depende
nc eoft hefunc
tionsi
sn otaconcema smuch
asth
efact白創出e yar芭notlin
ear
lyindependentB
. oth81and8 2es
tabl
ishth
es amelin
e
gra
phi
call.Wha
y tist h
esolut
iontotheproble m?T h
ereareinfl
nies
t o
lut
ios,
n a
sl on
g
3
.1.
2 ModellngIssues asthepairo f(Xl・X2) va
luessati
sfi
es8 1・I nF igur
e3 .a

1 nyp oi
nto nt helin
e
rep
rese
nting81isas olu
tio
n.N otonly(0.5,1.5),but(2,
0),(0,)a
2 r
ea l
sosolut
ions
.
TheLPp ro
grami
sc h
ara
cte
rize
db y白emathe
matic
alm odeldefin巴di nEqua
tions From卸 o pti
mizationper
spect
ive,白isisq u
iteg oodf o
ru n
liketheprev
iousc a
seo f
(3.
10
)ー(3
.12
).Duetoth
elin
earna
tur fa
eo 1
1ofth
ef u
nct
ionsinv~lved, t
hedi
scus
sion u瓜quesoluti
on,theobje
ctiv
ef u
nctio
nc anbeu se dtofi
ndt h
ebestsolu
tio
n.1two u
ld
ofthes
olu
tionne
edonlycon
sider恥 coe
ffi
cie
ntsofthefunctions -theva
ria
bl邸
bebet
ter,how
ever ,i
fthechoi
cesw e
refinit
er athertha
ninfin
ite
.
1
00 L
INE
ARP
ROG
RAM
MIN
G 3
.
1PR
OBL
EMD
EFI
N町1
0N 1
01

-
u・・
-
i
m

“u
U
e
n

e
FM

n


∞n

e

RH
RM可

RM
g.f-
ena 2
;ma 3
:Nos
ol
ut
lo
n;I
n s
ls
te
n!5
e
!

auy
u

H
HM
2


Cas

0
4

F
4


lo

V一予一一一

vb//之
3
3

KAA
m
昨年
d引引訓ゴ////
2
1ー

)
(
'
"1 )(~・ 1

。 。
ー1 ー1

-
2

-3
J -2 o 2 3 -3
4 -
2 -
1 o
X 2 3
1 X
1

F
lgu
re3
.1U
niq
ues
olu
tio
n-U
nea
rin
dep
end
enc
e.
F
lgu
r由3
.2N
oso
lu
li
on,
Inc
on
sl
st
en
tse
t01e
qua
tio
ns.
Whiles ever
aJc xa
m ple
sc a
nbec o
nstruc
tedt oill
ust
ra
tel i
nea
rd cp
endence,i
t R
cde
fin
eg3a
s
ap
pearsreasona
bletoa ssumethatfo
ra凶 φ11回 ercis
e仇 optim
izat
ion,t
henumberof
co
nstra
intscannotequalthenumberoful
Iknowns(m手 n).Inth
ep r
evio
usill
us岡 山n ,
n=2釦 dm=1( ther
ewaso n
lyo neef
fec
tivecons位ai
nt.I
) ti
susefu
ltorecog
nizetha
t g
3:X
I+2ろ =
3.5
出iscorre
spondstothec a
sen>m .
Thi
snew8 s山ed
3i as
hedli
nei
nFigu
re3.3
.Nowau niqu
巴solu
tio
nt o出eprob
lem
Ifm>n ,the
rearemoree quati
onsthanthenumberofv a
ria
ble
s.百 l
isimp
lies白紙
a
t(0,
5
.1 .5)i
ses
tab
lis
hed
.百lisi
s山 othesol
uti
onest
abl
ish
edbyconside
rat
iono
f8¥
th
es ys
temo fequat
ionsreprese
ntedbyEquation(3.1
1)is叩 inco
nsis
ten
tsetorhasa
叩 dg2a l
one
.Thisimp
lies白紙 g3isredu
ndan
t.If81ismulti
pli
cdb y1.5,8
2is
re
dundantsetofc q
uation
s.C onsi
derthefollowi
ngi l
lus
tra
tio
nform=3a ndn=2
mul
tip
liedby0.
5andbothad
ded
.thcre
sul
tisg3de
fine
dabove
.Thatis,
whichusesthesame8¥a ndg 2asinth
cfirs
tillu
str
ati
onwhileaddin
ganew8 3:

g
3=1
.5g
l+0
.5g
2
g
¥: X.+X
2=2
ぉcanb
eobtai
nedbyl
ine
arl
ycombi
n i
ngg¥andg.白紙 i
2 s
.addi
ngcon
sta
ntmul
tip
les
g
2: -x1+
X2=1
o
f仰 向n c
tio
ns.Thi
sisa no
there xa
mpleo flin
earde
pende
nce
.T hsl
i in
ear
g
3: X¥ 2=
+2x 1 d
epe
nden
ceandred
und
allC
Yisa
lsoi
IIus
tra
tedbyth
eset

F
e
i
g
x
i
u
s
rc3
.I
t
.
fo
2i
n
l
ew
l
us
e
t
r
r
a
t
et
es白紙 t
oex
istt

h
es
h
e
e
to
nth
fe
et
q
u
h
a
r
t
e
i
el
o
n
i
si
ne
si
sm
n
u
s
c
on
tp
s
i
a
s
s
t
en
st
ts
hr
o
i
n
u
c
g
easo
l
h出es
u
o
t
i
l
u
o
t
ndoωnot
i
on.Si
nce
g
¥: X¥+"
2=2
出eyar芭 a
lls釘泊ghtlin
es,出e ec
r anbeo nl
yo neuni
queint
crs
ect
ingp
ointInFig
urc g
2:-
xけ ら =1
3.
2onlyt woofth巴th
reeline
sint
er百e
ctatdi
ffe
ren
tpoin
ts. g
3: 2x1
.・2
x2=4(
sam
easg
l)
102 L
lNEARPROGRAMMING
3
.1 PROBLEMDEFINITION 103

F
orn=
=m,andw
ithg
l l+x
:x 2==2,a
ndg
2:ーX
1+X2=1
,出em
atr
ixA i
s

﹁│卜﹄
C
asena 2 .=:Un
lqU
8so
lu
ll
on,
Uno
ard
epe
ndo
nc9

11
;m

-EEEEE﹃E J
3

A
=
4
-
-、
E-
a

h

a
ndi
t
sde
ten
nin
anti
s
h
h

d
et(
A)=I
AI=(
1)*
(1)
一(1
)*ー 1)=2
(

.
r1 Fromt heor
emsinIinearalg
ebra[5],
ifd
et(A)isno
tzero,
inwhichca
set h
em atrixA
ter
me dnonsi
ngular,auniqueso
l u
tio
nexi
ststoth
esetofeq
uati
on.Th
s i
swas町u cfo
r

。 ・- "3.5 白ee
gr
aph
xamplei
ica
llyi
I
Iu
nF
s
i
g
回 t
ur
e
e3
da
.1
b
.
ove,as恥 o nl
ys o
luti
onw俗 locate
dat(0
.5,1.5),shown

Considertheexamplewithgl:XI+X2=2,叩dg 2:2x1+2 x
2=4.In山 i
sc ase,

d
et(
A)=I
AI=(
1)*
(2)ー(1)ペ2
)==0

l
fdet(
A)iszer
o,th
ati
s,m
atr
i ss
xA i ingu
lar,恥 rear
eei
thrn
e oso
lUl
ionsori
nfi
ni
te
s
oll
ll
io
ns. For 山i
se xa
mple,出ere were in
fin
iteso
lut
ion
s.Dctcr
m i
nan
tso f
-3 h
igher心rdersqu町 '
ematri
cesareevaluatedbys ett
ingu pl o
wer-or
derdeter
minan
ts
-3 -
2 O 2 3
X u
nti
l出eyare陀 ducedt oa2x2d ete
r m
inant,whichi se v
alua民da sabov
e.An y
1
t
extbookonenginee
ringmathe
maticsorlinera
a 1gebrashouldill
ust
rae白 i
t stech
niqu
e.
F
lgu
re3
.3U
nlq
ues
ol
ut
ln,
o I
In
ea
rde
pen
den
ce. I
tisnot回 produc
edh e
re.
I
fn" "m, d
iscus
sionoftheexi
stenccofsoluti
onsrequi隠 saddi
tio
nalconc
eptsI
ike
r
anko fam at
rixa nda ugme
nledm atr
i x
.S ince由巴 c asen>m i so fint
ere
stin
Thissuggests 出 創 出ec on
cepto fredun
dancyc an be ass
ocia
tedw ithl i
nea
r o
ptimi
za t
ion,onlyt ha
tc aseis employed ins ubs叫u enti l
Ius
tra
tio
n.A u sef
ul
depe
ndence.Th edis
cussi
onofli
nea
rdependen
c eandinde
pendencewasestabl
ishe
d d
iscus
sionwillneedat1eas
tthre
ev ar
iablesandtwoe q
uations
.T hre
ev a
ria
bleswi
ll
凶 泊ge q
ua t
ionsabove.Thesamed is
cus
sionc antak
ep lac
cbyr e
asonin
gont h
e d
en yth
eu seofgraph
icstodevel
opt h
ef ol
Iowingc on
cepts.Usingtheset
co
effi
cic
ntst he
mselv
cs.Inthi
scasetheco
effi
cientma凶 xA shouldleadusto血e
sameconcIu fI
i
conc
eptofad
si
o
e
nr
ler
m
c
g
i
a
n
r
a
d
n
in
g山el
li
sn田 c
i
n
s
s
e
a
a
ri
r
yt
nd
od
e
e
p
v
e
n
e
d
l
e
o
nc
pt
eo
h
fas
ec
rit
er
e
to
i
aforl
n
i
e
a
n
e
re
ard
q
u
e
a
p
t
e
i
o
n
n
d
e
s
n
.百 e
ce.
g
t: x1+X
2+X
3 3 =
g
2: -Xけ ら +0
.5x3 1
.5 =
De
termln
an t:Thed
ete
rmi
nan
tisa
sso
cia
tedw
ithas
qua
rcm
atr
ix.F
orag
ene
ral2x
t
hem
atr
ice
s紅 白
2ma
trxA,
i where

-
I

一A
flト L

﹁│仁
ω

--
Il

35
Il
35

1 n
rMlML


-
-

--EE E. J
・,

可EEE E
A


-
FEE-EEaE﹄
a

可EEEEEEJ
-
=
・Ea内,.
可EEEEBEE-J


hu
a
(
3.1
6)
=

--a
A

-
E・内, a

Z
-
勾,働帽


a

u
M

4

d
出ed
ete
rmi
nan
tise
xpr
es'edande
val
uat
eda
s Thenewma
tri
xA.i
sca
lld出ea
e ugm
ente
dmatrix-thecolumnsofbarea
dde
dtoA
.


i

a
│a
Ac
cordi
ng10山∞re
msoflin
eara
lge
bra(
pre
sent
edh e
rewithoutp
r of
o )
:
3.
(15)
いいい
い=d


白似叫
d

削t
(

巴山
A

削ル
山門)
=同a
=

a
句21 句2 • I
fthea
ugm
e n
tedmatr
ix(A・)an
dt h
ematr
ixo
fco
eff
ici
ent
s(A
)ha
vet
hesame
r
ankr<n,山en出 e
r巴M巴 manyso
lut
ion
s.
1
04 L
lNEARPROGRAMMING
3
.
1 PROBLEMDEFINITION 105

.I
f曲eaugme
ntedma 凶 x(A・加d出em
) a
trixofc
oef
fic
ien
ts(A
)donoth
aveth
e i
n出eb oo
k.百 l
e(+1)加d( )b
ー1 elo
war芭 o
bta
inedbyusi
ngー
(1);
ザ, w
her巴ian
dj
s
ameran
k,asolu
tio
nd oesn
otexist
. r
epr
ese
nt出erowandcol
umnv
alu
esoft
hecoe
ffi
cie
ntmu
lti
ply
ingth
evalu
e
・I
fth
eaugment
edm a
trix(A・
)a ndth
ematr
ixofcoe
ffi
cie
nts(
A)ha
veth
es a
me
r
ankr=1,wheem=n,
r the
nt h
erei
sauniqu
巴sol
uti
on. a
l1 a 門 a
ll "
l ー -

Rank01aM atri x:W hilether


ea reformaldefi
nition
sf o
rd ef
inin
gt h
er anko f出e
A=1 0
;lln ailn卜(+l)a111273│+( l)a1212J2│+(+l)a13仕ご│
~1 ~2 1

I~. ~, I 1
-
-~ I -~:l l
33
品 目

ma凶x ,ausefulwayt odetermin


e出巴 r ankisωl o
o k鉱 山e deten
凶n 剖t.τ'
h erank o
fa
ma
trixAi st h
eo rderof出el ar
gestnonsin肝l a
rs qu
ares ubm
atrixofA,t hatis,出e (
3.1
7)
l
arges
ts ubmatrixw i
thad etermi
nanto t
her白a nzero. 百l
ere
for
e,
Int h
ee xampl eabove, t
helarg
estsquaresubmatrixisa2x2m atri
x(sincem=2

Ill

dm <n

-
an .T aki ngthesubma 住ixw hichi n
clud
est hefir
sttwoc olumn
so fA,出e

-EA--A2且
'且'且今,
)

11
-

-
-
A

'Ea'EA

2A 司
a

+

-

f2,

且-
tA
de
terminantw asp reviouse s
tab
lishedtoh aveav alueo the
refor
eno ns
ingular
.

,.且

a
'

-
a

-
A

a
s,

a
L
Thu th
er anko fAi s2( r=2).百l esamec olumnsappearinA m
市 akingi
tsr ankalso

M
2
.官 l er
efore,infini
telym血 ys o
lution
se xis
t( r<n ).Onew ayωde 民r mine白E
so
lution
sist oa ssign(n-r )var
iablesarb加的 v alue
sa ndu s
et hemtod etermine
=(
1)(
0)+(
-1)
(-)+(
2 1)
(ー3
)=-1
va
luesfort here mainin
grv a
ria
bles.Thev aluen-ri salsooft
eni d
巴nt
ifiedas出巴
de
gr e
eo f
fr eedom(DOF)f orth
esy st
emo fequ
atio
ns.lnt h
eparti
cul
arexamp l
ea bove, A.isnons
ing
ularandi
t
sr a
nkis3wh I
ietheran
kofAis2.Thesys
temofequa
tion
s
山eDOFc anb ei den
tifiedwithav alueo f1(i.
e.,3-2 .F
) orinsta
nce,x3 canbe w
illhavenosol
uti
onsfr
omtheabovet
h 巴orc
ma n
dcanbese
engra
phic
all
yinFigur
e
as
sign巴dav alueo f1inw hichcaseXI=0 .5叩 dX2=1 .Ont
.5 h
巴otherhanc
J.ifX3=2, 3
.2.Forthesakeofcom
plete
ness,us
in gth
ep r
evi
ous
lydef
ine
dd ep
enden
ts e
tof
th
enXI=0 .
2 5andX2=0 .7.Thea
5 b o
vec as
esillu
str
atetha
tforaDOFo f1,on c
ex3is e
quati
ons
:
s
elece
td.Xl阻 dX2c anb eobtain
edt hrou
ghsomef urthe
rp r
ocess
ing
.
Anothere xam pleforiI
1ustr
ati
n g曲er ankis出ei nconsi
sten
ts yste
mo fequation
s
i
n釘o ducede 紅li
erw heren=2叩 dm=3 ,rep
roducedforconvenie
nceω g
l: x1+x
2=2
g
2 2=
: -x1+x 1
g
l: x1+x2=2 g
3 x1+2
:2 x
a=4
g
2: -x1+ろ =1
w
hic
hyi
eld
sth
efo
llo
win
gma
凶ce
s:
g
3: x1+2
x2=1

l}
[
-l 1
Them
atr
ice
sfo
rth
iss
yst
ema
re
A= b=[!} A'=H !
]

A=H }
l b=[I} A'=H i
]
l Ther
det
er
a
n
m
i
ko
na
n
fAi
tyi
el
.N
s2
d
o
t
sas
e白紙 u
i
ngu
la
si
ngt
hefi
rs
ta
r2x2subma
n
dl
凶x
a
str
o
.Thed
wo
e
te
fAf
r
min
a
o
n
rt
h
to
ec
al
fA i
c
u
s
la
tio
noft
he

-
-


'


'1 1 L
-

-
TherankofAc annotbegrea
ter白 血 2,s
incen=2a n
disl es
sth加 m=3 .Fromp r
ior

.


A--a--E


-

a ' A a且守


'
a且勾,“

寸2
'ia T

'A
A

+

+
2A
ト,

=
(

'
.
Z
'
ca
lcul
a t
ios出ed
n e
termina
ntoft h
efir
sttworowso fAis2 .Thisisgr凶 te
rt h
anzero

nu

z
z

00
司品
'

ζU
今ゐ

.E

A﹃


司, B
andth巴re
for
ether a
nko fAis2.ForA.t h
ed et
ermina
nto fthe3x3m at
rixh a
stob e

4

exa
mined.Thed eterm
inantofag e
nera
lnxns q
uarematrixAC a
nb ecalcul
atedin
ter
mso fth
ecザ'act
orsofthematr
ix.Thecofac
torinvo
lves血ede 飽nni
nanto faminor whic
hmakesA.s in
gul
ar.However,t
herankofA・ i
satle
as
t2duet
o出巴 pr
esenc
eof
matrix-whichisan(n-1)x( n-1)matr
ixo b凶nedb yd
el et
inganappropr
iatesin
gle 曲目阻 l
esubma佐ixwhichdet
ermin
edtherankofA.Fromth
eab
ovetheo
rem血e
, r叩 k
rowa ndasingl
ec olumnf r
omt h
eo r
igi
nalnXnma xA,
住i multip
liedby1o r-1, ofAise
qua
ltotherar
tkofA.,wh
ichis2andthi
sisle
ss出制 m=3.I
tcanbec
oncl
uded
depe
nd i
ngon曲e t
o凶 o fth
er owandcolumnvalu
es.References5a n
d6c 胡 p ro
vide 伽 t出er
earein
fil
li
tesol
凶o nsfor山 s ys
temofequat
ion
s.
mor巴infor
mat
ion.He r
e,出巴 de
t e
rmin
antforth
e3X3m at
ri xi
sd efi
nedforilu
I st
rat
ion
106 L
lNEARPROGRAMMING 3
.2 GRAPHICALSOLUT
lON 107

rhHhμい

1111111﹂

rlll111L
r'EEEaEaE E -EL
守EEEEEEEEEEEEJ

-
Ause
fulob
serva
tiono
fmatr
ixA・回 thep
陀c ed
ingexa
mplei
s白紙 twooft
herows

FEE--EE E -BEE-L
'znunu

可EE--EEEBEESEEJ
nu'且 nu

nunu'E
可EBB-a'EBEE--J


(
3.1
8)



=


+

+
a
reaconst
antmult
ipleofe
achoth
er.百世smakes出ema 回ce
ssi
ngu
la.Th
r esame


43

eq

e‘崎
43



L


今ゐ

d
L

'
h
oldsf
ortwocolumns出ata
remul
tipl
esofeac
hothe
r.

d
Un /tV ectors:R eal-worldo ptim
i z
ationp roble msf requentlyi nvolve al ar
ge Thea dva
ntageofunitvect
orsis白紙曲e yc ancst
ablis
h加 ypointintheCar飽s ia
n sp
ace
numbero fdesignvariables(nvariab
l e
s).Inrea
lLPp roblems.白 enumbero fvariab
les throug
ha na pprop巾 t
et ri
ado fnumberss i
g凶f yi
ngc o
ordin
atev alue
so r10回 tio
n.
canbes ta
ggering.F oras u
ccessfuls ol
utionto出eop 也凶 z atio
np roblem.i tis Acωally,anyp oin
ti n由eCartωians p a
cec anbed e
tennine
db yanys etoft h
l国
impli
citlyassumedt hatt heseto fdesignvariab
lesi slinearlyi ndep
e nd
e .
ntTh a
ti s
. lin
earl
yi nde
pendentvecto
rs.Th es
ev e
ctorsaret er
medthebasisvect
ors.Inthi
sc as
e.
thereisnod i
rectd epende nceamonga nytwov ariab
leso ft hesct
.I n出i scase.the th
es implec on
nectionb etweenthep oin
ta n
dt heelementa
rya dditi
on,illust
rat
ed
abstract~pace spawnedbyt hedesignv a
riable
sisc al
1ed白en -dim
eflsi
oflalEuclidean above,wi
llnotbeavaila
bl巴.Fu巾 e rmo
re,伽ought hemethodsofiIne
ara l
gebra,the
se
space.Th eworda bstractisuscdh erctosig
nifythati
tisac onstructintheimaginatin,
o th
reev cc
torsc anber educcdt otheunitv cct
orst hr
oughele m
entaryr ow/column
aso nlythreevariable
sc a nbeaccommodatedi n由巳 f a
miliar3Dp hys
icals pa
ce.百 le opc
rationsーa l
socalledG aus
s -Jor
dane liminat
iono rred
uction
.I nn・d i
mens i
onal
designv e
c t
orisap ointi n白 i
ss pac.Th
e eE uclid
e anspa田 i sad i
rectextrap
olationof Eucl
i d
eans p
aces p
a nnedbythend esignvariabl
es,白ep oi
ntp"(p..P2,...,p"),wi
ll
thep hysicl,geome
a 凶c al3Ds pace伽 ts urroundsu .T
s hiss paceist er m
e d恥 berepres
entedbyac ol
lecti
ono fnvaluesenclosedinpar
官n白eses.Thec orres
po n
ding
Cartesians p
ace.Fora ni11ustra
tion,consid
erthep oint(2,3,2
)i nCartcsi
ans paceorin 目unitvecto
rsared巴f i
nedas
there c
t a
n g
ularc oo
r d
i natesystem.I nFigure3,
4
.t hep o
i ntismarkedP .The凶 adof
numbers w ithinp arenthesesd enotest hev alu
esa longt ex
h "X2・andX3 畝 es, o (
3.1
9)
陀s p
ectively. o
TheC artes
i ans
markedx"x2'andx3・
pacei
Thep
sid
o
e
i
n
t
n
ifi吋 byas
twherct he
yi
e
to
nt
e
fm
rs
e
u
c
tu
ti
a
st
l
lyp
heor
e
i
叩e
gi
nd
n(
i
0
cu
)o
l釘 l

ft h
i
ec
n
eso
oor
ra
di
x
n
a
e
t
s
e
e
"
=I
.
syslem.Thep o in
tPc a nalsob eassociat
edWitl
lt hev e
ctorOP.drawnf romtll
eo ri
gin
oto血epointP.Veryoftenapointandavector-twoverydifferententities-are
useds ynonymou sly.Frome lementaryv e
ctora d
ditionp rinci
ples,thevectorOPc an 官l
eve
cto
rfrom由巳 o
rig
in(
0)t
oP"i
s陀 P問 s
ent
eda
s
becons 回 ctedbyc onsecut i
velyj o
iningthre
ev ectorsalongt hethr田 coordi
nate出 es.
Int h
ef igurethisisshownbyl ayingo u
tav e
ctora longt h ,
ex a xs,a
i d
dingav ec
tor OP=
pe +P
2e2+.
..+p"ell ,

along出eX2a xist oit,andf i
nallya ddi
ngt hcthirdv ectora longthcX3 a x
is.The Th
esenewd
efi
nit
ion
swi
llb
esu
ffi
cie
ntt
oun
der
sta
ndt
het
ech
niq
uesu
sedt
oso
lveLP
addit
ionals mallarrow sint hefigureare白eL mitv ec
tors.百l eyhaveam a g
n itudeof p
robl
ems
.
oneandad irectio
na longe acho fthe蹴 es.Th eseunitv ectorsarelabelede"e 2,and
e3int hef i
gure.Mathe matically,出巴p o
intP( 2,3,2)andt hevectoradditioncanb e
rcpresentedω(columnv ecto
rs) 3
.2 GRAPHICALSOLunON

百leg r
aphic
ald is
cussio
ni sagainl im
ited10twod esig
nv aria
blesin由巳 o ri
gina
l
X
3 problemde
scri
ptio
n.Itisusedh e
ret odevelopcer
taingeometr
ici d
easr e
lat
ed10LP.
InLP,th巴int
roduc
tionofslac
kv ar
iableswil
le a
sil
ye xceedth
islimi
to ftwovari
able
s
fo
rg r
aphic
alil
l凶 住atio
n.s othegraphica
ls ol
utionisill
us回 te
dw ith民 spe
ctto出e
2 or
igin
alv a
riab
lesint hedesig
np roblem.MATLABi sonc eagai
nu sedt o合 aw出e

3
g
s
e
r
a
o
l
l
p

e
m

h
uo
e
i

n
c
a
n
ls
.I
ti
o
ti
lu
t
si
s出es
i
m
o
p
.Th
n
o
t
r
r
a
t
i
a
n
g
h
ep
tt
tl
r

i
ob

Le
1
lemi
odo50f
sn
o
otr
ran
e
um
,afunctionf
d
u
e
c
r
o
e
i
rd
d10t
c
als
ra
o
w
h
l
i
n
es
ut
t
i
o
g1
a
n
in
nd
.S
e
a
i
si
r
df
nc
sd
o
r
eI
e
m
h
v
atf
ep
el
o
r
p
o
i
e
rt
ma
h
r
dt
eg
yg
hr
r
r
a
o
u
a
p
p
g
h
h
i
i
ht
c
a
c
a
h
l
l

X2 fu
nctio
nm -fi
ledrawLine.mb elo
w.百 i sf uncti
oni salsou sedtop rovi
demore
expo
sぽ巴 toMATLABp rogramming.

draw L
lne.m:古 山 i
saf
unc
tio
nm・f
il
efo
rdr
awi
ngs
tr
泊gh
tli
ne
s e1
.百l i
ne10b
e
F
lgu
re3
.4R
ect
ang
ula
rco
ord
lna
tes
yst
em. drawnisr
epre
sen
teda
s
108 lNEAAPAOGAAMMING
L 3
.2 GAAPHICALSOLUTION 109

以 +by=c else cmult -1;


end
Sin
cex,ya r
eusedωsymbolsf orva
ria
bles,lr
x e
pres
entsth
elowerran
geonx, w
hile end
X2r
epr
ese
ntst
heu
ppe
rra
ngc
. Limit
ingI
ines/c
onst
rain
tscanbcdrawnbyse
ttin
geith
er
aorbt ozer
o.Color(r
ed)i
su scdt
od rawap 町'a
ll
elli
neat10%i n
crea
se/d
ecre
ascin 告 set up a factor for drawing the hash constraint
t
heorigin
alvalueofc(dep
endingonthed i
rect
ionoftheor
igi
nalin
equ
alit
y)inst
ead if (abs(c) >= 10)
ofhashmark
s.L im
itcon
stra
intsar
einm agentaandth巴obj
ect
ivefun
ctio
nisinblue cfac 0.025;
das
hedl in
e. ThenewMA 11.B c
A ommandh er
ei s出el inecommand. Youa re elseif (abs(c) > 5) & (abs(c) < 1
0)
enco
町a gedtos田 khe
lpont h
ecommand.Th ecod
e: cfac 0.05;
else
drawLine.m cfac 0.1;
者D rawinglinearconstraintsforLPprogrammingproblems end
者 Dr. P.Venkataraman
者 OptimizationUsing Matlab if (
c 0)
告 Chapter 3 ・ linear Programming cdum cmult*O.l;
も else
者 Lines are represented as: ax + by c (c >= 0 ) cdロm (
1 + cmult* cfac)*c;
者 x1,x2 indicate the range of x for the line end
者 typ indicates type of line being drawn 1 (<=)
も 9 (>=) 苦 if b 0 then determine end points of line x line
告 n (none) b-
if ( =0)
者 y1 (c -a*x1)/b;
苦 The function will draw line(s) in the figure window y1n (cdum -a* x1)/b;
者 the green solid line represents the actual value y2 (c - a* x2)/b;
% of the constraint y2n (cdum ・ a*x2)/b;
者 the red dashed line is 10 者 larger or smaller else
者 (in lieu of hash marks) 者 identify limit constrainヒs by magenta color
者 the limit constraints are identified inmagentacolor str1 ' m'
苦 the objective function is in blue dashed lines str2 'm';
者 y1 x1; 者 set y1 same length as input x1
function drawLine(x1,x2,a,
b, c,typ) y2 x2; も set y2 same length as input x2
告 recognize the types and set color x1 c/a; 苦 adjust x1 to actual value
if (typ 'n') x2 c/a; 苦 adjust x2 to actual value
str1 'b'; y1n "
'0 ; 者 set y 0 ;
str2 'b' y2n 0 ; 者 set y 0
cmult 1; end
else
str1 '
"' g' if (
a 0)
str2 '
" 'r'; str1 'm';告 set color for limit line
end str2 'm'; も set color for limit line
end;
者 values for drawing hash marks
者 drawaxis with solid black color
者 dependingon the direction of inequality
if (typ -= 'n') hh line([
x1,
x2],[
0,0]);
if (typ == 'l')
cmult +1;
110 lN
L E
ARP
ROG
RAM
MIN
G 3
.
2GR
APH
ICA
LSO
LUT
ION 1
11

set(hh,'LineWidth',
1,'Color','k'); 8
Or'

hv 1ine([ 0,0],[xl,x2]);
set(hv,'Linewidth',1,'Color','k
'); 5
60
者 start drawing the lines
line([xl x2], [yl,
3
hl y2]);
綿』
if (
t乎p 'n')
set(hl,'LineWidth',
2,'LineStyle'"
ーー', 'Color',strl);
else
set(hl,'LineWidth',
1,'LineStyle',
'・'
, 'Color',strl);
end
if (b -= O)&{a -= 0)
text(x2,y2,num2str(c)); ~~
end
if( b ==0)I (a ==0)I(ヒ yp 'n') .
.-,・--
句 ー

grid
守 ..


.
ーー・
・』ー

.
・‘.
・、 .
.
一 ..

return,end

grid;

.
‘.
..
・ .
・.
h

h2 line([xl x2], [yln, y2n]); 0


-4

一一一一一-
二 5
三.J-25
0
0 5 1
0 15 2
0 2
5 3
0
set(h2,'LineWidth',
0.S,'LineStyle',
':','Color',
str2); Nu
mbo
r01m
ach
lna
s01I
yp
eA
grid
hold on F
lgu
re3
.5G
rap
hlc
als
Ol
ul
in,E
o xam
ple3
.1
.

3
.2.
1 Example3
.1 3
.2.
2 C
har
act
erl
stl
cso
ftheSolutlon

Thep
rob
lemf
romp
age94i
sre
pro
duc
ed00田 moref
orc
oov
eoi
eoc
e. τbegωm
l etryevid巴n
tinthegraph
icalsol
utionofExample3.
1isusedtoexpl
ainsome
oftheco n
ceptsassoc
iate
dw ithLPa ndi lSnumeria
c1techn
ique
.F i
gure3.6is白E
gra
phicaJrcp問se
nlatio
nof曲巴 c on
stra
intsinvolve
dinExample3 .
1( sa
mea sFigu
re
Maximize j
{X) J+9
:990X 2+5250
00X (
3.1
) 3.
5w i
thouttheobjec
tivc釦n c
tio
n).Inorderto隠 l
at
e出egcometryωLPc oncepl
,t
S h
c
st
an也r dforr
natofLPisn 配 ωS釘y.Thes tanda
rdforr
nates
tabl
ishe
dbeforei
s
S
ubj
回 t
to: g
.(X
):0
.4.+0
x .62S8
x .5 (
3.2
)
M
ini
miz
e {X
j :-99O
) xJ-900x
2-5250 (
3.5
)
g
2(X
):3
x 2S2
J-X 5 (
3.3
)
S
ubj
ectt
o
: g
.(X
):0
.4.+0
x .6x )=
2+x 8
.5 (
3.6
)
めは):3
x 2S70
.+6x (
3.4
)
g
2(X
):3
x.-X 4=
2+X 25 (
3.7
)
;.
.~ 0
x ¥
i~ 0
g
3(X
):3
xI+6x s=
2+X 70 (
3.8
)
T
h巴g ra
phica
1soluti
ooisshowninFigure3.
5.Thesolu
tion,
rcadfromt
hcfi
gu飽 (yo
u
姐 Z∞m白e
C arcaofsol
utio
o),i
sxj= 10,and
xi= 7
.Itis出ci n
ter
sec
tio
noftheac
tiv
e -
x.~O; x2~0; X3~0; X4~0; x5~0 (
3.9
)
c
onst
rain
ts(3.3)叩d( 3.4)
.百leactu
alv al
uesaex
r j= 1 48加 dx
0. i= 6.
42
.S in
cean
i
nter
ga1numbero fm achineshavet ob eord
ered,thesolu
tionisadjustedωa I
nFigure3.
6t h
econs
tra
int
sx.~ 0andX2~ 0ar
ea ddcdtothet
hre
efunc
tio
nal
ne
ighbor
inginteg
erva1u巴由 a
tsat
isf
ieslheco
ntr
ain
ts. c
ons
tra
intI
ine
s(3.6
)-(
3.8
) a
.Theh.
'!
he
dare
aisth
cfeas
ibl
er e
gio
n,出a
tis,t
h巴des
ign
112 L
lNEARP伺OGRAMMING 3
.2 GRAPHICALSOLUTION 113

(
三)
=ポ

50

40
i
Thswouldy
iel
d10p
oin
tsf
oro
ure
x儲n
ple,
whichi
sshowni
nFi
gur
e3.
6.

30
BaslcVarlab
les:Thes e
tofvar
iablesi
nt hebasi
cs o
luti
ontha
th a
ven o
nzeroval
ues
ar
ecal
ledbasi
cvari
abl
es.Cor
respondingy,
l thesetofvar
iabl
esinthebasi
cs o
lut
ion
!

20 白紙 hav
et h
evalueofze
roarecal
ledn on
basi cvaria
ble
s.Fort h
epointPl,XJ血 dX2
ar
enonba
sicvari
abl
eswhieX3・
l ・
X4 andxsar泡 bas
icvaria
ble
s.
i
2
10

百 BasicF
eas
lbl
eSo
lut
lon
:Thi
sisab
asi
cso
lut
iont
hati
sal
sof
eas
ibl
e.τ'
hes
ear
e
出ep
oin
tsPl,
P2
, P3,
andP4i
nFi
gur
c3.
6 nLP,
.I thes
olu
tio
ntot
hep
rob
le,
mifi
tis
uni
que,mustbeab
asi
cf e
asib
leso
lut
ion
.Thebas
icso
luti
oncanasobec
I o
nsi
der
ed
geome
凶caI l
yasac
ornerpoi
ntoranextr
emep
oin
tofth
efeas
ibl
eregi
on.

ConvexPolyhedron:Thi sisaboundedr egionofth


ef e
asibled巴signspace-白e
rcgi
ondefine
dby出巴 q uadrilat
eralcomprisingthepoi
ntsPI,P2, P3,andP4inFigure
3.
6.Thet e
rmc Ollv
exs e
tr epr
esent
sac olle
ctionofpoint
so rv ec
torshavin
gt he
-3
0
0 5 10 1
5 20 2
5
foll
owingpr
operty:Foran ylwop o
intsinthesct(orwi
thinarcgion),i
fal
lofthepo
int
s
Numbor0
1Ma
chl
n0 1T
80 ypoA onthelin
cconnecting血巴t wopoint
salsoI
iei n出csamer egion,t
her egi
onisaconve
x
se
t.Imagin巴 削yl in
ed r
lwni
1 nlhcr e
giont
l 巴f
ine
tlby山eq u
ad r
ila t
endwhosecomer
F
lgu
re3
.6F
eas
ibl
ere
gio
n,E
xam
ple3
.1
. po
intsarePl, P2,P
3, andP 4
.FromF igu
re3 .6itisc
1earthelinewilIst
il
lbewi 白in
spaceinwhichal
lofthecons
trai
ntsaresa
tisf
ied
.Thecirc
lesexa
ggera
tet h
epoin
tsof th
er eg
ionestabl
ishedby臨 qua 合iJate
r叫 -m akingitaconvexs et
.
int
erse
ctio
no ffi
vecon
strain
tstakentwoatat im
e.Manyo fthemarenumberedPl,
P
2,. ..,P
6.AIIofth
esepoint
sofint
er富 田t
ioncanbeas
socia
tedwithacer
tainp
roper
ty OptlmumS olut
lon:This i
s afea
sib
lesol
uti
on 出atm
inimi
zesth
eo b
jec
tiv
e
concemingtheva
luesofthevar
iab
les.Notether
earef
ivedcsi
gnvaria
bles(n=5)and func
tion
-pointP4ーinFigu
re3.6
.InLP ,t
heoptimums
olu
tio
nmustbeabasi
c
thr
ecfunct
ionalc
ons
train
ts(m=3 ).F o
re瓦創n p
lc: fe
asi
bles
olu
tio
n.

P
I x1=
:( x
0,2= X)=
0, ,
5
8 4=
.x 25,
Xs=70) Bas
ls:τ'heb
asis陀 P隠 s
ent
s出cco
lumn
softh
eco
eff
icie
ntma
trixA白紙 coπespond
t
othebas
icvari
abl
es.Theyf o
rmthcb
asi
softh
em -d
imen
sionaIs
pac
e.Th eyare
P
2 x1=
:( ~=
0, 11
.67X)=
, x
.5,
1 4=3
6.7,
6 Xs=0) t
ermedt
hebas
isvector
s.
P
5 xJ=
:( 1
0. x
7,2=7
.0 X)=
5, x
0,4=0,
Xs=-4.4)
CanonlcalForm:τ' heb a
sisvec
tor宮 間duc吋 tounitve
ctorsthroug
hr ow/colu
mn
P
6 x1=
:( 0,
x2=1
4.7,
1 3=
x 0,
x4=3
9.7,
1 s=ー1
X 5.2
4)
op
erati
ons( orG aus
s -
Jordane I
imin
ation
). Th ebasicfeatu
reo f出en umerical
Thevaluesof出evaria
blesareobta
in e
das由eint
e路 氏ti
onofth
econs
tra
intstak
entwo te
chniqu
ef o
rLP( Simplexmethod)isa隠 pet
iti
veproced
町 estart
ingfromaninit
ia
l
/

ba
sicfeas
iblesolu
tion,anddeterm
ining出eb estneig
hboringbas
icfeas
ibl
es ol
utio
n
/

atatime
.In出ea boveI
is,
tf oreac
hp oin
t,ex
act
lytwoofthevar
iab
lesarezer
o.The
J6
4

t
hatimprovestheob
jectiv
e.Thep roc
edureiscar
rie
donu n
tiltheoptimumso凶o
l nis
2

number2c orr
espon
dst otheval
ueo fn-m .nrep
res
ent
sthenumberofvari
able
sand
2
p

re
ach巴d,ori
fitisdetermine
d白紙 nos o
lut
ionispos
sibl
e.Thcc an
onica
lf o
rmisu se
d
l

mt henumbero fcons
traint
s.PointsP5a ndP6a r
einfe
asib
lebecaus
eoneo ft
he
z語ガ/4124

var
iabl
esh a
san e
gativevalue
. fo
rrapid
1yi de
ntif
yingthesolu
tio
n.Eachi ter
ati
onin出巴 proce
durecanbed e
scribe
d
math
ematica
Ilyasfollows
.
Thestart
ingcons
train
ts創'corganize
das
哨巾

BaslcS ol
utlon:Ab asicsoluti
onisoneobta
inedbysett
ingcxa
ctlyn-mv ari
able
s
hr
一YY

t
oz er
o.I nFig
ure3 .,a
6 Iloft h
ep oi
ntsiden
tifi
edbyt hec i
rcl
esr c
prc
scntbasi
c

[
A]
II
附[丸田 1=[
b]附 (
3.2
0)
so
lut
ions.Thepoi
ntsc hoscna b
ovea r
eallbas
icv a
riab
les
.I ngene
ral,frnd
o esig
n
va
ria
blesandmcons佐官in
ts,出巴 numherofba
sicsol
ulio
nsisgiv
cnbyt h
ecombin
ation A
fte
rth
eGa
uss
-Jo
rda
nel
imi
nat
ion,
Eq~Jation (
3.2
0)i
sas
sem
ble
das
114 lN
L E
AAPAOGAAMMING 3
.3N
UME
RIC
ALS
OLU
TIO
N-T
HES
IMP
LEXMETHOD 1
15

凹m糊[X]m +[
R]州 n
-m)
[X]
(s弔問)=[
b] po
intisno
tfeas
ibl
ewit
hre
spe
ctto出eco
nst
rai
nt82・Th
ere
for
e,t
her
eisnop
oin
t
白紙 isfe
asi
bl.Th
e e
rei
snoso
lut
iont
o山ep ro
ble
m .
These
tofm des
ignv a
ria
ble
sinth
ef i
rs
tterm副 官 t
hebas
icvar
iab
Jc.Th
s esc
tof(n-
I
nth
eab
oved
isc
uss
ion
. 出e t
wo-
var
iab
les
itu
ati
onsp
rov
ide
dano
bvi
ous
m)dc
signva
ria
bJesin出csccon
dtcrmare肱 nonbasicv
alu
cs.I
n出cS im
pJxmethod,
e
Ja
c s
sif
ica
tio
noft
hes
olu
tio
ns.I
npr
act
ice
.LPm
ode
lsa
rel
arg
ewi
tho
verh
und
red
sof
th
cnonba
sicva
riabl
csaresumm
ari
lys e
ttozcr
o.
v
ari
abJ
cs.M ode
l i
nga ndt r
ans
cri
ptionerr
orsmayg i
veris
et omanyo ftheabove
s
itu
ati
on.Th
s eg enemtio
no fsolu
tionisbasedonnumer
icaltcchni
qucsofline
ar
3.
2.3 Di
偽 陪ntSol凶 onTyp
関 a
lgebr
a
, whichisofte
ns e
nsi
tivet
o山eq uali
tyofth
ematri
xo fco
eff
ici
ents
.FiJt
eri
ng
o
uterra
ntdataisusu
allyasign
ifi
cantex
ercis
einth
esear
chofoptima
ls o
lut
ion
s.
Thcrea
回 atmostfourdi
ffer
entres
uJt
s白 atcanbee
xpcc
tedfo
rthesoJ
utiono
ftheLP
pro
bJem:(1)auniques
olut
ion,(2
)inf
init
eJymanyso
Jut
ios,
n (
3)unboundedsol
uti
on,
and(4
)t h
ep o
ssi
bil
ity山atther
eisnos o
Juti
on. 3
.3 NUMERICALSOLUTION-
THESIMPLEXMETHOD

Thes ta
ndardn u
m e
r i
c a
lp r
ocedureisbasedon山ea lgorithmduet oOantzig笛
(
1)Uniques olut
ion: 百l eexampleu sedf ordiscussi
onh asaUsi qu
es olu
tion mention
ede a
rli
er.Itisrefe町 叫 1
0as出eS im
p lexmeth o
d.Thep rocedu
reisr e
lated
(F
i割問 3 .5).百 leconditio
nn ecess紅 yf or血istoo ccuris山 鉱 山eo bje
ctive to白巴 s ol
utiono fas ystemo fI
inearequations.Th ea ctua
la ppli
catio
no f白巴
fun
ctiona ndthecons
traint
sh avedis s
imilarsJop
e ,andt
s hefea
sib
Jeregionis proce
durec anbea ssociatedwiththeGauss-Jordanmethodf romlinea
ra l
gebra
.
boundcdlJo
c sed
.G eo
metrically,th
isc a
nb evisua
llyexpJai
nedasthemovement wherethecoeff
ici巴ntrowsa retransfo
rmedt hroughe1ementarymulti
plicat
ionand
of山el in
er epr
escnt
ingt h
co bjec
tivefu n
ction,pぽ u
llc
J10itse
Jf,i
naf avo
rabJe add
itio
n.Mostmainframecomputcri nst
allati
onsu sua
llyc ar
rys of
twarethatwil
l
di
recti
on,unti
litremainsjustincontactwithoneo fthefea
sibJ
ecomers( bωic helpsolv
eLPp roblems.MATLAsa ls
op rov
i d
esp rocedures10so l
veLPp roble
ms
fea
sib
Jes oJuti
on)o fthef easi
bler eg
i o
n.Thef e悩 ib
Jer eg
ionisi d
enti
fied init
sO ptimiz
ationT ooJb ox.Inthissccti
on,t heSimpl巴xmethodi sa pp
liedto
ui
stin
ctlyinF ig町宮 3.
6.A s imp
l巴巴瓦巴r ciscufi magin
ingd i
ffe印刷 obje
ctiv巳 simpl
ep ro
bl巳m昌 primaril
yt uundcrs
tunuthcpl'Ogrumminga ndge o
mctricfeat
ures
.
fun
ctionJine
ss hou
ldc onvincethevi e
w ertha
ts e
veraldif
fere
ntobje
ctive
s伺 n Thiswil
lb eusedwhenwed iscu
ssdire
cItechniquesf o
rn on
linearproble
ms.I nthe
bedefinedtoloca
tetheu ni
q uesol
utionatP1 ,P
2
, P3, orP4.This20geome 町 nextsecti
on,theSimplexmethodi si n
troducedi nd e
taiJwithe xp
lanati
ons.In
andconstru
ctioncanbeu sedtounderstandtheextensio
ntond im
ension
s.He 児 subseq
uentsections,MATLAB.o rspr
eadsheetpr ogra
m si
IkeExcelcana lsobeu sed
tei
h IneswilJbereprese
n t
edbyl y
Iperplanes. toimplementtheSimpJexm ethod.
(
2)ln
fin
ilesolu
tio
n:・ Inorde
rf o
r出i stooccur,出 eo
bject
ivefunct
ionmustb e
p
aral
leltooneo fth
ec on
s位置int
s.Forexample,inFigur
e3 6,
. le
tt h
eorigin
al 3
.3.
1 FeaturesoftheSlmplexMethod
prob
lember ed
efine
ds o白紙 theobj
ecti
vefuncti
onispar
all
eltothecon
strai
nt
h・Anyp oin
tont h
ec o
nst
rain
t,andlyin
gb e
t we
enthelin
es egm
entdcfinedby I
nth
issec
tion
.themachineseJe
ctio
nex創npJeint
roduce
dear
Jie
rissetupforap
plyin
g
出epoint
sp2a ndP4, i
sanoptima
lsolu
tiontothepr
o b
lem.Theywillyie
Jd出e t
heSimpl
exmc 白od.Itisins
truc
tivet
onotcthemethodisi
ter
ati
ve.Givenastar
tin
g
sa
rnevalueof白 州 問v e
. p
oiti
n
, twillmarchforwar
dt hr
oughimpr
ovingdesi
gnsun臥ithasf oun
dthesoh瓜on
o
rcann
otp ro
ceedfu
rthe
r.F o
rc om
plet
enesstheor
igin
alproble
misr e
writ
tenher
e:
(
3)Unboundeds ol
lll
io: I
n n出i scase,th
ef e
asibl
er eg
ionisnotb ounded.In
Figure3.6,i
fthecon
strai
ntsglandg2weren otpar
toftheprobJemformuJ
ation,
出e nt h
ef e
asib
Jer e
gionisnotboundont hetop
.R efe
rringt
oF igurc3.5
.出E Maximizc j
(X:9
) 90xl+9
0O2+5
x 250 (
3.1
)
obj民 ti
vefunctio
nc anbes hi
ftedωunl
ilTUtedhighe
rv a
lue
s.Inp r
actie,
c there
S
ubj
ectt
o: 8
1(X
):O. l+0 2:s
;8.
5 (
3.2
)
4

wi
l lbeanu pp
erboundon出 巴 rangeofth
ed esig
nv ar
iabJ
es(no
tp 訂t o
fstand紅d 4x .6X
5F

format)tha
twilJbeusedtocJose山isre
gion.inwhichc a
sesol
utionsoftype(1
)
i

:3
x 2:
I-X s
;25 3.
( 3
)
r

or( 2
)c anberecove
red.Th eprcs
enceofa nunboundeds o
lut
iona1sosuggcst
s g
2(X
)
-2﹂TIz--

伽 tt hef o
rmulat
iono f批 p roblemmayb el ac
kin
g.A dd
itio
nalm eanin
g f
ul
c
on st
rain
t(s)c叩 beaccommodatedt odef
i nethesoJ
utio
n. 8
3(X
):3xI+6
x ;7
2:
S 0 3.
( 4
)

(
4)Nosolu
lio
n:・Figu
re3.6isusedtoexpl
ain血ispos
sibi
Iit
y.C
onsi
der白 紙 白E x1~O; x2~0

d
ire
ctio
no fine
qual
ityi
n8 1ischan
gedtoth
co p
posit
et y
pe(注
).Thef
easib
lc
ι

r
egio
nw i出 r
cspec
ttoth
ec on
stmi
ntsgland8
3istotherig
hto
fXI J5.
0.T=
his Thep
rob
lemwasa
Jsot
ran
sfo
rme
d10t
hes
tan
dar
dfo
rma
tasf
oll
ows
.
116 L
lNE
ARPROGRAMMING
3
.3N
UME
RIC
ALS
OLU
TlO T
N- H
ESI
MPL
EXMETHOD 117
Ex
ample3.1
Withth
isinmind,
theS
imple
xmethodisa
ppl
iedt
othemachines
ele
cti
onp
rob
lem
.
Thcexamplew
illu
seandc
Jar
ifyt
heit
emsint
heab
oveI
is.
t
M
ini
miz
e J
(X:-
) O
99xI- 90
Ox2- 5250 (
3.5
)

S
ubj
ectt
o: g(
X)
:0,
.
4x
l+0
.6x2+x
3 8
.5 = (
3.6
)
3
.3.
2 AppllcatlonofSlmplexMethod

g
2(X
):3 ,
x -x2+X4=25 (
3.7
) SimplexTable3
var
iablenames
.1
.Thel
:I
as
nTable3.
trowi s出eo
1(SimplexTnble1),出cf
bject
ivefun
ction.Spread
i
s
r
h
s
trowi
eetsar
n
ea
d
ic
ne
a
f
t
c
f
st
ici
e
h
n
e
t
n由巳 symbolfc
g
3(X
):3
xI+6x
2+X
s 70 = (
3.8
)
wayt op r
o田 sst
removedfrom出el
hei
a
s
nf
onnati
o
tcolumna
n.百 i
ndlas
tisb
trowt
ein
oa
gcmployed
ll
own u
m eri
c
,白e
a
lc a
1 cu
lati
ons(ぉs h
a
o
nb
wn)
.
e

x1き0
;x2~O; x
3注0
;x ; Xs注o
4さ 0 (
3.9
) Thelnstcol
uD1nis出巴 rig
ht品n nd
s i
d 巴valu
es.Theres
to fthccntr
ies紅白 theco
effic
ients
ofthecons住ain
te qu
ations
.
X3,X4,andXsar芭曲es l
ackvar
iabl
es. Th ecurr
entitcr
atio
niso v
erifthet a
bledis
play
st ec
h anonicalfonn.Inprac
tice白e
TheS implexmethodisu sedonthep ro
b lembein
ge xpress
edint h
es ta
ndard canon
icalfonnc omprisωspottingthemu n
itvcct
orsi nthetable,aswell箇 making
forma t
.Thefollo
winginformat
ionisus
eal
li norgan
izingthecal
cul
atio
na swel
la s suretheen凶e su n
dert ebcolumn,
h ex
ceptforther owsr e
presentin
g白eo bj
ective
陀co gnizi
ngthemotivat
ionf o
rs u
bseq
uentiter
ati
ons
.百1 eserefc
rtoap roblemfor fun
ction(
s),arenonnegativeP-Q
).A glancea tSimple xTable3. 1indic
ates伽 t出E
whichau niq
ues o
luti
one x
ist
s.Wh il
em阻 yo ftheitemsb c
loww cr
ci n加 duce
d canon
icalfonnisp res
ent
.
ea
rlier,th
eyarerefe
rence
dh er
eforcom
plet
eness. Thcu ni
tv ec
torsin出ct a
blealsoidcnt
ifytho
semv ari
ablcs出a twillbelon
gtot he
b錨 i
s.Th os
ev ar
iableswil
lh avean onzeroval
uef or出isi ter
ation
.Ther em
aining,
• Thcnumbero
fva
ria
ble
sint
hcp
rob
le sn
mi .羽 山 i
ncl
ude
sth
esl
ackands
urp
lus
n-m, non
basicvaria
blesaresc
ttoz e
ro.Thissolu
tioni
sd ir
ectlyintcrp
rete
d合omTable
va
ria
ble
s. .1
3 .Thes olut
iontheref
oreis
sm(m<n
・ 百1
enumbcro
・ 百1
epr
obl
emi
fc
sa1
o
nst
ra
wayst
i
n
om
t
i
n
si
im
izet
h
)
eo
b
.
je
cti
vcf
unc
tio
nf
, x
z
x =0
.0, =0
.0,ろ=8
. x
5,4=25,Xs=70,叩df=-5250

• Thenumbero
fba
sicv
ari
abl
e sm (
si sam
eas出巴 numbero
fco
nst
rai
nts
). Hast heO ptima lSolutionBeenOb 飽i ned? Theo ptimnlsol u
tionr equir
esthatf
・Thenumberofnonbasicvariablcsisn-m. ber e
ducedぉ mucha spossi
ble.Fort h
ecurrentsolu
tion白巴 v alueo fXIi sO.From
・ Thes
eto
fun
itv
ect
orse
xpe
cte
di " e2, ・・・ , em •
se Equatio
n( 3.
5),i ,
fx wer einc
reasedfromzero,出ent h
eo b
jectivef u
n c
t ionfdecre
ases
• Thecolumno
fth
eri
ght
-ha
nds
ide(
b)i
spo
sit
ivea
ndg
rea
ter白 a
nore
qua
lto
fur
therinvalue.S i
milarreason
ingc n
nbeu sedforX2・Therefo
re ,thesolutioncanb e
ze
ro. fu
rtherinp
司roved.S ol
utionhnsnotc o
nverge
d .Thes ec
ond/nexti t
erat
i onwill問 q
uire
nssembl
inga nothertab
le,Table3.2
.
・Th
ta
b
ec
le
a
a
u
1c
u
.I
la
t
tw
i
i
l
on
sa
lb
r
eo
er
ef
r
e
r
g
r
a
e
n
dt
i
zedi
nat
o鎚 th
et
a
b
a
b
l
l
e,
ei
wh
i
nt
c
h
i
hi
sc
sb
oo
a
k
.
ll
edat
abl
eau,
orS
imp
lcx Theo nlywayf o ,
rx a nd/
orX2t ohaveap os
itivevalueisif自己yb 田 ameab a
sic
var
iabl
e.S incethenumbero fb n
sicvaria
blesispresc
ribedforth epro blem,someo f
・Onlytheva1uesofthcc 佃仔i
cie
ntsa
r官n
ece
ss町 yf
ort
hec
alc
ula
tio
ns.Thet
abl
e 出ec urr
entb nsicvariab
lesmustbecomen onba
sic.Fore achi tera
tion,出eS implex
中crefore contains only coefficicnt va
1us,t
e hem
atr
ix[
A]i
npr
evi
ous methoda1low sonlyo nepairofv a
riab
lcstoc ond
uct出i sbasis- no
n b
a sise xc
hange.
d
isc
uss
ion
s.These紅 巳 t
hec
oef
fic
ien
tsi
nth
eco
nst
rai
nte
qua
tio
ns. Eachiter
ationtakesplacethroughanewt ab
le.Toa ff
ecttheexch ang巴itisn ece
ssary
・ 百1
eob
jec
tiv
efu
nct
io s出e
ni las
tro
win出e
tab
le.百1
eco
ns住温i
ntc
oef
fic
ien
tsa
re
w
rit
ten自
民t.
T
abl
e3.
1Si
mpl
exT
abl
e3.
1
• Rowope
rati
onscon
sistofndd
ing(s
ubtr
act
ing
)ad e
fin
itemul
tipleoftep
h iv
ot
rowt
ooth
Errowsofth
e t
able
.Thepivo
trowid
ent
ifi
estherowinwhichth
eun
it X
I X X
J X
4 b
2 X~

。 。
vc
cto
r(i
na.cc
rta
incolumn)w
illha
vcthevalu
eof1.
• Rowo
白紙 y
per
ous
a
h
t
i
o
o
u
n
sa
l
r
en ee
d
dbEablet
cdt
oo
os
po
bt
a
tt
i
h
E
nt
un
h
ec
i
tv
a
n
e
o
c
n
t
o
i
r
c
alf
si
o
nt
n
n
h
.P
et
r
a
a
c
b
l
t
e
i
c
.
a
I
l
ft
l
yt
hi
hi
s回 plics
shappens,
0
3
.
4
-
0
.
1
6

。 。 。 2
8
.
5
5

the
nt
mustb
h
ec
eg
in
u
r
.
ren
ti te
rati
oni
scompl巴t
eandc o
nsi
derョt
ionsforthenextonc
司 9
9
3
0 -
9
6
∞ 。 。 。 5
2
7
8
0
0
118 L
lNEARPROGRAMMING 3
.3 NUMERICALSOLUTION-
THESIMPLEXMETHOD 119

todeterm
inewhichi
st h
evaria
ble白紙 w i
llent
erthebas
is(X
IorX2),Ente
ringBasic SimplexTable3.2(Table3
.2)
:Thepivo
trowi
sob
tai
nedf
romo
rig
in叫row20f

。 。
Vari
a b
le(EBV).Alsotobeestab
lishe
diswhicho f白evari
abl
回 (X'X4'o
3 rx
s)will Ta
ble3 .Th
.1 efol
lowin
gis白巴 o
rig
ina
lrow
lea
ve恥 b as
is,Le
avingBas
icVariab
le(LBV).Interm
softhenu
mericalca
lcul
ati
ons,
25
3
inthenewtab
le,t
heuni
tvecto
ru n
dertheLBVcolumnwi l
Ibetran
sfe
rredtoth
eEBV
columnthrou
ghelem
entaryrow/columnop
era
tion
s. Thevalu
eofthef
ir
stel
ementi
nt enewrowwi
h 1
lbe1.Therowi
smo
dif
iedb
y


div
idi
ngthr
oug
hby3.Thenewsec
ondrowi
nTa
ble3.
2wil
lbe
Enteri
ng8 a
sicV ari
able
:TheEBVi schosenbyitsabi
lit
ytop r
ovideforthelar
gest 一0.3333 0.
3333 O 3333
8.
de
crl
団関i nt
h巴o b
ject
ivefun
cti
o ni
n也ec urren
titer
atio
nlt
able
.百 li
sisdetercnin
edby
I
nTable3.
2,血efir
ste
leme
ntofthefi
rs
trow(Tabl
e3.1
)mustbered
uce
dtoO.Th
is
th
elarg
estne
gativecoeぽi
cie
ntinth
erowa sso
ciat
edw i
ththeobjec
tivefunct
ion.From
i
salway
sachi
evedbya
ddi
ng/s
ubtrac
tingf
romth
erowbein
gmod
ifi
edanapp
rop
ria
te
Tabl
巴3.1,th
isvaluei
s-990andc o町 邸pondsto由ev ari
ablcXI・EBVi sX!.A ti
ec a
n
m
ult
ipleof
thepi
votro
w.Themod
ificat
ionto白efi
rs
trowis
bebrokcnar
bit
rarJy
i.
row1-[0.
4"(
piv
otrow2)
}toy
iel
d
Leaving8 asicV ari
a bl
e:TheLBVi sa lsoc ho senbyi tsa bilityω 泊l prov
e血e o 0
.73
331 - 0.
1333 0 5 .
166
7
o町田t i
ve.Th eLBVi so nlyd eterminedaftert heEBVh asb e enc hosen.官 邸 i s
Thet
hir
droww
illbeo
bta
ine
dby
importantbecauseo n
l ythecolumnu nder出eEBVi s e
xaI凶n edt oestabI
ish血巴 LBV.
Theminimuml a
' t
ioo fthev aluesof出er i
gh t
-hands ide(bcolumnv alues)tot h
e row3-{
3"(
piv
otrow3
)}
corrcspondingco e
fficie
ntsi ntheEBVcolumn,p rovided出cc oeffic
icntv alucis
出r
Thefour owwi
1
lbeo
bta
ine
dby
pos
it i
vc,d,c
巴 idcs山eLBV.T h
isr ninimumv aluci d
cntif
iest heroww hichi saIsothe
piv
otr ow.I nth
isrow, thecolumn, whichc ontainstheu n
ityv alu eof白巴 someu ni
t row4+[
(99
0"(
piv
o )I
trow2
vector(orac ur
re n
tb asi
cv aria
ble),i
st hccolumno f白cI e
a vin
gb asicv a
riable
.百 l i
s Tab
le3.2isobta
inedaf
terthes
ec al
cul
atio
ns.
istheLBV. Thenegati
vevalueofthecoe悶c
: ie
ntinTable3.2inrow4i n
dic
ates白紙 wen ee
d
InTable3.1曲eEBVh a salre
adyb eeniden
tifiedasXl'Th eratiosund e
rt h
iscolumn a
tleas
tonemorei te
rat
ionl
tab
le.TheEBVi sX2・Byexamining白巴 p
osit
iverat
iosof
are21.25,8 .33
3 3,and23. 3333.Th eleastval u
ei s8 .
3333.百lIsc orr邸p ondsto由e 曲ev a
1ue
sin白巴 bcolumnt othecoe
ffic
ienti
n白巴 X2column,th
eLBVi sid回 t
ifi
eda
s
S巴condrowo fTable3 .1
.Theu n
itv ec
toru ndertheX4columni si n出i srow( row2 )
. s・
X Thepivotrowisrow3.T a
bl e33wi
. 1
lbeconstr
uctedbytran
sfor
mingtherowsof
Thcrefore,X4is由eLBV加 d出es econdrowi st h
ep ivotrowf orT able3 .
2.T his Tab
le3.2
.
impIies出創出巴 s e
氾ondroww i
llb eutiliz
edt oc hang巴出巴 c urrentXIcolumn( EBV
column )ii
ltoau nitvector白 alisc u
rrentlyun derX4・Thism e c
h anicalp rocedureis SimplexTable3
.3( T
able3.3)
basedont hefollowingreasonin
g.百l evalueofEBVmustb es uchthatitwil
ln otc a
use p i
votrow3=( r
ow3 )

con
st r
aintviola
tionw iththec ur
rentvalueso f血eo t
h e
rb asicfeasiblevariabl
cs.The
newrow1=row1-{ 0
.73333 (pi
v o
trow3*
)
}
newrow2=row2+{ 0
.3333*(p
ivotrow3)
}
app
li c
ationoftheGauss-Jo r
danpr o
cesss hou
l dsh
iftt h
ecolumnu n dertheLBVt o出e
newrow4=row4+{ 123
0場(piv
otrow3)}
EBVl eavin
gt h
ecolumno ft h
eo t
herunitvectors(thatarepartoft hebasis)unalt巴re
d.
Table3 .2i
st he
nc onstructedusingthcpivotrow2 . T
abl 3i
e3. so
bta
ine
dba
sedont
hea
bov
eop
era
tio
ns.

2S
Table3. i
mpl
exT
abl
e3.
2 T
abl
e3.
3Si
mpl
exT
abl
e3.
3

X
I X
l .
t
) X4 X
s b X
I X2 X) X4 X
s b
nu--nunυ

nu---nunu

nunu--AU
nunUE且nu

'且
0.452
4
-且

0.
733
3 -
0.13
33 5.16
67 -0.
0285 -0
.¥04
7
nununu

nunU U
-0.
333
3 0
.33
33 8
.33
33 0.2
857 0.
047
6 10
.476
2
7 4
5 -0.1
428 0.
142
8 6.42
85
凸 1
54.
28 1
75.
71 2
147.
3 14
-
1230 3
30 1
353
0
1
20 lN
L E
ARP
ROG
RAM
MIN
G 3
.
3NU
MER
ICA
LSO
LUT
ION
-TH
ESI
MPL
EXM
ETH
OD 1
21

Tabl
e3. 3d
oesnothave佃 yneg
ati
vevalue泊 白eobje
ctiv
ef u
nct
ionrow.A 'The row identifies the pivoヒ row to create ヒhe next
so
lut
Then
i
o
o
nh
nb
a
a
s
sb
i
e
e
cv
na
a
ri
c
a
b
h
l
i
e
e
v
sa
e
d
r
.Th
ese
eb
tt
a
s
oz
i
e
cv
r
o
a
ria
ble
sh
.FromTab
a
v
l
et
e3
.
h
eu
3t
n
i
h
tv
eo
e
p
cto
rint
白numv
h
e
a
l
i
u
rc
e
o
l
sc
u
a
mn
.
nb巴 l
1 l
table';

obs
erved邸: A(:,6)/A(:,
1)
ans
;
x=10.476,2xi=6.4285.X
;=0.4524,I=-21437.14 o 0 0 -17/1980
o 0 0 -51198
N
ote,
theva
lueo
fj"+21437.14=Ofromw
hic
hth
巴so
lut
ionf
ort
heo
bje
cti
vef
unc
tio
n o 0 0 -7/99
(
f)c
. anbeob
tai
ned
. 0 0 0 ・16/3
'something not right - The above division should have';
3
.3.
3 SolutlonUslngMATLAB 'been an elemenヒ byelement one'i

Thet a
blesint h
ep re
viousc o
mputationc a
nb eg e
nera
tedquit
ee ff
ort
lessl
yu singa A(:,6)./A
(:,
l)
spr
e叫s heet.百l i
s would b ea ccomplis
hed by s e
tti
ng up 血. em athemat
ical ans
mani
pulationino nece
llan dcopyinga ndp脳 血gt o出eo t
hercell
s.Sincethi
sbook 85/4
al
so邸 si
stsinMATLABp rogr創nming,theill
us住ati
onherew
illallow佃 opportu
nityto 25/3
pr
acti
cet heuseo fMATLABf o
rm at
r ixmanipul
atio
ns.Thec odep r
esentedhereis 70/3
四 pturedusingMATLAB'Sd ia
rycommand.Thecommandr e
quir
est h
enameo fa白川 -16/3
fi
lewhichr e
cordsal
lc ommunicati
onw ilhMATLABa swel
lωitsr e
sponseduring叩 format short

-記
in
tera
ctivesessi
on( s
eeh .Th etex
tf i
leiscommentedl i
ber
ally(foryour

H1U乃4y︿
el pdia
ry)
unde
rstandin
g)a ndusin
gt hesemicolonat由ee ndofthest
r
.加gsp rev
ents由e ire
cho. A(:,
6) ./A(:,
l)
h出i sfi
lethecommentsa requo飽d s回n g
.Thec oderep
res
ents由巴 det
ail
so fanactu
al ans =

4ur
se
ssio
n.Th e
ses tate
ment
sa r
et ypeda 食er白eMATLABp r
o m
pt也 t heCommand 21.2500
window.Th i
sisther
efor
ea nint
erac
tivesess
ion.Valu
esto白erightofans=istheecho 8.3333
ofres
ulto f出ee x田 uti
ono f出eMATLABcommand.N ot
e:commentsn eedn o
tbe 23.3333
ty
ped. -5.3333
'Second row is the pivot row and x4 is LBV';
Exam
ple3_l
.tx
t 'Constructing Table 2';
format compact 'note the scaling facヒor for the matrix'i
format rational A
'Set up the coefficient matrix and b as matrix A'; A
1.0e+003 *
A=[O.4 0.6 1 0 0 8.5;3 -1 0 1 0 25;3 6 0 0 1 70;-990 0.0004 0.0006 0.0010 0 o 0.0085
-900 0 o0 5280] 0.0030 -0.0010 o 0.0010 o 0.0250
A 0.0030 0.0060 o 0 0.0010 0.0700
2/5 3/5 1 o 0 17/2 -0.9900 -0.9000 o 0 o 5.2800
3 ・1 0 1 0 25 'The element at A(2,1
) must be 1';
3 6 0 o 1 70 A(2,:) = A(2,:)/A(2,1
)
・990 -900 0 o 0 5280 A
'This is Table 1 - note the canonical form'; 1.0e+003 *
。0.0085
'EBV is x1 - first column'; 0.0004 0.0006 0.0010
0.0010 -0.0003
o
0 0.0003 。0.00 3 自

'To find LBV divide last column by coeff. in EBV'i 0.0030 0.0060 0 o 0.0010 0.0700
'column'; -0.9900 -0.9000 0 o 0 5.2800
'Take the minimum of the positive values';
122 L
INE
ARPROGRAMMING 3
.
3NU
MER
ICA
LSO
LUlO
T T
N- H
ESI
MPL
EXMETHOD 1
23

'The element at A(l,


l) must be a 0 '
; 'A(2,2) must have a value of 0';
A(l,:) =A(l,:)ー 0.4*A(2,:) A(2,:) =A(2,:) - A(2,2)*A(3,:);
A 'A(4,2) must have a va1ue of 0';


1.0e+003 合 A(4,:) A(4,:) - A(4,2)*A(3,:);
0.0007 0.0010 -0.0001 o
。00..00005823 A
0.0010 ー0.0003

o 0.0003 A'"
0.0030 0.0060 o 0.0010
。50..20870000 1.0e+004 *

nu
nu
nu
nu

nunununu
nunununu
nununU 司ム
nununuEJ
nununU 凋喝

nunununu
nunununu
nununu
nununup口

nununu 4
nununU 噌よ
nunununHE
nu 噌ム nU2d
nunUFO
o

----
噌ム向

----

ー0.9900 -0.9000 o o 0

U
ununu
'Element at A(3,


1
) must be a zero'; 0.0001 0



A(3,:) =A(3,:) - A(3,1)*A(2,:)

U


o 0.0001
o

4


A 0
1.Oe+003 *
。 。0.0052 format rational


0.0007 0.0010 ー 0.0001 A
0.0010 -0.0003
。 0.0003 o 0.0083 A

'
'
'

Rdrf
nu 司

nunU 4



噌ム円

﹄7 ,

, '
4nununu
o 0.0070 -0.0010 0.0010 0.0450 -11/105 19/42

--司ム

4
4nunu
-0.9900 -0.9000

﹃'
o o o 5.2800 1/21 220/21


'
噌 nu
'Element at A(4,


-anu
1) must be 0'; 1/7 45/7

oau
A(4,:) A(4,:) - A(4,1)*A(2,:) 1230/7 150060/7
A 'No further iterations necessary';


1.0e+004 * diary off

0.0001 -0.0000 。
0.0001 0.0001 ー 0.0000
0.0000
o 0.0005
O 0.0008
Th
ma
n
el
i
a
p
u
s
l
tfewcommandss
at
ions
.Iti
ss u
gge
s
u
t
g
g
e
巴s
da
lIh
cp o
ssib
il
saproblema
i
tyo
tth
fd
ee
e
n
ve
do
l
opi
n
f出ec
gaf
h
apt
e
o
rl
r.
oo
pfo
rth
erow


o 0.0007
ー0.1230 。o -0.0001 0.0001 0.0045
0.0330 o 1.3530
'Table 2 complete - and canonical form is present'; 3
.3.
4 SolutlonUsingM
ATL
A8' 舗onToolbox
SOptimiza
'Solution is not converged because of A(4,2)';
,EBV is x2'; T
hiss
ect
ioni
sus
efu
lfo
rth
osct
hath
avea
cce
ss1
0th
eOp
tim
iza
tio
nTo
olb
o.
xfrom
'Calculation of LBV'; MA'τ
1.AB(
Ver5
.2
).
A(:,
6)./A(:,
2) St
artMA T
I.
.A.I
B ntheCommandwindowt ypeh
elplp
.T h
iswillprov
ideinform
ation
ans onth
eu seoftheline
arprogr
ammingrou
tine10s
olvetheprob
lem.Here.thesta
ndard
7.0455 usei
se m
ployed.Itinvo
lvesspe
cif
yingva
1uesfo
rthecoslcoe
ffici
ent
s( ι
vecto
r).the
・25.0000 co
eff
icien
tlcons
tra
inlmatr
ix(A-ma凶x )
.a ndth
er ig
ht-ha
nds i
dev e
ctor(b・v
ecto
r).
6.4286 τbefollow
ings eq
uenceofst
epsil
lu
s住ate
s出eu seoftheprogram
.
-11.0000
'Pivot row is third row and LBV is x5' U
sin
gth
eLin
earProgrammingR
out
ine
ans >> f ・990;・900];
Pivot row is third row and LBV is x5 >>A [0.4 0.6 3 -1; 3 6
)
'Oops forgot the semicolon'; >>b [8.5 25 70)'
'Calcu1ation of LBV'; " 1p(f,
>> x ' A,b)
'Construction of Table 3.3 -no echo of calculations';
'A(3,2) must have value 1'; Thes
olu
tio
nasp
osl
edi
nth
eCommandw
ind
ow:
A(3,:) = A(3,:)/A(3,2); x
'A(1,2) must have a value of 0'; 10.4762
A(l,:) A(l,:) - A(1,2)*A(3,:); 6.4286
>> sol "
' f'*x
124 lN
L E
ARPROGRAMMING 3
.4 A
ODI
TIO
NALE
XAM
PLE
S 125

801 x+y~ 64O (


3.2
2)
・1.6157e+004
Tothi
ss ol
uti
onmustbeadde
d白巴 con
stant-5280whichwaso m
itte
di nproblem Thes
idec
ons
tra
insonxa
t ndya
ret
h巴r
esp
ect
ivew
are
hou
sei
I
mit
s.Thes
hip
pin
gco
sl
de
fin
itio
nforMATLAB.T
her
ear巴manydif
fere
ntwaystouse山巴 l
ine
arprogramming I
S
fu
ncti
oninMATLAB.
Cost=4.2ホ x+4
.5*
y+6
.0*(
200-x-y)+
0

3
.4 ADDITIONALEXAMPLES 4
. ・
7 ( )+5.
8oo-x)+4.れ(1判0-y x+y-6
1・( 40)
Cost=ー1
.4
'"x-y+19120 (
3.2
3)
h 出i
sse
cti
ona
ddi
tio
nale
xam
ple
s釘 ep
偲 s
ent
ed.Th
esee
xam
ple
sil
lus
tra
te山e
ext
ensio
n/ m
odifi
catio
no ftheSimp
lex method t
oh an
dlegre
atr由 回 o
e requ
al 1
ingt
Assemb hep
rob
lem(
Exa
mpl
e3.
2)
co
nstr
aints,neg
ativeval
uesfo
rth
edesignva
riab
les,e
qua
lil
ycon
str
ain
ts,a
ndsoon.
Inal
I由ec a
ses,theproble
mistrans
form
eda p
propr
iat
elyan
d白esameS im
plex M泊b凶z
e f
(x,
y:ー1
) .4x-y+1
912
0 (
3.2
4)
melhodisthenappl
ied.

Subjectω81(Xy:x+y:
) 52000 (
3.2
5)

3
.4.
1 Example3.2-
TransportationProblem 8
2(,
Xy:x+y注6
) 40 (
3.2
6)
TheF
loc
ate
re
s
di
hMi
nBu
I
f
f
kc
al
∞perativesuppi
o(NewY o rk)an
1esmi
dWilIi
I
a
ki
ms
ng
p
or
al
t(
l
P
o
nj
enn
s
u
y
g
sfromi
lva
nia
)
t
.1
stwow
thぉ ac
a
a
r
p
e
a
h
o
c
it
u
se
yo
s
f
0$x: ∞;
58 0:
5y:
514
40 (
3.2
7)

2000gallo
nsperdayatBuffaloand1600ga Ilon
sperdayatWi11i
amspo
rt.Itde
liver
s Fig
ure3.7iI
Ius
tra
testh
eg r
aphic
alsolu
tio
ntoExample3.
2.Thel i
nerep
rese
ntin
gt h
e
800gallons/dayωRochesωr(NewY o
rk).S yra
cuse(NewY o
rk)r 叫u
, ire
s1 440 con
sta
nto b
ject
ivefunc
tionvaluesle
rmdoesnotinc
lud
et h
ec o
nstantte
rm(19120
).
gal
lonsld
ay,and曲eremain d
er( 1
360ga1lons
)aretruck
edtoNewYorkC ity
.百l ecos
t Thesol
utioni
sattheinte
rse
clionofco
nst
r温i
ntglandth
eu ppri
e 1miton出ev al
ueof
toshiplhemilktoeacho fl hedes
tin
a t
ionsisdiff
ere
nta ndi
sg iv
eni nTabe3.
l 4
. xas出eo bj
ecti
veistodecrea
sefasmuchaspos
sib
le.Fromthefigur
ethesol
utio
nis
Esta
bi
1sh出es hip
pings位置t eg
yf rminimum∞s
o t
.
x=800;y=1
20,
0f=168ooor$168.oo (
3.2
8)
ProblemFo
rm u
lat/
on:Le txbe出enumberofga
Ilo
nsship
pedfromBuf
fal
oto
Ro
che
ste.Le
r tybe出enumberofg
all
onss
hipp
ed針。mB u
ffa
lotoSy
racus
e.
Thew
are
hou
sin
gco
ns回 i
nta
tBu
ffa
Ioi
s2 ∞ogallons/day.Therefore, Two-PhaseS/mplexMethod:Themaind iff
erenc
eb elweenExamples3.1a nd
3.
2is出e注 c ons
町ai
ntintheIat
ter
.S inc
et h
es ta
ndardLPp roblemonlyrequ
iresthe
x+y$2000 (
3.2
1) des
ignvar
iabl
esbesemip
osit
ive位 0 ),出er igh
t-han
dc ons
trai
ntsonxa ndyh aveto
beaccommodatedthro
ugha d
ditiona
Ii ne
quaIi
tyconst
raint
s.A ppl
yingt h
er eg
ular
Amounts
hip
ped企omW
ill
iam
spo
rtt
oR∞
,hes町 =8oo-x Simpl
exmethodwith
outadd
itiona
Ip r
ocessi
ngwouldc r回 t
eap ro
bleminrecog
nizing
Am o
unts
hip
ped企omW
ill
iam
spo
rtt
oSy
racus
e=1440-y 也ec 釦 o
ni回 1form
. Example 3.2e xpress
e din 出es tand
ardf or
mato fl in
ear
Amounts
hip
pedfr
omW
ill
iam
spo
rtt
oNewYorkCit
yis programmmgIS

1
600-(
80 1判 O
0-x)ー( -y)注o Minimize f
t
.x,
y
):ー1
.4x-y+19120 (
3.2
4)

T
abl
e3.
4Sh
ipp
ingCost(Cen匂 p
erG
all
on)
S
ubj
ectt
o: g
l(,
Xy:x+y+S
) I=20 ∞ (
3.2
9)

g
2(,
Xy:x+y-S2=6
) 40 (
3.3
0)
R
och
est
er S
yra
cus
e NewY
orkC
ity

B
uff
a10 4
.2 4
.5 6
.0
g
3(,
Xy:x+S)=8
) 00 (
3.3
1)
Wi
I
li創n
spo
rt 4
.7 4
.6 5
.1
8
4(,
xy:Y+S4=1
) 440 3.
( 32
)
126 lN
L EARPROGRAMMING 3
.4A
DDI
TIO
NALE
XAM
PLE
S 127


25 ob
jectiv
ed ependsonlyont heart
ific
iaJvari
ables.佃 difitsvaJueiszero,出isimp
lies
t
hat白巴 a rt
if
icia
Jv ariabl
esa relIonbasicvariabl
es.Thi salsos uggeststh
att h
ese



d,

va
riabl
eswercb asi
cv ar
iable
satth est
artoftheprocedu
rc.WhenP hase1iscomplete






曲enb ot
ht h
earti
fic
iaJobj巴ct
ivefunctionandthearti
flc
ialvari
a b
lesaredisca
rded台。m
出巴t a
bleandP hase1/begins.
PhaseIIist hestandardSimple xtechniqueappliedtot h
et abl
efromt heendo f
Phase1neglec
t i
ngall山 a r
ti
fic
iale l
ements.Th etableshouldb einc a
noni
calform.
Add
itionaltab
lesareo b
tainedasn eces
s a
ryuntilthesoluti
onisr ea
ched.
~脚
。 InExample3 .2setupearli
er,t
h er
ewi l
lbeonea rti
fi
ciaJvaria
blea1 andanar
tif
ic
iaJ
2
2 c
ostf u
nctinA"I
o nt heexampleo nlyEquation(3.30)willbea ff
ectedas
~ 5
00

E
g
2(X
,y:x+y-s2+al=640
) (
3.3
4)
ω
go

--
-
i
40 Thea
rt
if
ic
iaJc
ostf
unc
tio
nwi
llb
e

‘﹄﹃

Hhh

‘‘



﹄司句

句﹄司

句句
-

﹄﹃﹄司

﹄司﹄司

-
h


-・‘』旬。 3.35)
﹄司

Af=al (



h

-
100
0 Ta
ble3 .5rep陀sen
ts出巴 f 1f
Sttablei
nP haseI.Thef1rs
tf ou
rrowsr ep隠 s
ent白E
c
onst
rain
ts.Thef
1fthrow問 p民 se
nts血eori
ginalob
j田 町ef u
ncti
on.Thelas
trowis由e
-
150
0 a
rt
ifi
cia
Jo bj
ecti
vefunct
ion.Thisis出巴 rowu Sedto合 i
v巴出巴 iter
ati
onsinP ha
se1
.
0 1
00 2
00 300 4
00 50
0 6
00 7
00 8
00 T
able3 .5isnotinc anon
icaJf or
m.butr e
placi
ngthes i
xthrowbyt h
er es
ultof
x
:g副1
0間 1
10m
B凶f副o
lo∞h田 1
R 0
1
s
ubtra
cting血es ec
ondrowfromt hes
ix出 rowwillpr
ovideac a
nonic
alform.Tabl
e
F
lgu
re3
.7G
rap
hlc
al8
0lu
lln,
o E
xam
pla3
.2
. 3
.6illu
str
ate
stheresu
ltofsuc harowman
ipulati
on.

SlmplexMe ,
的 odPhBse1
:InT
abl
e3.
6th
erea
retwoc
hoi
ces(
x,)a
y v
ail
abl
efo
r
;y~ 0
x~ 0 ;sl
's2
's3
's4~ 0 (
3.3
3) 曲eEBV(
ent
e自I
gba
sicv
ari
abl
e)a
sbo
tho
fthemhaveac
oef
fic
ien
tof-1i
n血el
as
t
r
ow.W hil
et h
ec hoi
cec anbea rb
itra
ry,xisagoodc h
oicebeca
useithasalarg
er
Heresl・S3
's4aretheslackv aria
blesandS 2is白巴 s urp.
l凶 (sim
ilartoaslack-usedf or n
egat
ivec o
effl
cie
nti ntheo ri
ginaJobje
ctivefun
ction
.百 leLBV( lea
vin
gb as
ic
~ co
nstrain
ts)variab
le.I nExample3, 1
. whent hef1r
stS implext ab
lewass etup v
ari
able
)iside
ntif
iedthroug
ht h
eminimump o
sit
ivevaJueoft
herat
ioofth
evalu
esin
(SimplexT a
ble3.1)
,t hes lac
kv ari
ableswereh elpf
uli nidentifyi
ngt hecanonical t
hebcolumnt o出 evalue
su nder出巴 xcolumn.官 le
scrati
osare2000
/1,640
11,and
form
.Herei nExample3 .2,i
tdo 凶 notworkout伽 twayb ec
a usethecoef
flcien
to fS2 8
0011
.Thes ele
ctio
ni d
ent
ifie
s出es econdrowas自己 p i
votrowanda1総 白eLBV.
i
s- 1.Multiply
ingEq uation(3.30)by-1m igrat e
st henegativesigntot h
er i
ght-hand U
singthes ec
ondrowω 血ep ivotrow,t h
eu n
itvector[01000O Thωtobe
]
si
de.whichi sa ls
od isaJloweda s:f
紅 a s白er e
c o
gnitionof白ec anonica
lformi s
conc
e r
ned.T hi
smeansa ddition
alp r
oblem-speci ficpreproce
s singmustt ak
ep la
cet o
T
abl 5 E
e3. xample3
.2:I
ni
ti
alT
abl
e,P
has
e1
ide
ntifytheini
ti
alcanoni calform.Sincet heS implexme 出odi su s
edt ohandlelarge
problemswithsever
alv ariabl
es,i
tismorec onveni e
ntt oapplytheS implexprocedu陀
x y S
I S
2 0
1 S
3 S
4 b
i
nac onsist
entway.T hisisa ccomplishedbya p plyingthesameS implextechniq
uein
atwo-partseque
nce.
。 。 。
。 o o o 2
000

va
百l
r
iab
ef
le
1r
s
,i
tp副 i
sd e
fin
sr
e
e
df
c
o
ogt
re
甘z
ac
e
da
hs
sP
ur
p
h
l
a
u
s
sv
e1
a
.H
ria
ereanewk
bleint h
indo
esamee
fv
q
u
a
a
r
t
i
i
a
b
o
l
n
e.ana
.Also
rt
ifi
ci
,anew
al

l 。 。 。 。
。 。 。 。 o
640
800
14
40
o
i
b
si
j
ec
n
t
t
r
i
o
v
d
ef
uc
u
e
n
d
ct
ionc
.Thea r
a
l
t
l
i
f
e
l
da
cia
na
lob
r
t
j
i
e
f
i
c
t
c
i
i
a
v
lc
ei
os
sd
tf
e
u
f
i
n
n
c
t
e
iollo r加 a
d邸 asumo
r
ti
fa
f
Jl
i
ci
t
a
h
lo
ea
b
r
j
t
i
e
f
c
i
c
t
i
i
v
a
ef
lv
u
a
n
r
i
c
a
t
b
i
l
o
n
e
s ー
14
. 。 。 。 。f- o 1
912
0
i
nt
Sim
h
ep
plc
ro
xp
bl
r
o
e
c
m
.I
edu
nP
re
hase1
.Whent
,白ea
hi
r
t
si
if
l
sa
c
c
i
a
c
lo
omp
b
j
l
e
i
c
s
tiv
he
ei
d,P
s同 d
has
uce
e1i
dt
sc
oz
o m
e
p
r
l
ou
et
e
singth
.If山ea
est
r
a
t
i
n
f
i
d
c
ar
d
ia
J
。 。 。 o 。 。 A f
b
-EV L F i圃j│i E
1
28 lN
L E
ARP
ROG
RAM
MIN
G 3
.4 A
DDI
TIO
NALE
XAM
PLE
S 1
29

T
abl
e3.
6Ex
amp
le3
.2
:Sl
mpl
exT
abl
e1,
Phn
se(
Can
onl
凶 IF
orm
) , T
abl
e3.
8Ex
ump
le3
.:創m
2 ple
xTa
bl ,
e1Ph
ases(
Can
oni
ωIF
orm
)

,$


x y $
1 $2 a
l $) $4 b x y $2 $) $4 b

↓。
1lull-

AU'anu u

nuhunu'且
-shununuhunu

hunu-anunuhu

-EAUAununu

nunυ'anunu

nununu'a

u
白'
2
000 0 1
360

aU
640 制0

凸 nunU
8
00 1
60
o

白 nunu
O 1
440 1440

-

-
1.4 o f-1
912
0 0
.4 -
1.4 o f-18224
o Af-640


SimplexMethodPhase1
1
:Thec
olu
mnw
itht
heg
r田 t
es
tne
gat
ivec
oef
fic
ien
t
(
一1 )i
.4 ss
2・百l
i
si ss
s出eEBV.TheLBVi 3・百l
e出i
rdrowi
sth
ere
for
eth
epi
votr
ow.
町創l
sf
e町e
dfr
omt
healc
olu
mnt
oth
exc
olu
mn.C
ons
tru
cti
ono
fTa
ble3
.7s
t訂t
swi
th Theu n
itvect
or[0010O ]Tm u
stb e町a n
sfer
redfromtheS3columnto由巳 S2column
t
hesec
ondrowinT
able3.6,
whichi
salsoth
eseco
ndrowofTab
le3.7bec
auseoft
he
throug
hr owmanip
ulat
ionsu si
ngt h
ep iv
otrow.百首se x
erci
seresu
ltsinTa
b l
e3 .
9.
c
oe仔ic
ien
tof1inth
esecondrowunde
rt exc
h olumn(nos
cal
ingi
snece
ssa
ry).Thi
s
Thenega
tivecoe
ffi
cien
tu ndertheyc olu
mns u
ggest
swea renotfmis
hedy et
.For
i
sthepiv
otrow
.Too bta
ina0i nthefir
strowintexc
h olum,t
n hepiv
otrowis
thenextit
era
tio
n,EBVi sy.LBVi sSI'Thefir
strowis出ep i
votrow.Theunitvec
tor
s
ubt
rョc
tedfro
m出巴白 rs
trowinTabl
e3.6.Thenewfi
rs
trowis
[10000] Tm us
tb econs
tructedundertheyc o
lumnu s
ingro wmani
pula
tionu s
ing
。 -
1 0 0 1
360
th
ep i
Th
v
o
e
r
tr
ea
o
r
w.Thi
enon
sr
eg
a
e
t
s
u
i
v
lt
si
ec o
nT
ef
f
a
i
b
c
i
l
e
e3.
nt
si
10
.
nthela
strow
.Thes olu
tionhasbeenrell
che
d.
Fromi ns
pect
ionofTable3.10,th
es olu
tio
nis
Too b
taina0inthexc olumninth
ethi
rdr o
w.thepiv
otrowissubt
racte
df ro
mthe
th
irdrowofTabl
e3 .
6.Thefour
throwhasa0inplac
eandhen
cciscopied合'OmTable
3.
6.Thcfif
throwisobt
ainc
db yad
dinga1.4mul
tip
leofth
epiv
otro wtothefit
出r
1 ow x=8
0 Y=
0, 1
20.S2=
0 1
36.S4=
0 240,f=1
680
0 (
3.3
6)
i
nT able3.
6.Thelas
trowistheadd
iti
ono ft
hepiv
otrowtothela
strowf ro mTab
le
3.
6.Table3.7i
scompile
dasf o
llo
ws: Inthi
se x創nple,thes ameSimplexmethodwasr e
peate
dlya p
plie
da lt
houg
ht he
probl
e mwassolvedusing抑 ophas
es.Thef i
rs
tphasewa saprepro
cess
ingphぉ eω
movet hesur
plusvariab
lesawayf rom出巴 ini
tia
ls e
tofb as
icv a
ria
ble
s.百l i
sw as
ach
ievedb yi n
troducin
ga ddi
tio
nnlvaria
blesfore ac
hs u叩l u
sv ar
iab
lea ndan
T
abl
e3.
7Ex
amp
le3
.2
:Sl
mpl
e宜T
abl
e2,
Ph脚 1(
Can
onl
colF
orm
) ad
diti
onalcos
tfunctionth
atdrove出eitera
tio
nsofthefr
r宮tp
hase.
Tos ummariz
e ,fo
r~ a nd=c o
nst
rai
nts,ar
tif
ic
ialvar
iabl
esa nd釦 art
ifi
ci
alcos
t
x y $
1 $2 a
l $) $4 b fu
ncti
on釘 ein官。d u回 dint
ot heprob
lemf o
rc o
nvenie
nce.百l eSimple
xm ethodi
s
-
0 1﹂ 1 0 0

app
liedintwophases
.百l efir
stphas
eistermin
atedwhent h
earti
fic
ia
lv a
ria
ble
scll
n
-

nunuhu'a
nu'且AUnununu

'anununununu

'a'E'anu-a

u
凸 nu'anununu

1
360
6
40 beeli
m i
nate
df rom山巴 proble
m.
1
60
O 1440
T
abl
e3.
9Ex
amp
le3
.:S
2 l
mpl
exT
abl
e2,
Pha
s量n n
(Caon
lca
lFo
rm)
a

o
aマ

組品守

-
1.4 f-18224
o Af x y ,$ $2 $) $4 b

'anusaE且 E

'Enunununu
u o

u

凸 nu'anunu
1
2

--
・且
o 8∞
AUAUnu

o 160
FromTab
le3.
7.山eval
ueofAfi
sO.an
dali
sno
tabas
icvar
iabl
e・Thi
side
nti
fie
s 0 1
440
t
heendofPh
ase1
.Thea1c
olu
m nan
d白巴 l
as
tro
war
edi
scar
dedandPha
se11i
ssta
rte
d 3 A

a .4
1 o f-180ω
w
ithTable3
.8
.


組長 3
130 UNEARPROGRAMMING 3
.4A
DOI
TIO
NAlEXAMPLES 1
31

T
abl
e3.
10Example3
.:S
2 l
mpl
exT
abl
e3(
Fio
al,
)Ph
ascD Maximize j
{xl, :2
X2) x1ーら

x y SI S2 S) S4 b Thec
ons
tra
int
sca
nber
eco
gni
zedfromt
hes
tat
eme
nto
f出ep
rob
lemd
ire
ctl
yas

。 。 。 。
。 。
。 1
2叩


。 。
。 。
1
o 。 8
0
1
0
3
60
g
.: xl+ Xz ~5

2
40 g
2:2
x 2=
.+x 4
。 。 。 0
.4 。 f-16800 g
3:x1+X2~ 1
x1~ 0, x
2isu
nre
str
ict
edi
nsi
gn

3
.42 Example3ふ -EqualltyConst
. 悶 i
ntsandU
nre
str
ict
edVarlables F
igure3.8,
usingth
edrawLine.mm
-fi
le,i
sagr
aphi
cald
escr
iptio
no ft
heprobl
emand
t
hesolu
tion
.明1 esol
uti
oni
satxl 3a=
n =
dX2 -2in自己 f
igu
re,whereconv
eni
ently白 e
Example3 .3wil1i nc
1udeane qu
alit
yc on
strai
nta ndiJlus
tra
testhet ech
niquefor o
bje
ctivefunc
tionisal
sopa
ssingt
hro
ugh
.
han
d lingvariab
les白紙 a reunres町ict
edinsign(canh a
ven egat
ivevalue
s).Varia
bles
li
kep rof
i,
tt emperature,andn e tincomecanben e
gativequiteof
l刷1.The叫 u al
ity StandardFormat:Ast h
estan
dar
dforma
tex
pe出 on
lynonn
ega
tiv
eva
ria
ble
s.t
he
cons回 intishandledbyi n 凶 ducing印 刷i fi
cia
lv a
riabl
ea ndapplyin
g出etw o
-phase va
ria
blex2i
srepla
cedbyapai
rofva
ria
ble
sint
hefo
rmu
lat
ion
:
Simplexlt田 加i qu巴 il
lus回 tedi nExample3 ..Wh
2 enth i
sc or
respond
i略 的 自c i
al
va
ria b
leisz er
o巴(n do fPha se1),由巳const
rain
th asbeenme t
.Then egati
vev a
luefor
avariableissimulatedt hrough出ed if
fl
巴rencebetweentwop osit
ivevari
able
s.Once 6
aga
i n,thes
ec hang巴s p
r es
er v
et heSimple
xmethodi nit
so ri
gina
lf o
rm.Th efollo
wing
i
sa ni m
agin a
ryp roble mωillus
t r
ateadd
itio
nalfeatu
ressosomeiLbertyi
st a
keninthe

10
・,
fo
rmu l
ation.

0o
a
TheProblem:Today, afu
ll-
tir
nestuden
toncampusi sa l
waysd rive
nt omaximize

ドーく!
gra
des.As tronginfl
uencefo
raf av
orableoutcomeis血eamounto finve
s回 開t made

Zト ¥ ; ¥
inhit
ting出巴 booksversus出etimespentplayin
gp i
nbal
l.Inatypicalday,atlea
stone
hourisd ef
inite
lye xt
endedtot h
ep ur
suitofl ea
rningorp r
essingt h
es idesoft h
e
coin
-operatedm a
chine.Notmoret h
anf i
veh our
si sava
ilab
l巴f orsuchd ispe
rsio
n.
Over出ey e紅 s,afat
igueth
reshol
do ffouruni
ts.basedonac ombinationo f白巴 two
act
ivi
tis,h
e a
sb eene s
tab
lish
eda s a norm f ora cce
ptabl
ep erform四 ce
.T h
is
combinationisthesumo fth
ehourss p
entatthepinb
allmachineandt wic巴t heho
urs
spen
tonhomework ,anacknowledgmenttha
thitti
ng血eb ooksisstre
ssf
ul.An egati
ve
houro fpinballplayigwi
n 1
lgot oincrea
set hetimes p
ents tudyig,whichw
n il
l
con
tributep o
sitiv
elytot h
eg rad
es.Theo ve
rallg ra
deisd etermineda sal inea
r
combin
at io
no ftwic
et hetimespentacademica
llya ndsubtrac
ting白et imes pe
nt
pla
ying.Thep roblem出e r
eforeistod is
trib
utet h
et imetomaximizet heg rad
es
obt
ained.

ProblemF or
mulation:Therearetwoorig
ina
ldesi
gnva
riab
lesinthep
roble
m.XI
4 5 6
i
sthenumberofhour
sspen
ts t
udying,a
ndX2isthet
imespe
ntenjoyi
ngthegameof
pi
nba
llwhenth巴sameti
mecanbeadvantag
eousl
yspe
ntma
intai
ninghighg
rad
es.
τ'he
ob
j配 t
ivefu
ncti
oncanbeexp
resse
da s F
lgu
re3
.8G
rap
hlc
als
olu
tio
n,E
xam
ple3
.3
.
1
32 lN
L E
ARP
ROG
RAM
MIN
G 3
.4 A
DDI
TIO
NALE
XAM
PLE
S 1
33

x2=x 1- X22
2 (
3.3
7) Phase"T abe2
l :Table313i
. s1heseco
ndtab
leunderP
hase.1ThevJu
a eofth
e
Thestan
dar
df o
mlata
ft
ercon
ver
tingtoamininuza
tionpr
oblm,
e i
ntr
odu
cin
gslack, a
rti
fi
ci
alfun
cti
oni
s2,soPha
se1isnoty
etove
r.TheEBVisX22・
TheLBVisal・
The
sur
plu
s,佃da r
ti
fi
ci
alva
ria
ble
s,an
di n
clu
dingEquatio
n(3.
37)r
esu
ltsi
n se
condrowis1
hep
ivo
tr o
w.Thi
sr owwi
IIbeuse
dforrowm
anipul
ati
onsωyi
eldth
e
ne
xttab
le
.
Mi
n回r
ie f-2x1+x21-X22
z (
3.38
)
響│ T
abl
e3.
13E
xam
ple3
.:T
3 a
bl ,
c2Ph
ascI
Su
険je
ctt
o: gl:X1+X21-X22+
81=5
X
) X
2) X22 $) U) 8
2 a2 b
g
l
g
3
:2x1+X21-X辺 +at=4
:X1+X
21-X22- 8
2+a2=1

。 。 。 。 。 2 4
。 。 -
2 2
l
Thea
rt
if
ic
iaJf
unc
tio
ntob
edr
ive
ntoz
eroi
s

。 3 -3 。 。
。 。 --22 2 /+2
Af=al+~ (
3.3
9) 3 Ar-2

S
imp
lexT
abl
e0:T
abl
e3.
11伺 p伽悶1h
es回 d
ardf
O t
m18 i
nat
ab
le
.Iti
sca
I
IedT
abl
e Phase"T
abe3
l :T
abl
e3.
14i
sth
enewt
abl
eaf
te
rth
erowo
per
ati
ons
.Thev
alu
eof
o
toa
I
Iowf
orp
rep
roc
ess
ingw
i1hr
esp
ect
ωth
ear
ti
fi
cia
1va
ria
ble
ssot
ha
tac
ano
nic
a1f
OlID 由巳 a
rt
if
ic
iaJfu
nc丘onis0a sbohala
1 nda2釘 enon
bas
icvar
iab
leswi
thava Jueof0
四nbeob
鴎rv
ed.A
ddi
ng血e
sec
ond卸d血ir
dro
w阻 ds
ubt
rac出 g血e
res
ult合om由el
as
t fo
r白isit
era
ti
on.百lIssi
g凶fie
s白eendofPhase1
.Phaenw
s i
llst
ar
twiththela
strow
rowa
ndr
epl
aci
ngt
hel
as
troww
i1ht
hi
sco
mpu
tat
ionwil
1yiel
dth
enextt
ab
le
. (a
rt
if
ic
ia1
釦n ct
ion)andth
et w
ocolu
mnsth
atrepr
ese
ntth
ear
ti白c
ia
lvar
iabl
esr e
moved
f
romt
hec
urr
entt
ab
le
.
T
abl
c3.
11 Exam
plc3
.3
:Ta
ble0,
Pha
scI
T自b
lc3
.14 Ex
圃mp
lc3
.3
:Ta
bl ,
e3Ph
aseI
σ10
111
)
X
) 8
) b

X
2) X
22 a
) S
2 a2

1
。 。 。
。 。
。 5
X
)
。 。
X
2) X
22 $) 1 8
2 o
z b

2 I
o 。 -
1
4
1 。 。
o

l

o
2 一2
4
2
。 。
1

。 。
。 o 3
。 。
-2 I
o l 。 f
A
r 。 。
。 。 。
o 。
。 3

4 4 /+8
1 A
r
Phase1 ,Tabl
e1:T a
ble3.12provid
es白es t
ar
tof由eSimpl
exmetho
d.I nPha
se1
th
巴motivati
onistodri
vethear
tif
ic
ialfun
ctio
nto0,w
hic
hhasaval
ueof5.TheEBV Phase1 ,Table1:Table3.
15repr
esen
ts曲etab
l巴tost
artt
heite
mtio
nsforP
hase1
1
.
iS
Xl・TheLBVi sa2'Theth
irdrowisthepi
votro
w.Rowman
ipul
ati
onswithth
epivo
t However,t
herear
enonegat
ivecoe
ffi
cie
ntsi
n曲巴 la
strow(rowcorr
espo
ndin
gtoth
e
rowleadtoTabl
e3.13. obj
ect
ivefun
ctio
n).Sca
nningthe帥 lefu氏h
er,1
hecano
nica
lf o
rmc a
nb eob
ser
ved
.
百lere
for
e,theso
luti
onhasbee
no b
tai
ned.百leso
lut
ioni
s
T
llb
lc3
.12E
xam
plc3
.3
:Ta
bl ,
e1Ph
由sc
l
T
abl
c3.
15E
xam
plc3
.3
:Ta
bl ,
e1Ph
asc1
1
X , X
2' X22 ,$ a) $
2 a2 b
, ,$
。 。 。 x


X


局z


8
2 b
12123


o
o 。 5
4
。 。 4
o
。 f 。 2 2

。 。 。
。 。

--

o o 3
。 。 。 。
'Aqι

-1
2 Ar-5 4 /+8
1
34 L
JNE
ARP
ROG
RAM
MIN
G 3
.4 ADDITIONALE
XAM
PLE
S 1
35

xl
=3;
x2 22=2
1=0;x ;sl=4;s2=0;/=-8 g
l:4
xI+9x
2+73+I
x Ox4S6
00

Thev
alu
eofX2i
s T
hea
vai
lai
b1
it
yoft
hel
ith
ogr
aph
icm
ach
inec
anb
ede
vel
ope
das

g
2:xl+x2+3x
3+8
x4s
;420
2=(X21-x
X 22)=(0-2
)=-2
百J
epa
cka
gin
gco
nst
rai
nti
s
w
hichw aside
nti
fie
dear
lie
rg r
aph
ica
lly.
百leaboveexampl
eillu
st
rate
dtheSimplexmethodfo
rha
ndli
ngnega
tiveva
riab
les g
3:3
0 +40
xI ら +20x3+I
. Ox4S8
00
a
ndequal
itycon
str
ain
ts.Not巴自己 app
licat
ionoftheSim
ple
xt e
chni
queit
sel
fdidnot A
lldesig
nv a
riabl
esar官 邸p田 t
edtob eg偲 a
ter白 肌 zer
o.Asf ormula
teda b
ove,出e
c
hang
e.Ani nt
ere
sti
ngfeat
ureof白ep ro
bJemwast ha
tPhas
eIIw asimmedia
t巴ly p
roblemsug
gestsade
greeofincom
pleten
es s
.τnerearef
ourdesig
nvaria
blesandonl
y
o
btai
nedaft'P
el hase1wit
houtanyfur
therit
era
tin,
o whic
hsug
gest
s白紙 thesear
chfor t
hre
econst
rai
nts.明len umberofvar
iabl
esint hebas
isc a
no nl
yb e山間e.H ence,a
t
t
heop t
im u
mist ak
ingplac
ei nPhas巴 1eventhough出efocu
siso nthear
tif
ic
ial l
ea
sto neof出ev ar
iabl
esm us
th aveav al
ueo fz e
ro.S ev
巴ra
lu se
fula d
diti
ona
l
v
ari
abl
es. c
ons
tra
intscansti
Ubeinclu
dedtodef
ineav a
lidoptim
izati
onproblemwithanonzer
o
s
olu
tio
n.前lisisnowam ode
lingiss
ue.Forproblemswithalimi
tednumberofdesig
n
3
.43 Ex
. .4-
ample3 AFo
ur-
Var
lab
leProblem v
ari
abl
es,payingatt
enti
on10thep robl
emd evelopmentallow
sa nt
ici
patio
no fth
e
s
olu
tio
na swell俗 t h
eo ppo
rtuni
tyt o 町o u
blesho
otd ecis
ionsf romp r
act
ica
l
E
xam
ple3
.4p
res
ent
saprob
lemwi
thfou
rva
ria
ble
s.Thepr
oce
dur
eisid
ent
ica
ltot
he c
ons
ider
atio
ns.Iti
slef
tto出es tud
enttoexplo陀 th
isproblemfu
rth
er.
o
nei
nExa
mpl
e3.1,e
xce
pt出at血er
eisnog
rap
hica
lsol
uti
ont
othepr
oble
m.
StandardFormat: The o
bje
cti
v巴 f
unc
tio
nre
qui
res a minimum f
orm
ula
tio
n.
TheProblem: TheRITs
tud
ent
-ru
nmi
cro
ele
ctr
oni
cfa
bri
cat
ionf
ac
il
it
yist
aki
ng Henc
巴,

ord
ersforf ou
ri ndigenousl
yd evelopedASICc hi
ps出a tc anbeu s吋 in(1)t o
uch M
ini
miz
e f
.-6x1-1O~ -9x3- 20x4
sen
sors,(2) LCD,( 3)p re
ssures e
nsors,a nd(4)c on
trol
lers
.The r
ea reseve
ral
co
nstra
intsont heproductionbase
do ns pace,equi
pm e
nta v
aila
bil
ity,stu
denthour
s, Thes ym
bol/hasbee
nretai
nedfo
rc o
n v
enie
nceeve
nt ho
ught h
edII宅ct
ionof
andt h
efact山a t出ep r im
arym is
siono f白ef a
cil
ityiss t
udenttrai
nin
g.Firs
t,出e opt
imi
zat
ionh
asc
han
ge.百 l
d econs
回int
sarese
tupus
ings
lac
kvar
iab
le I・
sS a
S2,nds3

han
d l
ingt im
ec ons回 in,toutsi
deo fprocessin
g,forallchipsis6 00hours
.T ouch
sen
sorsrequi
re4h o町 s,LCD9h ours,pre
ss 町'
esensors7h ours
,an dcon住ol
ler
s1 0 g
.:4
xI+9x
2+73+1
x 0x4+S
.=6
00
ho
urs.Sec on
d ,th
et imea v
ailab
leo nthel i
t h
ogr
aphi
cm achinesisa bo
ut4 20hou
rs.
TouchsensorsandLCDr 叫u i
re1h our,pressu
res e
nsors3h ous,
r andco
ntrol
ler
s8 g
2 .+~ +3x
:x 3+8
x4+s2=420
ho
urs.P a
c k
agi n
gc onsider
ation
sp lacethemaximuma t800v olumeu n
its
.T ouch g
3:3
0x.+40x
2+2 3+l
0x Ox4+S3=8
00
se
nsorsrequ
ire3 0voJurneunit
s,LCD40v ol um
eu n
its,pre
ss町'csen
sors20unit
s,and
con住ol
ler
百 10u nit
sb e
c aus
eo f山e i
rc o m
pa ctsiz
e.A ll山ec o
ns住a i
nt
sa boveare lv
Al a
ria
ble
sar
e~ O
.百 l
efo
rmu
lat
iona
bov
esu
gge
stst
hes
tan
dar
dSi
mpl
exm
eth
od.
in
di回 te
dp e
rweeko fo pera
tionofthefac
ili
ty.百 enetr eve
nueis$6,$10,$9,叩d$20
fo
rt h
et o
uchs enso
r,LCD,p 問ssur
es ensor,andcon
trolle
r,resp
ecti
vely
.百l efac
ili
ty S何 '
P1xTable1
e :Tabl
e3.1
6is出ei
ni削 t
abl
efo
rExamp
le3..Thec
4 ano
nicIf
a orm
i
sintere
stedinm axi
m izingr e
venueperweeka ndwo u
l di
¥ketod e
te r
minetherig
ht i
sobse
rvab
lefro
mth
etab
leandt
hei
ni
ti
alb
asi
cfe
asi
bles
olu
tio
ncanb
edete
rmin
ed.
mixof由巳 f o
urd e
vices.

ProblemFormulation: The fo
rmu
lat
ioniss t
rai
ght
for
war
db as
edo nthe T
abl
e3.
16E
xam
plc3
.4
:Si
mpl
exT
abl
e1
st
ate
ment
sabov.L
e etx( r
ep問s
entt
henumbe
roft
ouc
hsens
orchi
psp
erw田 k,
X2白E
nu
mberofLCD,x3th
enumb
ero
fpr
ess
ures
ens
or,
san
dX4白en
umb
ero
fco
n佐o
ll
er
s. X
I X2 X
J X4 8
1 J
"2 S
J b
明記 o
bje
cti
vef
uncti
onis
4 9 7 1
0
。 。6∞
。 。
M
axi
miz
e: f
.6x.+lOx2+9x3+20x4 3
0 4
0
3
2
0
8
1
0 。 。 42
8
0
0
0

Theh
and
lin
gti
mec
ons
tra
intc
anb
eex
pre
sse

-
6 -
10 -
9 -
20 。 。 。f
136 lN
L E
ARP
ROG
RAM
MIN
G 3
.4A
DDI
TIO
NALE
XAM
PLE
S 137

T
abl
e3.
17E
xam
ple3
.4
:Si
mpl
exT
abl
e2 UsingM
ATL
AB

x , X2 X3 X4 ,
s 8
2 8
J b Thisi
sasta
ndardLPprobl
em.Thissec
tionuse
sMATLABinanint
erac
tiv
es e
ssiont
o

2.7
5 7.7
5 3.2
5 。 。
l -
1.25 。
。 7525.5
s
e
o
I
x
ve白 ep
創np
le.N
r
o
t
ob
l
et
em
h
.百l efo
ll
ewamingf
o
r
w
i
o
ngisad
mMATイL
AB
ia
.a
ryf
swe
i
lefo
rtheMATLABs
Il凶白es u
bsequ
en
e
tu
s
s
s
io
eo
nfo
ft
r出i
h
s
eLP
0.1
25 0.1
25 0.3
75
。 。 012
.
25
5
2
7 5
progr
amusin
gb oundson曲ed esig
nv a
riab
les
:百l ebo
ldital
ici
zedstat
ement
sa r
e



1.
。 。
2
8.7
5 3
8.7
5 1
6.2
5 commandsuse
dt oo
btai
ntheso
lut
ion.TheMATLABprompti
sedit
edou.
t
-
3.5 -
7.5 -
1.5 2
.5 f+1050 he
lplp
LP Linear programming.
X=LP(f,A,b) solves the linear programming problem:
I・
S S2.a
nd$3ar
et h
ebasi
cvari
abl
es.TheEBVisX4a
nd白 eLBVi
s$2w
hic
his白E min f 'x subject to: Ax <= b
min泊lumof{60.525,8
. 0}.Thep i
votrowi
sthesec
ondrowu
sedf
ortherow X=LP(f,A,b,VLB,VUB) defines a set of lower and upper
man
ipul
ati
onst
ol e
adtoTab
le3.1
7. bounds on the designvariables,X,so that the solution
is always in the range VLB <= X <= VUB.
S
imp
lexT
abe2
l :Usingt
hep
ivo
trowi
den
tif
iedi
n山el
as
tta
ble,出eu
nilv
ect
or[
0 X=LP(f,A,b,VLB,VUB,XO) sets the initial starting point
o1O]Tunderthe$2columnneedstobetransferredto出eX4 columnthrough to XO.
e
lemen
taryrowope
rati
ons
.T a
ble3.17shows白ec a
nonica
lforma
fte
rcompl
etio
nof
a
llth
eopera
tio
ns.Thebasi
cvaria
ble
sareX4.$"組 dS3・TheEBVisX2and白eLBV X=LP(f,A,b,VLB,
VUB,XO,
N) indicates that the first N
i
sS3・百lepivo
trowist h
e白i r
dr ow
.Theo bje
cti
veoft h
erowmanipu
lat
ionsi
sto constraintsdefinedbyA andb areequalityconstraints.
t
ran
sfe
rtheuni
tvect
or[001O ]Tfromth
e$3columnto白 exz
colu
mn.
X=LP(f,A,b,VLB,VUB,XO,N,DISPLAY) controls the level of
warning messages displayed. Warning messages can be
SimplexTable3:T a
ble3.18d
enotesth
ered
ucedta
blewi出thecano
nicaJformaf
ter turned off with DISPLAY -1.
th
er e
qui
redrowope
ratio
nsarec
o m
plete
d.Theba
sisva
riab
l回 釘eX2.x4,a
n dS
I・There [x,LAMBDAJ= LP(f,A,b) returns the seヒ of Lagrangian
m芭 none
gativ
ecoef
fic
ient
sinthela
strowsu
gges
tingthes
olu
tionhasbeenobtai
ned
. multipliers,
From白et ab
le白巴 s
oluti
onis LAMBDA,at the solution.
XJ=0,x2=7.09
6,x3=0 ,
x4=51.6
1,/=1103
.22
[X,LAMBDA,HOW] LP(f,
A,b) also returns a string how
Thesol
utio
na bo
veisn
otsat
isf
act
orybe
causet
heact
uald
eci
sio
nwiI
linv
olveint
ege
r that indicates error conditions at the final iteration.
val
uesfo
rthedesi
gnva
ria
ble
s.Atth
istiei
m nte
ger
p r
ogramm
ingisn
ota
no p
tio
n.The LPproduceswarningmessageswhenthe solutioniseither
ad
juste
dsolut
ionis unbounded or infeasible.
c= [ -6 -10 -9 -20];
X1=O,
x2=7,
x3=O,
X4=52,/=1
110 A= [ 4 9 7 10; 1 1 3 8; 30 40 20 10];
While白isc
hoi
cesati
sfi
es出ec
onst
rai
ntsg
3.g
2howevernee
dsaIit
tl
eel
ast
ici
ty(l
imi
t b = [600 420 800];
i
s4 23)t
obesa
tis
fie
d.Not巴白a
tsJisabas
icv
ari
abl
es oc
onst
rai
ntgJsho
uldnotbea x=[c,A,b]
probl
em. x =lp(c,A,b)
Warning: The solution is unbounded and at infinity;
T
abl
e3.
18E
xam
ple3
.4
:Si
mpl
cxT
nbl
e3 the constraints are not restricヒive enough.
x
x , X2 X
J X4 ,$ 8
2 $
) b 1.0e+015 *

-
3 。。 。 -
0.2 20
-0.0000
3.7067
0
.
0
.
0
7
3
2
4
1
2
9
5
80 0
3
.
51 0
.
3
4
2
2
1
9
5
3
8
1
5
5 。 。 .032258 0.025806 7.019269774
o 02 90322 -
-0
0
.
1.0
033 56
2 1
. ・8.8391

2
.06
451
60 1
.64
516
1 。 。2.25806451 0
.19
358 f+1
4 103
.22
2.8513

138 L
lNEARPROGRAMMING 3
.5A
DDI
TIO
NALT
OPI
CSI
NLlNEARPROGRAMMING 139

vlb= [0 0 0]; T
hisi
sal
sorefe
rre 0踊 an
d1 or
ma lmaximump
rob
lem
.
=
vub [100,100,100]; 百l
edualo
ft h
eabovepr
oblemisde
fine
das
x= lp(c,A,b,vlb,vub) Minimize 3.43

;
:
w:b
lYI+blY
2+.
..+b
"Jr
n
' ( )
x
0.0000
S
ubj
ect1
0: a
llI+a
Y 21Y
2+..
.+a
rnl
Ym~ c
J (
3.4
4)
7.0968
o
a
l2Y1+a
222+.
Y ..+a
m2m~ c
Y 2
51.6129

T
hisi
sth
cso
lut
iono
bta
ine
dbyw
ork
ingt
hro
ught
heS
imp
lexm
eth
od.
a
l,J .a
'1.
. 2
"Y2+.
..+a,tuJ'", さ C"
YI~O, i=1
,2,...,m (
3.4
5)
3
.5 ADDITIONALTOPICSINL
lNEARPROGRAMMING

Thissec
tio
nl o
oksbrief
lyataddit
iona
Jideasassocia
tedwi山t heLPp r
oblem
.F i
rst, Rela
tions(3.
43)ー(3.
45)d e
scr
ibeanormalminimumproblem.Therei
salsoani
nvers
e
edualproblema rel
ations
hipb etween 曲巴 def
ini
tionoft he two pr
oblems above a
sf aras 山巴
出erei
impo
sad
此ant
i
i
scu
s
n恥 d
si
i
o
s
no
cu
s
ft
si
h
onofse
nsi
tivi
t
ssoci
atedwi
yanalysis-var
tha
削io
nLPp
ninop
r
t
i
o
m
b
l
i
e
z
a
m
t
.D
io
u
ns
a
o
l
l
i
t
u
yi
ti
o
s
n
還 ide
ntifi
cati
ono ftheprimalandd u
alproblem
.I f出巴 lat
teriscons
ideredaprima
l
duetov ar
iat
ionint f
teorig
il
聞 1parametersoft l
teprobl
em.Following出isisa problem,出ent hefor
me ri
s出ec orre
spo
n d
ingdualprobl
em.
dis
cuss
ionofsever
alpiecesofinfor
m凶 onthatcanb eex回 ct
edfrom出ef i
naJtab
l e 百l ef o
llowingobserva
tio
nsc 回 bemadew i由 民spect10thepairofprobl
e m
s
oftheSimp
lexm e
thod. esta
blishe
da b
ove:

1
.Thenumbero
fdu
alv
ari
abl
esi
s出巴 sameω 出enumbero
fpr
ima
lco
nst
rai
nts
.
3
.5.
1 PrlmalandDualProblem
2
.Thenumbero
fdu
alc
ons
tra
int
sist
hcsamea
sth
enumbero
fpr
ima
lva
ria
ble
s.
Associ
ate dwi出e ve ryLPp r oblem,whichwillberefer
redtoωap rim alproblem, 3
. Thecoef
fici
entmat
rixA oft
hepri
malproblemi
str
ans
pos
edt
opr
ovi
de山E
the
rei s ac orr
espo nd ingd i即 1 pr
o b
lem.I nm佃 y ways,出edua J pl'Oblemi sa coe
ffi
cien
tm a
tri
xo ft
hed
ualpro
ble
m.
町 叩spositio
nofthep r im aJprobJem.百lIsismeanttoimpJytha
tift heprim alprobJem 4 叫u
.Thein a
lit
ies釘'Cr
eve
rse
dind
ire
cti
on.
isaminimizati
onprobJem白edua Jproblemwillbeam ax
imizat
io none.l ft heprima
J 5
.ThemaximizationprobJemoft
hep
rima
Jproblembecomesam
ini
miz
ati
on
problemh as11variab les,t hed ua
lp roblemw i
llh av
enc o
nst
raints.l ft h
ep rima
l
probJemi
nth
巴du
alp
rob
lem
.
problemh asmconstrai nts,theduaJp roble
mw i
llhavemv ar
iab
les.Fort hed isc
ussio
n
ofd u
ality,出es tan da rdp ri mC
llpr o
blemi sgener
allydefine
da sam a ximizati
on .Th
6 eco
stcoef
fi c
ient
so ft
hcprim
alpro
blembecomet
her
igh
t-h
andsi
deva
Jue
s
problemw ith~ in
叫u alitie
s( though白es ta
ndardproblemintheLPprogramming o
ft h
eduaJpl'Oble
m.Ther i
ght-
han
dsid
evaJu
esofth
epr
ima
lbecometh
ecos
t
disc
ussion was am in im iz
at i
on problem [s田Eq ua
tions(3.
10 )-(3.12) ] 加 d 由e c
oeff
icie
ntsoft h
ed u
alprobl
em.
∞ns回 Intswere叫 ualities).Thes凶 伽rdprimaJprobleminthissectionisde finedas[3
] 7
.Thep
rim
alanddua
Jva
ria
ble
sbo
ths
a出f
yth
eno
nne
gat
ivi
tyc
ond
iti
on.

Example3.5百l ef ol
lowigexample,a
n dapte
dandmod
ifiedfromRefer
ence3,i
s
Maximize z
:CIXI+CIX2+...+c
,x
, 3.
( 4
0) usedtoi
I
Iust
rat
etheprim
al/d
ualver
sionsoft
hesamep
roble
m.Theproblemiss
olv
ed

S
ubj
ect1
0: a
lll+a
x l2x
2+.
.. l,
+a.x
n~ b , 3.
( 41
)
usi
n gte
chn
iquesd
e v
elopedinth
ischa
pter
.

a
21I+a2~2 +.
x ..+az"xn~ b2 而 eP roblem:Thel o
calcoll
ege'sSchoolofAm e
ricanCraftsmanhasd ec
ided10
par
tici
pateser
iou
slyina10ca
Jchari
tyeventbymanufac
t ur
ingspec
ialcommemorative
dess,
k t
abls,
e andcha
irs.Each1ypeoff um
iturere
qui陀 slumberasweIlastwot yp
es
a
"I
, I+a
X 2+・・・ +a
naX n",
xn~bm ofski
lledlab
or:fmi
shing加 dc細'Pent
ry.Table3.
19documentst heres
ourcesneed
ed.
The10caJlumbercoop
erativ
eh a
sd onate
d48b oardfee
to flumb巴r
.F a
cultyandstaf
f
与さ O,
j=1
,2.....n (
3.4
2) havevolunt
田 町d2 0finis
hinghour
sand8c a
rpen
tryhours.Thed es
kw i
llb esol
df o
r
140 l
lNE
ARPROGAAMM1NG 3
.5A
DD1
T10
NAlT
OP1
CSI
NUNEAAPAOGAAMM1NG 1
41
l
i
l1

l

T
nbl
c3.
19 Example3
.5
:Rωources 主

T
abl 21 Examplc3
c3. .5
:Pr
bna
lPr
obl
cmSi
mpl
cxT
abl
c2

R
eso
urc
es s
Dek T
abl
巴 C
hai
r
d f
X , X2 X3 ,$ $
2 $
3 $
4 b

8 6
S
堅 。
。 。 。 。 。
o 1 4 1
6
。 。 。
。 。
L
umber(b釘d
o fe
et
}
4 2 .5
1 0
.5 -2 4
。 。
F
ini
shi
nghour
s(hou
rs)
C
arp
entr
y(hou
rs) 2 .5
1 0
.5
。 0
.75 0
.25 0
.5 4
5
o 。 。
1
5 。 -5 3
0 f+240

$60
,出et
abl
efo
r$30
,and出巴 c
hai
rfo
r$2
0.Thes
cho
old
oesn
ote
xpe
ctt
ose
J1more
出 印 日v
eta
ble
s.Thes
cho
olwouldl
iket
omaximiz
巴re
v巴nuec
oJ1e
cte
d.
o
pti
malnumbero
fch
air
st ,
obemadeis8
.Not
abl
esw
illbemade.百l
eto
taJr
eve
nue
8
tan
dar
dFormaト P
rim
alP
rob
lem
:Defining X
l a
sth
e number o
fde
sks i
s$2
80.0
0.
p
rod
uced,
X2asthenumberoft
abl
esmanu
fact
ured,andX3ast
henumbero
fch
air
s
m
anu
fac
tured,
thepr
imalpro
blemcanbeex
pre
sse
dins ta
nda
rdfor
mat悩 8ヨ1ndardFormat
. ーD ualP roblem :Whil ethed uaJp roblemcanb巴巴x pres
sed佃 d
setupm田 h阻 i cly,
a
1 itis函 館c ul
ttoa sso
ciate出ed esignv aria
blesinadire
ctm佃 n e
r
M
axi
miz
ez ,
:60x +30X2+20X3 (
3.4
6) aswasdone泊 t heprim Jp
a robl
em.Usingy "Y2,Y3,andY4a sthedesignvar
iables,th
e
problemc anbef ormu
l a
te dasi nE quations(3.48)and( 3.
49)belowu si
n gt h
e
句e
Su c
tt ,
:,
: g 8x +6
o x
2+X3:
;4
:
: 8 3.
( 4
7a) def
initi
ona t由eb egi
nni n
go fthissect
ion.Somea s soc
i ati
onsarepossib
leinlighto f
tran
sposit
ionof出ec ostcoeffic
ient
sandt h
ec o
nst
ra i
nts.Forexample ,thevari
abley,
g
2 ,
:4x +2x
2+1 ;2
.5X3:
:
: 0 3.
( 4
7b) canbea ssocia
tedw i
tht hel umberc o
nstra
intb ecausei nt h
ed ualproblemitsc os
t
coe
fficie
ntisthel u
mb erconstr
aintof出ep rim
alp roble m.Inas im
ilarmanner,Y2is
g
3 , +1
:2
x .5x2+0.5X3:
;8 (
3.4
7c)
:
asso
ciatedwiththefi
nishinghours,Y3with出巴 car
pe ntryh o
urs,andY4wilhthespecia
J
tab
lec o
nstrai
nt.明記 objectivefunctio
no fthedualproblemi se xpr
essedinEquat io
n
1
!
4:X2::;5 3.
( 4
7d)
(3.
48).Inviewof白eformoft hee xp
ressionofth eobj ec
tivefuncti
onw, 血E 毘 isa
pos
sibil
ityt h
at出ed esi伊 V紅 iabl民 int hedu Jp
a roblemc anhave四 e co
n o
r ni
c
>X2,
Xl x3~O impl
icationasfol
1ows:

Thesolu
tiontothepri
maJproble
mi savai
1abl
ei nTa
bles3.20-
3.22
.T a
ble3.20ist
h y ,unitpriceforaboardfootoflumber

in
it
iaJta
ble.TheEBVi sx a n
dt heLBVi s$3・Thepivo
trowi sthe出irdrow.The Y
2 un
itpric
ef o
raf i
nish
inghour
subs
equentrowoper
ation
sdetermi
n eTable3.
2 1
.Inthi
stabl
e,出eEBVisx3'theLBV Y
3 un
itpric
ef ora
nhouro fcarp
巴ntr
y
i
ssz,zmdthepiv
otrowistheSEcondEow.Table322ist h
eanaltabl
eesta
bli
shing血E y
4 白iscannotbe白eu n
itpric
eas也ed es
kh a
sapr
icedefmedi
nth
epr
ima
J
opti
malvaluesforth
ev a
ria
ble
s.xt,白eoptimaJnumberofdesks,equals2.~,血e problem-maybeas pecia
Jpric
eforth
edeskr
esou
rce

T
abl
e3.
20 Exnmple3
.:P
5 r
ima
lPr
obl
cm,
Si
mpl
exT
abl
e1 l 準
1
T
abl
e3.
22 Example3
.5:P
rim
a ,
lProblemSi
mpl
exT
abl
e3

x, X2 X) ,$ $
2 S) $
4 b 最 E X, X2 X3 ,$ $
2 .
1
'3 $
4 b

。 。
。 。 。 。 。
。 。 。 。 。 。
B 6 o 4
8 -2 o 2 -8 2
4
4

2
2
.5
1
。 。
.5
1
0
.5
。 。
。 。
o 2
8
0 o -2
.2
1 5 。 -
0
2
.5
4
.5
1
8
2
5 o o o
。 。
1 5
-60 -
30 -20 。 。 f+O 。 5 o o 1
0 1
0 o f+280
1
42 lN
L E
ARP
ROG
RAM
MIN
G 3
.
5AO
OIT
ION
ALT
OPI
CSI
NLlN
EARP
ROG
RAM
MIN
G 1
43

Thed
ualc
anb
eex
pre
sse
das T
abl
e3.
24E
xam
ple3
.5
:Du
alP
rob
le,
mPb
as ,
e1Ta
ble2

Min
imi
zew
:48
YI+2
0Y2+8
Y3+5
Y4 (
3.48
) Y
1 Y
2 Y
) Y
4 5
1 5
2 S
) a
1 a
2 a
) b
。3333 0 。 。 3333 。
6 。 5
S
ubj
ectt
o: hl8I+4
Y 2+23+O4注60 (
3.9a)
1
. -
1.3
331 .3
1 33
3 -
1. 20

: Y Y Y 4
03
330.25
.3 0.16
66 o -0.
166 o
6 0.166
h
2:6
YI+2
Y2+1
.53+l
Y Y4~ 3
0 (
3.9
4b) 。4
o 6
6
1
.60
1 .2
5
4
-
0
-
3
.16
67
。 0
8
.
166
6-1
。 oo -8.1666 o w-152
-0

。2.5 。A-35

o-
2.5 .
-025 .5
1 一
1.5
h
3:l
YI+1
.52+0
Y .53+O
Y Y4~ 2
0 (
3.4
9c)

YI>Y
2,3~ 0
Y (
3.5
0)
rowc o
ntainsther ninimumo f([20
/1.333],[510
.3333],[15
/1.66
67]})
.百 lepivotr owis
l
ntr
oduc
ings
urp
lusva
ria
ble
s(SI>S
2,S
3)anda
rti
fi
ci
alv
ari
abl
巴s(
al 2
'a3 。

)出ed
ual row3.T abl
e3 .25rep隠 s
entsth巴nex
tt a
ble
.百 leEBViss 2・Noteinth
iscぉε t
herearet wo
p
roble
misex
pre
sseda
sas t
and
ardLPpro
blem
: can
didatesforEBV( S2・S
3)
'S2isc h
os e
na rbi
tra
ri
ly.百l eLBVi sal'Thep iv
otr owis出E
M
ini
rni
zew
:48
YI+2
0Y2+8
Y3+5
Y4 (
3.48
) 街百trow.A f
te rthe[珂u i
redrowmanipulations,T
able3 .2
6isgenera
ted.Scannin
gt hela
st
row,th釘e a
reo nlyposit
ivecoef
fic
ien
ts.P hase1isnowc omplet
e.Th eart
if
ici
alvariab
les
S
ubj
ect
to: hl
:8l+4
Y Y2+2
Y I+a
3-S l=60 (
3.5
1a) and白 巴 紅ti
fic
ialcostfunc
tioncanber emo vedfromt h
eLPp roblem.
Elirnin
ating白ea rti
fic
ialvari
able
sa n
dt hear
tif
icia
lcostfuncti
onf romtheproblem,
h
2:6
)
'1+2
Y2+1
.53+l
Y Y 2+a
4-S 2=3
0 (
3.5
Ib) PhaseIIisstartedwithTab l
e3 .
27.N ot巴t h
atTable3 .2
7c onta
insn oinfo
rmationthat
i
sn ota lreadya vai
lableinT able3 .2.I
6 to nlyp rov
idesa nu nc
1utter
edt ab
lef or
h
3:l
Yl+1
.52+0.
Y 5Y3+O
Y 3+a
4-S 3=2
0 (
3.5
1c) con
tinuingt h巴 appli
cationo ftheS imp lexlechnique,andt here
foreisn otr ea
lly
nec
essary.InT able3.27,theEBVi sS 3・TheLBVi sYla ft
eratossb e
tweenYla ndsl'
[
nPhas
e1ofth
et w
o-ph
aseapp
roac
h,山ear
tif
ic
ia
lva
ria
ble
sar
ere
mov
edf
rom白E Thepivotrowi sthesecondr ow
.T hisrowi su sedtoobtainTable3.28.Inthi
st abl
e,
b
asi
susi
nga
nar白c
甘 ialc
ostf
unc
tio
nAd e
fin
edas not
et hatthev alueo ftheb a
sicv a
r i
ableSIi sO.T hisisc a
lledad egene
r a
teb asic
var
iabl
e .Th eEBVf orthenexttab
leisY 3・TheLBViss 3・Thepivotrowis白es 田 ond
M
ini
miz
eA: al+a2+a3 (
3.5
2) row( n
ote:t hep iv
otr owc anb e曲eroww i
tht hed e
g e
neratebasicsoluti
oni fthe
columno ftheEBVh asap osi
tivecoeffi
c i
entin曲a trow).Table3.29is曲ef in
alt a
ble
ThePhase[compu
tationsar
edisplaye
dinT a
bles3.23
-3.26
.T a
ble3.23isid
ent
ifi
ed andcontainstheo pti
m a
ls ol
utio
n.Thef in
alsoluti
ono fthedualpro b
lemis
ast巴s
h imp
lexTab
le1 ,andi
tin
c1udessomep r
eproc
cssi
ngbyw hi
cha"a 2,an
da3釘 e
made山eb as
isvar
iabl
es.Asar eminder,th
el a
strow問 pres
ent
s山ea r
tif
ic
il∞s
a t Y ,活=,
;=0 O
ly;=1
0,
見 =0, w・
s;=5, =280
fun
ctio
n.Fromi n
spe
ctionofTabl
e3 .23,Y
IistheEBV.TheLBVi sa2and由巳 piv
ot
rowistheseco
ndrow.Follo
wingthestand
ardrowopera
tion
s,Table3
.24isobt
ain
ed. Tos
umm
ari
z t
e,hes
olu
tio
noft
hep
rim
alp
rob
lemi
s
[nth
istabl
e,th
eEBVi sY2(也elarg
estn e
gati
vecoeff
icie
nt).
ηleLBVi sa3(
白E出 ird
x ,
;=2xi=0,
x ,
;=8s;
p=2,
4勾p=5,
z*=280

T
abl
e3.
23 Examp
le3
.:D
5 u
alProb
le,
mPh
os ,
e1Ta
ble1 ・
fh
esu
bsc
rit“
p p
"isa
dde
dtoa
sso
cia
tet
hes
lac
kva
ria
blew
ith白ep
rim
alp
rob
lem
.
Thes
olu
tio
noft
hed
ualp
rob
lemi
s
b
Y
1 Y
2 Y
3 Y
4 5
1 5
2 S)

l Q2 a)
,点=1, =1, ;
Y
4=0, , W・
。。。。
Y
;=0 0 0 Y si=5 =280
8 4 2
。。 。。。 6
0
6 2
1
.5
1
.
0
.
5
5 。 。 。 。 。 2003 SomeFormalObservations

4
8 2
0 8 5 。 o 。。 。。 w Thes
eobse
rvati
onsarej
ust
ifi
edmorcfor
mall
yinmanybooksonli
nea
rprog
rammi
ng,
-
15 ー7
.5 4
ー 。 。 o 110 A- someo
th
ef o
r
fw
ma
h
lr
ic
e
s
hh
ul
t
av
sa
eb
r
e
ee
e
l
ni
ab
o
n
r
1u
c
a
le
de
di
dus
nt
in
gt
h
er
h
e
es
f
o
e
l
r
e
u
n
t
i
c
o
e
sa
n1
tt
0t
h
h
ee
ee
n
x
do
a
m
ft
p
l
h
ed
i
sc
is
h
a
c
u
p
s
t
e
s
e
r.H
di
e
r
nt
e,
h
is
-品晶

Table3
.25 Example3.
5 , ,
:DualProblemPhase1Table3

y, Y
2 Y
3 Y
4 ,$ S
3 a , a2
。 。
$2 a
3 b


o -0.
0.
1
2
8
7
5
8
7
6
-
1.
0
.
14
2
2
1
9
4
3 。

114
.
-0.2
29
1
43
114
. 29
02857 。

-
1.
0
14
.
21
29
4
3
-l
.¥429
-0.2
857
2
0
.
.
8
5
7
1
7
4
1
3
。 o 0.
2143 -0.
142
9

0.1
429 -
0 .
8571

-
0.142
9 0.85
71 1
2.857

。 。 -4
0
.
.
2
8
8
5
5
7
7
1 ー2

1
.
.4
14
2
86
29 -
1
7.
.
42
14
86
29
3.
-
1
4
.
28
6
14
29 。
ー7

2
.
.
1
4
4
2
2
8
9
6 -
3.4
286
2.
1429
w-291
A-2
.8
.43
5
7

T
abl
e3.
26 Example3.
5:DualP
rob
le,
m Phase1Table4 ,
y, Y
2 Y
3 Y
4 ,$ $2 S
3 ,
a ~ a
3 b

。 。
o -
0.25 -0.
875 0.
875 2.4999
。 0
.125 -
6 E
-O岳 -0.1
875 6E-06 0
.5 0.
1875 -6E
ー凶 -0.
5 1.25

。 。
0
.25 4E-0
5 0.
125 -4E-05 -
0.125 4E
-05 1
2.5

。 。 。 。
6
.49
98
。 。
-
3.0
001 4
.99
98 0
.00
02 -
3.9
998 -
6.4
998 -
0.∞02 3
.99
98 w-3IO
o A
宇品切
146 lN
L EARPROGRAMMING :
1
1 3
.5A
DDI
TIO
NAlT
OPI
CSI
NLlNEARPROGRAMMING 147

T
ab1
e3.
27 Exomp1e3.
5:D
uo1P
rob
1em
,Ph
ascD,
Tab
1c1 T
ab1
e3.
2 :Du
9 Examp1e3.
5 a1P
rob
1em
,Ph
ose1
1,T
ob1
e3

Y
I Y2 Y3 Y4 S
I S2 S
3 b Y
I Y2 Y
.l Y4 .
f
l S
2 SJ b

。 。
。 。 。 。


-
0.
0
.
2
1
5
2
5 。

-0
.
ー0
8
.
1
7
8
5
7
5 。
。 0
.5
2.5
.2
1 5
2
8 。 。 -
1
-
1
.2
5
.5 。 2
4
5
1
0
ー2 o o
。 。
0
.25 0
.5 -2 1
0
。 。
0.
125 1
2.5
O -
3 5 6
.5 。一 4 w-31
O
~i
2
4 5 2 8 .
f-280

c
ons
tra
int(
3.5
1b)i
ssat
isf
ieda
sanin
equ
ali
ty.T
heref
o陀, t
hes
eco
ndp
rim
al
se
cti
on.Nopro
ofs創 '
egiv
en.A¥
lofth
eobse
rva
tionsmaynotb
ere
lev
antt
oExample
v
ari
abl
ex2isn
onba
sic剖 d出isi
sev
iden
tinTable3.
22.
3.
5discu
sse
dabove,butar
einc
Iud
edher
eforcom
plete
nes
s.
(
i)I
i ftheithdua1var
iab
leisbasc,t
i h
entheithpri
malcons
trai
ntisast
ri
ct
eq
ual
ity
.FromT a
ble3.29,
Y2a n
dY3a r
eb a
sicvari
abl
es,th
eref
ore(
3.4
7b)
1
. Theprimalan
ddua
lp ro
blem
sh av
et hesam巴valu
efort
heopt
ima
lo b
ject
ive
叩 d(3.
47c)mustbeeq
ual
iti
es.Thisisi
ndecdtr
uc
.
func
tion,
7"=w"=2
. 80
.Thisi
str
ue,however,
onl
yifth
epr
obl
emshaveopt
imal
sol
utio
ns. Thescr
ela
tio
nsc
ana
lsob
ccs
tab
lis
hcdbyv
alu
cso
fsl
ackv
ari
abl
es.
2
.(fxisan
yf e
asi
blesol
utio
ntotheprimalpro
blcm.andyis叩 yfeas
ibl
esolu
lio
n 6
.Rccoverin
gp rima
ls ol
utionfromf i
naldualtab
le: Whenl heprima
la nddual
t
othcdualpro
blcm.出 叩 w(y)~ 7
.(
x)
.T h
isfeat
urepro
videsanestim
atcofth
e p
roble
rnsareint hestan
dardf o
rm,thev alu
eo fth
cithprim
nlv a
riabl
ee q
uals
bo
undsofthedua1optim
alv a
lueifaf c
asi
b1eprim
alsolu
tionisknown.Thi
s t
hereducedcoeff
icie
nt(tha
tis,thecoef
fici
entinthela
strowofthefin
altab
lc)
r
csu
ltal
soholdsfo
rt h
erevers
ec a
sewhenaf ea
sib
l巴dualisknown. o
ft h
es l
ackls
urplusvari
ableassoci
atedw i
tht hei
thdualcons
trai
nt
.I nTable
3
.29,thevaluesoft h
er educ
edc os
tc oef
fici
entcorre
spond
ingtot hesur
plus
.I
3 f
出eprima 1problemi su nbounded
.t hed u
alp roble
mi si n
feas
ibl
e.The
v
aria
blesSI・S'a
2 ndS3 ar
e2,0,and8,r e
spec
tive
ly.Th回 eareprecie
s¥ythe
unboundedproblemimp
lies白紙 t h
eobject
ivefunc
tionva
1uecanbepushedt o o
ptimalvalu
eso ftheprima
lv a
riabl
es.
in
fin
itelim
its
.百 lishappen
si fthefea
sibl
edomaini snotc1ose
d.Ofc ourc,
s
pr
acti
calcon
sidera
tio
nswillli
mitthcob
jecti
vefunct
ionvalu
et ocorr
cspon
ding 7
.lf出ei t
hdualvar
iabl
eisnonba
sic,thevalueofi
tsredu
cedc ostc o
effi
cien
tis
im
I it
sont hedesignvar
iabl
es.Thei nve
rserela
tion
shiphol
d sto.I
o fthedua1 thevalueo
f由巳 slackl
sur
plu
sv a
riabl
eo fth
ecorres
pondi
n gpr ima
1c o
nstra
in.
t
proble sunbounded,
mi theprima
lisinfe
asib
le. InTable3.
29,YIandY4ar
enonbas
icv a
riab
leswi山 re
ducedcostc o
effi
cien
tsof
24and5,respω
tivel
y.Thesear
ct h
ev a
luesofS
I(Sl
p)andS4(S4p)inTable3.2
2.
4
.Ifth
ei hp
t r
imalcon
str
aintisanequa
1it
yc o
nstr
aint,t
heithdua
lvaria
bleis
u
nre
slr
icte
dinsig
n.Thercver
sehol
dsto
o.Ifthepri
malvar
iabl
eisun
rcs
tric
ted 8
.Obtain
ingdua Is olu
tionf romp ri
mals olut
ion
: Whent hepri m
a landd ua
l
i
nsig
n.出e nth
cdualcon
stra
inti
sanequ
alit
y. p
roble
rnsa r
ei nthestan
dardform ,thevalueoftheithdualvar
iableequalsth
e
r
educcdcoeffi
c i
ent(白紙 is,thecoef
ficien
tint h
elastrowo fthefina
lt a
ble
)o f
5
.Ob
tai
nin
gpr
ima
lso
lut
ionf
romd
uals
olu
tio
n: t
heslackl
s u
rplusvaria
blea ssoc
iatedw i
th出ei t
hp rim
alc on
straint
.lnT abl
e
)I
(
i fth
eit
hdu
alcon
stra
inti
sastr
icti
neq
ual
ity,t
hen出ei山prim
alvar
iabl
eis 3
.22,thev a
lueso fthereducedc o
stc oef
fici
entcorrespond
ingt ot h
es u
rplu
s
n
onb
asi
c(f
oroptimumso
lut
ionson
ly)
.Fromt hed
uals
olu
tin,
o t
hes e
cond v
aria
blesSI,S'S3,
2 andS4副 官 0,10,¥
0,a nd0,r e
spec
tivel
y.T he
s eareprec
isel
y
t
heoptima
lv aluesofthed u
alv ar
iablesinTable3.2
9.

T
obl
e3.
28 Example3
.5:D
ualP
rob
lem,
Pho
s 1,
e1 T
nbl
e2 9
.Ifth
eithprimalvaria
bleisnonbasc,
i t
hevalu
eo fit
sr e
ducedcostco
effic
i巴n
ti s
t
heval
u eofthes l
ackl
surplu
sv a
riabl
eo ft
hec or
respondi
ngdua1c o
nstra
in.
tI n
T
able3.22,X2i
san onbasicvar
iabl
ew ithr
educcdcostcoe
ffici
entsof5.Thi
si s
Y
I Y2 Y
.l Y4 S
I S2 5
J b

-
2 。
。 -
0.5
。 -
0.5
。 。。
t
h
c
o
ev
ef
f
a
i
l
c
i
u
e
eo
n
fS2i
tofO
nT
,出e
a
c
b
o
l
r
e3.
児 s
p
29
o
n
.S
di
i
n
nc
gs
eXIandX3a
lack
lsu
rplu
r
eb
sS
Ia
as
ic,w
ndS3v
i
a
t
r
i
ht
ab
h
l
er
e
sw
c
i
d
l
uc
lb
edc
巴ze
o
s
r
t
o,
2
2
0
0
.
.
2
5
5 。 ー0
.37
5
。 。 2.5 a
sobservedinT油 le3.29.


-
0.2
5 1
5
8 -
2 5 5 。 。 IV-3
00 Thea
l
is
tc
b
a
o
nb
v
el
co
i
s
b
t
tr
ai
n
e
f
e
er
r
df
e
o
dt
rn
o
ot
n
h
s
t
ep
an
d
r
a
i
m
r
alandd
dfo
rm
u
.T
h
a
e
lp
r
r
o
ew
i
b
l
le
lb
m
ea
si
p
p
ns
r
t
o
p
a
r
n
d
i
a
a
t
rdf
emo
d
o
i
r
m
f
.As
ic
ati
o
i
n
m
il
sf
a
r
o
r
1
48 lN
L E
ARP
ROG
RAM
MIN
G 35 A
,ODlT
ION
ALT
OPI
CSI
NLlN
EARP
ROG
RAM
MIN
G 1
49

n
ega
tiv
evalu
esofvar
iab
lesぉ w
ellase
qua
lit
yco
nst
rai
nts
.Th
eli
st
edr
efe
ren
cesc
an n
Sesl
tl
vl
ty1
0Co
stC
oef
flc
len
t
b
econs
ult
edforf
urt
herin
for
mal
ion
. 2
0 2
5
電?・・・・・・・ーー
司・
.- 一一ー・・・・・・・ーーー-
‘・・-句、 一一ー司・--ー---
司・・・ち片・・・‘ー 1
61
50
3
.5.
2 S
ens
ltl
vit
yAnalysls

Thesolution10theLPp roblemisd ependenlo nthevalue


sf or出ec o
effi
cien
ts,c,b,
andA( alsotermedparamete
rs ),inv
o lv
edint heproblem
.I nmanyp r
act
icalsitu
ati
ons 5
-
.

-16150

3
0
the
sep a
r 創neler
sa reo nl
yknowna pproximatelya n
dmayc hangef romit
sc urr
ent -

、ー
valu
ef o
ra nynumbero fr e
aso n
s,partic
ularlyafle
ras oluli
onh asb eenesta
blish
ed.
Ins
teadofr ecomp
utinganews o
luti
onitispossibletoobta
inaf reshoneb ase
dont he
g s
exi
stin
go nea ndit
sfinalSimplext a
ble
.T hisissueissig
nific
antinp r
acti
calproblems
wit
ht housandsofvariabl
esan dcons
train
ts.Thea daptat
iono fan 巴wsolutio
nw it
hout 舌ー1白
re-
solvi
ngt hep roblemi scalledsensi
ti
vi.ηa nalys
is.InLPp r o
blems,sensi
tiv
ity 星 -
16
15
0
an
alys
isr efe
rstodeterminingt h
er angeofpara m
etersforw h
i cht h
eoptimalsolut
ion -
15
st
i
llhasthesamev ariab
lesinth巴b a
sis,eventho ug
hv al
uesalIheso l
ulio
nmayc h
ange.
Examp le3 .
1isusedf o
r出i sdiscu
ssion.Figuresare出 edfori1
Iu s
trat
ionrath
erthan -
20
aformalp roof
.Figuresaren otusefulformoret h
ant wov a
riabl
e s
.G en
erally,mosl
compulerc odesthats ol
veIinearp rogramm ingp roble
msa lsop erformsensi
tiv
ily 1ー
c =200-optlmumchanged1
0A
an
alys
is.R e
visit
ing Example 3 .1,it w悩 n ecessa
ry1 0i den
tifyt he numbero f
-
30 1
0 1
5
componentp lncemcntm a
chine sofl yp
eA a n dB.Theo b
jectiveistom aximize山e 0 5
numbero fboar由t obem anu
fac tu
red.C o
nstraintgI re
pres
entsthea cq
uisit
iondoll
ars M
ach
lne
sofT
ypeA
av
aila
ble.Cons 紅'a
in
tg 2repr
esentsthef l
oorspacec on
stra
in.C
t onstra
inlg3repres
ents
円g
uro3
.9 S
en
si
ti
vi
tya
nal
ysi
s,c
han
gin
gco
slc
佃町i
ci
en
.t
th
enumbero fo per
atorsa vaila
ble
. Th ep r oblems t
atementa ndther es
ult
sa re
repr
oducedb elow(note白紙 X 3
'X 4andX sarethcs l
ackvariab
les)
Cha
ngin
gt hccos
tc o
eff
ici
entch
angesth
esl
opeofthel
inerep
rese
nti
ng出e
o
bje
ctiv
efunc
tion血atmayleadt
oac h
angei
n批 so
lut
ion
.Fo
re x
ample,Equ
ati
on
Mi
nim
ize j
(X:-99O
) xI-9 1
X ∞
2-5250 (
3.5
) (
3.)c
5 anbewri
ttenぉ

s
ubj
ecIt
o
: g
l(X
):O
.4x
l・
+-0
.6X 3=
2+X 8
.5 (
3.6
) 2ー
x ={990/900)XIー([5250+j
]/9
00)

IfCIw eretob emade-1900,出e nt h


es lopeof白el i
newillbeー(1900/90
0).Th e
g
2(X
) 4=
:3xI-X2+X 2
5 (
3.7
) sen
siti
vityd uetoC Icanb ee xpe
riencedb yr u
nningS en
sltlvlty_cos
t.m.1The
changew i
l hrespe
ct10t heori
gina
lo bj
ectivefunct
ionisshowni nanimati
on.The
g
3(X
) 2+X5=
:3xI+6x 70 (
3.8
) orig
ina
ls olu
tioni
sm arkedonthefig
urebyac ir
cl
e.Theo r
igi
nalsol
uli
onisunchanged
whenthema 伊i t
udeoftheslo
peisrais
ed,forinst
anceCI= -
1900.Ont heoth
erh an
d,
x1~O; x2ミox3~ 0, x4~ 0, Xs~ 0 (
3.9
) i
fCIw ere10b emade-200 ,Ih
ed o
ttedlin
ei ndi
cat
esthenewc os
tlin
ea ndinthi
scase
thesolut
ionwi 1
lchangetop o
intA.Thi sisshowni nFigur
e3 .
9白紙 i s山E問 sultof
Thes
olu
tio
nis runningthem-fi
Ie.Thef lo
orcons
trai
ntisn olong
erb i
ndin
g.Itcunbeestabl
ishe
db y
simpleca¥cul
ation
s白紙 i n
fin
ite
lymanys olut
ion
sa reposs
ibleifC
Ih asav alueof
;
x=10.4762,X ;
x=0.4524,]=-21437.14
;=6.4285, -450.InI h
iscascthecostfunc
tionispar
alleltoth
eb ind
ingcons凶 i
nt83'Fromt h
is
discu
ssioniti
sa ppar
ent白紙 10k eepthelocati
onoftheorig
inalsol
uti
onu nchange
d,
CI mustb eg rea
lert h
an- 450.S ucha n
ulysisisp os
sibl
ef oral
lI heotherc o
sl
ChangingCostC o
e f
ficlentValues(c)
:F ir
stcon
siderthee仔ectofchangi
n g coef
ficie
nlsin v
olvedin山i sprobl
em.Inp arti
cul
ar,theana
lysissho
uldi n
dica
tefor
th
ecos
tcoef
fic
ien
lsofth
ed c
signva
ria
blc
s.IfCI
Othec
oeff
ici
cntofde
signva
ria
bleXI・
i
schange
df ro
m-990,wil
ltheseto
fbasi
sv ar
iab
lesrc
mainthesame? l
Fi
le
s10b
cdo
wnl
ond
edf
ro
mtew
1
l e
bsi
l
cnr
cin
di
cn
le
dbyb
ol
df
ac
e阻 同 時 目 f
ty
pe
1
50 1N
L E
ARP
ROG
RAM
MIN
G R
EFE
REN
CES 1
51

w
hatrang
eo fco
stcoe
ffic
ien
tst h
eso
lut
ionwou
ldsti
llre
mai
nwh
erei
tis
.Th
isi
s S
ens
iti
vit
ytoc
ons
tra
intc
oel
fic
ien
ts(
a11
)
r
efe
rre
dtoasde
term
iningsen
sit
ivi
tyt
ocos
tco
eff
ici
ent
s. 2
0r
lIil~O
-‘・

ChangeI
si
dechangc
nth
s,t
eResourceL
h
ec on
str
aiti
n Ine
l
s
mlts(
lpla
n
bV
岱/bo
e
u
c
t
n
or
血r
)
i
:Whent
e
sa r
h
ev
emovedp
a
lu
a
巴S
m
ll
o
c
nt
lt
h
cr
ot h
i
e
g
m
s
h
t
e
-
l
h
a
v
e
n
s
d
.
-.
・-‘ ...・
ーニご":----
前li
schangesthefeas
ibl
eregion.Th巴r ef
ore,t
heopti
malvaIue
smaya I
soc h叩 gedueto 一『司司邑

th
echangesin出e f
l回 s
ib
l巴 隠:g
ion.Oncea gainth
ec h
angescanbei l
lu
s回t edb yrunn
ing
5
血巴Se ns耐v 町一巾s
i .m.Figu
r e3 .
10iIu
I s回 te
sthechang
eintheright
-handsideva
Iueof
出efrr
st∞n st
r泊nt
.b..針。mi t
sv a
Iueo f8.5to6.5
.Th i
schang巴caus郎副 t ob ecomean @

a
t
c
t
h
i
eo
v
ec
ri
gi
on
s
na
佐a
Ip
i
r
n
o
tI
.
b
le
nth
mg1
i
sc
w
a
as
sn
e,
o
t
ta
heo
c
t i
v
p
e
t
i
.I
maIsolut
i
n血enewf
onh
or
a
m
u
smovedf
lati
oni
tis
romAt oB
.However
.N
,i
o
ns
t
e
et
n
si
h
t
i
a
ti
vi
t
n
y ト~・
ち」
an
aly
sis,出ep rob
lcmistodiscoverthcrangeofb.so白紙 thesolut
ionst
il
lh as由esame
va
ria
blesin出eb a
sis
.lfblwe 陀 tor e
ma i
na bov
e8 .
0475,th
enthesolu
tionwo uldst
i
llbe
atA卸 dglw i
llnotbeanactiv
ec o
ns町aint
-
15
ChangeIntheC
oef
flcl
entM
atrlxA: A c
hang
ei nth
ec oe
ffici
entma
trixis
s
imi
lari
neff
ectt
otha
tduetoth
ec ha
ngeinth
ec o
stc
oeff
ici
entw
, hi
ledir
ect
ly
-
20

a
1':
0.6-o
ptl
mumc
han
ged
m y
Sen
sl
tl
vl
tyt
ore
sou
rceI
Im
lt
s
2
0 。 s 1
0 1
5

1
5 M
ach
ine
sofT
ypeA

F
lgu
re3
.1
1Se
ns
il
lv
il
yan
aly
sis,c
han
gin
gco
slc
oe
ff
lc
le
n.
l
1
0

5 i
mpacti
ng由巳 problcmbyc ha
ngingthefea
sib
lereg
ion.Thesec han
gesals
od ependon
白 w
hetherthev a
riab
lei nt h
ec olumni sab ns
icv a
rinbl
c01 ' anonba
sicv ari
ublc
.

。 Se
nsltlvlty_
coeff.mi ll
ust
rat
est h
er es
ultofc hangingthec oef
fic
ienta l
l' An
ド i
ncre
aseinthev a
Iuemovest heoptimaIsol
uti
ontoB,w h
ilead e
creas
el eav
est h
e
o -5 s
olut
ionuncha
nged.Inbo t
hs i
tua
tion
s,XIandx2aresti
l
lp a
rto f出eb a
sis
.I nthefi
rs
t


E c
ase,g.b ecomesab i
ndingc o
nstrai
nt
.T hisisillus
trat
edi nF ig
ure3 .11
.T hc
号・1
0 c
oeff
ici
entisintheflf
冨t colum
n,w hichcorr
espon
dst oab a
s icvar
iab
le.C ha
n gi
ng
是 c
oeff
ici
entv a
luesi nt hefir
st column ino t
herc on
stra
ints wi1
¥y iel
ds i
mila
r
-
15 i
nform
atio
n.Th erea
derisencour
agedtotryoth
erchangesinthecoef
fic
ientusing出c
m
-fil
esavai
labl
eint h
ec odesec
tionofthi
schap
ter
.

b
1:6
.5-o
pti
mumchanged-a
cti
vec
ons
tra
int
REFERENCES
-
30
0 5 r
o 1
5 .D
1 an
tzig,G.B.,Lin
earProgrammingandEx t
ensi
o叫 P
rin
cet
onUni
ver
sit
yP r
ess,
M
ach
lne
s01T
ypeA Pin
r ce
ton
.NJ.196
3.
2
.Luen
bergr,D
e .G.,Lin
earandN o
nlin
earProgrammiJg
l ・Add
ison-
Wes
ley.Rea
din
g.
1g
F u
re3
.10S
en
si
ll
vi
tya
nal
ysi
s,c
han
gln
gri
gh
th
・ a
nds
id
e. MA.1984.
152 L
lNEARPROGRAMMING PROBLEMS 153

3
.Winsto n,W. L.
, l nt
rod
uct
iont oMathemati
calPro
gramm
ing
.A ppli
c a
tio
ns and
AIg
or ithms,Duxb
uryP 陀s
s,Bcl
mont,CA,1995. S
ub: 3xI-X2S3

4
.Arora,J.S.,ln
trod
uct
ionωOptimalDe
sig
ll.McGraw-Hi NewY

I or
k.1989. XI+2x2~5
5
.Wilia
1 ms,G..Line
arAIge
brawithAp
plic
atio
ns.Wm.C.BrownPubl
ish
ers,Dub
uque. XI+x2~4
IA,1 9
91 .
6
.No
b1c
.B..飢 dD
ani
el,
J.W.,
App
lie
dLi
nea
rAI
geb
ra.針 e
nti
α-H
al En
l, g
1ew
oodC
li
ff
s. !0;X2u町 四 回c
XI2 旬di
nsi
gn
NJ
.197
7.
3
.6 Theloca
lb o
oksto
remustd e
terminehowmanyo fea chofthef o
urnewb ooks
onphoto
nicsi
tmustordertosatis
fythencwi nt
erestg e
n e
ratedinthed
isci
plin
e.
PROBLEMS Book1c os
ts$75, wi
IIprovideap r
ofi
to f$13, and問 q uir
es2i nche
so fshel
f
spa
cc.Book2c os
ts$85, wi1
lp ro
videap r
ofitof$10, andrequ
ires3i n
chesof
(
Foral
ltwo
-va
ria
blep
rob
les,p
m rov
ide ag
rap
hic
ald
efi
nit
ion
lso
lut
iono
fth
c sh
elfspa
ce.Book3c o蜘 $ 65,wi
llprovideaprof
i tof$8, andrequi
rω1i
, n
chof
p
rob
lem
.) she
lfspa
ce.Book4c o
sts$100 ,w
illprov
ideap r
ofito f$15andr eq
uire
s4i nch
es
ofshe
lfspac
e.Findthenumbero feachty p
et h
atmustbeo rderedtom蹴 回i z
e
3
.1 S
olv
eth
efo
llo
wigi
n In
earprogrammingp
rob
lem
: pr
ofi.
tTota
ls h
elfspacei
s1 00inch
es.Totalamounta v
aila
bleforordcri
ngis
Min f
t
.xl・
X:
z
}:XI+X2 $5000
.Ithasbeendecide
dt oorderat1e
astat o
凶 o f¥0o fBook2andBook4 .
S
ub: 3xI-X2~ 3 3
.7 Th elocalcommunityc olle
gei sp1anningtogrow出巴 b iote
chno10gyo ffe
ring
throughnewf c
dera
lands tategrant
s.Ana mbiti
ousprogrami sbci ngp1anncd
XI+2x2~5

XI+X2S 4
forrccruit
ingatlea
st2 s∞ tude附 fromi nandouto fst
ate
.Theya retorecr
uit
atlea
st40o ut-o
f-st
atcstud
ents.Th eywi 1
1attemp
tto陀 氾rui
tatleas
t30s tud
ents
XI~O;X2~O whoa rei nthetop20%o ftheirgraduatinghighschoolc1as
s.Curre ntfigu
問S

3
.2 S
olv
cth
efo
llo
win
gli
nea
rprogrammingp
rob
lem
: indic
ate白紙 a bout8%o ft h
ea ppl
icantsfromi nst
ate,and6%o ft heapplic
叩 ts
fromo utofsta
tebelongto白ispooLTheya l
soplantorecr
uita
tleast40s tud
ents
Max f
(x)ox
z):XI+巧
whoh av eAPcoursesinbio10gy.Th edatasugges
tthat10%and15%o fin-st
ate
S
ub: 3xI-xz~ 3 ando ut-o
f-st
aleapplic
ants,respec
tive1y,bclongto出i lTh
spoo. eya nt
icip
alc
XI+2x
2S5 tha
tt headditi
onalcos
tp erstudentis$800f orcachin-s
tatcslu
denta nd$1200
foreacho ut-
of-s
tat
cs tudentF in
dt hc
ira ct
ualenrollme
ntn ecdedtom inimize
XI+X2S 4
costandt he
iractu
alcost
.
!0
XI2 ;X22
!0
3
.8 Figure
3.12re
p陀sent
sanoptim
izati
onproblemt
odele
rminethema.
ximumtOl
a1
3
.3 S
olv
eth巴f
oll
owi
ngl
inc
arp
rog
ram
min
gpr
obl
cm: numbero f出巴 smaI
1errect
ang1
es山a twil¥fi
twithinthcl a
rge
rone.The
Min f
(x"X2
):XI-X2 dime
nsionsareind
icat
edon白ef ig
山"C.τnenumbero fth
e1 ar
gerr
芭ctan
g1e
S
ub: 3xI-X2~ 3 shou
ldb eat1ea
st5morct h
ant h
esma ¥
1eron
cs.Thcr ec
tangl
escann
otb e
ro
late
d.Nof r
act
ion
alr巴cl
angl
esareal
1owed.
XI+2x
2S5

XI+X2S4 (
Opt
ion
al:c
onf
irma
Ils
olu
tio
nsu
sin
gth
eOp
tim
iza
lio .
nToolboxfromMATI.AB
.)
XI2
!0;X22
!O
3
.4 S
olv
eth
efo
llo
wigi
n Inearprogrammingproblem: 100


M田 f
(x"X2
):XI+X2
1
.5
S
ub: 3xI-X22
XI+2x
!3 t 仁コ
2S5
2
.5 70
XI+X2S 4

XI2
!0;X22
!0
3
.5 S
olv
e出ef
oll
owi
ngi
Inearprogrammingproblcm:
‘'A
':
_ 1
'1.
. ・
、 u ・
.
. Rguro3
.12P
rob
l日m
3.8
.
4
.1 PROBLEMD
EFI
NIT
ION 155

num
eric
alt ec
hni
quesess
ent
ial10t
hedevel
opmen
tofNLP[ 1,
2)
.Theb ooksfamil
iar

4
totherendershoul
d do admi
rab
ly. Thi
schnpte
rals
oi ntr
odu
cest hesymbolic
compuωti
ol
l(computeralge
bra
)r e
sou
rceava
iln
bleinMATLAB,namely,Symbolic
MathToolbox[3
).

4
.1 PROBLEMDEFINmON

InNLPi ti snotess
entia
l山a tal
lt hefuncti
onsi nvo
lvedben onlin
car.Itissufficie
ntif
ju
stonco fthemisn on
linear.T h
er芭 aremanye xamplesi ne n
gineeringinwhicho nly
白eo bjectivefunct
ionisn onlinearwh ¥
iet h
ec on
strai
n tsa relin
ea.l
r finthisc asethe

NONLINEAR o
p
b
r
j
o
e
c
b
t
l
i
e
v
m
ef unct
ionisaq uadrati
cf unct
io
s(LQP).Optimizationproblemsf
n,the
o
seproble
r恥 mostp
m saret
制 r
er
e
l
medl
yone
il
le
x
a
rq
per
u
a
i
d
e
r
n
a
c
l
et
ic
o

PROGRAMMING i
c
d
o
e
n
n
s
t
t
i
r
f
a
yt
i
nl
h
s
em athe
maticalmodelc
. A knowledge o fe n
o
g
m
i
p
n
r
e
i
e
s
r
i
i
ngo
g,o
n
fth
rt
ed
h
es
ea
ig
p
nv
pr
a
o
p
r
r
i
i
a
a
b
t
l
es,
ed
o
i
b
s
j
c
i
e
p
c
l
t
i
i
v
n
e,
e,i
andt
sa l
h
s
e
o
essen
tialtoc st
abli
sham at l
lematicalmode .
lP ri
marily,thisi n
volvesd e
term iningthe
funct
ionalr elat
ions
hipsamongt hcdesignv ar
iabl
es.Thcr emainingtaskt h
eni s10
est
ablishthes o
luti
on.
Howd oesonee s
tablishthes o
lutiontothen on
linearo ptimizat
ionp robl em?
I
nm athematics( n
fternlla tthiss ta
gcL hereisam athematicalmodel f orthe
Optimiz a
tionp roblemswhosem athematicalmodelsa recharacteriz
e dbyn onlinear problem)t hesol
uti
ollisob t
ainedbys atis
fyingthenecess aηandSI 伊c
{ ientc ondi
tions
equationsa recalledNonlinearP rogramming例 LP)p roblems
.I nCh apt巴r3i twぉ rel
atedtot h
ec l
assofproble~. Then ecess
aryc ond
i tionsar官 thoserela
ti on
st ha
ta
noted血a tthesep roblemsalsofel
li nt
ot h
ec atego
ryofm athemat icalpro gramming C佃 didatefortheoptimums olut
ionm l
lstsa
ti.
φ.Ifitd oes,出e n,andt h
isisi mportant,
problems.Engineeringdesignproblemsa rem ostlynonli
near.I nChap 旬 r2s evera
l tmaybea
i no pt
imalsolution.Toq uali
fyad esignvectorXP( Xrepres
entst hedesign
probl emswereexaminedg raph
icall
ynnditwase vident
thatcurvaturea ndthegradien
t vecto
r)a sa n optimum,i tmusts nti
sfya ddit
ionnlr elation
sc nlledt es
h uj
Jici
ent
oft hef u
nctionsi n
volvedhadas igni
fica
nti n
fluenceont hesolution
.I ns ubsequen
t condi
tions.T he
refore, 佃 optimums oluti
onmusts ati
sfybo 出n ec
essarya nds u
fficie
nt
chapterswew illc ontinuet ocenter由ed iscu
ssiono foptimalityc onditio
nsand condi
tions.T hischaptere st
ablishestheseconditio
nsf ort heo pti
m i
zationp roblem.
numericalt cchniquesarou ndtwo-vari
ablep roblemsbecause出ei d
e a
scana lsobe Example4 .1isestabl
ishedn extandi susedi nsever
a lwaysi nther emaind e
ro f出E
expressedg rap
hically
.E xtensiontomoret hantwov ari
ablesisquites tra
i g
htforwar
d chapter1 0d evclopt h
ec ondi
tionsm entioneda bove. Once 1hωec ondil ion
sa re
andi smosts implewhent hep問 senta
tionismadet h
rought h
eu seo fvectora1gebra
. avail
able, th
en um
ericalt echniq
uesi noptimi
zationwi Ui ncorpor
atethemt oe stabl
ish
MA Bw
TI.A illbeu ti
lize
df oral
lg ra
phicneeds. thesolut
i o
n.
Tradit
ionally,t he
rei s ab ottom-upp re
sentati
on of m ateria
lf orn onlinea
r
optimizat
ion.U nconstrainedproblemsa red isc
ussedfirs
tf ollow巴db yc onstrain
ed 4
.1. n-
1 ProblemFormulatlo Example4
.1
problems.Forc onstr
ainedp roblems山ee q
ualityconstrai
nedproblemi sd iscuss
ed
fi
rst
.A s 回i l
arp rogr
essioniso bservedwith問 gardt othenumberofv ariabl
es.A
Theproblemi
s問 st
ric
tedtotwovari
ablestodrawg r
aphi
calsupp
ortforsomeof白E
single-
variableproblemi si nt
roduced,followedbytwov ariable
swhichi s由en
di
scu
ssion
s.Ther
earetwoconst
rai
nts,which,dur
ingthedev
elopmen
tofthischa
pter,
extendedt oag enernlproblemi nvolvin
g"v a
rinb
les.Thiso rd
e ra l
lowsi ncrement
al
mayswitchbe
twccnequa
lityandine
qualit
yc o
nstr
ain
tstoi¥
lus
tra
te問 l
ate
df e
atu
res
.
introduct
ionofnewc on
cep s,
t b
utp ri
marilyallowsthecreati
veu seofe xistingrule
s
toestablis
hs olu
t i
onstothee xtendedprob
lerns
.
Ana naly
ticalfoundationisess
entia
ltou nd
erstandande s
tablishtheconditions山at Problem: Findt
hcr
ect
ang
leo
fth
cla
rge
sta
r回 (
in血巴 p
osi
tiv
equ
adr
ant
)白a
tca
nbe
theo ptimalsolutionwillhavet os at
isf
y.百 lisisnotf o
rt hes akeo fm a
t hem
a ti
cal 町a
nsc
rib
edw地 i
nag
ive
nel
lip
seands
ati
sfyap
res
cri
bedl
ine
arc
ons
tra
int
.
cur
iosity,b utis叩 e ss
entinlcomponentoft hen umeri
calt echnique:n otablyt h
e From出cp rob
lemspec
ifi
cat
ion,t
heell
ips
ewillpro
videaninc
qua
lit
yc o
nst
rai
nt
stoppingc rit
eri
n. Th en ecessarym nthe
mnticald efin
itions and i ll
ustra
tionsa r
e w
hile山el i
nea
rrela
tio
namongt h
cvari
abl
cswil
lp r
ovide加 cq
ual
itycon
str
ain
tfor
introducedinthischapt
er.R efer
encesar巴nvailnb
leforrefresh
ingt hecalculusandt h
e t
bi
sc x
amp
le.
154
156 NONL
lNEARPROGRAMMING 臨玄オ
4
.
1 PROBLEMDEFINITION 157

3 M
ini
rni
ze f
{, 医l
X
) n (
4.5
)

S
ubj
ectt
o: [
h(X
)]=0 , (
4.
6)
2
.5
[
g(X
)]m$
;0 (
4.7
)
x
z
X1
0w$
;X$
;Xup (
4.8
)

F
ort hesp
ecif
icproblemb e
ingd i
scusse,andrefeningt
d oFig
ure41,t
. h
ede
sig
n
v
aria
blesareth d
ecool
' i
natevaluesxl 叩 dX2 山a
la llowth
cc om
putat
ionofth
e
r
ec如忠lIa
t rare.Th
a eoptirn
izat
ionproblemis

Min
irn
ize j{XI , X~: -
XIX2 (
4.9
)

S
ubj
ect
to: h
l( ,.
x xz
:2
} 0
xI+1
5X2- 30 0 = (
4.1
0)
//
Jff

,. (
/f
0
.5
// x
T/4)+(~)一 1$;0
81(X X2): (
4.1
1)
//
O
$;x
l$;
3; O$;x2$;3 (
4.1
2)


。 0
.5 1
.5
Thes
idec
ons
tra
int
sin(
4.1
2)c
ana
lsob
epo
stu
lat
eda
son
e-s
ide
dandc
anbew
rit
ten
2 2
.5 3
as
X
1

F
lgu
re4
.1 C
ons
lra
inl
sofExa
mpl
e4.
1. X1~O; x2~0 4.
( 13
)

MathematlcalModel: Figur
e4 .1capt
urcsth
ees総 帥o ft h
ep帥 l c
m.Codefil
cs
Ex4L1.mlandcreate_elllpse.ma refi
lcsn田cssa
ryf rMA
o T
I.ABtocre
atethe 4
.1.
2 DlscussionofConstraints
f
igur
e.τ'
herea
retwovar
iable
sXI andX2・前le
reares
tand
ardmathem
a ti
calex
press
ions
fr山ee
o l
lip
se,andt
hestra
ightli
neisnoproblcmaft
erChap
ter3. Using t
here
lat
ion
s( 4
.9)ー(
4.1
2)s e
ver
ala dd
itio
nalc
1ass
cso fproble
msc a
nbe
descr
ibe
dbyinc
ludi
ngonlyasubs
etofth e
cr1at
ion
s.The
yareexaminedbel
ow.
StandardFormat:The s
tan
dar
dfo
rma
t oft
he NLP i
sre
pro
duc
edh
eref
or
convemence: UnconstralnedProblem:Thcrea
renof u
nctio
nalc
onst
rai
ntsalth
oug
hth
esi
de
co
nst
rain
tsarcne
cess
arytokeept
hes
olu
tio
nfini
te
.Forthi ,
scxample
Mi
nir
niz
e f
(xtX2'• • • ,
t Xn) (
4.1
)
M
ini
rni
ze j
{ ,
XI ~): -
x1~ (
4.9
)
S
ubj
ectω h
k(x h・
・・
., ,.
)=0,
x,
, ,
k=12 ド . ,
L (
4.2
)
I
nthisproblem,i
f出巴 desig
nv a
ria
blcsa
reunboundedat山cuppe
rl im
itt
, he
n血e
X2・
め(XI, ・
..,
Xn ;0
)$ ,j=,
12,
.•.
,m 4.
( 3
) s
olu
tionwouldbeatthelar
gestp
osi
tivev
alu
巴ofXIandX2・Atwo
-side
dl i
mitfort
he
d
csig
nv a
riab
lesisus
uall
yagoodi de
a.Thedes
ignerdoe
shavet
he回目ponsib
ili
tyof
x
l$; Xj $
;xl
' ,
;=12,
...,
n 4.
( 4
)
d
efi
ninganaccept
abl
ed e
signspa
ce.

I
nve
cto
rno
tat
ion Equal
ityConstralnedProblem1: Thefunc
tio
nalco
nstr
ain
tsi
nth
ispro
ble
m紅巳
o
nlyequa
lit
ies
.Withrefer
ence1
0Example4.
1出cf o
llow
ingprob
lemca
nbesclup
I
FI
i田 1
0bed
own
loa
dedf
romI
hew
ebs
i
lc町 ci
nd
ic
ll
le
dbyb
old
fnc
e悶 悶 悶r
if
ly
pe
. (
aft
erchang
ing曲cinequ
alit
ytoancq
ual
ity
):
158 NONL
1NEAAPAOGAAMMING 4
.2 M
ATH
EMA
TIC
ALC
ONC
EPT
S 159

Minimize f
t
..,
x X
2):-
x.x
2 som
eco
nstra
intsa
reac
tive(e
qua
lit
y)a
tth
eop
tim
als
olu
tio
naso
the
rwi
sei
twould
S
ubj
ectt
o: 1
1)
(x
..X
2) .+1
:20x 5X2-30 0 = beanunc
onstr
aineds
olu
tio
n.

h2
(x.・
X
2):(~/4) +(4)ー 1=0
4
.2 MATHEMATICALCONCEPTS
O~XI :
:
;;
3; 0~x2::;;3
LikeLP ,somemathematicald efi
nit
ionsa r
en 田 凶saryb e
foret hen 町 民sarya nd
I
ntui
tive
ly,suchaproblemmayn otb巴 optimi
zeds in
cet hetwoc ons
trai
ntsby s
uffic
ien
tc ondi
tionsforth
eNLPc anbeestabl
ished
.D e
finit
ionsaren e
e dedforboth
th
emselvesshou
lde st
ablis
ht h
ev al
uesfortheIwod es
ignvaria
ble.Th
s eargumenl
s 白ea nal
ytica
ld iscuss
iona sw e
lla sn umeri
calt ech
nique
s. MATLAB p rovidesa
us
edinLPf oraccepla
b l
ep robl
emd e
fini
lio
na r
ea l
sovali
dh 巴悶.Thereisalwaysth
e SymbolicMathToolbox whichp ermit
ss ymbolicc omp
utationi nte
graledin出c
p
ossi
bili
tyofmultip
les oluti
ons-whichisastron
gf e
alur
eo fnon
lin巴a
rp r
oblems.I
n num
ericale nviro
nm e
nto fMATLAB.Thi sa llo
wsI heuser10e xplo陀 pro b
lemsi n
s
ucha neven
tt h
eseto fvar
iabl
esthatyie
ld出elow 巴slvalu
ef o
rtheobje
ctivewil
lbe ca
lculs,l
u i
nearalgeb
ra,solu
tion
so fsystemo fequati
ons,ando the
ra re
as.Inf ac
t,
t
heoptimalso
luti
on.NOle白紙 s uchas o
luti
onisobtain
edbys cann
ingtheaccep
tabl
e usi
ngs ym
bolicc om
p ut
ationstud
entscaneasil
yr eco
ver山ep r邸 宅qu
isit
ei nfor
mation
s
olut
ionsrat
her白 anthroughappl
icati
onofanyr i
gorouscon
ditio
ns. f
orthecourse.As hor
th an
ds-onexerc
isetos ymb
oliccomputationisprovide
d.τ1'he
prim
arydefinit
ion
swen eedareder
ivat
ives,pa
rti
alderiv
ativs,
e ma
trics,
e d
erivat
ives
E
qua
llyConstralnedProblem2
t :If
thep
rob
lemwe
偲 0i
1 nc
Iudeo
nlyoneo
flh
e ofmatr
ices,andsolut
ionsofnonli
nearequat
ions.
c
ons
tra
ins,
t f
orexample,
4
.2.
1 SymbollcComputatlonUslngMATLA目
Minimize f
t
.l・
x X
2):-
XIX
2
Oneoft
hebes
lwaystog lfami
e 1i
arwithsym
bolicco
mputati
oni
stotak
ethequi
ck
S
ubj
ecl
lo: h
2(x
"X2
):(~/4) +(~)ー )=0 on
lin
eint
rod
ucti
on10theSymb
olicMathToolboxav
ailab
leint
heMATLABDemos
0
:
:;
;XI:
;3; 0
:
:;
;X2
::
;;3 di
alo
gbox[4
].Thefol
lowings
equ
enceloc
ate
st h
elu
tor
ial
:

>> demos
T
hisisava
lidopt
imi
zat
ionp
rob
lem
.As
imi
larp
rob
lemc
anb
ede
fin
edw
ilht
hef
ir
st Symbolic Math - ・ > Introduction
c
ons
trai
ntbyit
se
lf
.
Thec o
mputalionale ng
inee xecu
l ing由巳 s ymbolicop e
rationsi nMAT 1.ABist h
c
kemelo fMaplem arkeledan dsuppo 巾 db yW aterlooMaple ,In
c.l f出E民 a de
ris
Ine
qualltyConstrainedProblem: I
nthi
scaset
heco
nst
rain
tsa
rcal
lin
equ
ali
tie
s.
alr
eadyf am
iliarw ithMaple ,出enMA T
1.ABp r
ovidesahookt hroughwhichMaple
Avaria
tio
nonE xarn
ple4.1wouldbe(theeq
ual
ityco
ns町ain
tistra
nsfo
rmedtoan
e
qual
ityco
nstr
ain
t) commandsc anb ee x田 ut
edi nMATLAB.Th es y
m b
olicc omput ati
oni nMATLABi s
performedusingas ymbolicobjec
to rs ym.Thisisa n
otherd atatypeiIkethenumber
andstri
ngd at
at y
p esusedin阻 rli
erexercise
s.Th eS ym
bol icMathToolboxu sessym
Minimize f
tx.x
. 2
l
:-XIXz obj
ectsto陀 prese
n tsymbolicvari
ables,e x
pressio
ns,andm atric
e s
.
S
ubj
cctt
o: g.(x"X
2) I+1
:20X 5X2-3
0:
:;
;0 Int h
ee xer
ciset ha
tf o
llows,afunctiono fonev a
riabe,
l andtwof unct
ionso fIwo
var
iables(cons
traintsfromExample4. 1)a 巴 u
t
1 sedf ri
o IIustr
alion
.Drawingont h
e
g
2(X
"XZ
):(
xt/
4)+(4)ー 1
::
;;
0 au出or'sc1assroomex 戸 巾n ce血i spreliminarydiscuss
ioni sint ermsofv a
r ia
blesX
O
::
;;
XI:
:
;;
3; 0
::;
;x2
::;
;3 andyf o
ri mprovedc om
prehension.Inl a
tersect
ions,su
bscriptsonxa reusedt odefi
ne
mul
tiplevariab
less otha
t出et r
ans
itiontot h
eg en
eralproblemc a nbef a
cil
ita
t e
du si
ng
L
ikei
t
sco
unt
e中町ti
nli
nea
rprogramming,出 i
sisav
ali
dop
lim
iza
tio
npr
obl
em. vect
ordescrip
tion.Thef unct
i o
nsint hcscexeaisesare
E
qua
llyv
ali
dwouldb
eaproblemt
hati
ncIudedj
ustoneo
flh
eco
nst
rai
ntso
ran
y
numberofin 叫ual
itycons
tra
ints
. ftx)=12+(x-I)2(x-2)(x-3)
Itise s
senl
ialtou nd
erstandboththenatureandt henumbero fconstr
aint sas g
.(,
xy 5y-30
:20x+1
)
wel
la showt he
ya f
fecttheproblem.Ing e
neral,equ
alityco
nstrai
ntsa r
ee as y10
handle
m athe
matICally,d
iffic
ultt
osati
sfynumerically.an
dmoreres
tr i
ctiv eonthe g
2(X
,y
):x
24+
/ l-1
sea
rch f ort hes olut
ion. Ineq
ualit
y c onst
rain
ts a rediffi
cultt o r esolve
math
ema t
icallyanda remoref le
xib
lew ithrespe
ctt othesear
chf ortheo ptimal I
TOOr
cl
ca
sco
f10n
0 e
wSwdentEdillolli
nc
lu
dc
sIh
csy
mbo
licl
ool
bO¥u
l l
ongw
il
hIh
eba
si
cMA
TLA
D
so
lutionastheydefi
neal ar
gerfea
sibl
er e
gion.Aw ell-p
osedproblemrequir~s th
at sortw町 t
1
60 NONL
lNEARPROGRAMMING 4
.2 MATHEMATICAlCONCEPTS 1
61


、,
'E=
da
fS5
sadiar
yf

g
百lefoll
owingMATLABs
ess
ionwascapωr
eda i
lea
ndedit
edinate
xt

Y
・ nl
S

噌・-
E.
ed
ito
r.The児 f
o陀 山eMATLAB prom
ptd o
esnotap
pe紅.百lebold
fac
ew o
r d
sare
commands出at山er e
ade
rwi
lltyp
eatth
ecommandl
ine
.
x sym('x') 者 definingx as a single symbolic object l
jl
" [gl;g2) 者 9 column vector based on gl,
"
J
'
g2
",
9'
x
9
x [20*x+15*y-30]
syms y f g1 g2 g 者 definitionof multiple objects 1/4*x+y-1]
whos % types of variables in the workspace
Name Size Bytes Class も 9 can be the constraint vector in optimization
f 1X1 126 sym object 者 problems
g 1x1 126 sym object も thepartial derivatives of 9 with respect to design
gl 1X1 128 sym object 苦 variables is called the Jacobian matrix
92 1x1 128 sym obje'ct も theproperties of this matrix are important for
x 1X1 126 sym object 者 numerical techniques
y 1X1 126 s戸nobject
xy . [x y]; も rowvector of variables
Grand total is 14 elements using 760 bytes
J'" jacobian(g,xy) も calculating the Jacobian
f
.. 12 + (x・1)*(x-1)*(x・2)*(x・3
) 者 constructing f
f J
12+(x-1)"2*(x・2)*(x-3) 20, 1
5]
[1/4, 1]
diff(ま} も first derivative
aos ezp10t(f) 者 a plot of f for -2 pi x 2 pi (default)
2*(x-1)*(x-2)*(x-3)+(x-1)^2*(x-3)+(x-1)"2*(x-2) ezp10t(f,[
0,4)) 者 plot between 0 <= x <= 4
も note the chain rule for derivatives df diff(f);

% note the independent variable is assumed to be x
3 h01d 00
, x,2
diff(ま ) 者 the second derivative wrt x 5 ezp10t(df,[0,41) 告 plotting function and derivative
ans 書 者 combine with MATLAB graphics - draw a line
2*(x-2)*(x・3)+4*(x-1)*(x-3)+4*(x-1)*(x・2)+2*(x-1)"'2 室
1ioe([0 4],[00 ),'C010r',,r')
fn4
1a2
d

g
fg*
(x

}
aL=


X2

a

者.ZO:~,
the third derivative wrt x
'nHE


選 9
定 [20*x+15*y・30]

3 1/4*x+y-1]
2x

y
0+

ATY
gg

X5

-wnuw


*句

nu
qd

2
Ed
唱・--
Enu
噌t-14

告 define 9工
=*

も to evaluate 9 at x 1,Y 2.5


*

subs(g,{x,y},{1,2.5})
3

内,
a

ans
g2 '
" 0.2S*x + Y ・1
; も define g2 27.5000
者 gl,g2 can only have partial derivatives 1.7500
-
・id an 2

も independent variables have to be identified


'8t=

A
ddit
iona
lsymbo i
1cco
mput
ati
onswi
llbeintr
oduc
edthrou
ghc od
ea sapp
rop
ria
te.
g

}
x
t-
aιEMnu

も partial derivative No
tet h
at白er e
sul
tofbothnum
ericandsymbo
licc o
mput
a t
ionsc a
nb eeas
ily
c
ombineda10ngwit
hgr
aph
icst
oprov
ideapo
werfu
lc o
mputingenvi
ronmen.
t
162 N
ONL
lNE
AAP
AOG
AAM
MIN
G 4
.2 M
ATH
EMA
TIC
ALC
ONC
EPT
S 163

4
.22 B
. asicMathematicalConcepts T
abl
e4.
1 C
alc
ula
tio
norDer
iva
Uve

Thebasicmathe
m a
ticale1emen
tsint hedis
cus
sionofNLPa r
ederiv
ati
ves,par
ti叫 x dx x+dx d
fld
x D
eri
vat
ive
M
de
riva
tive
s,vect
o r
s,matr
ices,Jac
obian,andHes
sian
.Weh a
vcusedtheS y
m b
olic
MathT o
olboxint h
ep r
eviousscc
tio
nt ocal
cul
atesomeofthe
sequa
nti
tie
sw ithou
t 3 4 1
8 1
8 4
dcf
inin
gt he
m.Th esetop
icsw i
llhaveb ee
ne x
tens
ive
lycover
edinthefoundatio
n 3 0
.1 3.
1 0.48
51 4.8
51 4
cou
rsesonmathematic
sinm ostdis
cip
line
s.Ab r
iefrev
iewi
soffe
redin血iss e
ctio
n 3 0
.01 3
.01 0.04
08 4.0
805 4
usi
ngM A
TLAB.百l i
so p
port
u n
itywil
lal s
obeutil
ize
dtoinc
rea
sefam
ili
ari
tyw i出 th
e 3 0
.00
1 3
.001 O.4 ∞ 4.0
08 4
Symbo
licMathT ool
boxa ndinco
rpor
a t
巴itwith出eMATLABcommandst hatwere
use
din山巴 earl
iercha
pter
冨.

Functlono'OneV
ari
abl
e:f
t
.)i
x d
ent
ifi
esaf
unc
tio
nofo
nev
ari
abl
e:
o
fth
echa
ngeint
hefunc
tionv
alu
e,4
f
, 10出echa
n g
ein恥 di
spl
ace
men
l,a
x.F
or出E
f
(x =2+(x-li(x-2
) 1 )(x-3) e
xam
pJe,
thed
eri
val
iveatx=3withax=0.
001isobt
ain
eda
s

i
susedasas
pec
ifi
cexam
pleo
fsu
chaf
unc
tio
n.Thed
eri
val
iveo
f出ef
unc
tio
nat山e
l
oca
tionxi
swri
tte
nas lI_
E f
.
:(3+0
.00
1)ー1
(32
-.11nnSl (
4.1
5)
d
x
l.rc3 0
.00
1 ー

玉江 - 1・ kx+ax)- .f(
x) γ 笠 (4.1
4)
dx-ilm Ax =ll
fI1-L
ax→o ax ax-
>oax Theder
ivati
vcfo
rlhesin
gJe
-va
ria
blefu
nctio
nalanyval
ucxisaJ
socaJ
ledlh
eslop
e
xisthep o
inta b
outw h
i ch由巴 d e
riva
tiveiscompuωd.ムri st h
cd i
stamニetua orth
egrad
ietto
l flh
cf u
nct
ion創 出alpo
in.
tIfalin
eisdraw
ntang
enl10th
efunc
tio
n
n
eighbor
ingpoin
twhos巴l o
cat
i o
nthere
forew
illbex+a .Th
x eva
lueofth
ederivat
ive a
lthevaluex,th
etang
entof白E叩 gleth
at出isJin
emakeswi出 t
hex-
axi
sw i
llhav
e
i
sobtain
edasal i
mitofthcra
tioof白ed iff
ere
n田 intheval
ueofthefun
ctionat曲e th
es創nev al
ucasth
ederi
vat
ive
.If血isang
leis9,出en
twopoin
ts(幼 ω 出ed i
s岡田 s epa
rati
ngthet wopo
ints(位),ぉ thi
ssep叩 t i
onis
re
d u
cedωzero.Thecomputa
ti o
nofthcderi
vati
vefo
rthespec
ifi
cex創npleisusua
lly
o
btai氾du
n s
ingthepro
ductrul
e.R e
sult
sf romth
ee x
e民 i
seons y
mbol
icco m
p u
t a
tion ま=tan9
p
rovideth
cresu
Jt
F
igu
re4
.2i
ll
us
tr
at
es出et
ang
enc
ypr
ope
rtyo
fth
ede
riv
ati
ve.
ま = 均 一 例 一 例 ー 3)+(x-1
)ゆ い ) + ト )^川ー 2
1 )
MATLABCode:F
igu
re4
.2w
asc
rea
ledb
yth
eco
det
ang
ent
.m.I
nth
esa
med
ire
cto
ry,
Ta
ble4.1illu
str
ate
s出el i
miti
ngproc
essf o
rthcd eri
vat
iveofthefunc
tio
nc ho
senas 出ec
oded
erl
vat
ive
.mp
rov
ide
sth
eil
lus
tra
tio
noft
ang
enc
yth
rou
ghaf
i伊 r
e
白ecxampJe.Thed er
iva
tiveisbein
ge val
uatedatp o
int3.Ast h
ed i
spJac
ement
sare an
ima
tioninMAT
LAB.In出ef ig
urewindowbot
hthef
unct
ion(dr
awna
sthecurv
e)as
re
duced,出巴 va
lueoftherat
ioa p
proac
hcs出巴 v alueof4w hi
chistheaCl
ualval
ueof we
lla
sthelin
erep
rese
ntig4
n f a
ndaxaredra
wn.Asth
eneigh
bori
ngpo
int
sarcclo
ser,
t
hederi
vati
ve.Wh enaxislarg
e(wit
hav alu
eo f1),出crati
ois1.T
8 hisissi
gni
fic
ant
ly i
tisev
ide似 合omt h
ef i
gur
ethatth
ec ur
vecanbeappr
oxima
tedbyastra
igh
tlin
e.
d
iffe
rentfromthevalu
eo f4.Withaxo f01t
. hevalueisaroun
d4.851
.W ithfu
r也er Whenax=0.001,出ederi
vati
veistan
gentt
othec
urv
eas出 eyar
eind
ist
ing
uis
habl
e.
re
duct
iontoO ∞
. 1t herati
oh a
sav al
ueo f4.00
8.F romt h
esecomp
utalio
nsitCanbc
ex
pected白紙 asaxa ppr
oaches0therat
iowillreachtheexac
tvalueof4.
0. H匂herDeri
vat
ive
s:Thederi
vat
iveo
fth
edc
riv
ati
vei
sth
eca
lle
d出esecond
d
eri
val
iv.F
e orm
all
yiti
sdc
fin
ed邸
NumericalD
eri
vat
iveCompu
削'i
o: Manyn
n umc
ric
alt
ech
niq
ucsi
nNLP(1叫 u
i陀
出ec
omp
uta
tio
nofd
eri
vat
ive
s.Mosts
oft
war
eim
ple
men
tin
gth
eset
ech
niq
uesd
ono
t
u
sesym
boliccompu
tati
on.Automat
ionand回 seofuse毘 q
ui r
e血at也e sede
riv
ativ
es 互
主-!
!..
(笠-li",坐笠生L
!;
rn炉 心 .
1
.
出 -4yalx
b
ecompute
dn um
eric
all.百l
y ere
sul
tsinT
able4.1ju
stif
y出en um
ericalco
mputat
ion t
Ji-d
l xl
dx)一
心-
-1
0 ax 似
:
ゐ ax (
4.
16)
o
fader
iva
tivethr
oughatec
hniq
uecall
edth
efirsl
forwadd砂
r 量r
, ence[5
].Usi
ngav e
ry
s
mal
lpe目urbat
ionax,lh
号deriv
ati
veatapoin
lisn u
merica
llyc a
lcul
ateda
st h
erat
io S
imi
lar
lyt
hel
hir
dde
riv
ali
vei
sde
fin
eda
s
164 NONL
lNEARPROGRAMMING 4
.2 MATHEMATICALCONCEPTS 165

t
ang
ent-s
lo
pe-d
er
lv
at
iv
eatx
=3 4.19
24 d
fl _I;~~(x +ax
,y)-f
(x,
y) ( )
d
xl1
(.
< ^
二ム
.)1)山山
/
:u

22
Thcaboverela
tio
ne xpre
ssesthepar
tia
lderiv
ativeofthefunc
tionfwithresp
ectto出E
l
o12
+(x
・t・
)(x
-l
)・(
x-1
2・
(x
-3)
va
riab
lex.G ra
phicallythi
ss ug
gcststha
tt h
ctwop o
intsaredisplace
dh or
izonta
lly
2
01-・" (as
sumingthex-a
x i
sisb or
izont
a1)
.Int h
eabovee xpr
ession(an
dp rio
ro ne
st o
o),the
su
bscr
ipta
fte
rtheverti
call
inees
tabl
isbe
stbepoi
nta加u twhich出eparti
alder
ivati
vewith
郎 pec
ttoxisbeingeva
luatc
d.(x,
y)即 応s e附 any
/allpo
ints
.As im
ilarexpr
essio
nc 四 be
1
8
wr
itte
nforthepa
r首alderiv
ativ
eo ff
with陀 sp
ecttoy.Forthi
sexamp
le :

ー[-~.司f
x-
d 一
-2'一d
y:"=2y

F
ort
hep
oin
tx 2, = =
y 1
:

df • d
f
1
2 f
(2,
I)=1
; 一 =1・ ー =2
dx-" d
y
U
nti
lt h
ispoi
ntwc have madeuseofsymbolsrep
rcs
ent
ingc
han
gesi
nva
lue
s
1
0 (
fun
cti
ons,
var
iab
les
)wi
thoutafor
rna
lde
fin
iti
on.In山i
sbook

a s():犯 p
res
ent
sfi
nit
els
ign
ifi
can
tch
ang
esi
nth
equ
ant
ity()
o 0
.5 1
.5 2 .5
2 3 3
.5 4
x d(,
)o():r
epr
ese
ntsd
iぽe
rcn
tia
l/i
nfi
nit
esi
malc
han
gesi
n()
F
lgu
re4
.2l
Iu
slr
all
on0
1th
ela
nge
n.
t Changesinfunc
tio
nsoccurduetoc
h a
ngesinthevar
iab
les
.Fromc
alcu
lus[1
]t hc
di仇 re
nti
alchan
geinjx
{,y
)(ゆ duetothed
iff
ere
nti
alchangei
n血 va
riab
lesx(dx)
andy(dy)ise
xpres
sedas

表=増) (
4.1
7)
d
jd,
-
:
J
df=d
"
J
L"

x_.
.d
x+
fdv
-
:
J
.d
y-J (
4.2
0)
T
hiscangoonpro
vid
ed出ef
unc
tio
nha
ssu
ffi
cie
nth
igh
er-
ord
erd
epe
nde
nceon出E
i
ndep
ende
ntva
ria
blex
. Forc onv
cnienc
eands i
mpli
city,thes ub
scr
iptr e
prese
ntin
g白ep ointwhcret he
expr
cssioni
se val
uate
disn otindic
ate
d.Thed e
fin
itio
no fthepar
tia
ld e
rivat
ivei
s
appar
entintheaboveexp
ressio
na shold
i gya
n tacons
tantvalu
eimplies出atの=0.
F
unc
tio
nofTwoV
Bri
Bbl
es:Thel
wo-
var
iab
lef
unc
tio
n
Anotherint
erpr
etat
ionforthep a
rti
alderiva
tivecanb eobserve
dfromt h
ca bov
e
def
init
io:c
n ltan
geo ft
l
tefun
ctionperunitcit
angeintl
t
ev a
ria
bles
.
j
{x川:
x
214+y2-1 (
4.1
8)
Gradient01th eFunction
:I nthefuncti
ono fas i
nglevariabe,t
l hederi
valivcwas
i
sc hosentoiI
lus
tra
tetherequir
edm at
h cm
at ic
alconcepts.Thefir
stimportantfcatur
e a
ssocia
tedwi 出 thes l
op古. I
ntwoo rmorev ariab
lesthes lopeisequi
valent10山e
oftwoo rmorevariab
lesis白紙 thederivat
ivesdefinedforasing
lev a
riab
l e(ordina
ry g
radien.
tTh egradie
ntisav ector,
anda tanypointrep児 se
ntsthedire
ctio
ni nw h
ich
der
ivat
ives)donotapply
.百】 eequi
valentco n
cepthereisthepa
rtialde
riva
tive.Parti
al t
hefuncti
onwillincre
asemo strapiか
d
, E xa
rniningtheconven
t i
onalobj
ectiv
eo fNLP,
der
ivati
vesaredcfmedforcachindependcntvar
iab
le.百l epar
tia
lderiva
tiveisd e
n o
ted m
inimizatio
no fo b
jecti
veβm ctions,thegradien
th asan atura
lp a
rttop la
yi nt h
e
byt esymbold
h .The sed c
riva
tiv
e sareo btai
nedint hesamewaya st heo rdina
ry dev
el opmen
to fmethodstosolvetheproblem
.Theg radien
tiscomposedo fthepar
tia
l
der
ivati
vee x
ceptthcoth
ervaria
blesareheldataconstantval
ue.Inthecx創 np
l e,when d
crivat
ivesorganiz
edasav cclo
r.Vectorsin白 i
sbooka recolumnvecto
rsunlessothc
r
compuling白ep ぽtia
ld e
rivat
iveofxt hcvalueofyisn otallowe
dt ochan
g e. n
oted.Theg ra
d i
enthasas tanda
rdm at
hematicalsymbo.lltisdcfi
nedas
166 NONL
lNEARPROGRAMMING 4
.2M
ATH
EMA
TIC
ALC
ONC
EPT
S 167


=

3
Dco
nlo
urf
or(
f =x
川 1 2
/4+I-l

(
4.2
1) 3
Vf
2

Atthisstageitisa pp
ropriatetoconsolid
ate白i si nform
ationu singg ra
phics.The
gr
aphicId巴s
a cript
iono f白ee x創npled efi
nedi nE quation( 4.
18)h astobet hre
e 0 一
一.
dim
ensionalaswen eedonea xi
sf rx
o ,ano出erfory,andt heth i
rdforj{x,
y)
.C hapte
r 3
2
.5 3
2i
th
n
ep
tr
r
o
o
b
d
l
u
cedt
巴mist
hr
e
ou
e
-
s
di
ec
m
o
e
n
n
t
s
i
o
o
u
na
rp
lp
lo
l
t
s
ot
.C
ti
n
o
n
gu
t o
s
i
u
n
rp
gMATLAB.Amoreu
l
otsaredrawnf ors
s
p
e
e
c
f
u
i
ld
fi
cv
es
c
a
r
l
i
u
e
pt
so
io
no
fth
e
f
。 2

fu
nctio
n.IntheiIIus
trat
ionthev a
luesforthecontoursoffare0,1 ,2,叩d3 .I nFigur
e x
43,twok
. indsofc ontou
rp lo
tsa r
es hown.Int h
et oph a
lfat h r
ee-dimens
ional( 3D
) 2
Dco
nlo
ur
con
tourplotisshown ,whileon白 l owerhal
f恥 samei nfo
rma tio
nisp res
en凶 ぉa 3
two-
dimensional(2D)c on
to u
rplot(th
isisconside陀 dth巴standardcontourplot
).Thc 2
.5・ g
ll
ld
le
nl0
1S
2Dc o
ntourplotismoreu se
fulforgraphicIs
a u
pporto fsomeo ftheideasinNLP.Th e
3Dc on
tourwillbed ispe
ns巴dw ithin山er emaindero fth
cb ook.

MATLABCode:Flg4_3.m. Thea nnota


t i
oninFigur
e4.3(inclu
dingtheta
ngentli
nc
andthegrad
ient町 ow)wasdone出 roughthep
lot吋 it
ingcommandsa v
aila
bleon山e ,

- longenl815
menub srinthefig
urewindow(MATLADv ers
ion5.2andlate
r)
.Am吋01 "pO"t
l i
onuf
白 cpl
otsa問 gene
ratedt
hrought
hestat
cmentsintem-f
h i
Iei n
dica
tedabove
.Thec odc
mixesn umer
icand s y
mboliccomp
utation.Itallowsm u
ltipl
ep lo
tsandt a
rge
ts 2 3
x
grap
hiccommandst ospec
ifi
cplo
ts.
F
lgu
r,4
由 .
3Gr
adi
enla
ndl
ang
en!I
I
n自a
!ap
oin
.t
Discu
ssiono(F igur
e4 .
3:I nFig
ure4.3poin
tPi soncontourf=O.PointQ i
son
th
econtourf=2.PoitSi
n sontecontourf=1
h .Poi
ntRh as出esameyv alucasp
oint From恥 f ig
uret
hevaleoffw
u i
I
lchangea
longgra
dientdi
rec
tio
n.Ifd
fre
pre
sen
tsa
P佃 d白 esamexvaJucaspoin
tQ.For出ev al
uesinthef
igu
ret h
econ
t o
urvaluei
s0.75 di
ffe
ren
tia
JmoveaJong恥 畑gentl
ine,
白en(dX,の ar
em e
asuredaong刷 g
J e
ntli
ne)
(
thi
svalueshou
l dbedis
playedi
nMATLABwindowwhcnt h ecod巴Flg4_3.misru
n).
(
4.2
3)
df=~dX+ 主の =0
l
in sameasure4
ePQi f 批eJ y

l
inePRr
epr
ese
ntsc
han
gesi
ndfwhcnd
.yi
s0 E
qua
tio
n(4
.23
)sh
oul
dbcz
erob
eca
usemovingt
ang
cnt
ial
ly(
asm
alla
mou
nt)t
he
v
a 巴o
Ju f
fisn
otc
han
ged
.
lineRQ問 p
res
ent
sch
ang
e ndfwhend
si .xi
s0
Th
~acobian: eJac
obin[
a J]def
ine
sause
fulwayt oorga
niz
eth
eg r
adi
ent
sofse
vcra
J
Mathe
maticallム
y,fcanonlybeestimatedbyaddingthechangcsalongthelinesPR
f
unc
tio
ns.Usin
gthrecv
ari
abl
esandtwofunc!
ion
sj x,
{ y,
z)a
ndg(x,
y,
z)th
ede
fin
iti
on
andRQsince出cd efi
niti
onoft h
epar
tia
lderiva
tiv
esonlypcrm
itscal
cula
tingchangc
s
o
fthcJac
obi
anis
alon
gt h
ec o
ordinatedir
ecti
ons.
tSt
(p
Atp
c
rpcn
o
d
i
i
n
cula
r
h
)t
edott
o山ct
edl
.
I
i
n
n
ei
ge
st
n
h
et
t岨 di
ang
sd
e
i
n
r
.Theg
t
田 t
edt
ra
o
w
d
a
i
e
r
nta
di
tt
n
cr
h
e
csamcp
as
ingth
oin
eva
ti
Ju
sn
eo
orma
l
f白e
I
e
Jf互主│
fun
ction(ind
icatedby白ea rr
ow).Byd ef
init
ion,
ifdfre
presen
tsadiff
erent
iaJmove J=
[
J 1~x ~ ~~ 1 (
4.2
4)
Jongt
a h
eg r
adientatanyp o
int,出en(dx,めP副官 measu
reda lo
ngthegra
dientvect
or) I~星笠笠|

df= 空
白+さ dy (
4.2
2)
168 NONL
lNEARPROGRAMMING 4
. AlCONCEPTS
2 MATHEMATIC 1
69

nEq
I uat
ion(
4.2
4)t
heg
rad
ien
tso
fth
efu
nct
iona
pp町 i
n出esamer
ow.Thef
ir
strow Eq
uat
ios(
n 4
.27
)and(
4.2
8)w
illapp
回 rq
uit
eof
teni
nsu
cce
edi
ngc
hap
ter
s.A f
ew
s出 eg
i rad
ientoffwhilethesecondrowisthegr
adi
entofg.lfth
etwof u
nct
ionsar
e m
inu
teso
ffa
mil
iar
iza
tio
nwi
llp
rov
ides
ust
ain
edcompreh
巴ns
ionl
at
er
.
c
oUectedint
oacolumnv ect
or.thedif
fer
ent
ialch
anges[dfdg]
Tin山ef u
ncti
ons,du
e
t
o出ed iffe
rent
ialchangeinthcv a
riab
les[dxdyd],
z c
anb eexpre
sse
da sam a
tri
x 4
.2.
3 Taylor'sTheorern/Serles
mu
ltip
ucationusin
gtheJacobian

川州制
SlngleV a
r lab
le:Th eT
aylors
eri
esi
saus
efu
lmechanismt
oappr
oxima
te出eva
lue

rill--L
、・
4・
p+

rBEE-EEEL
oft hef u
nctionf
t
..
x)at山 poin
t(x お)if白efun
cti
oniscom
ple
telyknowna
tpo
int

lEE E

]4
[官
=
・-J
(
4.2
5)


xp • 百le exp叩 sio
nis(f
orfi
ni
tcn)

I
d
whichi
ssi
mil
a oE
rt qu
ati
on(
4.2
0). 的+釘)叫,)+ ま
I~
(お)サ 手I~ (制2+ ト
古家│
う州
He
ssian:TheHessi
anmatrx[
i H]i
sthesamea
sth
ema
tri
xofs
eco
ndd
eri
vat
ive
sof Theser
iesiswidelyusedinmostdis
cip
lin
estoest
abl
ishcon
tin
uousmodel.I
s tis出E
afu
nct
ionofs
eve
ralvar
iab
le.Forf
s t
.
.x,
y) mai
nstayofmanyn um
ericaltech
niqus,i
e nc
Iud
ingt h
oseinop
tim
izatio
n.E q
uati
on
(4
.29)isusua
llytrun
catedωthefirs
ttwoo r山 町 term
swi白 血eu n
dersta
nding批
Idγaγ│ app
roximatio
nw i
llsuff
ersomee r
rorwhoseord
erd e
pendson恥 t erm伽 tisbein
g
tr
unca
ted:
Iぜぬ│
=
1 (
4.2
6)
[

JL
i[ i
J[I
L
I
dy
dxザ│ [(Xp+A
t +玉江 {AY¥.
1
.1
.I
)三f(XJ&│Jh)+21dlJ
釘 )
f
l
2+O(位 )
3l (
4.3
0)

Th
eHe
ssi叩 m
atr
ixi
ssymm
凶 i
c
.Fo
r出巴 exampled
efi
nedbyEqu瓜i
on(
4.1
8). l
fthefi
rs
tte
rmi
sbr
oug
htt
o山el
ef
t,出 ee
qua
tio
n.d
isc
ard
ingt
hee
rro
rte
rm,c
anb
e
w
rit
tenas

n

v 司&
fAU
h

M f

(
何=イ吠う
xp+釘)一
削 f

(
令x


:ろ


X
/,

))

)=

=
d
x 判
L(仰刷釘削)+上
目1d
2


X
-1

(
4.31
)

-Ab-xh
FunctlonofnV
arl
abl
es: Forf
t
.
.X.where匹]=
) [XI・
X....• x
2 ,
.
rr
.白eg
rad
ien
tis
I
nEquation(
4.3
1),
thef
ir
stt
ermon白er
igh
tisc
all
edt
hef
irs
t-o
rde
r/l
ine
arv
ari
ati
on
whilethesecondt er s出es
mi econd-
o rder
/quadraticvari
atio
n.
(
4.2
7) F
igure4.4demonstratestheapproximationsusingTaylo
r'sser
iesofv ar
iousord
ers
a
tp oit2.
n 5withr es
pectto白巴 orig
inalf u
nction(re
d).Theprinc
ipalideaistodea
lwi出
theapproxima
tin gcurvewhichh asknownp rope凶e sinst
eadoft h
eo rig
inalcur
ve.
Th
eHe
ssi
ani
s 百lCc onst
antT aylors e
riesisw oefullyi n
a d
equat
e .百l eline
are xpansionisonly
margin
allybet
ter.Theq uadr
a t
icexpansionap pro
ximatestherig
htsideo ft
hefunct
ion
笠 d'
i ••• 立

d comp
de
fini
釘吋 t
t
elya
ot
c
ce
h
p
el
ta
e
b
f
ts
lei
id
nt
ewhichi
her an
si
ges
ns
ho
i
w
g
n
n
ific
a
.Tos
nte
e
π o
r.百 l
ehowt
ef
h
i
eT
f
t
a
h
y
・o
lo
rd
e
rs
re
er
x
i
e
pa
si
ns
i
su
oni
se
s
d,
d
x1 x
à~
i
J 2 x
i
J1a
xn
cons
i d
ertheq u
ad r
aticc urveabout出cp ointx=2 .
5.Att hi
sp o
i n
t出巴 v alueofthe
~ a '
i func
tionf
t
..
2.5 =
) 1 1.4375,thevalu
eo fth巴fi
rstderi
vativf
e'(2.
5=
)- 0.75,皿d thc
valuc
(
4.2
8)
問 =
1dX
2ax1 à~ oftheseconddcrivativ
eisf" (2
.5=
) 4 .UsingE quation(4.3
1)

(
4.3
2)
f
t
.
.2.
5+制 =1間 5+(
-0万)釘+主榊
~ γ
a
x
i
Jnd
x , .
c
d
F
ord
iff
ere
ntv
alu
e fA
so t
.bo山 p
osi
tiv
candn
cga
tie,
v t
hev
alu
eof
j(x
)ca
nbeo
bta
ine
d.
百l
epl
o fE
to q
uat
io 4.
n( 32
)sh
oul
dbet
hesamea
s恥 o
nel
abe
ledq
uad
rat
ici
nFi
gue4.
r 4
.
1
70 NONL
lNEARPROGRAMMING 4
.3 GRAPHICALSOLUTIONS 1
71

A
pp
ro
xl
ma
t!
onu
s
!r
tgT
ay
lo
rse
rl
es

f(xp+dxゐ+勾)=f(xp'ゐ)+町川引+ 、〆 I~YI

22

iMy蜘P,yp)][~] (
4.3
4)


I

-0
2
0 キ

a
1
t
1

Fornv
副ab
le,
swi
thろt
hec
urr
entp
oin
tadd
n .
Xth
edi
spl
ace
men
tve
cto
r,

4.35
告18 ぽp+
f I
l p)+
X)=f(X 町 鳥 川 +jmTm ( )

i f
i
fh-
t or
de
ra~d o
r
lg
!n
a
l

4
.3 GRAPHICALSOLUTIONS
E 百l
egr
aph
ica
1so
lut
ion
sar
epr
ese
nte
dfo
rth
reek
ind
sofp
rob
lem
s:u
nco
ns位a
ine
de
, q
ual
ity
c
ons
tra
ine
d,a
ndi
neq
ual
ityc
ons
凶in
ed,
bas
edo
nth
efu
nct
ion
sinE
xam
ple4
.1
.

4
.3.
1 UnconstralnedProblem
12
M
ini
mie J
z tXI,
x2
):-XIX2 (
4.3
6)

D 0
.5 1
.5 2 2
.5 3 3
.5 4
x o~xl ~ 3
; 0~x2 ~ 3 4.
( 37
)
F
igu
re4
.4T
ayl
ors
er
ie
sap
pro
xim
ali
on. Thes id巴 cons
train
t ss 巴rvetol imitt h
ed esigns pa
ce.C onsideringtheo b
ject
ive
functionin( 4.
36),itisc lea
rt hattheminimumv al
ueo ffwi 1
lb er巴aliz
edifthe
MATLABCode:Fig
ure4.
4isc
omple
tel
ycrea
tedu
sin
gthecod
eFlg4_4.
m.1
tus
esth
e variabl
esa reatt hemaximum( Xi=3 ,巧=3 ).Thev alueo fthef u
nctio
ni s-9.
MATLAB
-prov
idedsym
bolc“
i t
ayl
o"f
c un
cti
ontogene
rat
et hev
ari
ousex
pan
sio
ns Figure4 .
5i l
1ustr
atest hep r
o bl
e m.Thes olu
tionisatt heb ounda
r yoft h
ed es
ign
abou
tp o
int2
.5
. space.Fig4_5.mi stheMATLABc ode山a tw i
llp roduceFigure4.5.Themaximum
valueo fthefuncti
o nis0( basedont hesidecons
traint
s).InF igue4.
r 5thetange
nt
andt heg radienttot h eobjectivef uncti
ona tt hesolutionaredrawni nu s
ing
TwoorMoreV ari
ables:Theseri
es蹴 o n
lyexpandedto臨 qu拙 'a
t
icte
rms
.The MATLABp lote
ditc ommands.l D也i sp artic
ulare xample,thes i
dec on
strai
ntsare
t
runc
atio
nerr
ori
signo
red
.τ'hetw
o-var
iabl
efunc
tionexpa
nsioni
sshownind
eti
a1a
nd necessarytod e
termin ethesolutio
n.I fthedesigns p
acew ereincrease
dt h
esoluti
on
a
lsoorga
niz
edinter
msofvec
tor
sa n
dm a
tri
ces
.Thef i
rs
t-or
derex
pan
sioni
sexpr
ess
ed wou ldc o
r r
espondinglyc hange.
i
ntermsoft
hegra
dien.
tThesec
ond-o
rderexp
ansio
nw i
llbeexpr
ess
edinter
msoftb
e The巴x amplechose ntoillus
trat
e曲eu nconstr
ainedpro blemdefi
nedb y(4.
36)and
H
essianma甘ix (4.
3 )i
7 sn otusuallye m p
l o
y edtod eveloptheo ptim
alityc on
dition
sf orgener
al
unconstraine
dp roblems.Twor equirementsa r
ee xpectedtob es at
isti
edb ysuch
f
(x
' +
J 似 Y
/J+I
l) J
y tx
'
J =
)+1
'y,
(
Q冗
,まI
さ│釘+
1ろ}MP
I
+
.
I
"p
p

a
r

p
o

p
b

l
l
b巴 au
i
e

c
a
m

t
s
n
i
:(
i
o
q
n
1
u
)t
es
sth
h

e
es
o
s
l
u
ec
o
t
l
i
o
u
o
n
t

d
i

i
o
n,o
t
nm

i
ustb
r白ep
o
nsmayn
ei
r
nt
o
o
b
h
l
te
ei
e
x
i
nt
mi
s
e
riorofthed
s unimoda
.Mosts
t o f
tw
e
.
a
s
lN
r
ig
e
ea
ns
v
r
e
p
r
ed
a
t
e
c
h
v
ea
e
l
e
e
l
n
s
o
d(
s
pe
2
,i
)t
np
dt
h

oa
e
r
r
p
em
a
p
c
t
l
u
i
yt
s
c
a
h
t
l
e
r

笠│… 2
fI
石 (w-Y+手
1 e
) optimal
ityc on
ditionsa ndt h
e yrarel
yv erif
y出e ser equire
mentsa r
eb ein
gme .I
t tis
pY
/
2・ q
2
1ë)~I (x,川、ー〓 ・
ー 耳 I
t , 4.
( 33
) usua1
lyt hedesi
gner'sre s
pons
i b
ilitytoensuretheserequirem
entsareme .Tod
t eve
lop
也eo ptimali
tyc o
nditionsa naItemateu nco
nstrain
e dproblemispresen
ted:
If批 di
spl
ace
ment
sa r
eorg
ani
zedasacol
umnve
cto
r[似勾]
T,t
hee
xpa
nsi
oni
n
(4
.33
)ca
nbeexpr
esse
dinacon
dens
edma
nnera
s M
ini
mie J
z tXI,
x2
):(XI-1
)2+(X2- 1
)2-XIX2 (
4.3
8)
市72 NONL
lNEARPROGRAMMING 4
.3 GRAPHICALSOLUnONS 173

3
.5

2
.5

.

N 2

1
.5

0
.5


。 0
.5 1
.5 2 2
.5 3 3
.5 4
x x
' t

F
lgu
re4.
5 U
nco
nsl
rai
neds
ol
ut
io
n. 円g
ure4.6 U
nco
nst
rai
nedp
rob
lem
:in
te
ri
or回 1
l
Il
lo
n.

o$XI$ 3
; O$X2$ 3 (
4.3
7) OSX1$3; OSx
2S3 (
4.3
7)

Fi
gure4.6disp
laystheproblemandit
ssoluti
on.Flg4_.
・6.mprovi
desthecod
e.t
hatwiI
I
F
i思u"e 4
.7(
由ro
ug ー
hFIg47.m) i
1
Ius
tra
test
hep
rob
lem
.Thed
ash
edl
inei
s白e
ge
nerale most ofF igu
re4 .6.Iti sc e
Jar 山att hes olut
iona ppea
rst ob eot
∞ns住ain.
tSi
ncei
ti
sanequa
Jit
yco
nst
rai
nt,
thes
olu
tio
nmustb
eap
oin
tont
hed
ash
ed
li
ne
.Thec o
nt ouroff= ー1a ppear
st ojustgr回 巴 出ec o
nstra
inta n
dt here
foreisthe
i=2a
x ndxi=2.Theo ptim
alv al
ueo f山eo bjec
tivef u
ncti
onis- 2.Inthecont
our
minimump os
s ib
leva Jueofthefunc
tionwithoutviola
tingthecon
strai
n tI
. nFigure4
.7,
p
lot,出eo ptimumisapointmakingitdif
ficJt
u todrawt h
eg r
adient
.If白isi
sthecase

也eninthreedimcns
ions,attheoptimum,出cg ra
dientwil
¥Iieinaplanetan
gen
ttothe
血eg r
adien
to fth eobject
ivef u
nctionaswe I
las曲 eg radi
entof白 econstra
intsatthe
fu
nctio
ns ur
face
.Movingi n出 i
splaneshouldnotc hangethevalueoftheob
ject
ivc so
lutio
nar官ilIustra
ted.Itappears白a tat血isp o
intt hes
eg ra
dien
lsa repar
allelcvcn
fu
ncti
on.Th i
sobserva
tionisuscdtodevelopthen田 essa
ryconditi
onslat
er
. thoug
h出e ya red ire
c t
edo p
positetoc achoth
er.Byd e
fini
tionthegradien
ti sinthe
di
rect
ionofth cmostr apidincr
easeofthef u
nctionattheselec
tedpoi tT
n. hisi
sn o
ta
coi
nciden
c巴.T hisfactisusedtoestabl
ishthenecessarycondi
tionsfortheproblem
.
4
.3.
2 EqualltyConstrainedProblem

F
orat wo
-var
iabl
cp ro
ble
mwec
ano
nlyu
til
izeonec
ons
tra
intf
oram
ean
ing
ful 4
.3.
3 I
neq
ual
lt 悶I
yConst nedProblem
o
pti
miz
ationpr
oblem
:
Thenumberofin
巴qu
alit
ycons
tra
int
sisn
otdep
enden
tont
henumberofv
ari
abl
es.For
i
1I
us岡 山n ,bo白 co
ns佐直in
tfunc
tion
sofExample4.
1ar
芭 f
ormula
tedasine
qual
ity
Min z
Imie j
{XI,
x2
):ー'
XIX2 4.
( 36
)
con
s町amts
.
S
ubj
ectω hl
(XI,
x2
): / X
!
4+~ -1 (
4.3
9) Minimize j
{x,) X2):-XIX2 4.
( 36
)
174 NONL
lNEARPROGRAMMING 4
.4 ANAlYTICAlCONDITIONS 175

4 4

3
.5 3
.5

3 3

2
.5

対刷 2

.5
1 1
.5

0
.5 0
.5

0
.5 1
.5 2 2
.5 3 4
0
.5 1
.5 2 2
.5 3 3
.5 4
X xt
1

F
lgu
re4.7 E
qua
liy∞n
t str
aln
edp
rob
lem
. F
lgu
re4.8 I
neq
ual
ityc
ons
tra
lne
dpr
obl
em.

M
ini
rni
ze j
{X¥,
x2
):-
xlx2 (
4.
9)
S
ubj
ect
to: gl(XI,
x2
):20xI+15x2-30S0 (
4.4
0)
S
ubj
ect1
0: hl
(XI,
x2
):20X 5X2-30=
I+1 0 (
4.1
0)
g2(Xl
>X2
) x
I え
: /4+ー ISO (
4.41
)
g
l(I,
X x
沙: (
x
I/)+(~)一 IS0
4 (
4.1
1)
OSXIS3; OSX2S3 (
4.3
7)
Figure4
.8il
Iustra
testhegr
aphica
l s
olution
.Thesoluti
onisatth
einte
rsect
ionofth
e oSXIS3; 0SX2S3 (
4.1
2)
do
tt e
dl i
nes
.Thecodei savai
lableinFlg4_8.m.百 l
eg r
adie
ntsaredrawnusingth
e
p
loted
itf u
nctio
nsont h
emenubari nthewindow.A l
sof o
ntsty
leandfontsiz
eh a
ve Thegra
phi
calsolu
tionofS
ectin4.
o 3
.3sugg
estst
hatt
heineq
ual
itycon
str
aintwil
lbe
becnadju
stedusingtep
h lote
ditcommands.Theo p
timalsol
utio
nmustlieonorto山E ac
tiv
eatthesol
uti
on.If白紙 i
sthec
ase,
thenFigu
re4.8wi
llonceaga
inrepr
e s
ent出e
l
ef
to fthed ashedlin
e.S imi
larlyit must i
Iebelow oron t hedashedcurve
. gr
aph
icalsol
uti
ontothi
ssect
ion凶s
o.Thiswil
lbevcr
ifi
edinthcnc
xtsccl
Ion
.
Si
multaneousl
yi tshoulda1sodecrea
set heobje
ctiv
ef unc
tionvalu
ea smucha s
p
ossibl
e.
4
.4 ANAL
YTICALCONDITIONS

4
.3.
4 E
qua
lit
yandl
neq
ual
ltyConstralnts Analy
tic
alcon
dit
ionsrcf
erto恥 n回 e
ssar
yandsuf
fic
ien
tco
ndi
tion
s伽 twillperm
it
th
er eco
gni
tionoft h
es ol
utio
ntot h
eo pt
imaldesi
gnprob
lcm.Thcc ondi
tio
ns
Example4
.1i
sde
vel
ope
dwi
thb
otht
ype
sonc
ons
tra
int
spr
esetI
n.li
s問 p
rod
uce
dhe
re: deve
lopedhcre empower th
en u
meric
alt ec
hni
questofoll
owl a
te
r. They a
re
176 NONL
lNEARPROGRAMMING 4
.4 ANAlYTICALCONDIT10NS n
1

i
ntroduc
edi n由巳 sames eq
uenceasi n山ep re
vioussect
ion
.l nste
adoff onn
al
ma
thematic
ald eta
ils,thec on
ditio
nsa ree st
abli
shedl e
ssf onn
ally from th
e
ge
ometri
caldescr
iptio
no 。

f p roblemand
lor出r oughinωi
tivereaso
ning
.F o
nnal
1
0

dcve
lopmento fthcanaly
tic
alc o
nditio
nsc a
nb ef oundinR ef
ercnces6-8.For
e
stabl
ishi
ngt h
econditi
onsitisexpec
tedthatthesolu
tionisintheinte
rio
rof山e B
f
easi
bl巴regin,
o andther
eisonlyoneminimum.

、・
4
.4.
1 UnconstrainedProblem

H FHX
Thep
rob
lemu
sedf
ori
llu
str
ati
oni
s

組句
M
ini
miz
e J
(x
. X
2):(
X )2+(X2- 1
I- 1 )2-XIX2 (
4.3
8)
2
OSxIS3; OSX2S3 (
4.3
7)
F
i
t
h
g
r
u
e
r
e
c4
-di
m
.
e
6p
nsio
r
n
o
a
v
i
lp
de
l
o
dac
tofth
ontourp
esamep r
l
o
o
to
blem
ft
.I
h
ti
ep rob
sameshp
lem
l
.F
ot
igu
re4 .9p r
.Thecommandst
ovi
oc
d
e
re
sa
ate

F
igure4.9area vaila
bleinFlg4_9.m.Thef ig
ureneedst oberota
tedintemc
tivclyto
ap
pearasillu
s 回 ted
.At angentplanei
sdmwn鉱 山 巴 minimumf o
re m
phasis.Figure -2 4
4
4
.9wil1beu s巴dtoi de
ntifythep r
ope凶e so f
thefunctionJ(l,
x x
z)attheminimum.
Theminimumi si d
entitie
dbyas upe 凶cri
ptaste
risk(X・ orl i,
x X2J
T).Studying 。

F
igure4.9,thef unctio
nh asaminimumv alueof-2, whilex=
j 2andx =
22 .I f白e
X
2

v
aluesofX1an dlo
rX2we 民 tochangeevenbyas l
igh
tamountfrom自己 o ptim
alva l
ue, 1g
F u
re4
.9 Thr
ee-
dim
ens
ion
alp
lo
t01F
igu
re4
.6
.
i
na n
yd ir
ecti
o n,thevalueofthefuncti
onwi l
1certa
inlyincrea
sesinceX'isthelowest
p
ointo ft hec oncaves u
rfacer ep閃senting 出e f uncti
onf R eprc
senting 出E
d
isplacemcn
tf romtheoptimumv al
ueso fthevari
ablesasdX, andt h
cc hangci
nt he S
inc
eth
iss
hou
ldh
oldf
o l
ra1p
oin
tsi
n白ep
lae,
n dx11
-0a
: nddx
21-O
: .The
ref
ore,
f
unctio
nv alucf romt h
eoptimuma slf
, fromd i
rectob s
ervati
onitiscleartha
tt he
o
ptimalsolu
ti onmustb eap oint由atsat
isfie
s df-fl 主 -fl
dX - v, dX2- v
1
4
f>0, f
o 1dX
ral
o
rth
egr
adi
entof
fatt
heoptimumm
ustbez
ero
.百 a
tis,

Flr
st-OrderC
ondltl
ons: Thesameidcacanbcap
pli
edinthelim
it,t
ha s,f
ti or
i
nfin
ite
sim
ald i
spl
acem
ent dx1 a
nd dx
2 ab
out X The .

f
unc
tio
n i
ts
el
f ca
n be
Vf(x~,x;) =0 (
4.4
3)
app
roximate
dbyap l
anetang
enttothefunct
ionatthesolut
ion(showninFi酔re4.
9)
Eq
uat
ion(
4.4
3)e
xpr
ess
est
hen
ece
ssa
ryc
ond
iti
on,o
rfi
rst
・or
derc
ond
iti
on OC),
s(F
(c
onsid
cr血isぉ af i
rst
-or
d巴rTay
l o
rs er
iesexpa
nsion).Movingt oanypoin
tint h
e forunconstrai
nedoptimiz
ation.Iti
st ermedthefr
rs
t・or
derconditionbecau
seE quati
on
pl
anefromt h
eoptimum(seeFig
ure4 .
9)willnotch a
n g
et heval
ucoft h
efunc
tion, (4.4
3)u scs出eg radi
ento rthefir
stderiva
tiv
e.E qua
tion(4.43)isu s
edtoidentif
yt h
c
白E閃 f
or =
edf O.Movingawayf romoptimumi mpl
ies白紙 dx1a nddx 2ar
enotzer
o. possi
bles o
luti
onstotheo pt
imizationproblem
.If出巴 functi
onw eretofli
po verso出at
Re
writingEquat
ion(
4.2
0)intcnnsofX1andX2 thesamef u
nctio
nwc 陀 tomaximizet hevalueof出ef unction,thesolu
tionf o
rt h
e
vari
abl巴sw i
llbea tthesamev alueo fthedesignvar
iabl
c.Iti sclea
rt h
atEq uati
on

df= かか 1+ =0
(
d
t
4
e
.
t
oe
3
4
e
n
)appliesωthemaximump
r
s
m
u
i
r
net
e山a
heminimumv
tthesolu
t i
o
a
ne
l
ueo
s
tab
ft
li
h
s
r
ef
h
e
o
u
b
n
l
e
c
ti
ma
on
l
.A
dby出巴 f
s
o.E
d
i
r
d
i
s
t
t
-
q
i
o
u
o
r
a
t
n
d
e
i
a
o
lc
rc
n(
o
o
n
n
s
d
4.
i
i
d
t
4
e
i
3
r
o
)b
a
n
t
si
i
o
yi
n
so
t
sa
p
t
s
elfw
偲 n

ima
e
i
c
l
e
l,i
ln
ss
o
a
r
n出i
t
y
s

df= 医
者][
:
J=
O 4.
( 42
) ca
Eq
scaminimum.F
u
ation(4.43
)c a
orag
nbes t
a
e
t
n
e
e
ra
da
lu
s
nconst
rainedproblcm,th
en e c
essarycondi
t i
onsof
4.
4 A
NAL
YTI
CALC
OND
ITI
ONS 1
79
178 NONL
lNEARPROGRAMMING

Vf(
X') ・
=0 (
4.4
4) ま 仇 -1)-x1=
=2 4.
( 4
7b)

whichispr
ima
ril
yav ecto
re x
press
ionoft
herel
ati
oninEqu
ati
on(4.
43
).Equat
ion
(4.
44)i
susedtoest
abl
ishtheval
ueo ft
hed
esi
gnv a
ria
ble
sX'botha
nal
yti
cal
lyand EQua
tions(4.
47a
)an 4.
d( 47b
)r e
pre
sentapairof
lin
earequ
ati
onswhi
chcanbes o
lve
d
nume
ric
all
y. as-X1=2,I2=2.Thevalueoft h
et -u
ncti
onfis-2.Sof aronlytheneces
sar
y
con
diti
o n
shavebeens
ati
sfi
ed.Thevaluesabovec
ana l
sore
fert
oap o
intwherethe
釦nctioni
samaximum,orwherether
eisas ad
dlepoi
n.
t
Second-DrderC o
n d
it i
o n
s:The s eco
n d
-ordercond
itio
ns (SOC) areu sua
l1y
rega
rdedassuf
fic
ien
tc o
nditi
ons.Itcanbei n
fe町'e
d出 a
tthes
ec o
ndit
ionswillinv
olve
secondder
ivat
ivesofth巴 fu
nct
ion.TheSOCi soft
enobtain
edt h
roughtheTaylor SDC:For出i
spr
obl
em[
seeE
qua
tio
n(4
.26
)]

blr
日叶什つ
expan
sionofthefun
ctiontoscc
o n
do rd
er.IfX申 i
s出巴 so
luti
on,andd.Xrep
rese
nts白e

-

H
changeof出巴 va
riab
lcsfrom出巴 op t
imalvaluewhichwi
llyiel
dac hane,
g f
i
dt hen

(
4.4
5) I
sitp
osi
tiv
ede
fin
ite
?
市川 + t a h r凶
年 刊 念 +6X)ーが)=可(X
(
i
) Notp
oss
ibl
e10t
es
tald
l .
X
Thisi
ssirn
ila
rtoE qua
tion(4.35
)e x
cep
t出ee xpa
nsionisab
o u
t出cs o
lut
io.6
n f (
i
i)TocaJcula~巴 the e
ige
nva
¥ue
sofH,
mustbegrc
atertha
nz e
ro.Employingthene
cess
arycon
diti
ons(4.
44),th
efir
stter
m
ontheri
ght-
handsid
eo fEqu
ation4.45i
szero
.ThisI
cavcs出efollowi
ngineq
ual
ity
1=川 一λ 一→~I卜=山川一\
-1 2-λ 川l 、 ハ
= 山 川-3

)仏恥
い川-
→-
¥
)

)

af=jaTH 4.
( 46
)
τ
'ee
h i
gen
val
uesa
r巴 λ=,
¥λ=3andt
hem
atr
ixi
spo
sit
ived
efi
nit
e.
(
ui)Toc a
lcu
¥at
edete
rrn
ina
ntsofal
lord
er富 山alinJu
c deth
emaind
iag
ona
lan
d
whereH(X
・)i
sth
eHe
ssi
anm
atr
ix(
thema
紅ixo
fse
con
dde
riv
ati
ves
)oft
hef
unc
tio
n
fa
tth
cpo
ssi
bl巴optimumv
aleXへF
u or出er
ela
tio
nsi
nEq
uat
ion(
4.4
6)t
oho
ld,
the i
ncudet
J heele
menti
n白 efr
rs
trowandfi
rstcolumn,
m
atri
xH(X 勺 mustbep
osi
tiv
ede
fin
ite
.Th
erea
ret
hre
ewayst
o巴s
tab
lis
hth
eH i
s
p
osi
tived
efi
nit
e. 1
21>
0

-
-
'a
T


(
i
) F
ora
llp
oss
ibe.
l 6
X
,d.
X .
H(X')6X>O
.

ヲu


nu

2且

qJ
d斗



(
i)Thee
i ige
nva
lue
sofH(X')a
rea
llp
osi
tiv
c.


,ゐ
(
iu)Thed
ete
rmi
nan
tso
f叫]l
owe
ror
der
s(s
ubm
atr
ice
s)o
fH(
X')t
hati
ncl
udet
h巴
maind
iag
ona
lar
eaI
lpo
sit
ive
. Them
atr
ixi
spo
sit
ived
efi
nit
e.
Ofthe出r
ee,
onl
y(i
i)and(
ii
i)c
anb
epr
act
ica
llya
ppl
ied,
whichi
sil
lus
tra
tedb
elo
w. Sec_4_
4-1.mprov
ide
s山ec o
nfi
rma
tionofth
enumer
ica
lva
lue
sfo
rth
ise
xam
ple
u
singSy
mboli
cToolboxandb
asi
cMATLABcommands.
Example
4
.4.
2 EqualityConstrainedProblem
M
ini
rni
ze j
( ,
XIx2
):(
XI-1
)2+(
X2-1
)2-X
IX2 4.
( 38
)
Th
cpr
obl
em:
O~XI ~3; O S; x2~3 4.
( 37
)
M
ini
rni
ze f
(XI,
x2
):-
XIX
2 (
4.36
)

FDC Su切ectω hl(xl ,x2):xt/4+~-1 4.


( 39
)

ヂ=2(xl-2)-x2=O 4.
( 4
7a) O~xl~3; O!:>x2~3 4.
( 37
)
180 NONL
lNE
ARPROGRAMMING 4
.4 A
NAL
YTI
CALC
ONO
ITI
ONS 1
81

F
igure4.7illu
str
ate
d白eg r
aphicaJsol
utio
n.Itwお n ot
iced山a tatthesol
ution,th
e Eq
uat
ion
s(4.
51)e
xpr
ess出eFOCorn
国 民S
釘 yc
ond
iti
onsf
or叩 巴q
ual
ityc
ons
tra
ine
d
g
radie
ntof恥 o bjec
tivefun
ction叩 dthcgrad
ientofthecons
train
twe 問 p
aral
leland p
rob
lemi
ntwov
ari
abl
es.Th
cla
ste
qua
tio
nint
hca
bov
ese
tist
heC
Ons
回in
teq
uat
ion
.
o
pposi
telyd i
rected.E
xaminin
go t
herfeas
ibl
ep oi
ntsinFistIm4.7(ont heda sh
ed 百i
sen
sur
est
hes
olu
tio
nisf
eas
ibl
e.Thef
ir
sttwoe
qua
tio
nsc
anb
eas
sem
ble
din
c
urve)i
tc anbeasce
rt剖nedthatthespec
ialgeom
etrica
lr e
latio
nshi
pisonlypossibl
c v
cct
orformtoyicl
dthesameinfo
rmati
onexpre
sse
dbyEqua
tio
n(4.48
),wh
ichwas
a
tthesol
utio
n.Atthcsolu
tionapropor
tiona
lrelat
ions
hipcx
istsbetweenth
egradien
ts o
b凶n edgra
phi
call
y.百leIeft
-ha
ndexp陀 s
sio
nsin山efi
rs
tlwoequ
ation
sabov
care
a
tthes olu
tio
n.U singthcc o
n s
t a
nto fprop
ortio
nali
tyA I( aposit
ivevalue)t h
c t
hegr
adie
ntoftheLag
rangi
anfunc
tio
n:
r
ela
tions
hipbetweenthegr
adic
n t
sc anbeexpre
ssedas

VF=可 +λIVh.=0
町=ーλIVhl or Vf+川町 =0 (
4.
48
)
E
qua
tion(
4.48
)isu s
ual
lyo
bta
ine
dinamoref
orm
alwayu
sin
gth
cmethodo
f A
ppl
yigEq
n u
ati
ons(
4.5
1)t
oth
cexampleo
f出i
sse
cti
on:
L
agran
gem
ult
ipl
ier
s.
aFλIX 1
MethodofLagrange: I nl h
ismethod,t
hep r
oblemistrans
form
edbyi ntro
duci
ng ?一 =-x.+一七ム =0
oX1 L
anaugmentedfunc
tion,c
alle
dt eLa
h gran
gian.asth
eo b
jecti
vefunc
tionsub
jecttot
he
same叫 ualit
yc ons甘泊nt
s.TheLa gr
angi
ani sdef
ineda sthesumo ft h
eo ri
gin
al
aF (
4.5
2)
ob
ject
ivcf u
ncti
onan dali
nearcomb
inati
ono fth
econ
strai
nts
.前 leco
cffi
cicn
tsoflh
is ?
"
.:
¥
_=
--

_-x
"
"2+
. '2
λ
"
'
""
¥ x
ol2.=o
A

li
nca
rc ombina
tion制 官 known創 出 巴 Lagrangemult伊lie
rs
.Withr cfcr
ence10thc VA2
exam
plci n山isscct
i o
n

Minimize F
( 2,
拘,x A
I)=
f(l,
x u+A
x Ihl
(I,
X x
2) 4.
( 4
9) h144-l=o
τbec
omp
let
epr
obl
emi
sde
vel
ope
das
Equ
ati
ons(
4.5
2)陀 p
res
ent伽 田 e
qua
tio
nsi
n伽 田 v
ari
abl
eswhichs
hou
ldd
ete
rmi
ne
thevaluesf orxj.xi,λj. Note白紙 E quations(4.52
)o nlyd efi
net hen ec
e s
sary
Minimize F
(XI,
x2,
A)=-XIX2+λ
I 1(
.寸/4+4-1) (
4.5
0) con
ditios,
n whichmeanst h
es o
luti
onc o
uldbeamaximuma ls
o.
Th cr
eisonep ro b
lemw ithresp
ecttothesetofEquatio
ns( 4
.52
).Th 巴equat
ionsare
S
ubj
eclt
o: hl
(I,
X x
2:4/4+4-1
) 4.
( 39
) anonlinca
rs e.
tMostp re
r e
quis
itecoursesonn umcric
alm ethodsdon otattemptto
sol
v巴 anonlinea
rs ystemofequati
ons.Usual
ly.l h
cyonlyh a
ndleasingleoneth r
ough
O
::
;;
XI:
:
;;
3; 0
::
;;
x2
::
;;
3 (
4.3
7) Newton-Raphsono rtheb iscc
tionmethod.I nfac
t,NLPo rdesignoptimi
zationis
pri
marilyab outtcchniqu
e sforsolvingas ystemo fnonli
near叫 uation,a
s l
beitof
Is曲es ol
utiont
ot h
e回 l sfor
medproblcm[Equalion
s(4.5),
0 (4.
39),
(4.3
7)]thesame spωi
ficf o
rm .Th
s ismeansE quat
ions(4.52
)ca nn
otbes ol
vcdunti
lwea dvancc釦r th
er
asthesol
utiontoth
eorig
inalproblem[Equ
ations(436),(
4.39
),(437
)]?Ifth
ed e
sign in由isc ou
rse.F ortu
nately,havingat o
olIikeMA 札 ABo bv
iatesthi
sd if
fic
ulty,and
i
sif回 s
ible,
也enmostd efi
nite
lyyes.F o
rf eas
ibledesi
gns,hl("X2)=0,
x 組d白巴 prov
idesas 位。n gjust
ific
ationofusingan umerica
l/sy
mbolictoolforsuppo
rting白巴
o均配t iv
ef unct
ionsinEq uat
ions(4.3
6)and( 4
.50)arethesame.Ifdesig
ni snol developmentoft h
ec ou
rse.2
fea
sibe,
l thcnbydefin
iti
ontherei
snos ol
utionanyway.
τbeFOCa reobtai
nedbyc o
nside
ringF(x"X2,入1)as佃 uncons
train
edβmctio
llin
出ev ar
iabl
csXI・X2,λ
l'Thisprovi
des血r e
er e
lati
onstosolv
eforxj,x
i,川 MA礼A BCode: InMATLAB.t herearetwowayso fs o
lvingE q
uation
s( 4.
52),usi
ng
symboli
cs u
ppor
tf u
ncti
onsorusingthcnumeri
c a
ls u
pportfunc
tion
s.Bothprocedur
cs
dF i)f • ah , havclim
itat
ion
swhena ppli
cdtohighlynonlin
earfunct
ion.Th
s esymbolicfun
ctio
nis
一一=一ι+λ.ー-!.=o

ax ixl '.'. ax
)
s
a
o
n
lv
dr
e
e
a
q
n
d血
ui
re
巴nume
syout
ri
oc
c
a
h
lf
oo
u
s
nc
ea
ti
o
ni
ni
ni
s
t
i
f
a
so
l
lg
v
u
e
c
.Then
sstost
u
a
r
me
r
tt
i
h
ca
ep
lt
ro
c
c
c
e
h
d
u
n
r
i
e
q
uei
.Qu
sa
it
ni
eo
t
f
e
t
e
r
at
ns
i
v
e
eo
vc
n
r
a
e
l
d
iffer
entg u
essesmayb c隠 quir
edt of i
nd出cs olut
ion
.S olutio
nso fsystcmsof
aF af." ahl (
4.5
1) eq
uationsarefun
damentaltotheres
to f出eb ook.Thef ollo
wingcodeisinclu
ded悩
一一=一一 +λ,一一 =0
ahands-onexe
rcis
e.Itisavai
IableasSec4_ 4_2.m.Itrequire
seqns4_ 4_2.mt o
aA
2 ax2" '
.aX2
exe
c u
teβo l
vecommand.Thcco 蹴附o f血ef il
csarelis
tcdbclow

aF
1
11C
問 n
rco
lh
er1
00
18b
es
ld
csM
ATL
ADs
uch田 M
Ulh
cnd副 I
d臥 c
c
l.
一 =h.=O
1
82 N
ONl
lNE
ARP
ROG
RAM
MIN
G
4
.4A
NAL
YTI
CALC
OND
ITI
ONS 1
83
S町 4_4_2.m
も define initial values
者 N ecessary/Sufficient conditions for
xinit=[l 1 0.5]'; 者 initial guess for x1,x2,1am1
者 E qualityconstrained problem
告 者 the equations to be solved are available in
者Optimizationwith MATLAB,Section 4.4.2 も eqns4_4_2.m
% Dr. P.Venkataraman
者 xfina1 ~ fso1ve('eqns4_4_2',
xinit);
者 Minimize f(X1,
x2) -x1 fprintf('Thenumericalsolution (x1*,
x2*,
lam1*):¥n'),

disp(xfina1);
者ー・ー----ーーーーーーーーー---・・ーーー・
者 symbolic procedure eqns
4_4_2.m
もーー・ー--ーーー"ーーーー--ーー'ーーー・・ function ret eqns4_4_2(x)
define symbolic variables

も x is a vector
format compact . 者 x(l) x1,x(2) x2,x(3) lam1
syms x1 x2 lam1 h1 F ret=[(-x(2) + 0.5*x(1)*x(3)),
者 define F (-x(l) + 2*x(2)合 x(3)),
F -x1*x2 + lam1*(X1*X1/4 + x2*x2 ・1
); (0.25*x(1)*x(1) + x(2)*x(2) -1)];
h1 x1*x1/4 +x2*x2 - 1;
者ヒ he gradient of F OutputI
nMA
TLA
BCommandWlndow
grad1 ~ diff(F, X1);
grad2 = diff(F, X2); The solution (x1*,x2*,lam1*, f*):
1.4142 0.7071 1.0000 -1.0000
者 optimalvalues
-1.4142 -0.7071 1.0000 -1.0000
も sa七isfaction of necessary conditions -1.4142 0.7071 -1.0000 1.0000
[lams1 xs1 xs2] sOlve(grad1,grad2,h1,'X1,
x2,lam1'); 1.4142 -0.7071 -1.0000 1.0000
も the solution is returned as a vector of Optimization terminated successful1y:
者 the three unknowns in case of multiple solutions Relative function va1ue changing by 1ess than
も lams1 is the solution vector for lam1 etc. OPTIONS.TolFun
;mORmT:the results are sorted 向 habeti叫 ly The numerica1 solution (x1*,x2*,lam工*):
1.4141
者 fprintf is used to print a string in the 0.7071
幸 commandwindow 0.9997
者 disp is used to print values of matrix Thesymboliccomputa
tiong e
nerat
esfoursol
uti
ons.Onlyt h
efir
stoneisva
lidfort
his
f -xs1.*xs2; probl
em.Thisisdecide
db y出es ideco
nstr
aint
sexpressedbyEq ua
tion(4.
37
).Thisis
fprintf('The solution (x1*,x2,
合 lam工
*, f*)¥n'), 阻iIIust
rat
ionoftheaprio
rimannerbyw hichthesidecons
trai
ntsaff
ectth
ep r
oblem.
disp(double([xs1 xs2 lams1 f])) ー
Ont h
eo t
herhand
.出en umericaltech
nique
sp r
ovideonlyonesolut
ion10th
eproblem.
曹司・・・ー-------ーーーーー・ーー・ーーー・ーー--- 百lIsisaf u
ncti
ono fthein
itia
lg u
ess.Gen
erally
.n umeri
calt田 hniq
ueswil
ld eli
ver
% Numerical procedure sol
ution
sclose
sttolhepointtheysta
rte
dfrom.Thes ol
utioni
s
者・ー・・ーーーーーーーーーーーー--ー・・・・ーーー--
も solution to non-linear system using fsolve x;=1
.41
41;x
;=0
.70
71;吋=1
.0
も see help fsolve
告 τ
'es
h o
h瓜o
nsf
orX
I叩 dX2C
佃 beve
rifi
edf r
omt h
egraph
icalsol
utio
ninFigur
e4.7.
者 the unknowns have to be defined as a vector Thesol
uti
onscana
lsobeve
rif
iedthr
oughthehan
d-heldca
lcu
lat
or.Thevalu
eandsign
告 the functions have to be set up in an m-file frλ
o areu s
ual
lyimmat
eria
lforest
abli
shin
gt h
eo pt
imum.Foraw el
l-po
sedproblem
i
tshoul
dbeposi
tiv
esincci
nc陀asi
ngthecon
stra
intvalu
cisuse
fulonl
yifwcaretry
ing
t
oi d
ent
ifyalowervalu
efor曲eminimum.Th i
sforcsha
e ndftomovci nopp
osite
4.
4 A
NAL
YTI
CAlC
OND
ITI
ONS 185
184 NONUNEARPROGRAMMING

d
ire
cti
ons(
gra
die
nts
).Inc
rea
singc
ons
trai
ntval
ueca
nbea
sso
cia
tedw
ithe
nla
rgi
ngt
he S
ubj
ectt
o: [
h(X
)]=0 , (
4.6
)
f
eas
ibl
edomainwhichmayyie
ldabet
terde
sig
n.
X1
0wSXSXup (
4.8
)
LagrangeMult 伊 l
, ,ler
s:TheL agrangemulti
plie
rmethodi san巴l e
gantfo
rmulat
ion
t
oo bt
ainthesol
ut iontoaconstrain
edp r
oblem.Inoverview,itseemsstran
ge血atwe
0E
1 qu
ati
on(
4.5
3),
thr
eee
qui
val
entr
epr
ese
nta
tio
nsf
ort
heL
agr
ang
iana
res
how
n.The
havetoint
roducea na d
diti
onalunknown( λ
1)tosolvetheconstra
inedprobl
em.T hi
s
vi
olat
es曲ec on
ve ntiona
lr ul
ef orNLP白紙 t h
ef ewerthev ar
iabls,
e t
hebette
rt h
e FOCare
c
L
h
a
a
n
g
r
ce
a
n
s ofo
gianal
b
l
t
a
o
i
w
n
st
in
h
g 白es
e位ansf
o
o
l
r
m
ut
a
i
o
t
i
n
o
. As i
nofac
n
o
d
n
i
s
t
c
r
a
t
a
e
i
di
ne
dp
nt
r
o
h
ed
ble
i
s
mi
c
n
u
t
ss
oa
i
one
nunc
a
r
o
n
l
s
i
t
e
r
r
,出E
aine
d
dFνム ヨh" (
4.5
4)
"~'.k =0; i=,
一一=ーム+) A
. 12
pr
oblem.TheL agra ngemult
ipli巴rals
oh asaphysic
alsignif
icance
.Att hesolu
tioni
t a
J
E
i axizkh'
ex
presses山er atioo f蜘 c hangei ntheo bj
ectiv
ef un
c t
iont ot h
ec hangein臨
c
onstra
intval
ue.Toi ll
ust
rat
e出i sconsi
der:
S
ubj
ect
ω: 胆(
X)]=o , (
4后)

F=f+λ
Ihl X1
0w~X~Xup (
4.8
)

Idl
dF=df+λ 1 E
qua
tio
ns(
4.5
4)a
nd(
4后)p
rov
idet
h 1+1
e1 rel
ati
onst
ode
ter
mie恥 n+1
n unknowns
xヘλ・
.E
qua
tio
n(4
.8)
isu
seda
fte
rth
eso
lut
ioni
sob
tai
ned
-ifn
ece
ssa
ly.
Equ
ati
on
dF. dF. dF (
4.5
4)i
sal
soe
xpr
ess
eda
s
dF= 一~dx,+
dX _.. .一一命令+
dX :
:
λ-
2-'2 • d a
A
.
, ,
.


-
1

-
川什川山
n,t


Attheso
luti
o h
eFOCdeemst
hatdF=0(
whi
chc
ana
lsob
ese
eni
nth
eab
ove

V

V

V
+
'

n
n

ι
V
(
4.5
5)

u
H
v
EE

-hH
.Hence,

r
de
tai
ledex
pansi
on)

内,ゐ
L
λ一一王立 笠
L
1- d
h 6
11
Theabovedependencedo巴snota
ffe
ctt
heesta
blis
hme
ntofth
eoptima
lde
sig
n.I
t Second -Ord e
rC ondition
s:At恥 s olut
iond eterminedby山 FOC,t hefunction
does hav巴 animp
ortan
tr ol
ei nthedi
scu
ssionofdes
ignsen
sit
ivi
tyinNLP sh
ouldi ncreas
ef o
rc hangesi n6X.Changesi n企X a ren otarbi
trary.Theyh a
v eto
pro
ble m
s. sa
tis
fy曲el ine
arize
de q
ualitycons町ain
tatthes o
lution.1tistakenforg r血 旬d出a tthe
su
ffi
c i
entcon d
itionsMeu sual
lyapplie
di nas malln ei g
h bo
r hoodo ft heopt imum.
GeneralEqualltyC
ons
tra
lne
clProblem: Rememberingn-1>0, Also,changesa r
ec ontemplatedonlywithreSPECtt oX andn otw ithr es
pectt othE
Lagrangemul tip
lie r
- TKLagrangemet
hodisobnc alledthemetho dqfu n
d et
e rmined
M
ini
mi 匹J
e f(X),
z '
I (
4.5
) co
eff
icie
nt.ーi ndic
atingiti
so otavari
able
.1nt he叩 a
叫l“

yc 叫叫d白er
iv
巾 a
副6ωo
叩noft白heFOCfor
帥 :
p州 e ∞ ∞∞
l
Subjectω[I(
X)]=0 , (
4.6
) prev
i ouss

m
π
巴c
m



l恥 L
ω叩
0n(
ag
凹 ∞
c
ra
o附
n
n
s
g
t
i
r
a

a

i
I
刊 w
n
e
asc
叫dmin泊

on
回1
i

訟za
副t
io“
帥叫 u
n

聞nc
即附on
),血巴 SOCc
s
蜘 i 削 B
叩 b
勘0 r
叩町

eexpec
r側 暗
飽 dt
削,
ngf
osa
m

ti
m

『町

s
f
nt
yt
h

h
e
e
foll
o w
ingr ela
tio
ns:
X1
0wSXSXup (
4.8
)

Theaugmentedp
rob
lemw
itht
heL
agr
ang
ian
: X*+必

岬 =F( 訓)ト
川-尺

F'(
X乃
.
)乍=VF
) 賦(
'(
X'
噂) →d可[v内α(
邸 T炉守
凶 頓


z
2
F怖


(附


X
X削
'
'
)

羽]瓜
) O
〉刈 糾

Minim
取 ム')=f(X)+
F(X L入品(X) VhTAX=O
k=l
I
nth
eab
ov 勺l
e[V2F(X i
sth
eHe
ssi
ano
fth
eLa
gra
ngi
an,w
ithr
esp
ectt
oth
ede
SIg
n
=f(X)+A'h
; v
ari
abl
esonl
yeva
luatdatt
hesol
uti
on.A
lso,th
eF0CmquimthatVF(X)=0.With ・
め +lTh
=f( (
4.5
3) r
efe
renc
etotwov
ari
abl
esandoneco
nst
rait
n:
4.
4 A
NAL
YTI
CALC
OND
ITI
ONS 唱87
186 NONL
lNE
ARPROGRAMMING

t
:
.F= 核吋 三
走州向
)+言
叶〉。 +2
T
ran
sfo
rma
tlo
ntosnE
qua
lit
yCo
ns

Minimize
t
rai
nedP

j
(
r

X
ob
l

I・
X
e

2
)
m

:-
XIX
2 (
4.3
6)


問 位
M=i )+詞
吋〉
。 +2tL
(
4.5
7)
S
ubj
ect
lo: g
l(X
I'z
X

g
2
}+

(XX
2,.
z
i
:20xI+15~ -30+z
)+ 這:xi/4+x~-1 +z~=0
i=0 4.
(

(
4.
59

6
0
)

)
t
:
.
.
xl dh/ox
2 (
4.5
8)
t
:
.
.
x dh1/dx1 OSXIS3; OSX2S3 (
4.3
7)
2

S
ubsti
tuteEqu
ation(4.
58)inEq ua
tion(4.
57)andtheSOCr e
quire
sthattheexpre
ssion Th
erearefou
rvar
iabl
es(X
I.X
2.ZI
.Z2)andtwoequ
ali
tycOl
lst
rai
nts
.Iti
sav
ali
dequa
1it
y
i
n braωmustbep osit
iv.百四 d
e e
riva
tive
si nEq ua
tion
s( 4.5
7)叩 d( 4.58
)師 co
ns回 ine
dp rob
lem. TheL ag
rangem ulti
pli
er m巴th
odc anb eapp
lie
dtot h
is
e
valuate
datthem泊imum. 岡 由mau--Tod叫 n guis
h曲em ul
t i
p目 的 制o c
iat
edw i出 i
叫 叫i t
ycons
凶脳
Applyingt
hes ec
o n
d-ordercondi
tiontotheexampleof白i ssecti
oni s1巴f
tお 叩 血esymbol~ i
suse.Th
d i
siss凶ct1
yf orcI回ty
.
e
xerci
sef o
rthe陀 ader
.Compar 芭dt o白eSOCf orth
eu n
constr
ainedm ini
m i
zation
pro
blem,Equa
tions(4.5
7)and( 4.
58)町宮 not側 syωapply,e
speci
allythesubst
itu
tion M
eth
odo
fLsg
rsn
ge:TheaugmentcdfunctionortheLagrangiani
s
:
fE
o quati
on(4
.58
).Fromap rac
tic
alp e
rspe
ctiv巴 批 SOCisn o
ti mposedfor叫 ual
ity
c
onstra
inedprob
lems.Itisl e
fttot hedcsig
ncrtoe n
surebyo the
rmeans白 川 出e
M
ini
miz
e
s
oluti
onisaminimums o
lut
ion.
F(x 1 ~, ZI・ Z2・ß I'ß2) =f(xl
・ .X)+s1
2 [gI
( ,
X1x2
)+z
il+s2
[C2
(X'ろ)+z~] (
I 4.61
)

4
.4.
3 I
neq
ual
ltyConstrainedOptlmization I
ftheLag
rangi
ani sco
nsi
der
ed鎚 a
nun
con
str
ain
edo
bje
cti
vef
unc
tio
n.t
heFOC
(
nec
ess
aryco
nditi
ons)a
re
Theproblem
dF df./l o
gl ./l dg2 (
4.6
2a)
一 +s一 =0
一 =axlaX12axl
-41
a
xl
Minimize f
(XI・
Xz
}:
ーXIX
2 4.
( 36
)

dF of./l o
gl ./l ~g2 (
4.6
2b)
S
ubj
ectt
o: g
l(I,
X x
2:20X
) I+1
5X2-30S0 4.
( 4
0) 一 = ー +ßI~Ul +s
2ー =0
dX dX2' .dx .r~ðx
I
"'
2
2
g2(xl ,xz):x114+~-1 SO 4.
( 41
)
dF (
4.6
2c)

τ =2s,
z,=0
_n

OSXIS3; OSX2S3 (
4.3
7) 週
1目1
;
aZ1

Thenumbero fvariab
les(n=2 )剖 dt henumbero finequa
litycons
trョin
ts(m=2 )do
notdependone achothe
r.I nf a
ct.a ninequ
alit
yc ons釘ainedproblemi nas in
gle dF . n (
4.6
2d)
?ー=2s.z.=0
va
riabl
ec anb eu se
fullyd es
ig n
eda nds olv
ed.S ec
tion4.4 .
2s olv
edt he叫 ual
ity aZ
2
con
strain
edp roblem.Ift heabovep roblemc anb e回 n sf
o rmedtoa nequiva
lent
cq
ualit
yc onstr
ainedp roblem. 出e n we havef oundt hes o
luti
on.百1 es tan
dard
回 1sform
ationreq凶resas la
ckv a
riabl
ezjforeachineq
ualit
yc ons凶 ntg UnlikeLP dF ? (
4.6
2e)
j・ ー =
g.+zf=O
proble
ms,theslackvar
iableforNLPi snotrest
rict
edinsign.τber
efore,t
hesquareof d
PI ul

th
enewv a
riabl
ei saddedtot heleft
-handsid
eo fthecor
r四 pondingcons住ain
.tThls
addsaposi
tivevaluetothelef
t-h叩 dsidetobrin
gt h
ec on
s回i ntuptozero.Ofcourse i
JF ? (
4.6
2t)
ー =g,.+z~=O
azerovaluewi
llb eaddedifthec o
nst
rll
intisalr
ell
dyzero. d
s2
U " , 必
188 NONL
lNE
ARPROGRAMMING 4
.4 A
NAL
YT'
CALCONOtnONS 189

Eq
uat
ion
s(4
.62
e)and(
4.6
2t)a
re珂 u
ali
tyc
ons
tra
int
s.Eq
uat
ions
et(
4.6
2)p
rov
ide
ssi
x Eq
uat
ion(
4.6
4),
theLa
gra
ngi
ani
sre
for
mul
ate
dwi
tho
utt
hes
lac
kva
ria
ble
sぉ (
wea
re
句u
ati
ons
tos
olv
efo
rx,
1x,
Ez;,
Z5.
91.向
.Bysimplerecombination,
Equ
副on
s(4
.62
c) g
oin
gtop
ret
endZn
eve
rex
ist
ed)
to(4.6
20canbec o
llaps
edtotwoequ
atios,
n whi
lethes
lac
kva
ria
ble
sZIandZ2canbe
eli
F
m
i
i
n
r
s
at
tm
e
d
u
f
l
r
t
i
o
p
mt
l
l
yE
z
ep
qu
r
a
o
t
b
i
l
o
em
.
n(4.
62c
)byZI・Replace by-8t
z
1fromEqu
atio
n( 4
.62e
).
Minimize F
(x.,
x2.
s.1
32,
)=.
f
{.・
x x
2)+s
.[g
.(x
..x
2)]+s
2 .
[8T,X
2)
] (4.65)
Droptheneg
ativesig
naswellωthec o
eff
ici
ent2toob
tai
n


whichisthesameformulati
oninE qu
ation(4.
53)
.Thes l
ackvaria
blewasi ntrod
uced
t
op rovide出巴 tran
sformati
ont oane qu叫it
yc ons回 i tI
n. tisa l
soev id
ent白 鉱 山e
18.=0 (
4.6
3a) co
ns凶 c t
ionof由巳La grangianfunc
tionisin
sens
itiveto白巴 typeofconstra
intSince
1
32
82=0 (
4.6
3b) 白emultip
lierst
iedtotheinequ
alit
yconstr
ain
tarer e
quire
dtob cposi
tive,whil
ethose
co
rrespondin
gtotheequal
itycons
trai
ntsareno
t,th
isbookw i
llcontinuetodis
tingu
ish
Equ
ati
on(
4.6
3b)i
sob
tai
nedbyc
arr
yin
gou
tsi
mil
arm
ani
pul
ati
onsw
ithE
qua
tio
ns bet
we n出巴 m
e ul
tip
lier
s.Th iswil
ls e
rvetoenfor
ccc la
rit
yo fpres
ent
ation.TheFOC
(
4.6
2d)and(
4.6
20.TheFOCc
anb
ere
sta
teda
s f
orthep r
oblem:

dF df. d 8
.. d 82 (
4.6
2a) e
)F dr ~d
8I ~ d
8 (
4.6
2a)
一 =;
J 一=二L4144H=o
n n 内

d
x. d
x
+ßI~+ 132ー =0
. r1dx.'r~ðx. d ,'
x d,
x ' O
Xt.ZI
"d
x
". I
""

dF d

d=二:
X d
2 2
:
X
r ~d
L+r
8I ~ d
ßI~+ 1
1
dx2
3
8今
2 =0
r~ðX2
ー (
4.6
2b) dF df.n d

dz=d
X ー
x2'1
"
"' d
g
.
X
. .n d
+ß I"\~I +1
z .
32
Z
g
2
一 =0
d
I
".
X
z
"
(
4.6
2b)

1
31
8.=0 (
4.6
3a) :払 =0[
Casea gl<
0];日
2=0[
g2<0
]

1
32
82=0 (
4.6
3b) Caseb
:1 ,
3 =0[
8.<0
];仇>0[
g2=0
]
(
4.6
4)

Thesefourequati
onshavetobes o
lvedforxj,x
i, 日,
j・
2
sNote伽 tzi,Z 2a reootbei
ng C
asec
:s.>0[
g.=0
];s
2=0[g2<0]
determincd-whichs u
ggess白紙白e
t ycanbediscardedfrom恥 p roblcma1t
ogc白er
. Cased
:s.>0[
8.=0
];島>0[
82=0
]
I
twouldbeu s
efultopret
cndz'
sncvcre xi
stcdinthefir
stplac
e.
Equations(4.
63)layoutadcf
init
ef e
atur
ef o
ran o
ntrivi
alsolu
tio
n:cit
h e
rsjisze
ro
(and8/手 0)or8/i
sz eo(島刊).S
r inces i
multaneo
usc qua
tions蹴 b e
ings ol
ved,出e
Equat
io nset(4.62)anda nysing
lec a
seinE qua
tion(4.64)provid
esfourequat
ionsto
con
ditioson曲em
n ul
tipl
iersandconstr
aintsmustbes ati
sfie
ds i
mul
taneous
ly.For sol
v巴f ort h
cf ourunknownso fthep ro
b l
em.A llfoursctsm us
tb esolvedforthe
Equatio
ns( 4
.63
),出is甘 組s l
aωsint
o白 ef ol
lowingfourcas
es.Thcinfor
mationon8in so
luti
on.Th ebestdesig
nisd ecid
cdbys canningthesev
erals o
lut
ions
.
brac
ketsistocmphasizeanaccompanyingconsequen
c e. Thcs igno fthem u
ltipli
erint hesolutio
ni snotas j
uJic
ien
tc ond
itionforthe
泊 叫ualityconstrai
nedproblemTh cval
ueisun 加 po
rtantforopti
mizat
ionbutmayb e
rel
evantfors c
nsit
ivit
yanalys
is.Generallyapositi
vevalueo f由
巳m u
ltip
lierin
dica
tcs
Casea
:s.=0[
8.<0
];1
3
2=0[
82<O
J 白紙 thes o
lutionisnotal o
calmaximum.F ormall
yv erif
yingaminimums olut
ion
:仇=0[8.<0];仇*0[
Caseb 82=0
] re凶偲sc
q onside
rationo fthes ccondd cri
vativ
eo ft hcLa gran
gia.I
n np ra
cti
cal
si
tuat
ions.ifthcp roblemiswelldefine
d, t
hcpositi
vevalueo f山cm u
ltipl
ierusua
lly
Casec:1
31*0[
8.=
0];1
32=0[82<0)

l 目

sug
gcstsaminimums ol
utio.Th
n isisus e
dc xte
nsivc
lyi nt h
cbookt oident
ifythe
optimums oluti
on.
:日
C邸 巴 d I棋 0
[8.=
0);九*0[
82=0
] (
4.6
4)

In Eq u
atio
n( 4.
64),ifsj*0 ( o
rc orr
espondin
g8 /=0),thent hecorre
spondin
g S
olu
tlo
noft
heEx
ample:ThcLa
gra
ngi
anf
ort
hep
rob
lemi
sde
fin
cda
s
cons位aIn
tisanequa
lit
y.Intheprcvi
ousscct
ionas i
mplerea
soningwasusedωshow
白鉱山cs
Whi l
et h
ig
no
esi
g
f出em
nofth
叫t
emu
i
l
t
p
l
i
i
p
e
rmustbep
l
ierwasi g
n
o
o
si
tiv
問 df
e(>0
o
)f
r白ee
o
q
u
raw
al
it
el
yc
l
o
-
n
f
o
s
r
t
m
r
a
u
i
l
a
n
e
te
dp
dp
r
r
o
o
b
l
b
e
l
m
e

m
.
i
t
F
(x.
x2.
s.s
2,
)=
-x.
.X
z+s(
2Ck
.+1
5X ,
z-30)+九(0.おi~+ .s -l)
i
sin clu
dedaspar
toftheFOCf or出巴 i
nequ
alit
yc o
nstra
ine
dp ro
blem.Befo
reresta
tin
g TheFOCare
1
90 N
ONL
INE
ARP
ROG
RAM
MIN
G
4
.4 A
NAL
YTI
CAL
CON
DIT
lONS 1
91

dF (
4.66
a) Thesolu
tinf
o orCaseawasd iscu
ssede
arl
ierandisconr
trmedabo
ve.
Z;=42+2ORI+05h=0 Casebhnsfoursolu
tion
s.Thefir
stonei
su na
ccep
tablebeca
useco
nstr
nintgli
snot
s
ati
sfi
ed.Thesecondsolut
ionisfea
sibl
ensfarasth
ef u
ncti
ona
1cons
trai
nt ,
sg andg2
dF (
4.6
6b) a
reconcemedb utt heydon otsati
sfythesidecon
stra
int
s.Th ethi
rda ndfour
th
55=41+15Pl+2h=0 s
olut
ionsareunacceptab
lef o
rt hesamer e
ason
.T hu.C
s asebisn otn nopti
mnl
s
olut
ion
.
Cnsecisunac
ce p
tablebeca
useconst
rai
ntg2isinvio
lat
ion
.
(
s12O
xI+15X
z-30)=0 (
4.6
6c) Cnsedhnstwos o
luti
onsth
ef i
rs
tofwhichi
sn o
taccep
tabl
eforse
vera
lrenso
ns.The
s
econdsolu
tio
ns n
tisf
iesnl
lofthereq凶remen
ts
(
s20おイ +4-1)=0 (
4.6
6d)
• I
tsnt
isf
iesth
econ
str
ain
ts.80thcon
stm
ints釘 宮 n
cti
ve.
es
Th i
dec
ons
tra
int
s制 官
• Themul
tipl
iesむ ep
r o
siti
ve(maybeasu
ffi
cientcon
diti
on)
.
・Itsat
isf
iesth
esid
econs
tra
int
s.
OSX1S3; x
.
z
O S S3 (
4.37
)
es
百l o
lut
ioni
s
Casea:sl=0
;s2=0
:Thes
olu
tio
nis町i
vi
ala
ndbyi
nsp
ect
iono
fEq
uat
ion
s(4
.66
n)
an
d(4.
66b
).
x1=
0.8
151
; 2=0
X .
9132
; 仇= 0.
043
9; 九=0.0856;
X1=0; x 2=0; 1=0; gJ=ー3 0; g2=ー (4.
67)
1=ー0
.74
43; g
l= 0
; g
2 0=
Thei nequ
a1it
yc on
抑 制t saresati
sfi
ed.Thes id
ec on 抑 ai
ntsa re削 isf
ied
.Thev al
ues Thi
sisnlmostconfir
m dby出巴 n
e umeri
cnlsolu
tio
nw hichnpp
earstohnveap r
oblem
inE quation(4.
67)r e
p回 sentapossiblesol
uti
on. wi出convergen田 .I
tisalm
ostattheso
luti
on.1
tmustb enoldh
e e
reth
att h
eMATLAD
Thes olut
ionsfo
rt heothercase
s釘'co bta
inedusingMA 11.AB・百lecodeisav
aila
ble fu
ncti
onu s
edtos ol
ve白巴 problemispa
rtofthestan
dardpack
age.Thefu n
cti
onsin
i
nSec4_4_3 m.F
・ orC asesba ndct heappro
priatem ult
iplierissettozeroandthe th
eO pt
imizati
onT oolboxwil
lc er
tai
n1ydob et
ter
.N eve
rth
eless
.t ei
h ncompl
ete
r
es ultin
gt h
rEeEquationsint h
reeunbEownsa res olved.Forc asEdt hecompl
eteset so
lut
ionisrepo
rtedbelowbutwilbei
l gn
oreddueto出es ymb
olicsol
utionava
ilab
le
off ourequat
ionsinf o
urunknownsi ss olved.casedi salsoSOlvednumeri
call
y.明l e i
nC a
sed.
MA TI.ABcodewil
la1 s
or uncodeFlg4_8.mw hichconta i
nsth巴c ommandst odraw山e
f
igure.Th eoutputfromt heCommandwindowi
The solution *** Case a ***(x1*,
spa tchedbe10w .

x =0.8187; x
2=0.9085; , 似 3
s =O. 5; 弘=0.0913
x2*,f*,91,92)
o 0 0 ・30 ・1 T
herearenowt woc and
idat
esf r白es
o o
lut
ion
:出et ri
vi
nlsol
utio
ninCaseaandth
e
The solution 企 **Case ( b)合 ** (x1*, ,
合 b2* f*,91,92): s
olut
ioninCnsed
.Thes olu
tioninCn巴di
s sfav
orednsi
thsal
n o
werobj
ect
ivef
unc
tio
n
???勺E

x2
1.4142 0.7071 1.0000 -1.0000 8.8909 0 va
1ue
.A llofthec n
sesa b
ovec anbeexpl
oredwi由 民spec
ttoF ig
ure4.
8.Iti
san
-1.4142 -0.7071 1.0000 -1.0000 ・6日.8909 0 e
xcel
lentfa
cil
ita
torforcompr
e h
e n
dingt
hecase
sa n
d血巴 sol
uti
on.
-1.4142 0.7071 -1.0000 1.0000 -47.6777 0
n

1.4142 -0.7071 -1.0000


s

1.0000 -12.3223 0 4
.44 GeneralOptimlzatlonProblem
.

The solution * 合安 Case (c)*** (x1*, X2*,b1* f*,91,92):


司ど

o.75001.oooo τ

o.0500-o.7500o o.14o6 'eg


h e
ner
a1o
pti
miz
ati
onp
rob
le sd
mi e
scr
ibe
dint
hes
eto
fEq
uat
ion
s(4
.1)(
4.
8)
.百l
e ー
Thesolution***Case(d}***{xl*, x2*,bl*b2*f*,gl,g2): s
pec
ifi
cpr
obl
emi
nth
isc
hap
terd巴f
ine
dinS
ect
ion4
.3i
s
1.8150 ・0.4200 0.0426 ・1.4007 0.7624 0 0
0.8151 0.9132 0.0439 0.0856 -0.7443 0 -0.0 M
ini
miz
e j
(X X,
l拘):ー' X
2 (
4.9
)
Maximum nu of function evaluations exceeded;


lncrease options.MaxFu nEvals
Optimizer is stuck at a minimum that is not a
S
ubj
ectt
o: h
1(l,
X x
V:20x,+15X2-30=0 4.
(10
)
root
Try a9ain with a new startin9 guess
g
l(X,

xV:<4/4)+(~)ー IS0 (11
4. )
The numerical solution ( x1,
合X2 ,
合b1*, b2*):
0.8187 0.9085 0.0435 0.0913 OSXlS3; OSX2S3 (
4.1
2)
叩i111114I11Jjq
192 NONUNEARPROGRAMMING
4
.4 ANAL
YTICALCONOITIONS 1
93


長野忠Z
A
ii
l端 部 出;
;
35
5 島;
( ・
oX2
XI ..
.,x

JSO
.j=1
.....• m
2 (
4.3
)


;雪 M
u/附 附od:Theproblcm
i …… s
f
i ym
ini
miz
ingt
hc
TheL
agr
ang
ian
:

Minimize
~~X
I~.xl' =1.2....• n
j 4.
( 4
)

M
ini
miz
e X.
F
(XJ 2
, A..
.s 2+入1
U=-X.
X (20
x.+1
5x2-3
0)+s
.(0
.25
x?+xi-1) F
( ・,
x1・

・ X
n,A.,
..
.,λ
/.s
I'....s
r
n)=
S
ubj
ect1
0: "
1(X
,JX
2)
:20
xI+1
5x2-30=0
f
(x,
・..
Xn)+λ,
h,+・
・・+
入内 +s.g,
+・ +sr
n
Cm (
4.7
0)
OSXIS3; OSX2S3
Th
erearen+1+munk.n
own.Th
s esar
nenumbero
fcqua
t io
nsare.
r叫uire
dtos
olv
e
TheFOC 出epro
b1em.百
】es
e釘 "
epro
vid
edbyt
heFOCo r出eKuhn-Tuckerco
ndi
tio
ns:

1c
1 q
uat
ion
sar
eob
tai
neda
s
aF
瓜 I+O.
Z;=-X2+2 5s内 =0 (
4.6
8a)
h,
dF df.~ d " .,dhl.n dg,
. . n dg
m (
4.71
一=ー+ A.,-:;
ート・
+入 ー +PI--+ー・+sm-
: )
aF d, dx
x ,",
'
- d,
x ---
'd
x,-r,ax, -rmax,=0; i=1.2.....n
à~ =-x.十叫+明x (
4.6
8b)
2=o
l叫 u
ati
onsa
r芭o
bta
ine
ddi
rcc
tly也r
uug
h山ecqu
凶it
yco
nst
rai
nts

aF
瓦-=2伽 1+15~-30=0 (
4.6
8c) n)=
hk (xI' X2 • ・.. .X 0; k=1
.2..
. .
.1 (
4.7
2)

mcquat
ionsareappi
1edthrou
gh出巴 2m c
ases
.T hi
si m
plie
s白 紙 出ereare2mp os
sib
1e
Casea
: ,
s=0; l<0
g (
4.6
9a)
s
olu
tio
ns.Thescsol
utio
nsmustincl
udeEquat
ions(4.7
1)and(4.
72)
.Eachc as
巴setsth
e
m
ult
ipli
er島o r由巳 corresp
ondin
ginequ
alit
y叩c0
叩n
附s
tma
int身
がtω
oze
巴瓜 I f
them叫l
t
Caseb
: ,
s>O; .=0
g (
4.6
9b) s
ettozero
.出e n出ec orresp
ondin
gc ons
位置in
釘凶 蹴
tmustbef eas
ib1

efo
血引

rana ccc
ptab
le

3
2
;:町立は 肌
;;zzuyf ωa 同 uirωthesoluuo
山 s
yst
em
s
o
m
u
l
l
u
t
t
i
i
p
o
n
l
.I
i
e
f出ec
rmustb
o
n
ep
st
o
s
r
a
i
i
t
n
i
v
ti
ef
ss
o
e
ttoz e
ro(acti
vec
raminimum.With出i
o
nst
r
si
ai
nt)
.t he
nt
nmind出cme
h
ec
qu
o
a
r
t
i
r
o
e
s
n
po
sc
n
a
di
n
nb
g

結滞在i な1
22
3;
-
結成2
32
22
!
e
xpres
sedas

-・

鳥め

--=
げば u
nu

e
白U
.

U
向 nu
oJ
t
he j<0
ng

dd

npu

鳥>0 (
4.7
3)

設立制思議部議悲鳴;:
Mi
nim
ize f
(X.,
x・
2・.
..x
,J
I
fcon似 onsi
i
m
c
q
t
h
p
u
l
a
l
cs
e
i
i
m
t
i
d
e
e
n

ec
t

o
i

n
s
n

t
gE

ra
nE
q

i
n
u
smustbea
l
a
q
t
s
s
Sh
u
i
i
a
a
t
o

v
i
n(
gn
o

e
d
ct
n
4
s(
.
7

ob
3)
4
.

ec
7
.f
.Oncet
h
3
o

e
)a
re
h
c
e
k
e
r
a
s
en
chc
o
tm
a
eFOCc
d.Asc
s

v
e

o
n
i
t
eas
d
d
.出edωigni

i
e
i
t
n
m
i
o
c
e
u
n
1
ta
sd
di
n
e
e
t
o
e
u
r
n出ce
st
mi
x
sn

n
a
o
o凶 o
eap
mp1
ta

o
e
s
c

s
i
se
c

b
a
e
p
fm v
l
¥
r
t
a
a

es
ier
b
1u
o
1
e
l
u
.t
e

t
h
.I
sa
i
i
n
o
n
si
n
d
.
s
(
4.1
) n
otb u
iltinto出巴 FOC. l tiso n
1yc onftrm
eda ft
erap os
sib1
es olut
ionh a
sb een

Su 民l
to: i
den
tif
ied.Equa
tions(4.7
1)ー(4.7
3)areref
erre
dtoastheKuhn・Tu
c k
ercondi
t io
ns[ s
ee
"
k(
XI,
X2.
...
.xn
)=O
.k=1
.2.
...
.1 (
4.2
) E
xarnple4.
3( S
ectio
n4.5.2
)foraddit
iona
ldiscuss
ionofth
eKuhn- Tuc
kercondi
tions
].
194 NONl
INE
ARPROGRAMMING 4
.
5EX
AMP
LES 195

4
.5 EXAMPLES Ex
p叩 d
ingt
hee
xpr
ess
ion
sint
heb
rac
ket
san
dre
org
ani
zin
gasal
ine
釘 ma
住ix
equ
副on

Twoexarnpl
esarepre
sent
edint
hisse
cti
on.Thefi
rs
tisanuncons
trainedprob
lem白紙
"
1
1 1
1

h
f
i
a
ss
tt
in
i
g
go
nif
i
rr
c
e
a
n
g
r
tu
es
s
s
i
巴i
o
nd
.Th
n
atar
ese
e
d
c
o
u
n
c
li
di
on
.S
sth
p
e
cb
c
e
i
f
a
r
ic
a
nd
l
e
y,
l
si
g
iti
np
l
l
r
o
u
b
s
t
l
r
e
a
te
me
st
x
p
h
l
ep
o
rob
閃 di
lc
mo
nCha
fc
pt
e
u
r
r
ve
s1
ヱyf,2Y;I~ 司 IL
Z;
Y;

iz
;
and2
.
L
Y; L11
/
=1

I
=J
I ;
=1
4
.5.
1 Example4
.2
Not巴th
att
hem
atri
cescanbes
etupeas
ilya
nds
olvedusi
ngMATLAB.TheHess
ian
Problem: A s
e fy,
to Zd
atai
sgi
ven
.Iti
sne
ccs
sar
ytof
indt
heb
ests
tra
igh
tli
ne mat
rixi
sth
esqむ em
u at
rixont
hel
eftTheSOCr
equ
ires出ati
tbeposi
tiv
ede
fin
ite
.
出ro
u ghth
edat
a.T h
i se
xerc
iseister
medc町vefit
tin
gordat
a陀 duc
tio
norregr
essi
on.
Tok田 Pth
ise
xarnplesim
pletheda
tapoi
ntsar
egene
rate
dusingth
epar
abo
licequa
tion
Code:Sec4_5_1.m: E xarnp
le4.2issolve
dusingMATLAB佃 dt h
er e
sult
sfro m出e
Z=O.5y
2.Thedataaregen
eratedi
narbi
tra
ryord
erandnonun丘ormin
ter
val
s.
Commandwindowa reshownb elow
.Comparet hi
sc o
dewith出a tinChapter1.The
re
sul
tsaredis
playe
donap lo
t(notinclu
dedin由巳 bo
ok).Newf ea
ture
sin出巴 c odear
e
LeastSquaredE
rro
r:Theo
bje
cti
vef
unc
tio
n白紙 d
riv
esal
arg
enumbero
fcu
rve th
eu seofrandomnu mbers,usin
gth esumcommand, andwriti
ngtot h
eCommand
fi
ttin
glreg
ress
ionm ethodsist hem i
n i mi z ati
ono fthel ea
sts q
ua r
ede rr
or. 百l e window.Fromthepl
ota nd山巴 tab
ularva
Iuesi
tiscle
arth
ataline
arfi
tisnotacce
ptabl
e
co
nstruct
iono ft heo b
jecti
ve 問 中i res two e nt
itiω-t
hed ataa nd山 t yp eo f fo
r由i sexa
mple.ThequaIityofthefiti
snotundcrdis
cuss
ionin山is巴x arn
pleasiti
s
mathe
malicalr e
lati
onshi
pb etw回 nt hed a ta.Int h
is巴xar
npleitisas tra
ightl in
e. appa
rent白紙 anonlinea
rfitshouldhavebcenchos
en.Thisisle
flasane x
erci
sc.Thc
Gene
rallyitcanb eanyp o
lynomi al, ora n yf un
ctionro
r山a tmanne
r.T hisisusu ally foll
owingwi
llappearin山eCommandwindowwhcn出ec odeisru
n.
th
ewayc orrcl
atio
ne q
uationsared e t crm i ne dine x
.pe
rim
cntalfl
uiddynamicsandh eat
tr
ans
fer.Forthisex創nple血ed ataa ret hec oll
ectio
nofpoint
s(Y
;
・Z /),i=1,2,• • •,
n Results from Linear fit
T批
h
施e
1 e
郎.
x戸
pec也凶dstra
igtI
h in巴c叩 b恥巴 c
仙 h】a
紅ra
低 C~隠
.er
由i包
zedb句y objective function: 16.5827
design variables x1,x2:
2.3458
Z=X1Y+X
z -1.5305
yi Zl
. Zp diff
wherexli
stheslopeandX2i s出ei nterc
ept
.Usingopti
mizin
gterm
inolo
gy,th
erear
e 1.6514
4.7427 11.2465 9.5951
twodesig
nv a
ria
ble渇. F
o rac u
bicp oly
nomi,
I
at he
rewil¥befou
rdesi
gnvari
abl
es.百
3.7230 6.9304 7.2031 -0.2727
Z
pjis血巴fitt
edvalu
ef or也ei ndep
endcntvar
iab
leY;,出eobje
cti
vefun
ctin,
o whichi
s
4.3420 9.4266 8.6552 0.7714
theminimumofthcsq u紅 eoftheerr
orovcra
Iloftheda
tapoi
nts
.canbc巴xp閃sseda
s 0.7179
0.3766 0.0709 ー0.6470
2.4040 2.8895 4.1089 -1.2193
n 1
1
8.1002 0.3270
4.1054 8.4272
M
ini
miz
e f
(x1 L
内 )= [Z/-zpi= [
Z X尚 +
/ー( X
2)]
2 L (
4.7
4) 4.1329 8.5404 8.1646 0.3757
;
=1 >1
1
= 3.3369 5.5674 6.2973 ー0.7299
2.7835 3.8739 4.9991 -1.1253
I
tispos
sib
letoc
omp
le te恥 f
orm
ula
tio
nwi
出si
dec
ons
凶 n
tsa
I出ough白紙 i
sno
t 4.2032 8.8334 8.3296 0.5039
n
eces
s釘y.明leFOCar芭 3.1131 4.8456 5.7723 -0.9267
3.1164 4.8561 5.7802 -0.9241
ー0.8199


=

3.2415 5.2538 6.0737
(
4.7
5a) 0.1954 0.0191 -1.0720 1.0911
2[Zj-(x
0.7284 0.2653 0.1781 0.0871
4.5082 10.1619 9.0450 1.1168

ま=;2IZi- 仰i
叩 (
4.7
5b)
1.9070
0.4974
1.8183
0.1237
2.9430
-0.3638
-1.1247
0.4874
196 NON
lINEAAPAOGAAMMING
4
.5E
XAM
PLE
S 197
1.9025 1.8098 2.9325 -1.1227
0.1749 I~I whereX=[
X¥ 2]a
oX nds=[
1
31,
12,
3仇,s
4]T
.百l
eKuhn-
Tuc
kerc
ond
iti
onsr
equ
iretwo
0.0153 -1.1203 1.1356

429

e ・

-
叫u
ati
onsu
sin
gth
egr
adi
ent
sofI
heL
agr
ang
ianwi出 向s
pec
tlo白 ed
esi
gnv
ari
abl
es
e2
10

-
954
n45
a72
V04

a
u
e
s

↑・
r
M

昨日士山 EpdpfJSEJ
A
Fム

X
4FEq4

l
F _a
a F
一 =0:一2=0
(
4.8
0)


a
X ・ a
X
r
4
.5.
2 Example4
.3
Thea cωa Ie xpress
io nf or白 eg radientsob tainedfromE quation( 4.80)isleftas叩
cxercis
ef o
rt hestudent .百leKuhn- Tuckerc o n
ditionsa r
ea ppliedbyi den
t i
fyingthe
T
hisexmnplci
sth
esamea
sExample23.thef
lag
pol
epmMem.Iti
squ
ited
iff
icu
ltt
o

器部諸説3 315
variousc ase
sb asedont hea c
t ive
nesso fvariouss et
so fcons
traints.

日程盟百
Fort hispr oblemn=2a ndm =4 .T hc rea re2 4 6c
削 =2 = 1 asesthatm ustb e
inves
tig atc
d悩 p arto f出巴 Kuhn ・
Tuckerc o nditionsgivenbyE q uatio n(4.
73).While
l,

総i
tz
i
someo ft hesecasesa retrivia ne
verthelessitisaf o r
midabletask.T hisp roblemwas

締 結 鵠F限 切z
c
solvedg raphi
c a
llyi nC hapter2andt hesameg raphicalsoluti
o nc anb eexploited10
ident
ifyt hep紅 ticu
larc ase白紙 n eedstobes olvedforthesolution.V i
s it
ingCh apter2
ands c叩 n in
gF igure2 .9,itc釦 b ei denti
fied白 a tco n
s回 ints81and8 3area c
tive( a
s
confirm edby出 ezoomeds olut
ioni nF igu問 2 .
10).Thes olu
tioni sx T=0 .68m a nd
Minimize f
(xl占)=6
.05
59E05(x~ -x~) xi=0 .65m.
(
4.7
6) l
f8 1a nd8Ja reactivec ons 凶 附 , 白E叩n由 恥em刷Lu
l

S
ubj
ectt
o: Byt hcs a
邸mer easoningt hemu 凶lt
ip
μl
ie
旬rsassoci at
ed別wi由出巴 i n
activec onstr
aints82叩 d
E
伽4
恥'伽t 山iS,
旬 1
3
2and1 34,mustbcs ettoz er
o.Th i
si nformationont h
ea ctiveconstr
aints
g
l(X
内 )
:7.
496 .
x
9E057+40000x1- 9.7418E06(x1-x~) s0 (
4.7
7a)
canbeu sedtos olveforx j,xi鑓 白i sisas y 山 moftwo叫 u ationsi ntwou nknowns.
Thisd 脚 no,
t however ,co mplete印 刷s factiono f白 eKuhn-T 山 kerc on
dition
s.1 3
1
ands Jmustbes olveda ndverifiedthattheya re伊 副v e.82a nd8 4mustb ee v
aluated
g
2( 'ろ)
XI :(
5卿 +1
.4994E05xr
).
(7+X内吋)ー 1・7083E07(Xi-x~) S0(4.77b)
x andv er
i fie
dt ht出e
a yarel esst ha
nz ero
.
Sec4_5_2.mi sthec od es egment血a tisu sedtos o
lve白巴 particularcased i
scusscd
g
3(Xl
'x2
) .909IE-03xl+6.1116E-ω -0.05(x1-xi
:1 )S0 abovc.Thcp roblemi ss olvcds ymbo
l i
cally.Twov crsio
nsoft hep r oblemares o
lvcd:
(
4.7
7c)
theoriginalpr oblemandas caledve r
sion.百1巴 o bjectiv
ef unct
i on( 4.76
)islJlod
ified
g4(XI'~) :X2 -x1+0
.00
1S0 tohaveac oe
fficien
to fu nit
y.T hiss houldnotc h回 g ethevalueo fthed esignvari
ables
(
4.7
7d)
(why?).Youc anexper imentw ith恥 c odea ndv e
rifyif白 isisi ndeed凶 e .Note白c
0
.02Sx1S1
.0
; 0
.02Sx S1
.0 (
4.7
8) ,. valueso ftheL agrangem ultiplier
sd uring血i sc xercis
ea ndinfert herelat
ionb etween
2
them凶 t ipli
ersa ndt hes calingo f血巴 o bj
e ctivefunctio.Th
n ef ollowingd isc
ussion

K
駒'uhn

血 珂u

i
7
-'
油t
u
y∞

c
k
c
e.

o由 t
ω

r'
r 創n
o
n
t

di
i
削Non釘:
陶胸
s佃 dt

s,F
heLa
g
ou
而町r
ran
La



g
砲g
ia
r
a
ni
n
s
g
酔cm机L
t
刷 p
li
附e
r
釘sa
蹴r i
n


陀 川泡n
則I
r
r

assu
R
m
e
e
fe
st
rri
h
a
n
tt
gt
h
ec o
o山es
deh
ol
a
u
sb
tio
ee
no
nru
ft
na
hcc
ndv
as
a
l
ca
u
b
esa
ov
v
e
ai
,t
l
h
ab
l
eo
e.
ptimalv a)uesf or山巴 d esign
dxi=0.6443m.Thisi
佐eU 加 叩
varia
blesa rex j::0.67 73m a n sv eryc loset ot heg ra
phical

}
sol
ution.B eforewec on clude白紙 t hesolut
i onisachieved,takeno teoft h
em ul
tipl
iers:

F(Xs)=6.0559E0
5(f-~) +
x 向=5.2622e-010叩 d向=- 0.
12 70.Ifth em u
ltiplier
sa renega tive,白e nitisnota
minimum.Thev al
ueso f由ec onstr
aintsatt heo ptimalvalueso ft hed e
signa r
e8 2=
s p.
4969E0
5x ∞
,OXr-9.7418E06(x1-xi))+
f+40 -4. 5
55 3e+ 007a nd8 4= ー0.0320.Bothvaluessuggestthatthecons凶 ntsare
ina
ctive.Atl ea
st出es olutioni sf e
a s
ible-al lco ns回 in
tsa r
es atisfi
ed.Thev al
ueo f
1
32(
(50 +1
.∞
4994E05x
l)(
xf+x内+~)ー 1.7083E07(x1-4)) + stiszer oanditisa1soa na ctivecon
臥(
1 l16E-ω ー0.05(x1-4
.9091E-03x.+6.1 )+
s
4(X
2- .
x
+0.001)
(
4.7
9)
198 NONL
lNEARPROGRAMMING
4
.5 EXAMPLES 199

c
onsideredact
ive.百1es o
lution,
however ,vi
olat
岱 t h
es i
decons往aint
s.τ'hegrap
hical ωchi ter
atio
nu sually白egr 叫i en
to fthefuncti
onsatthcc ur
rentvalueoft h
ed e
s ig
n
s
oluti
o ni
sr at
herexp
lici
ti nident
ifyingtheminimuma t出epoin 包e stabl
ishedinthe var
iabl
esisi nvolvedinthecalc
ulat
ions.Thisgradi
ent,exp陀 ss
ed凶 am atrix,i
sca1led
f
ir
stsolut
ion.百1e凶 via
lc aseofthemulti
plierbei
ngz er
owhent hec o
nstra
inti
sa c
tive 出eJ acobi仰 m atrixors impl
yt heJacob
iall.Sophis
ticate
ds cal
ingt ec
hniques[7,8
]
i
sobse rv
cdw ithresp
ecttot hefir
sttwoc onst
rain
ts白紙 e xpr
esss t
res
sr e
lat
ions
.l n employthed iagon
alen 凶e softhi
sm at
r i
xa smetr
icstoscaletherespe
ctivefun
ctions
.
g
eneral,出ct crmsintheseinequ
aliti
esh avelarg
eo rd
ersofmagn itude,es
pecia
llyif Theseen肘ωaree valua
tedatthestart
ingvaluesofthedesignvari
able
s.Th efunction
t
hereareoth巴requa
tions出a texpresscon
strain
tsond ispl
acem
en ts,制芭as,ortheli
ke. canalsobes ca
1edi n山esamemannera sEq ua
tions(4.8
1)and( 4.
82).Fort h
ef ormer
L
argev alue
se x
ertal a
rgei nf
luenceont h
ep roblemsomucha stoc auselowervalue anexpectedl owerandu ppervaluesofthec o
nstr
aintsar
芭n ece
ssary.Inthisexer
c i
sc,
c
onstr
aintstohavelitt
leornos ign
ifi四 nccfor曲 eproblem
.Th isisu s
uallyasevere 出ec onst
raintsw i
llbes c
aledu s
ingr el
ation
ss im
ilartot herela
tionsexpresse
dby
pro
b leminnumerica
li nv
estig
atio
ns.Th eremedyf or白isissc
alin gofthefun
ction
s. 珂u a
lit
ies( 4
.82).Th escalin
gf a
ctorforeachc on
s位回n twillbed etermi
nedu si
ng白E
sta
rti
ngv alueort heini
tia
lg uessfort h
ev ar
iabl
es.A s t
arti
ngv a
lueo f0.6forb oth
desig
nv ar
iablesisselect
edtocompute白ev a
luesn巴cessa
ryf o
rs c
alingthefunc
tions.
Scallng:C onsid
cr出eo rdero fm agn
itudei nE quati
ons( 4
.77 a
) and ( 4
.77c
). Thes c
alingc o
nstantsfortheeq凶凶 onsa r
ec al
culate
d凶
Nume
rica lcalc
ulat
ionsare合 i v
enbyl arge
rm a
gnitud
e s.lneq
uality( 4.
77c)willbe
ig
noredinrelat
iontotheothcrfunct
ionseventhoughthegrap
hicalsolutio
ni n
dicat
es
白紙お isa ct
ive
.百世 sisaf r
equent侃 curr
en田 ina
llkindsofnumeri
ca lt配 hniquω.The g
¥O=293888.
4; g
20=102561
. ; g
12 30
=1万 70E-03; g
40
=1
s
tandardapproachtom i
nim i
z e白 eimpactoflarg
ev a
riati
onsinm agnitudesamong
d
iffe
悶 1tequat
ionsistonormalize出er e
lat
ion
s.Inprac
ticethi
sisalsoe xten
dedt o出e 百1
efi
rs
tth
reec
ons
tra
int
sar
edi
vid
edt
hro
ughbyt
hei
rsc
ali
ngc
ons
tan
ts.Thel
as
t
v
aria
bles.百 isisref
erre
dt oasscalin
gl h
evaria
blesands c
alingthefuncli
ons.Many 珂u
ati
oni
sun
cha
nge
d.百 1
eob
j民 t
ivef
unc
tio
nha
sac
oef
fic
ien
tofo
ne.Thes
cal
ed
c
urren
ts oft
warewi1
1s ca
let h
ep rob
l巴mw itho
utuserinter
vent
ion. p
rob
lemi
s

S伺 lin
gVariab
les:百1eprcs
enccofsid
econs
trai
ntsinpr
oblemfo
rmul
ati
ona l
10ws Minimize 1イ -
4 (
4.8
3)
anat
ura
1dcfi
niti
onofsc
ale
dvari
abJ
es.Theuser
-defi
n e
duppe
randlow
erboundsare
us
edtosca
leeachvar
lab
lebetwe
en0四 d1 .There
fore, 8
.
:2.5509~+0.136lx.-33.148(イ -xj) 壬 O (
4.8
4a)

ふ -X~ I
f2:(
0.
似88+1
.46
19x
¥)イ+x内+ヰ)ー 166.
( (
5641i-x~) ~ 0 (
x 4.8
4b)
え=→--',; x
:=scaledithvariable (
4.8
1a)
Xi-Xi

ヰ-x
:
)+ 1(x1-x~) ~ 0 (
4.8

=
x
X;
(. X: (
4,8
Ib) あ
:1.086
8x.+0
.34
82-28.
464 4c)

I
ntheori
gina
lp ro
blemEquat
ion(4.
81b)isu
sedt
osub
sti
tut
eforth
eorig
ina
lvar
iabl
es C4:X2-XI+0.001~O (
4.8
4d)
a
fte
rwhicht heprobl
emc 叩 beexpre
ssedinte
rmsofsca
ledvar
iab
le.Analtem
ate
f
ormul
ationistouseon1
yt heup
perv a
lueofth
esid
econst
rai
nttosca
1ethcdes
ign 0
.02~ XI~ 1
.0
; 0
.0 ;x2~ 1
25 .0 (
4.7
9)
v
ari
abl
e:

s
i=x
i/4
e (
4.8
2a) Sec4_5_2_scaled.m: The c ode( couldh av
eb ecn par
to fS ec 4
_5_2.m)
in
vesti
gate
st hes cal
e dproblemi n出巴 sameway伽 tt h
eo ri
gina
lp roblemwas
x
j=x
j寓 (
4.8
2b) in
vestig
a凶 .P ri
marily,出isexpl
o i
ts由巳 inf o
rmatio
nfromt h
egraphi
calsoI凶o n.1
tis
expe
cted出品tt hesolutio
nf o
rt h
ed esig
nv aria
b1eswil
lbet hesamca lth
ought h
e
While曲 i
slim
its山巴 h
ighersc
aldva
e 1ueto1,i
tdo
esnotse
t出el owersc
aledvalu
eto mu1ti
pli
erv a
1uesareexpecte
dt obed if
fere
n .
tFromt h
einform
ationin出eWorkspace
zer
o.F r出eexampleo
o f山issect
ion,th
erei
snon e
ces
sityforsca
lingthedesig
n windowt heoptimalvaluesforthed es
ignv ar
iabl
esarex =
i 0 .677
4a ndx =
i 0.6445.
var
iabl
essinc
ethei
rorde
J'ofm
agnitud sone,
ci whichi
sexa
ctlywhatsca
1in
ga t
lempt
s AI
lo f帥 c ons
trai
ntsa r
efeas
ible.Theo ptima
1v a
luesof白emu1ti
plier
sh avechang
ed.
toach
ieve. The問 isnol oogeraz e
rom ultipIie
r-ith astumedp osi
tive
.Th e
reiss t
il
lo ne
mu1tip
lie
rw ithan egativesigni mplyin
gt hep o
inthasn o
tmet白巴 Kuhn- T
u c
ker
Sca
lin
gt h
eC on
strai
nts:Sca
lingoft
hefun
cti
onsin出eprob
lemisu
sua
llycri
tic
al con
ditio
DS.Actually,i
tshouldha vebeenantici
pateds
incechang
ingo flh
es i
gl
lo ft
he
f
orasuc
cess
fulsol
uti
on.Nu
meric
altech
niq
ucsusedino
pti
miz
ati
onarei
ter
ati
ve.In mul
tipli
erisnotp o
ssiblewithscalin
g.
200 NONL
lNEARPROGRAMMING PROBLEMS 2
01

Th er
eiss il
tIt hematte
ro finconsisten
cyb et
w田 nthegra phic
a ls ol
utionandthe 4
.MATLAB
ーDemos S
ymb
oli
cTo
olB
ox-
Int
rod
uct
io.o
n n
lin
ere
sou
rcei
n MATLAB.
dis
sati
sfac
tionoftheKuhn- Tuckerconditi
ons.Explo
ringthisp a
rticularexamplehas M athWork sIn.,
c MA.
beenveryto r
turo
usbuthasp rovid
ed白eo ppor
tunit
ytoexplorei mpor ta
ntbutrela
ted 5
.B u
r den,R.L .andF a
irs,
e J.0.,Numerical刷 物' si
s
.4 t
he d
..PWS_KENTP ub
lish
ing
qua
ntit
iesI ikcs c
alin
g.A n otheri mporta
ntc ons
ider
ationi s 出e s co
pco fthe Company, Bost
on.( 1
989)
Kuhn-Tuckerc o
nditi
ons.Theseconditionsappかonlyatreglllarpoints. 6
.F ox,R.L..OptimiwtionMethodsforElg
I i
neerin
gD e
sig.A
n ddison-W
esley,R
eadig,
n
MA.( 1971)
RegularP oln
ts:Regularp o
ints[8]ari
sewhene q.
uali
tycon
str
ains,h
t (X),ar
e 7
.V飢 d erpl
aats,G.N .,N/lmeri
calO p
timi w
t i
onT ec
hlli
quesforElIgin
eer
ingDes
igl
l.
P陀 s
ent泊 白eprob1e
m .百le
yar芭a1s
oe x
tende
dtoac
tivein
叫回Iitycons住必nts(
pseu
do McGmw- Hi11,NewY or
k.( 1
984)
equa
1itycon
s位剖 n
ts)
.Kuhn-Tuckcrcond
iti
onsar
cv a
lidon1yf
orregu
1arpo
ints
.百 l
e 8
.A ror
,J
a .S.,lntrod
ucti
ontoO p
timaIDes
ig .Mc
n Gmw- H
il, NewY o
rk.(19
89)
twocsscn
tia
1feat
uresofare
gularpo
intX.are .Kuhn,
9 H.W.a n dTuckc,
rA.W., Nonlu
l earProgram
ming.P r
oceedin
gs01th
eS e
cond
Be
r k
el e
ySymposiumonM athem
aticalS t
atis
tic
sa l
ldProbabi/
i
.η,J.Ncyman( c
d.
),

• ThcpointX i
sfe
asi
ble(
sat
isf
ie l
saIc
ons
tra
int
s). Un
i v
crsityofCalifo
rni
aP r
css,195
1.

. Th
cgr
adi
ent
soft
he叫 ua
1i
ty∞n
str
温in
t l
sぉ wcIa
sth
eac
tiv
ein
叫 回l
it
y
c
ons
tra
int
satX.mustf
ormal
in釘 i
e nde
pen
den
tse
tofv
ect
ors
. PROBLEMS

Int h
es ca1edproblemo fExamp1c4. 3t h
cc on
strain
tsgIand8 3a reactiv
e.The (
In many o
fth
epr
obl
ems be
1ow,you a
rer
equ
ire
dtoo
bta
int
hen
ume
ric
al
solutinx
o j=0 .6774andxi=0 .6445i sfeas
ible. The gradien
to fgI is Vg.= s
olu
tion
.)
[-37.631435.454司T.Thegradi
e ntofg2i =
sVg1 [ -34.3
11 930.47
86]T.lta p
pear
s
thatthetwog radi
cntsarca1mos
tp aral
1cltoeachoth巴r
.T hisisalsocvidentinth
e 4.
1 Defin
ctwon onli
nearfu
nct
ion
si ntwovari
abl
es.Findth
cirs
olut
iont
hrou
gh
graphic
als olutio
n. The gradi
e ntst h
erefo
rca ren otI ine
arly indepcndcnt- cont
ourplo
ts.
Kuhn-Tuckcrc o
nditio
nscannotb ca p
pliedatthi
sp oin.
tT hisdoesn otmeant h
e 4.
2 Forthcfunc
tion
si nPr
oblem4.
1o b
tainthegra
die
ntsofthefu
ncti
onandU
I巴
pointisnotal oca
lminimum.Th 巴r巴isgra
phicalevidencethati
tisi ndeedso. Jac
obian
.Confirmthemusi
ngtheSymb
o l
icMathT oo
lbox
.
Kuhn・Tuckera r
et heon1yav ail
ableforma1condit
ionsf orrecogni
tiono fth
e
4.
3 D
efineth
edes
ignspace(cho
osessi
deco
nst
rai
nts
)forat
wo-
var
iablep
roblc
m.
optimum v a1
ues.Iti sunivc
rsa1lya pp
liedw i
thoutr ega
r dtor egu
lariか Some
.
D
cfinetwonon1
in
earf u
ncti
onsintwovar
iab
lesth
atdonothav
eas ol
utio
n
addit
iona1con
sidcrat
ionssh
ouldb ckeptinmind[ 8
].
w
ith
inthi
sspa
ce.Gra
ph i
ca1l
yconf
irmth巴r
csu
l.
t
4
.4 D
efine ades
ignspa
cef o
rat wo
-var
iab1epro
blem.Def
inc two n
onli
nea
r
Ifequa
lityconstr
aint
sa represen
ta nda l
1o f白ei nequa
1it
yc ons釘'
ain
tsare f
unc
tionsi
ntwova
riab
les白紙 h
aveatle
asttwoso
lut
ion
swith
in白es pa
cc.
ina
ctie,出e
v nt hep oin
tss at
isfy
ing 白cKuhn- Tucker condi
tions may be
4.
5 Defin
ean onl
inea
rf u
nctio
no ftwovar
iab
les.Chooseacontourv
alueanddraw
minimum, maximum, orasadd1epont
i .High
cr-orderconditi
onsareneccss
ary
thcco
ntour.Id
cnt
ifyapointonthccont
our.Calc
ulatet
hev a
1ucoftheg
radi
ent
toidc
ntif
yt h
ct y
peofs o
lut
ion.
atth
atpoint
.Drawthegr温die
ntatth
epointusi
ngthecomputedval
ue・Ca
lcul
atc
I
ft hemu1ti
plie
rso ftheactiv
ei neq
u a
1it
yconstr剖ntsar eposi
tiv,t
e hep oi
nt
canno
tb ea10ca
lmaximum.I tmayn otbealocalminimume i
the
r.Ap oin
tmay
由巳 Hess
i回 鉱 山ca bovepoin.
t
bcamaximumi f出巴 mul
tipl
icrofana c
tivci
n叫u alit
yc o
n s
trai
ntiszer
o. 4
.6 U
singth
erel
nti
oninEqua
tion(4
.2),
3 es
tab
lis
h伽 tthegr
adi
enti
sno
rma
ltot
he
t
ang
ent[ap
hysi
calin
ter
pret
ati
onforE
quatio
n(4
.23
)].
4
.7 D
efineano
nli
nearfu
ncti
onof伽 民 va
ria
ble
s.Chooseapoi
ntinth
ed e
sig
n
s
pac
e.Fid出eg
n rad
ientof出巴 f
unc
tionatthep
oin.
tCa1
cul
ateth
eH e
ssia
n
REFERENCES
m
atri
xatt
hesamcpont
i.
1
.Stcn,
i S.K .Calcu
lusandAna
lytic
a lGe
omet
ry.McGmw-H ,
I
i NewY or
k.(19
87) 4
.8 Exp
rcssth
eTayl
orser
iesexpan
sion(qu
adra
tic
)o fth
efunc
tionf
tx) (2-3x+=
2
.Hoste
tle
r ,G.H .,San
tin,M.S
a .,a ndMontnlvo,P.0.,Ana
lyti
cal
.N wn
eri
cal.and
x
2)sinxabou
t由巳 po
intx= 0.7
07.Confirmyourre
sul
tsthrou
ghtheS
y m
bol
ic
C
omputation
alMethodsforSci
enceandEngin
eering.Pre
ntiω-Ha
1I
.E n
glewoodCI
i飽
, MathToo
lbox.P
lottheor
igi
nalfun
ctio
nand出ea p
prox
imati
on.
N
J.(1991) 4.
9 Expandth
efu
nctionf
tx.y)=10(1-x22+(
) y-2
)2qu
adra
tia
c1l
yabou
ttep~int
h
3
.Molcr,C.andCosta.P
.J.,
SymbolicMathToolbox-forωewithMATUB-UsersGuide, (1,
1.Howwi
) l1youdisplaythein
for
mati
on?Drawthec
ont
ourso
ftheo
rig
ina1
Mat
hWor ksInc
..MA. fun
ctio
nandtheappr
oximati
on.
5
202 NONL
lNE
ARPROGRAMMING

4
.10O
btainth
esolut
iongr
aph
ical
lyforthe
c a
sewhenEqu
atio
n(4
.10
)isad
dedto肱
p
roblemdefin
edb yEqua
tion
s( 4.
36),(4.
39,and(
) 4.3
7).O
btain出esol
uti
on
u
sig白eS
n y
mbolicMathToolbo
x.
4
.11O
bta
in白cs
olu
tio
ntot
hco
pti
miz
ati
onp
rob
lemi
nSc
cti
on4.
4.
4us
ingMATLAB.
4
.121
nSe
cti
on4
.51,o
. bta
int
hec
oef
fic
ien
tsf
oraqua
合 凶Cf
i
tto出ep
rob
lem
.
4
.13 Useanexampletoshow白紙 optimumvalue
sfort
hedes
ignva
ria
ble
sdonot
cb甜 ge江 t
heobj
ecti
vef
unct
ionism
ult
ipl
iedbyaco
ns凶t.Prov
ethesamei
fa
co
nstanti
sa d
dedto出efun
ctio
n.
4
.14 Howd o
esscaIi
ngoftheo
bje
ctiv
efunc
tio
naffc
ctth
evalu
cof山em u
lti
plie
rs?
Usca
mu
lti
p
ncxamplct
li
ぽ s?
oi
Checkw
n
f
i
e
t
rt
h
ha
e陀 s
nex
a
u
m
lt
p
.Howd
le
.
oe
sscal
ingt
hecon
str
ain
taffe
ctthe
NUMERICALTECHNIQUE8-
THEONE-DIMENSIONAL
PROBLEM

τ'
heo ne-dim
ensionalu ncon
straincdo pti
mizationp ro
bl emisofteni ntr
o d
uced阻 d
sol
vedn umer
icallyinmostc o
u rse
s山a td eaIwithn ume
ri c
ala n
alysis
Jtechni
ques.It
app
earsi nd
irec
tly,notablyasfi n
dingt h
er ootofan online
are q
ua t
ion,whichi s山e
samea ssat
is今ing山eFOCf o
ra nu nconst
rainedoptimizatio
np roblem.Twoo fthe
pop叫art ech
niquesare白eNewton-Ra p h
sona nd出eb iscct
ionte c
hnique
.τ' e
h y釘 E
int
roducedi nS ect
ion5 .2t op rovide ac omparisonw itht h
em ethodsu sedi n
opt
imizati
on.I ne ngi
neeringd csign 山es i
ngle-v
ariab
leo ptimizati
onp roble mis
prob,l
曲 ya回 vialiy,b
t utone- dimensionaloptimizat
ioni sac r
itic
aIcomponento f
m凶t iva
riab
ledesi伊 a ndisd iscussedinS回凶on5. .M
3 eanwhilet hecIass
icalroot
fin
dingm ethodsi den
tifie
da bo vedon otp la
ya nys ignif
ican
tp artinn umerical
opt
imizatio
nt echniq
uesa stheya rec o
nsideredcomputationa
llye xpensiveandn ot
rob
ustenougho veralargecIas
so fproblems.Ani mportantcon
sidcratio
ninno n
Iinear
des
igno pt
imizat
ionisthatduringtheini
tia
litera
tion
s ,
whenyoua r
et yp
icall
yfaraway
合om白es olu
tion,accuracyc 皿 b c位置d edf orspeed.Int hes
ei tera
tion
sitisa lso
imp
ortanttomovet hr
oughto山cn cxlitcr
atin,
o instca
do ffal
teri
ngat白ec ur
rentone
.
These
.cri
teri
ah a
v e陀 q
ui悶 dthatthco ne
.dimensionaltechniq
uesb esimpleinconcept
asw ella se asil
yi mplem
cnta b
le. Two d iff
erentt echni
ques,t hep olynomial
approx凶lati
onand曲eg oldense c
tion,prov
idep opu
l a
rs upp
ortform ostoptimi
zation
soft
w 訂e.Veryo fte
nt hetwot echniquesarei mpl
em en
te dincombination.The yare
dis
cussedinSection5.2
.

203
204 NUME
円IC
ALT
ECH
NIO
UE5-T
HEO
NE.
OIM
ENS
ION
ALP
ROB
LEM 5
.2 SOLUnONTOT
HEP
ROB
LEM 205

5
.1 PROBLEMDEF
lNITION Thesecon
dsolut
ionisus
efulo
nlyifex
pressi
on(5.3
)isanac
tiv
ec o
nstra
intOth
erwise
th
esolu
tiont
oExample5 1wi
. l
1preva1
i.百lefin
alsolu
tio
nchosenensu
陀 sex
press
ions
I
nordertocon
nectw it
hthed i
scu
ssionslat
er,th
eone-
dime
nsio
n a
lv a
riab
lewil
lbe 5.
( 1
)ー(5.)a
3 resat
isf
ie.Ag
d ra
phic
a li
nves
tigat
ionin山enexts
ectionsho
uldil
lus
tra
te
i
den
tif
iednsαins
te a
do fX o
rXI・Inthefol
1owingch
apte
rs血isisa1s
or e
fer
redton
s th
isfe
atuec
r 1ea
rly
.
t
heonc-
dime
nsionalste
psi
zec o
mpu
t a
tion.

Ex
ample5
.1 Thi
sexamplei
ssi
mil
art
oonei
nCh
apt
er4
: 5
.2 SOLUT
lONTOTHEPROBLEM

Thesol
uti
ont
oExamples5.1佃 d5.1ai
sexaminedgr司p
hic
aII
y.Nex
tthec
1nssi
calr
oot
Minimize f
(α)=(α_1
)2(
α-2)(α-3
) (
5.1
) fi
ndin
gtec加iq
ucsofNewton-Raphsonand山ebisec
tio
nmethodar
epres
ente
d.These
M芭 f
ollow
edbythepoly
nomialapproxi
mati
ona nd山eg o
ldens
ect
ionmcth
od.
S
ubj
ect
to: 0SαS4 (
5.2
)
5
.2.
1 GraphlcalSolutlon
Theproblemdoesnotrepresentanyrealdesign.Itwasconstructedtohavemultiple
loc
al minimums w ithint hea reao finterst
e.E xpression(5.1
)r eprcsentsan Theexamplehasal
readymadei t
sappear
anc
einC ha
p t
er4.Figu閃 5
.1isapl
otofth
e
unconstrninedproblem.Thesideconstraintsac
c ompanyal
1problcmsinthisbookto ob
ject
ivefunct
ioninEx ample5 .I
.1 tals
oinclu
des出cs o
lut
ionωExample5 .1
a.I
f
conveytheideath
attherea r
enotruIyunconstr
ain edproblems
.Sideconstraints
also ex
press
ion( 5
.3)rep
resentsani nc
qua
lityco
nstr
aint,thefea
sibl
er e
gionforone
-
defi
neana cceptabledesignregionforallproblem s
.S ect
ion5.2w i
llexplorethis va
ria
blefunct
ionsi
sq u
ited if
fer
entfromth
et w
o-vruia
bleproblem
sencoun
teredi
n
problemthroughthcvariousmethodsmentionedcari
Ier.

5
.11 ConstralnedOne
. -DlmenslonalProblem

Theo n
lycons~raint t
hatExample5,1
. asin
gle-
vari
abl
eproblem,ca ∞
na,ommodateis ,
i
c
n
o
e
q
n
u
s
ali
回 i
η
con
tAs
n.
s t
i
r
n
a
g
i
le
n
-
.
tFromt
va
riabl
ep
hcp
ro
bl
r
e
e
vi
mc
ou
n
n
sc
no
ha
th
p
t
a
c
v
rthe
rec
e如 何 ua
a
nb
l
it
emo
ycon
st
隠白血 o

ra
int(Ch
a
ncs
pte
u
r4
c
)
h
.
," '
/
J

Inaconst
rnin巴dm ultivar
iabl
eo p
timiza
tionproblemi
twil
lo f
tenbeneces
saryl
o.fi
nd
白es tepsiz
eα such白紙山econs 位置intj
ustbecomesac
tiv
e.Itispo
ssibl
etodefme出巴 3
g
(α)
pro
blem.

{国}回,(司)-

内'h
Example5
.1a
c
ons
tra
lne
dminimum
Minimize f
(α.
)=α ー1
( )2(
α-2)(α-3
) (
5.1
)

S
ubj
ectt
o: g(α
):0
.75
α2-1
.5
αーIS0 5.
( 3
)

OSαS4 (
5.2
)

I
na c
tualappl
icat
ionsi
tismoreiI k
ely出atcxp
ress
ions(5.
1)ー(5.
3)e
sta
bli
shtwo fe絡iþI~ .r~砂舟"
ー1属 .

p
roblemsth
atprovid
edi
ffer
entsol
utio
nsto出cste
psiz
cα.Thefir
sti
s白esolu
tiont
o
-

.
e
xpre
ssion
s( 5
.1)and(5.
2),whichisthesamcasExnmplc5.1
.Thesecondisth
e H J " ' l ι g l o b a l~Inlmum
s
olu
tionto
;
.
. 『ーーーーー unco
nstr
ainedminimum
-
2

g
(α.
):0
.75
α2-1
.5
α ー 1=0
。 0
.5 .6
1 2
a
3
.5 4
5.
( 3
)
OSαS4 (
5.2
) 円g
ure5
.1 G
rap
hic
als
ol
ul
io
n:E
xam
ple5
.1
.
2
06 N
UME
AIC
ALT
ECH
NIQ
UEー
S T
HEO
NE.
OIM
ENS
ION
ALP
AOB
LEM
5
.
2SO
LUT
10NTOT
HEP
AOB
LEM 2
07

:
:
t
z;
;ロ:;立とむねなお品3
21
i2
22
21
1出;

探知
Theaboves e
quen田 isf a
irl
ys tand
ardinitera
tiv
et ech
nique
sf ormanyc la
sse
so f

1FZZ;itmt 品川双山口 p
r
S
l
o
e
ble
m
p1i
s.I
n
di
ta
ca
t
l
e
s
oc
st
a
h
pl
ep
u
r
r
i
e
st
mar
h
ee
yi
f
ss
e
伺 ω
ncef
rco
o
rm
fite
r
o
a
s
to
t
iv
ft
eme
h
et
白o
e
chniq
uest
ds-thes
of
t
ar
o
t
l
i
n
lo
wi
gsol
nt
ut
h
i
i
sb
o
n
ook
.Thi
.
s
i
sani n
it
ia
lg uessp r
ovidedb ytheuser10slar
tthei t
era
tiv
ep r
ocess
.Thei ter
ati
ve
E
xam
ple
5.1 p
roces
sisc o
ntinued10thesolut
ionbycalcu
latin
gc han
gesinthevaria
b le(.

.)
.The
v
alueofth
ev a
riab
leisupdate
d.C onv
ergenceischec
ked.IfEquat
ion(5.
5 )issa
tis
fid,
e
t
henthesolut
ionhasb eenfound.Ifconver
ge n
ceisn o
ta ch
ieved,出叩 t h
eu pd
ated
α事
=2.6484; f*=ー0
.61
95 (
5.4a
) v
alueprovid
esthev alu
et op r
oceedwith出巴 n ex
ti t
era
tio
n.Ofc ourse, .
1αcanb e
Exa
mpl
e5.
1a c
alcu
late
dinmanyw aysandN ewton-R
a p
hsonisjustoneofthewaysωe stabl
ishthe
I c
hangeinthevar
iable
.

α*=2
.52
75; f
.=-0.5815 j
l

(
5.4b
) Calc
ulatlon01Aα (Newton-Raphson):L et αbe t hec urrentvalu
eo ft he
v
ari
able
.Iti
sa s
s u
medtha
tE q
uati
on(5.5
)isnotsati
sfiedat出 isvalueo
fthevar
i a
ble
出e陀 a
( s
onforustoit
er
at
e).Letabeaneighboringvalue.Ideallywewouldlike10
5
.2.
2 Newton-RaphsonTechnique a
chieveconv
ergencea
tthisval
u巴( ev
en邸 wea reawa rei
tr nig
httak
eu sse
v e
ral
i
tcr
ati
ons10ach
ievcconve
r g
巴nc
e).UsingTaylo
r'st heoreme xp a
ndedtothelin
ear
TheN
cwt
on-
Rap
hso
nte
chn
iqu
e,a
lsor
cf
er
rなdt
oasN
cwt
on'
ste
chn
iqe,
u i
sag
rad
ien
t- t
err
nonly,
b
asd剣山nt
c ofi
ndi
ng山cr
ooto
fas
ing
lcn
onl
ine
are
q剛 o
n.R
ootf
ind
ing
おおむlニ
l itU122ZZ;::rh 刷 出ee
qua
ti 。;

川 おa :
;
L ゆ(
α)=c
t(α
dゆ
+似)=中(α)+25Aα=0 (
5.
6)

中(α)=0 (
5.
5)
Aα=一魁旦1=-'坐 c b
(o

,.
)I (
5.7
)
w
her官
ゆ(α)i
sanon
lin
eareq
uati
onintheva
ria
bleα
. 坐 Id
lα│τ
百l
ete
chn
iqu
ehasad
dit
ion
alfea
tur
cs:

・Ithasag回 m
etricu
nde甲inn
ing
. F
orEqua
tion(5
.7)tobceff
cct
ive
,山 egr
adie
nto fth
ef u
nctio
nshoul
dn o
tb ez
cro
.lt
• I
tusωtheTayl
orser
iese
xpand
edi
In
ear
Iy
. i
sa1
soin
evit
abl
e出a tcha
ngesinαwillbela
rgew he
rectisfl
at,
andsmal1whe
rethe
・ I
ti
site
rat
iv
e. s
l
a
v
o
o
p
ei
i
sl
d問 g
a
r
i
o
g
n
e
.F
sw
o
h
rt
er
heN
eth
e
es
w
l
t
o
o
p
n-
ei
R
ss
a
m
p
h
a
s
l
onm
lT
. h
e
i
th
si
odt
sas c
ob
ri
o
ee
u
f
sd
f
c
i
c
s
t
a
d
i
v
v
et
an
h
t
a
ei
g
t
e
eo
ra
ti
f出i
o
nss
smc
h
t
o
h
o
u
l
d
d
.
th
・I a
sth
epr
ope
rtyo
fqu
adr
ati
cco
nve
rge
nce
. F
igu
re5.
2iIu
l st
rat
esth
egeomet
rica
lcons
truc
tionoftbetech
niqu
catthepoi
ntα =3.

Anyi
te
ra
ti
vct
cch
niq
uea
ddr
css
ingE
qua
tio
n(5
.5)c
anb
esu
mma
riz
eda
s Example5.
1 TheNewt
on-
Rap
hso
ntc
chn
iqu
eisa
ppl
iedt
oth
efi
rst
-or
derc
ond
iti
ons
(FOC)o .1
fExample5.
G
enericAlg
oritl
rm(A5
.1)
St
ep1.Assum 巴α

S
tep2.C a
lcul
ate.
1α M
ini
miz
c α
f()=
(α ー1)2
(
α ー2)(α-3
) (
5.
1)
S
tep3.U pd
ata
e =α+. α
1
I
fconverge
d中(()=
δ :0)出e ne
xi
t S
ubj
ectt
o
: 0SαS4 (
5.
2)
I
fnotconver
ged(ゆ(
匂: :0
;
f )白enα ←a
TheFOCis
gotoStep2
pω1
Ii
I 0b
edo
wnl
oad
edf
wmt
h
cwe
bsi
l
e町宮 i
nd
ic
al
edb
ybo
ld
fn
ccs
nn
sse
r
ifI
yp
e.
ω
{叫 =去=判均
中刷 ト
α一l
州 -2
引2


伽釧
)

州彬


似α-

)
3
)+(
似ト
αい
川一
→1
り)向州勺恥 勾
3)
+(十
α
似日一
→り)州α
l rμ
十-
2
(5
.8
)
208 N
UME
RIC
ALT
ECH
NIQ
UES-T
HEO
NE.
OIM
ENS
ION
ALPROBLEM
5
.2S
OLUTlONTOTHEP
ROB
LEM 209
1
0
τ'
hec
odeSe c5_2_2.mr珂ui
resf
iveit
erat
ion
st oco
nverg
et h
ev a
1ueoft
Ito
1
.0E心8(co
nsi
dere
dz e
rohe
re.T悩sva
) Iueof1.0E・08i
sterm
edthecon
verge
nce(
or
stopp
ing)c ri
terio
n.Thca ccc
lerationo fconvergenceo rrat
eo fconvergencet othc
8 solut
ionisf o
r m
allyd e
fincdinmanyd iffe
rentways.Oneo fthcwaysi stomonitorthe
ra
tioo fゆ (α+6α) 1
中( α).Ano thcrisωtrack6α.l na ppl
yinga ndu nders
tanding
numericaIt e
chniquesitisimporta nttodevelopa nins
tinc
ta ndfeelforthenumbers
6
correspondingtovariousfuncti
on s脳 血ei tera
tio
nsp ro
gres
s.Thes peedo r白e q
uality
ofc onvergencecanbeg augedby出es hi
ftint hedccimaIp oi
ntint hequanti
tyo f
int
erestt hr
ought heitera
tio
ns.C o nside
rt hevaIueo ft
Ithrought hef i
vei te
rati
ons
[4.0000,0.8750, 1040,
0. 0.0023, 0.00
00].Defin
itely白ec hangcsin中a ren on
linea
r.
TheNewton-Raphsont e
chniq uecanb edirecUyappliedtoE quat
ion( 5.3
)-after
a
I lth
emeUlodi sdesignedtoo p
era teonthesekindsofproblems.I
tislef
tasa nexe
rcise
for山巴 r 回 d
er.百l ereisav eryi mportantfea
tureo fmosti tcr
ati
vet echn
iquesthat
2 exp!ore m叫 tipl
es olutions-asi s 白ec aseo f Example 5 .1
. Rerun t hec ode
Sec5_Zι2.mw ithas tart
ingvaIueof0 .5f ra
o .
.Afters ixitera
tio
ns,αconvergest o
出ev aIueof1 .0,whichi salocaIminimum.Whe rewouldi terat
ion
sl eadifthesta
rt
。 v
t
a
Iuei
wo-va
s1
ri
a
.
b
l
5?Thesea
ep ro
blem.I
nsw
nat
e
y
r
p
sa
ica
r
Ie
e回 s
ngin
yt
eer
os
i
n
田 g

gd e
si
r
g
ap
np
hi
r
c
a
o
Il
bl
yi
em
nao
,s
igni
n
f
i
e
c
-o
an
te
rmaybea
xp
erience
andi ntu
itio
na rerequiredtor ecognizeUlescsitua
tion
swhen出c yoccur.A h e
althy
S出 picio
no ft h
es o
lutionm ustaIwaysbei ntheb ackofone'smindwhene xp
loring
-2 multi
variablep roblems.I n summary,m ostiterat
iven umericalt e
c hn
iquesa re
0 0
.5 1
.
5 2 2
.5 3 3
.5 4 designedtoc onvergetosolu
tio,1Sthatarec/ose10wheret heystart
from.
α

F
lgu
re5
.2D
eve
lop
men
t01N
ewt
on.
Rap
hso
nte
chn
iqu
e.
5
.2.
3 BisectlonTechnique

ηJeT echnlque:Twoi te
rat
ion
sareshownhere.Thec o
mpleteappli
cati
onisdone Thisisanotherpopulartcch
niquetof in
d曲 目 ∞t ofafuncti
on.I
tisa lsoc a
Iledabinary
th
roughMA11ABcodesecs-2-2.m.Thecodeu sessym
boliccalc
ulatio
n.Inrumino searcho ri n
terva
Iha Ivingp roc
ed u
re.U nli
ket heNewton-Raphson method t h
is
悦 codethefig
urewindowd
ispla
ys印 刷r na
tionoftheit
er
ati削 rave
lω 曲 目 仰60; proceduredoesn ot民 qui
ret heevaIuati
ono f白eg r
adientof曲ef unctionwhoser o
ot
Al
soshowni sthec h
angein6αwithe achi t
era
tio
n. Thei t
era
tiveresu
ltsare i
sb eingsought.Oneo fthereasonsthemethodi sb e
ingi ncl
udedist ocomparei twith
summ
arizcdinat a
bl t山ec
e8 n
d.Theca1
cula
tionsreq
uircthegra
dientof中(α)
: thegoldens c
ctionmethodd iscuss
e dla
tcr
.Then umericaltec
hn i
q uei n山ismethodi s
basedonthe問 おo ning白紙 t her
l
∞t(orzero)ofafunctioni strappedo rboundb etween
ゆ'(α)=2市(α-2)ポ(α-3
)+4
*(αー1
)*
(α ー3
)+4
*(α ー 1)*(α-2
)+2
*(αー1
)^2 apositiveandan e
gativevaIueoft hefunction
.Th ea ctua
Is o
lutiona c
hievedby血E
methodisa nintcr
valinwhich出ez eroorthesolut
i o
nc anbelocat
e d
.Thcf ina
Iinte
r v
al
I
te
rat
ion1
: i
st yp
i回lIyd ctcrminedtobeav crysma Iv
l alu
e,callcdthctolerance, oftheordcrof
lOE-08.S 泊c e出i sisar ootf i
ndingp rocedur,whena
e ppliedtoo ptimi
zationitis
α=3; f(
α)=0.0; ゆ(
α)=4 t
I
'(α)=16 6α=-0.
25 applicdto恥 g ra
dientof批 o t訪問t iv
ewhichwei de
ntific
da sゆ (
α.)Eq u副o n(5.5
).
Establis
hingtheminimumo ftheob j
ectiveisther
e b
yt ran
slat
cdtol ocating曲er ootof
t
I(α+L

.)=0.875-notc
onv
erg
ed,
atl
eas
tan
oth
eri
ter
ati
onn
ecc
ssa
ry 出eg radientf un
ctio
n.I tisp os
siblct od evcl
opab isec
tiont cchniquef ordire
ctly
I
te
rat
ion2
: handlingtheminimizationproblem.
Themethodr 珂uirestwop ointstos t
art,sayαnandαb・Thev aIueo fItat由民E
point
s must b eo ppos
itei ns ig n.
τ' hescc an be t h
es idcc onstrai
ntso ft he
α=
2.7
5; f
(1α
.)=-
0.5
742
; 中
(α.
)=0
.08
75; 帆α
.)=
9.2
5; 却 = ーO
.ω4
6

one-dimensionaIoptimi
zationprob l
em.ltisassumed白紙 a tIcastones ol
utio
ne x
ists
in白 i
si n
iti
凶i nter
val.Duringe achitera
tion,出isinteva
r 1ishaIvedwith出emidpoint
(α+6α)=0.1040
ーno
tco
nve
rgd,
e a
tle
asta
not
hcri
ter
ati
onn
cce
ssa
ry
ofthei n
terv
alr epl
acingcit
her叫 orαb, whilek c
c pi
ngt hcrootst
illt rappc
db ctween
210 N
UME
RIC
ALT
ECH
NIQ
UES-T
HEO
NE-
DIM
ENS
ION
ALP
ROB
LEM
5
.2S
OLU
TIO
NTOT
HEP
ROB
LEM 2
11

a
mct
ionv
alu
eso
fop
pos
ites
ign
.Th
eitemtiveMmiquei
sex
pre
sse
dast
hef
oll
owi
ng
a
Igorithm(
ase
tofp
roc
edu
res白 紙 紅er
epe
ate
d). 5.
2.4 PolynomlalApproxlmatlon

A
lgo
rit
IJm
!orB
ise
cti
onM
etl
lod(
AS.
2) Theme 白odi ssimp
lcinc once pt
.Insteado fminimizingad iff
icu
ltf unc
tiono fone
vari
able,minimizeapolynomial出a tappro xi
matesthefunctio
n.Thco ptimalvaIueof
S
tep1
: Choose叫 a
nd叫 t
ost
artL
. et叫 〈 叫
曲ev ariab
l 巴白紙 m ini
mi z
e sthep olynomialist hcnconsidcredtoa pproximatcthe
S
tep2
:Se
tα=叫 + ( 叫 ー 叫)
12 optim
alv aJucof白ev aria
blef ort
1Jeorigina
If un
ctio
n.Itisr a
ref o
rt1ed
J cgre
eo ft1
Je
S
tep3
:If中(
α.
)=0
.0-ConvergedS
olu
tio
n-e
xit approximatingpolynomia
Jt oe xcecdthrec.A q ua
dratica pp
roximationiss t
a nd
ard
叩 les
s曲e曲i rddegr
eeisw釘 r ante
d.Itisc1eartha
tscriouserro
rsina pprox
imationare
日se If(αb-αn)<l
OE・04-t ol
era
ncemet-e
xit
expectedif出ep oly
nomialist osimulatet h
eb eh
aviorof出eo ri
ginalfuncti
ono vcra
E
lse Ifゆ(α.
)*中(叫)
>0.0;曲 en叫 ← α 釘.
l g
er angeo fvaIu
eso f山 v ar
iabl
e.M a the
maticalt1Jeoremse x
ist白紙 j ustif
ya
Elseαb←α quad
raticr ep
rese
nta
tiono ftJef
1 un
ction, wit
hap rescri
b e
dd egreeofe r
ror,witJi
Ina
got oS
tep2 smaJln eighbor
hoodo ftJem
1 inimum.What山 i sensuresi s 出att1Jepolynomial
approxima
t iongetsbette
ra s白 eminimum i sb ein
ga pproach
叫. E xample5 .
1.
Wec
ons
ide
rExample5
.1whichi
sre
pro
duc
edh
ere repf
吋u cedforconv
eniepce,isu s
edf ri
o I1ustr
atio
no ftheprocedur
e.

Example5.1
Minimize f
{α)=(α_1
)2(
α-2)(α-3
) (
5.1
)
M
ini
miz
e f
(α.)=(α_1
)2(
α-2
)(
α ー3
) (
5.1
)
S
ubj
ectt
o: 0Sα 云4
(
5.2
)
ThcFOCis S
ubj
cctt
o: 0SαS4 (
5.2
)

Aquad
rati
cp o
lyn
om JP
ia (
α)i
sus
edf
ort
hea
ppr
oxi
mat
ion
.Th
isp
oly
nom
iali
s

仰α
(何
仲 e
xpr
essedas
(
5.
8)
P
(α)=bo+bρ+bα2 (
5.9
)
2

S関 5_え.3.m
: This地 孔ABc oder u
nsth
eb i
sec
tionmethodon臥 制p l
e5 .1
.It Twoe lcmentsn田 dt o恥 u nderstoodpriortot Jef
1 ol
1owingd iscus
sion.百l efi
rst
i
I
lust
rat
est
hetrapp
ingof山emullrnumbyth
etwov a
lue
sone it
hers
ideOfthemot. conccms白ee va
luationoftJep
1 olynomi叫.andt Jes
1 econdc on
c erns出ei nc
lusio
no f
百le
陀町宮 1 7ite
rat
ion
sforatole
ranceo .0E・04whicht
f1 e
rmi
nate
dt h
cp r
og r
am. exp陀ssion(5.2)i n出ed is
cussion
.Thcp olynomiaJisc omple telyd e
finedift he
Compa 削 h iswith5i t
cra
ti叩sf ortheNewton-Raphson1削 hod.forab ett
crsoluti
on. co
effi
ciensbo• b
t .,andb 2arcknown.Tod etermine恥 m.t 1Jreed atapoin
ts[ (
α1'/
.),
U 巴l owernumbero fi飽ratJon
sc 佃 be油 凶 t o恥 qu Ji
a t
yo fir由' nnat
ion山 edt o (
α.'!
2 z
).( 3,
α. 1
3)]arcgenerat
edf romEquation(5.
1).Thiss e
tsupai Incarsystemofthree
upd脱 出ed 悶伊 v ariab
lechangcτncg radie
nt-ba
scdi n
forma tio
nu scdint hc equ
ationsin尚昆eunknownsby問 q uiring白紙t1Jeva Jucsoft 1Jef u
nctionandt he
Newton-RaPIEBontEChmquel smoresophist
icate
d.thou
gh出cg radientcomputationis polynom Jm
ia ustb et hesamea tt Jet
1 1
Jrcep o
ints.Th es olutiont otJi
1 ssystemo f
anadditi
onaJw orkload. equ
ationsis山 v alueso ftJcc
1 o
effic
ients
.百 1 巴 co
ns i
derationo fe xpr
ession(5.2
)
T Kprobl emdescrib
edbyE quation(53)cmbeh andl
eddirect
l ybyt hE
bisection dependsont1
Jetypeo fone-dime
nsionaJprobl c
mb eings o
lved.Ift h
eo ne-dimc
nsiona
I
脱 出o d山町( α
.)is恥 same箇中( α
).Inaw町aY.出
th
附e problemisag enuinesingl
e-var
iabledesignp roblem,出e ne xp
r ession(5.2
)n ee
dsto
o
叩pp
卯o削 utザYtωo陀r
ev
判1
附1
路s


附i
tp
比 r
iork nowlcdg
e.p a
rti叫 arl
yw ithres
p 附 ωd efininga nd bep resent
. I f 出e o ne-dime
n s
i na
o I problem i sas ubp r
o blem 台。m 山e
剛 s la
tingana lg
ori伽 i n
toI UD出ngcode.Thereis刷
usu拘 as t
凶rong∞
昭 cor
附re
s
叩po
叩 nd
l
伽 muJt
idimensiona
lo ptimi
zationproblem,t
1Jenexpression(5.2)isn otava
ilabl
e.Inthat
betwecn自es t
cp-by-st
cpdωc ripti
onof出en u
mericaJtec
hniqu
e( t
山healgori
th
白r町

E cωeas canningproccdureisusedtod ef
in巴α 1,的,a ndα3・
白e∞
山 c
o也de 白伽a
ωtw illi mplement 出e 蜘 p sω e ff
ectas o
lution( f
ore x ampl
e.

:
2
f
o
2
t
l
i
t
l
o
-
B
w
;
l
n
日E
P;
52
11
11
:Z
Z2
20
:よ2
2L
gtwomethodsa
t
J
r
b
eu
r
eば
s
edex
ten
sivel
yfo
ron
edi
men
sio
nalmi凶m
iza
tio
n.They
ScannlngProcedure:百 l
ofz
erofor出isvaJu
e叩 b
ep
ej
us
r
t
i
民 間 i

fie
dsi
ss
nc
t
ei
a
rt
tr
e
e
df
fe
r
ro
st
m恥 l
ova
Jue
owri
e Im
s鉱 山 c
itf
ur
o
r
r
e
α
n
.Ava
titer
at
Ju
i
on
e
.
Acons
tantin
tcrv
alforα,6
.αisalsoid
ent
ifi
ed.Forawel1-
scale
dp roblemt1
Jsva
i Iue
h
and
lcthem
inim
izationpro
blemd
ire
ctl
y.
i
susual
1y1.Sta
rtin
gatt1
Jelowri
e Imit
,曲。i nt
crva
Iisdoubl
edu n
tiltl
Jrep
e oi
ntsare
.
5
.2S
OLU
T¥O
NTOT
HEP
ROB
LEM 213
212 N
UME
R¥C
ALT
ECH
N¥Q
UES
-TH
EON
E.O
¥ME
NS¥
ONA
LPR
OBL
EM


dete
nnine
ds
Example5,
1
.t
u
ch出a
es
h c
a
tt
nn
i
h
n
eminimumi sb rac
gproceduregenerat
ke
t
回 t
e
h
db
ef
o
e
l
t
w
l
e
o
w
e
i
nt
n
gv
h
e
a
l
m
u
.Wi白 r
e
s:
esp
ectt
o


1
0


α=0
;j )=6
{O ; α
¥=0; /
¥=6 ,
.

α=1
;j{
l)=0 ; ん=0
; 同 =1 B ,

α=2
;j )=0
(2 ; t
hi
sca
nno
tbe円 ωtheminimumi
sn0
1ye
t回 pped


; 円=
4; 2=18
/ ,

t

a
α=4
;j(
4)=1
8


Ap rocesssuchasth
atil
lus
tr
at巴disess
enti
alsSitisbothind
iffe
ren
ttothep r
oble
m


b
p
r
ei
o
c
ngs o
l
凶 si
ve
st
dandc
oe n
s
anbeprogrammed伺 s
u白 山attheminimuml
il
y
i
e
.Thei
sbetwe
m
p
e
orta
n出eI
n
tr
i
e
m
q
i
t
ui
se
re
m
s
t
e
a
n
b
l
to
is
fanys
he
dbyt
uc
h
h
e ,

dasMA ,
p
roce
Th
du
r
es
e.百l
e
to
isp
fiI
r
n
e
o
a
c
ed
re
u
q
r
ei
u
at
sd
io
e
n
v
st
elo
oe
p
e
stabI
isht
T
I
h
.Bm-
A
ecoef
f
i
f
i
)eU
cie
n
pperBound_1Var.m.
tsoft h
ep ol
ynomiali
n ,

Equation(5.
9)is 2 ,


6= +b¥(O)+b2(0) (
5.1
08) , r

bo

0
:::bo+b¥(
l)+b2(
l) (
5.l
Ob)

1
8=bo+b
¥()+b
4 (
216
) (
5.l
Oc) 。 0
.5 1
.5
α
2 3 3
.5 4

UsingMA
TI.AB出esoh
瓜ont
o白ee
qua
tio
nsi
s R
gur
e53p
. o
lyn
omi
ala
ppr
o必ma
1io
n.

h
o=6
.0;b
¥=-9; b2=3 5.
(11)
∞dedevelopmenti
ste
rme
dab
loc
kst
ruc
tur
eda
ppr
oac
h-I
nth
isw
ay-
lar
g巴c
ode
a
ndt
hep
oly
nom
iali
s d
eve
lop
men
tisp
oss
ibl
eus
mgs
mal
ler
pie
ceso
fex
ist
ingc
ode
.

P
(α.}=6-9α+3α2 upperBound1Var.m:Thiscodcsegmenti
mple
men
t s山edetc
nni
nat
ionof山e
upperboundoilhE
凶onofonev
ari
able
.Theinp
utt
othefu
nct
ioni
sth
e附 ncofthc
Theminimumf
ort
hep
oly
nom
iali
sth
eso
lut
iont
o


dP
=-9+6α=0; α:=α・
0 α r
=1
.5
器問:思議議部先制抗告。部
oE q cotZ 詑Z3;42;;;22dEmusthaM 山 Bm-f
i)e,
in白esamed
ire
cto
ry

t
ZT
ft
U3
23
1:
;:
;Z
?5
51
2-
百ICa
ppr
oxi
mat
esolu
tio
nt uatio
n(5.
1)is1.
5.Fi
gu陀 5.
3dωcribest
hepoly
nomia
l
ap
pr
Ont
o
xi
h
m
at
eo
i
o
t
np
he
ro
ced
ure
rhand,
.l
i
ti
ft
sc
h
l
e
ed
a
a
r出a
t
nf
tt
o
h
ea
rth
p
p
ep
r
o
o
l
y
x
im
n
a
o
m
t
i
i
a
o
nl
lc
e
o
a
e
v
e
f
f
smucht
icie
ntsw
obed
er
e
ea
s
r
i
r
o
e
u
d
.
ndas m
all
er
おおむ tw
hic
hth
cfu
nct
ion

regi
onnearα=2 .6,then出巴 re
sult
swouldbemorei mpr
essiv
e.Note出a tra
山町出m
5.
(12
)
p
uscah i
gher-ord
erp oly
nomial,abett
erse
tofd at
aisp児島町吋. U
sag
e: upperBound_1Var('EXam le5_1',
0,1,
10)
Thes c a
nningprocedureand出ep ol
yn om
iala p
proximati
ontechni
queswillfi
nd
si
gnifi
cantu s
ee xp
l o
ringmultidim
ensio
na lopt
imizat
ionproble
ms.Th es位置tegyfo
r cod巴 se
gment i mpl
ements 白e po
lyno
mial
devcl
opingMATLABc odcfromnowonmusti nc
lude出ep o
ssib
ili
tyofcodereus
e.百le PolyApprox_1Var.m: 羽li
s
fun
ct i
ono f one v
ari
abl巴
・ Th
isfu
nct
ionu s
cs
samec odesegmentscanbeusedinmanyd i仔ere
ntnumeri
caltech
niqu
es.Suchgener
ic app
roxim
ation method f
ora
J
I
l'

5
.
2SO
LUT
IONT
OTH
EPR
OBL
EM 2
15
2
14 N
UME
AIC
ALT
ECH
NIQ
UE5-T
HEO
NE.
OIM
ENS
ION
ALP
AOB
LEM

UpperBound_1Var.mt od eten
ninether an
geo f出ev a
ria
ble
.Th einputto白e αup←α/:
2;
向← α1;12←A
fun
ctio
ni sthenameo fthefunct
ion;theo r
der( 2o r3)o ftheappr
o xi
mation
; α1=(1-'
t)
ao
!w+ταゆ ;
/1=
/(α
.)
lowbound-the sta
rtv alu
co ft h
es canp as
sedt o UpperBound_1Var.m;
in
tvl
stpー 恥 s
e c
anningint
erva
lp asse
dt oUpperBound_1V ar.m;in町ia
ls一郎
;
ri+1
GoToS
tep3

i
s
numberofs cann
ings t
epsp a
ssedtoUpperBound_1Var.m.Theo utputof出e

出iZ
progra
misav e
ctoroftwovalu
es.Thefir
steleme
nto fthev e
ctori
stheloc
ationofth
e

昔話器鴻!日
minimumo ftheappro
ximatin
gp oly
nomial,andthes econdisthefun
ctionvaluea
t
th
isloc
ati
on.
Thefunct
ion陀 fe
r e
ncedby出ec od
em ustbeaMA Bm・f
TI.A i
le,i
nthesamedire
ctor
y
(Examp 抱5_1.m).百1 einputforExample5_1ist hev alueatwhichthef un
ctio
n
nee
dstobec om
p u
ted.andit
so utp
utisthevalu
eo fthef un
cti
on. o
nlyc
alふlateふevalues.Thealgo仙 mi
sim
ple
men
tedi
nad
iff
ere
ntf
i
le
.

U
sag
c:Value PolyApprox_1Var('Example5_1',
2,0,
1,1
0)5.
( 13
) ExampleS.l
Mi
nim
ize /(α)=(α_1
)2(
α-2
)(α
-3) (
5.
1)
Thetw
oprog
r a
msus巴出eswit
ch/
casean
dthe/
evals
tat
emen
tsf
romM
ATL
AB.T
he
cod
eal
s Iu
oi
l s町at
esc
all
inga
ndretum
ingfro
mot
her釦nct
ion
s.
G
oldenS
ect ionMethod
5
.2.
5 GoldenS
ect
ionMethod
S
t叩 1 =
.(1.10" o.
o;lo
w 6;=
αuP=4;!"'=1
8
L¥<X
j!n
o
l=0.00
1;E=(0
.00
1 1
4);N=17
T
h巴m ethodofgol
densec
tioni
sthcc rcamofthef
amil
yofinte
rva
l問 duci
ngmethods
(
forexa
mple.出eb i
sec
tio
nm et
hod).Itreduc
es出ei n
ter
valbythcsamefra
cti
onwith S
te .5
p2.α.=1 2
79;
/.=0
.19
37;向 =2.
472
1;1
2=ー0
.54
01
e
achite
rat
ion
.Thei n
ter
val
s釘 ederivedfromthegol
densec
lionra
tio
.1.618
03.This
r
ati
ohassigni
fic
ane泊 a
c 巴st
het
icsaswellasmathe
matic
s[3,4
].Themethodi
ss i
mple F
1gure
5・4i
lu
1 st
rat
est
h巴lay
outofinf
orm
ati
ona
tthissta
ge.
Itc
anbCVErind山a
t
t
oi mp
le m
en.
tItisind
iff
ere
ntto出es ha
pea ndco
nti
nuit
yp r
oper
tie
so f血efunct
ion α
..α
2arelo
cat
edsymm巴町i
ca
llyw
i t
hmspe
cttoo
ute
rb o
undsdO嶋
田,"
p.
b
eingminimiz
ed.Mosti m
portan
,t L
hen umberofit
era
tio
nstoachie
veap res
αibed
t
oler
ancecanbcest
abl
ishe
db e
foreLheiter
ati
onss
ta
rt
. S
tep3
.i=1
/
1>1
2
A
lgori
thmf
orGold
enSec
tio
llMethod(
AS.
3) (
1l
.o .5
lV=1 2
79;
low=0.
193
7;叫 =2.
472
1;.=-0.
/ 540
1
S
tep1.Cho
oseαlo
wα叩, 2=3
α .05
57;
12=0
.24
86
τ=0
.3819
7(fro
mG old
enRati
o), i=2
e=t
ole
ran
ce=(L
¥α)
Ona
l/(α
up_
αlow
) S
tep3
.co
ntin
ued
...
N=numbero
fite
rat
ion
s=- 2
.078lne 1
2>1
3
a
.up=3
.05
57;戸 =
0.2
486
;α2=2.
472
1;五=-0
.54
01
Sωp2.α1=(1- τ
)αlo w+τ
α叩 ;fl=/(α
1) 1=2
α .11
15;
12=ー0
.12
24
di掴j調jY35233器:

向 =τr i +(lー τ
OW
) P
α,U ;
f2= 爪句) i=3
τncp o
intsar
ee q凶dista
ntfrombo
und
s GoToS
tep3e
tc
St
ep3.If(i<N)
If/I>/2
Inea
chitcr
ati
onL
hereison
lyone制 ofc
al叩lat
io
ntoev山a胸
a 中evariableand伽
va
lueofth
ef u
nctio
n.There
stof
thECom
putauo
ntsmas
SIgn
snge
xts
tin
gi nfo
rmat
Ion
.
α10"←α .;α1←α 2;i←1
f 2 Thedi
ffe
rcn
回凶臨o u
町 b omdsisa
lsoch
ang
ingwi
the
achkmuon-hExmpleal
~=τα,Iow +(1-τ)α叫ん=/(向)
i←i +1
S
ta
rt
: L
¥α=4.0
GoToS tep3
I
fh>
/. I
ter
ati
on1
: L
¥α=4
.0-1
.52
79=2.
472
1
2
16 N
UME
AIC
ALT
ECH
NIQ
UES-T
HEO
NE.
DIM
ENS
ION
ALP
AOB
LEM 5
.
3IM
POA
TAN
CEO
FTH
EON
E.D
IME
NSI
ONA
LPA
OBL
EM 2
17
2
0
v
ectoroffou
rpair
so fvaria
bleandfunc
tionvalu
esaft
erthefi
nalit
era
ti
on.Witha
1
8
s
malltole
ran
ce剖 yoneofl h
esepa
irspr
ovide
s出巴 minimuml o
cat
ionofth
efunct
ion
.
I
tisr eco
mmended山att hesecon
dp a
irbea cc
essedfo
rthi
sp u中os
e.百1 efunc
tio
n
1
8 r
eferen
cedb ythec o
dem ustb e a MATLAB m-f
ile,int h
es a
med i悶 c
tor
y
(E
x ample5_
1.m).Thei npu
lforExample5_1.mi sth
evaluea
lw h
ichthefunc
tio
n
1
4 n
eedstobecomputed,andit
soutp
utistheval
ueofthefun
cti
on.

1
2 '
t U阻 .
g
e:

1
0 Value 'ExampleS_1',
GoldSection_1Var( 0.001,
0,1,
10)(
5.1
4)
'
{6}h

E
8
The
rearenonewco m
mands.Thco r
gani
zin
ganddisp
lay
ingofinf
orm
atio
ninth
e
Commandwindowiswort
hn o
tin
g.Ifth
isco
deisp
artofala
rge
rp r
ogra
m,出叩 th
e
pr
int
ingofin
for
mat
ioninthecommandwindowne
edstobeswit
chedo
ff
.Itc叩 b
e
6 a
加medo nfo
rdeb
uggi
ng.
4
'J
Compar/sonw lthPolynom/alApproxlmatlon:Thet wopopul
arm ethodsfor
2
miniou
z ingaf unctio
no fo nevariab
lea rep o
lynom
iala ppro
ximati
ono rg olde
n
。 s s
s
e
c
i
g
t
n
i
i
o
n
f
i
.Thea
cantdif
l
g
f
e
o
r
r
e
i
n
l
c
e
h
s
msforp
.Thef
o
o
l
r
y
m
n
e
oo
u
ri
ala
sao
pp
n
e
r
-
o
s
x
h
i
m
o
at
ta
i
p
o
na
pr
oa
n
c
d由巳 g
ha n
o
di
ld
sa
e
c
ns
co
e
m
c
p
t
a
i
o
n
nh
ie
a
db
v
y
e

si
gnif
icanter
rorintheestima
tionoftheminimum, whichwil
li m
proveasthedatafor

αup
-
2
-
1 2 3 4 5
appro
xi ma
tiongetbett
er.Implie
dint h
ei mpleme
ntati
ono fth
ep o
lynomialapproach
α i
sthec ont
inu
ityo f白ef un
ctio
n.Theg oldensecti
onmethod,ontheothe
rh and,i
s佃
F
lgu
r由5
.4G
old
en5
ec
tl
on-s
tar
ti
ngv
al
ua
s. it
erat
ivetech
nique
.Then umberofite
ratio
nsdependson出e to
leran
c巴expectedin血e
fi
nl隠 s
a ultandisknownp ri
orto出巴 st
artoftheiter
atio
n s
-asig
nif
i伺 n
ti mprovement
re
lati
vet otheNew lon-Raph
s onmetho dwhere山巴 n umberofiter
ati
onsc a
nnotb e
I
ter
ati
on2
: dα=3
.05
5 .5
7-15279=1 2
78 pr
edictedapr
ior
i.Thei mplement
ationissimpleandth
eresul
tsimpr
essiveasi
tisable
tohomeinon曲巴 oun 回1 u
m.Itisind
iffere
nttothenat
ureofthefunc
tio
n.
Thereisn oreasonwhyt het wocannotbec ombined.τbegolde
ns ect
ioncanb e
usedtoesta
blis
hf ourdat
ap o
intswithar e
asonabl
etole
ranc in
e( st
eadofal owvalue
)
Thef
in
ali
ter
ati
oni
sre
pro
duc
edb
yru
nni
ngt
hef
oll
owi
ngc
ode
: andac ubi
cp ol
y n
o o
ualc a
nb efi
t10identi
fytheapprox
i m
ateloca
tio
no fminimu m
.

i
ter
ati
on1
7
2.63
95 2
.639
9 2.
640
2 2.6
406 5
.3 IMPORTANCEOFTHEONE-DIMENSIONALPROBLEM
-
0.619
7 -0.61
97 -0.
619
7 -
0.6
197
百1
巴 o
ne-dim
ensio
nals ubpr
oblemin am ul
tiva
riab
leo pt
imiz
a t
ionp rob
lemis
百l
elo
ler
anc
eα2一α
Iint
hef
in
ali
ter
ati
oni
sab
out0
.00
1ase
xpe
cle
d. e
mployedfor白ed ete
rmin
atio
no fth
es t
eps
izeaf
terthcse
archdirec
tio
nh a
sb e
en
i
den
tif
ied
.Iti
se a
sie
r10undc
rstan
dthes
el e
rmsbyrecog
nizi
ngthegener
icalg仙 m
o
GoldSec
tion_
1Va
r.m
: Thec odcl叩 s
r l
at
es白ealgor
ith
mforth
egold
ens田tio
n f
oruncons
trai
n吋 o p
tio
uza
tion
.I norde
rt ofoc
ust h
ed i
scus
sion,rat
hertha
n白e
m 白od(A5.
3)i
n川弘TLABcode.Theinput10t
hef
unc
tio
nis出enameo
fthcf
unc
tio
n g
ener
alobjc
ctiv
efunct
ionrep
res
enta
tin,
o aspe
cif
icone,Exampl
e5 .2,
isint
rod
uce
d.
俳tnCt
nam )w
e h
oseminimumi sbein
gs o
ught
;曲et ol
cra
nce(t
ol)o
ft heap
pro
xim
a ti
on;
te平
h 蹴 value( l
仰o
叫w und)o
b側o f白恥es釘c叩 p
仰a e
叫dt
鎚蹴 ω
oU仰 pp
仰er
市B叫
ound_1V町ar
口.
m
n

宵m

官1
;出肱巴 Example5.2
s
鈴c
a
朗nmn
略g i
加n
te
飽rv叫(ω
t
u仰 1)pa
お5
5
鉛e

吋dtωoUp
仰perBou
叩md_1V町ar
'
口.m;
the
白 聞mu
m
叩帥E
l・ )=(
x 2+2{~ -x3)2+3(x
lーら) (
5.1
5)
蹴 p
戸s
ρ仰仰
1巾旬 p
1 蹴叫 t oUpperBound_1V町 . m.Theo ut
putof恥 p ro
gramis; M
ini
miz
e f
(x X2'X
3 3- 1
)2
218 219


NUMERICALTECHNIQUE5-
THEONE-DIMENSIONALPROBLEM 5
.4 AODITIONALEXAMPLES

Ac 山富orygl
anceatExample5.2in
dic
ate
s曲a tth
esol
utioni
satxl=l;x2=I;X3=1
;
andtheminimumv a
lueoffsO
i .Threeva
ria
blesar
echosenbec
ausewear芭no
tgoin
g (
5.1
6)
touseanygr
aphic
sf ori
llu
str
ati
on(
iti
sesse
nti
altofoll
owthevect
ora
lge
bra
). Xl=lL│

a
nds
oon
.
GenerlcAlgorlthm(A5.4
):Theg ene
ricalgor
ithmisanite
rat
iveoneandi
sa l
so
r
efe
r聡d toωas ea
rchal
gori
thm
.astheite
rat
ion
stak巴pla
cebymovinga l
ongasea
rch
d
irec
tio
n.Thesesear
chdi
rec
tio
nscanbedeterm
inedinsev
era
lways( Cha
pter6
).The
5
.4 ADDITIONALEXAMPLES
al
gorit
hmwithou
tanyconve
rgenc
elst
oppingcr
ite
riaca
nb eex
pressedas
h 山i ssecti
ona dd
itio
nale xamplesofs in
gle-
varia
bleo ptim
izatio
np roblemsa rc
S
tep1
.ChooseXo exp
lored
.Thea v
ailab
lec odeforthepolynomi
ala pproximat
iona ndgoldens e
ction
S
tep2
.Fo
rea
chi
ter
ati
oni shoul
dh el
ps ol
vea nyandallsingle
-va
riab
leo p
timiza
t i
o nprobl
ems.Thisisl a
rgel
y
le
fttotheread
ertoexploi.
tInth
iss e
cti
ono n
lye x
tensions,mo
dificat
ions,orcre
ative
D
eterm
inese
archdi
rec
tio
nSJv
ect
or
appI
icat
ionso ftheo ne
-dimensiona
lo pti
mizat
ionp rob le
ma r芭 con
sidered
.F irs
t,
S
tep3
.Calc
ulaes
t X;=αjSj
Example5.2isrevi
site
dtom od
if ythegol
densectio
nmethods o出atitcanbeu sedto
N
ot:s
e X;i
snowaf
unc
tio
noft
hes
cal
arc
ja
l sS
jisknownfromS
tep2 四lcula
te由巳 S旬 ps
izeinmultidi
me n
siona
lp ro
blems.Example5. 3isas ol
utiontothe
ji
c
l sc
all
edt
hes
teps
izea
site
sta
bli
she
sth
ele
ngt
hofsX
j Blas
siusproblem.百 li
sisa ne xampleoft h
ee xac
ts olutio
nt o白eN avier
・Stokes
珂u at
ionforflowo v
eraf la
tplat
c.Example5. 4isane xaminatio
no ftheinequ
ality

j1=X/+sXi con
stra
intinExamplc5 .laby t hegoldens e
ction methods ot h
ate qu
alitya nd
的i
sde
ter
min
edbyM
ini
miz
ingF
(Xi
+l
) ine
quali
tyconst
rain
tsc a
nb ehandled
.
百Iisi
sre
fer
redt
oaso
ne-
dim
巴ns
ion
als
teps
izec
omp
uta
tio
n
i←i+1
;00ToS
tep2 5
.41 Ex
. I
l
ample5.2- l
ust
rat
lonofGeneralGoldenSectlonMethod

A
ppl
ica
lin0
o /GenericA駒 市hm(A5.4)ωEXIlITlp
le5
.2 τ
'ee
h x
amp
lef
rom血ep
rev
iou
sse
cti
oni
svi
sit
eda
gai
ntom
odi
fy出eg
old
ens
ect
ion
methodtod 巴tcrmi
ne白es te
psi
zef o
rm ulti
dimensi
onalproblem.百 isbookisals
o

…~[g}印刷 a
i
d
b

e
o
nd
v
u
e
e
tg
v
l
e
o
e
l
p
t
t
o
m
i
p
e
n
i
n
n
gMATLABt
gt
tw
hec
i
t
o
hr
d
e
sp
oworkf
c白紙 w
ec
i
tt
l
o
ls
ry
e
o出ep
o
ec
u
o
o
.I
n
l
s
i
y
nas
d
n
e
o
r
m
i
c
a
b
a
n
l
se出 ss
eu
la
s
p
ei
pr
u
nt
ox
i
b
h
m
se
en
at
c
t
e
i
i
x
o
oni
tc
sl
h
ap
a
t
e
r
r
ge
lyane
.An明 u
nmethodislef
x
i
e
r
v
ta
c
a
l
i
e
sa
s
e
n
n
t

exerci
seforthestud
en.
t
d川引J引
F1111111L=

τ

'
heg oldc
ns ecti
on method requi
rest h
ee stab
lishme
nto ft h
eu ppe
rb ound
.
-
x
-
drllML
n

-
t
p

n α ,.
-a

10
er

M
,,‘、・・・

・凶+
山 、 引 川 円 引J

t
ヲ-司

τ

guAU

grill-L

n9uw
et
ι﹄ 苛

..
蹴ト

rJ

e,twof swil
1n
U11111111

巴r e
for un
ction e edtob echangedtohandledcsig
nv e
cto
rsa n
dt h
e
LzrE
-一﹁

'
h

a
陪 1Ill1
四=
='J

eb
叫副


内u

V且

n
u
-n a

10 α
enr

searchdirec
tionvect
ors.Thec odeisa va
ilabl
eぉ UpperBound_nVar.m加 d
MMM

.006.

EBEBEE--EEEJ
x

GoldSectlon_nVar.m.Them odif
icatio
nsa renOlv er
yc hal
lengi
nga ndcanbe
E -'EEEEEL

inferr
edbyc omp
aringt h
eusageof山etwof un
ctio
ns.
3

Forthesin
glevar
iable
:

f(X1
)=f
(α1
)=(
0-0
)2+2
(0-6
α1)
2+3
(6α
1一 1
)2=72αl+3(6αJ-1
)2 U
sag
e 'Example5_1',
:UpperBound_1Var( 0,1, 5.
10) (12)

F
ormanyv
ari
abl
es:
M
inimi
zingj{α1
),出cva
lueo
fα1=0
.1.T
hisi
sao
ne-
dim
ens
ion
al
o
pti
miza
tio
np r
oble
m.
U腿 ge:UpperBound_nVar('Example5_2',
x,s,
O,l工
,0 5.
) (17
)
Whilethesol
utio
nabov
ewasobt
aineda
nal
ytic
all
yb e
causei
twasas i
mplel
ine
ar x: current position vector or design vector
e
xp陀 ssi
on,出ep ol
ynom
ialap
pro
ximat
ionorthegold
ens e
cti
onmethodcou
ldhave
b
eenu se
dins巴a
t d. s
: prescribed search direction
220 N
UME
RIC
ALT
ECH
NIO
UE5--T
HEO
NE-
DIM
ENS
ION
ALP
ROB
LEM 5
.4 A
DDI
TIO
NALE
XAM
PLE
S 2
21

Ofc o
urse,Example 5_2.mr etu
mst hevalu巴of出ef u
nctio
nc orre
spondi
ngt oa MathematlcalFormulatlon
ve
ctorofdesignva
riab
les.百lisimp
lies白紙 thefunct
ionca
lltoExample5_2.mc an
on
lyt ak
ep lac
巴a f
terthedesignvaria
blesareeval
uatedfrom出ev al
ueo fste
psiz
e
"+2f"=
f
f 0 (
5.2
0)
ap
pliedalong山ep re
scribe
ds e
archdi陀 c
tio
nf ro
mt h
ecurren
tlocati
onof出ed esig
n.
Theu sageofG oldS
ec t
ion_nVar.mmustaccommodatef unct
ion(5.17)and出e x=O; f
(O= 0
) ; f(O)=O (
5.2
1a)
needtodea
lw ithadesig
nv ec
tor
.Comparingw iththesi
ngle
-vari
ablecase
x=∞ f( }=1
回 (
5.2
1b)
U蝿 g
e:
Th
eso
lut
ion,
non
dim
ens
ion
alv
elo
cit
yint
heb
oun
dar
yla
ye,
riso
bta
ine
das
Value GoldSection_1Var('Example5_1',
0.001,
0,1,
10)
(
5.1
4)
U皿 g
e: ず=f(x) (
5.2
2)

Value GoldSection_nVar('Example5_2',
0.001,
x,s,
0,1,
10) Thes ol
utio
nt oE qua
tions(5.20
)t o( 5
.21)isl ar
gelyth r
o ughspe
cialiter
ativ
e
(
5.1
8) te
chniq
ucs. These tec
hniq
uesu se an umer
icali nte
gra
tionp r
oced
ure li~巴出e
V
isi
t血巴 c
odetos
巴巴 thed
巴 凶1
5
. Runge
-Kuttamethodt oint
egr
atethesystembyg u
essinganda djus
tin
gt h
em iss
ing
boun
daryconditio
nsatthein
iia
t1p oi
ntsuch白紙 t h
ef i
nalpo
i ntbounda
ryc o
nditio
ns
Compar/sonw
/thS
ect
lon5
.3:Thec
odeGoldSectlon_nVar.mwasr
unf
rom aer
r ea1i
ze.Thi
d sisdueto出ef a
cttha
ttheinte
gra
tionprocedu陀 susu
all
ys o
lveini
tia
l
山eCommandwindowu
sin
gth
efol
1owingl
is
ti
ng
: va
lueproblemso n
ly.IntheBlass
iusproblem,出 i
swouldi mpl yth
em i
ssingini
tia
l
va
luecanber egar
dedぉ adesignvar
iab
le.
>>x [
000] ;
>>S [0 0 6]; ('(0)=α (
5.2
3)
>> GoldSection_nVar('Example5_2',
0.001,
x,s,
0,1,
10) Theo
bje
cti
vef
unc
tio
nth
ere
for
ewi
llbe
A
fte
r11i
ter
ati
onst
hef
ina
lJin
eint
heCommandwindowwas M
ini
miz
e: ザ(∞)一 1
)2 (
5.2
4)

ans CI Im
pli
edi
nth
efo
rmu
lat
ioni
s伽 l
f(∞)i
sob
tai
nedbyi
nte
gra
tin
gth
edi他 r
en
ti
al叫 u
ati
ons
0.1000 1.2000 o o0.5973 (
5.2)(
0 山ωec anb ec ons
ideredasd i
ffe
ren
tia
lc ons釘'a
in臼).百l e
reiso neoth
cr
c
onsi
derat
iontotakeintoaccount
.百lein
tegr
atio
nm et
h odsrequ
irethe戸ublemtobc
Th
eab
ovei
sin
ter
pre
teda
s: e
xpress
edins t
at
es pa目 form,whichr珂凶問叩 n 山-ordぽ di
ffe
ren
tia1珂uat
ion10be
e
xpre鎚edasas yst
emo fn白百 l-
ordc
r叫 u
ati
ons.百 l
econversi
onisfai
rl
ysta
ndarda
ndis
α
1=0
.10
00; f(α
1)=1
.2 ∞ x1=0; A
2=0.0; x3=0.5973 (
5.1
9) don
et h
roughu溜lSfo
rmatio
na ndinu叫uci
ngaddit
ion
alv 組 曲les
.F o
rthi
sexam
ple:
whichm
atc
hesS
ect
ion5.
3adEq
n u
ati
on(
5.1
6).

y =f
5
.42 Ex
. .3-
ample5 Two-PolntBoundaryValueProblem
y~ =f=Y2
Ar ea
1exampleforone-v
ariab
leo p
timizati
onc anbefoundin出en umer
icalsolut
ion
ofthelamin
arf l
owo ve
raf l
atplat
e[ 5
].百 leproblem,usua
llyattr
ibu
t巳dtoB l
assis,
u
Y;=f
'=Y3
re
p r
esen
tsanexampleoftheexactsolu
tionoftheformid
ableNavier-Sto
kescquat
ion. Y;=f"=ず'/2
百lem ath
emati
calfom lUla
tin,
o allowingforsimil
arit
ys olu
tios,
n i
se xp陀ssedbya
th
i r
d-or
dern o
nlinearordina
ryd iffe
ren
tia1e qua
tionw i
thb o u
ndaryc ondit
ions
Th
eop
tim
iza
tio
nca
nbef
orm
ula
tedぉ:F
indα
sp配 i
fie
da ttwop oi脳 -at wo-poi
ntb oundaryv aleproblemσPBVP). Wh
u at
f
o l
Iowsisth
eessent
ia1math
ematicaldes
cripti
on.百leinte悶 tedreade
rc a
nf ol
lowthe M
ini
miz
e: [
Y2
(∞)
ー lf (
5.2
5)
d
etail
sinmostbooksonf lui
dm e
c h
a n
ics,inc1ud
ing出巴 su g
gestedref
e問 nce
.
u
sin
gth
eRu
nge
-Ku
ttamethod(
or叩 yo
the
rme
tho
d)t
oin
teg
ral
e
222 N
UME
RIC
ALT
ECH
NIQ
UE8-T
HEO
NE.
DIM
ENS
ION
ALP
ROB
LEM 5
.4A
DDIT
lON
ALE
XAM
PLE
S 223

r
-

fwlw
-
i
r
JI11111J
-

o
-
仰い同﹄

n
(
) 1BEEt-EEEBEEEEJ
-
-EEEEEEEE﹃EEE


Ther e
sulte xpectedisα=0. 3320
6.However,t h
et ole
rances
peci
fie
dwaso nl
y

o
vn

rEE E -E E -EL

可EEEEEEaEEEEEJ
UJUJgJI
-


-
令 , . 帽3

a
(
5.2
6)

α
(
)U4η
I
0.001
. The i nit
ial bounding in
terv
al was onl
y 0.4
. Th egold
ens ec
tio
nh a
s



l
r


' (
)
-
produceda ni mpressiv
es olu
tionto山eTPBVP.A lson o
tetheconv
enienceof

v

vi
v

d3
AU


EJ


modular pl'Og
rummin g. No changes we陀 madet o UpperBound_1Var.m or


GoldSectlon_1Var.mt orunth
isexa
rnpl
e.
Frompublis
hedwork[5Jthevalu
eo α・
f =0.33206.Insleadof出e白nalpointat∞ i
t
i
sconsid
ered10be5..Le
0 avin
g白i svaluea
sav aria
blec andef
ineac o
rrespond
ing
tw
o-va
riabl
eo pt
imi
zatio
np ro
blem.In山ei mplemen
tatio ntofo
llow,出epower叩 d 5
.43 Example5
. .4-
RootFindlngwithGoldenSectlon
con
venien
ceo fMA Ba
1LA r
芭r ead
ilyappa
rent
Thea
ppli
catio
nofthegol
dens
ecti
onmethodtothero
otfin
dingproblemi
simp
ort
ant
t
oaccommodatecq
uali
tyandin
equ
ali
tycons
trai
nts.Con
siderExample5.
4:
Example5_3.m: Thism-f
ilei Is
sl edtoimplementexpr
ession(5.
25)
.Itcall
st h
e
MATLABbui
lt-
infuncti
onode451 0uset h
eRunge ・Ku
tta4 /
5o rdermetho
d.The

g )
:0.
75α,
2_1
.5
α ー 1=0 (
5.2
7)
fun
cti
onode45req
uire
st h
esta
teequati
onstob eav
aila
bleinanothe
rm-fi
le.Ita
1so
E叫uir
es出edef
ini
tionofth
eint
erva
lofinte
grat
ionaswel
lastheini
ti
alcon
diti
on.The 0$α$4 (
5.2
)
fol
lowi
ngli
nefromthecod巴dc
scrib
estheusage(曲ecodeiswelIcommentedtoo)
明i
sis白ei
neq
ual
ityc
ons
回 i
nto
fEx
arn
ple5
.lae
xce
pt伽 ti
tist
ran
sfo
rme
dtoa
n
[t y ] ode45('Ex5 3 state',
tintval,
bcinit); e
qualit
yc onstm
i tI
n. n血i
sformt heαne
cessarytomakeitint
oana c
tiveco
nstr
ain
l
c
a nbeestabl
ishe
d.Th es
imple
stwaytoa cco
mplishth
isi
stoconv
erttheproble
mto
ti
sth
ein
dep
end
enlv
ari
abl
ean
dyt
hed
epe
nde
ntv
ect
or. am in
imizationp r
oblemforwhi 抽 出en umer
icaltech
niqu
esh av
ea lre
adyb ce
n
c
stabl
ishe
d.S qua
ringEquat
ion(5.2
7)ensu
rcstha
ttheminimumvalu
ewouldb ezer
o
(
ifitex
ist
s).There
foreth
esoluti
on10Equa
tion(5.2
7)ist
hesameas
Ex
5_3_state.m: Thes
tat
eeq
uat
ion
sin(
5.2
6)a
rea
vai
lab
lei
n出i
sfi
le
.
M出m
iz: 月α
e ):[
0.7
5a2- 1
.5α-1]2 (
5.2
8)
stst [ y(
2) ,y(3) ー0.5*y(1)*y(3)]';
whichcanbehandldbyGoldSection_1Var.m.Wh
e il
e山iswasquickandpain
les
s
R
efe
rt ol
hecod
eford
eta
ils
.GoldSectlon_1Var.mi
sus
edf
romt
hecommandl
ine there
ar官 someatte
nda
ntp ro
blemsusi
ngthisapp
roach
.目隠し t h
en o
nlin回 r
it
yh a
s
f
or白isprob
lemas inc
reas
ed.Thisisusua
llynotencou
ragedinnumer
icalin
vcs
tig
ati
ons
.S econd,th
e
numberofsolu
tio
nshassat
isfy
ingFOCincr
ease
d.Figu
re5.
5rep陀sen
tsthefunc
tion
s
inEquat
ions(5.
27)and(5
.28)
.
U岨 g
e: GoldSection_1Var('Example5_3',
0.001,
0,0.1,
10)
Sol
utlonUslngGoldSection_1Var.m:Thef ollowi
ngd is
cussi
onisb asedo n
S
tar
tit
era
tio
n: t
heexperi
enceofa tt
emptingtor u
nt h
cg o
ldens e
ctionmethodw i
ththelowerbound
a
tthev a
lueo f0,白ec asewi t
h出eo thc
re xamp
l e
s.The 問 isap roblemsincethe
start s
olu
tioncannotbef ou
nd.Th ep roblemapp回 r
st obeint h
ec a
1cul
atio
no fth
eu pper
alphal(low) alpha(工) alpha(2) alpha(up) 司
' b
ound.lnmanyo ft h
enu m
e r
icalt e
chniqu
est h
ereisana s
sumption白attheobjec
tive
o 0.1528 0.2472 0.4000 f
unct
ionbeingdea1twithis山首modal,出a tis,hasas in
gleminimumi ntheregionof
1.0000 0.1904 0.0378 0.0161 i
ate
res.F
t ort h
ist ohappen.itisassumed白a t血ef u
nctionbeingminimizedwi1l
a
lwaysdecrea
sef romthel owerbound
.Takeal ookat山ef unct
ionfinFigur
e5 .
5.It
Thef
ina
lit
era
tio
n: si
i ncre
asingatthcva1ueofz e
ro.UpperBound_1Var.ma ssumestha
t白ei n
iia
t1
i
nte
rva
1ist o
ol a
rgeandc onti
n u
estobisec
tittofinda釦n ctionva
1ue白紙 isless曲a n
iteration 12 "
4 t
heoneatthel o
wcrb ound.Thisdrive
st h
ei n
terva
Itoz e
roandt h
ef un
ctio
nise x
ited
alphal(low) alpha(l) alpha(2) alpha(up) w
iththelowerbounda ndw ithnosolut
ion
.
0.3359 0.3364 0.3367 0.3371
0.0000 0.0000 0.0000 0.0000 Remedy1: Theeas
ies
twayouto
fthedi
ffi
cul
tyi
stocha
ngctheva
lueofth
el o
wer
bounda
ndt
ryagai
n.Iti
sus
efu
ltound
crs
tandth
at山巴 p
roble
miswi
ththeca
lcu
lati
on
P
ROB
LEM
S 225
224 N
UME
RIC
ALT
ECH
NIQ
UE T
5- H
EON
E-D
IME
NSI
ONA
LPR
OBL
EM

1
8 U岨 g
e:GoldSection_1Var('Example5_4',0.001,0,.
1,20)

-
E
--
-e
-
start

-a・
1
6 alpha(l) alpha(2) alpha(up)

alphal(low)


'
2.6000

a
1.6069

-
0.9931

-a・
0.0289


1
4 2.1720


3.0624

・a
1.0000

-
-
iteration 16

'
-'
o
alpha(up)

-
alpha(2)

J-Mhe-e
1
2 alphal(low) alpha(l)
2.5270 2.5273 2.5278

a
2.5266

--
0.0000 0.0000

v
1
0 0.0000 0.0000
(
δ


}て

.••

s'p-
t
(HM)

'--e
REFERENCES

ゐふ,ふ
1
.Burd
en, R
.L,a
. ndF
air
es,J
.D .,N
umer
ica
lAnal
ysi
s.4thed
.,PWS_KENTPu b
lis
hin
g
Company,Bost
on,1
989
.
4 s
olu
tlo
n 2
.Hos
lel
ler,G・H..samina-M.s..andMonta
IOU-p.D.,A
nal
yti
cal
,N w
nericd
,仰d
c
ompu
tation
alMeth
odshrscienc
eandEng
inee
ring,
prmti
cc-H
all-E
nslew
oodCl
if
fs
.
2
g 3
.V
N
J.


1991
.
1
酬・ G
.N.
.Nu
抑 制 O
pli
l仰 1
101T
1 e
clm
iq附 f
orE
ngi
nee
rin
gDe
sig
ll,
M cGr
aw-Hill,NewY ork
.1 98
4.
4
.H u
ntlc
y.H .E.
, T heD l
vIl
leP r
opo
rli
on:A Slud
yi nMut
hem
ali
:
ralBea
ut.D
y o
ver
Publ
icau
ons,NewY or
k.1 9
70.
0
.5 2
.
5 3 3
.5 4 5
.S ch
lich
ung.H.,Boundaη-LayrThe
e or
y,McGraw-Hi
U.NcwYo氏1 9
79.

F
lgu
re5
.5E
xam
pl自5
.4
.
PROBLEMS
o
ft h
eu pp
erbound( bra
cket
ingtheminimum)ra山ert h
anw it
h出巴 g old
ens e
cti
on 5
.1 E
xte
ndExample5.
1toi
ncl
udctwoi
neq
ual
ityc
ons
tra
int
sfo
rwh
ichas
olu
tio
n
m
ethod.Changingthelowerboundto1andr erun
ningth巴goldensect
ionme 出od ex
ists-D
ispla
y白 f ω
鵬ul(
p
rovid
esas u
cce
ssfu
l陀 sul
twhichmatch
es出eg rap
hicalsol
uti
on.Whilesucc
esswas 5.
2 ExtendExample丘5
引.
1toi nc
Iudetwo加
in叫 u
al
叫it
ycon
stra
intsf
orwhich由
t
her
l巴1
凶sno
r
eal
ize
d.suchapr田 edur
en ee
dsuserin
tcr
venti
onωwella ssomeknowledgea bo
ut
so
luti
on.Displa
yt h
ef unctio
ngrap
hica
11y
.
t
h巴problcm-inthi
sc a
sether
ewas出eg raph
icalsol
utio
n_Thesearenotacce
ptab
le
q
ualiti
ωforanauto
maticpro低l
c ur
e.
5.
3 Reprogram白ec odeSec5_2_2.mωobtain出ev alueso,
ff,
中 andc
't
t hr
o u
gh
MA
'τ1.ABfun
ctionprogra m
s回 dapplytoExample5.1
.
Remedy2
problem
.i
:S
tsh
i
o
o
u
c
l
et
db
h
ep
epos
o
s
i
s
b
i
t
l
iv
et
es
os
l
e
o
n
p
s
ea
eth
tt
i
sp
h
o
el
sit
o
i
v
we
es
rbouodi
ig
n01t h
si
es l
o
n
p
d
ic
ea
ati
veo ft
ndmovet
h
h
e
e
5・
4 間2
2J;
;二1
3記念品2
22
:l
::
:Z
34
7tユ設計 t

lowerboundt ot h
ep ointwheret heslope isn eg
ativ. Such ap
e ointcanbe 5
.5 Id
entif
yt hevalueofαwhere山ec on
str泊nt(5.)b巴comesa
3 c
tiv
eusin
g由巳
disc
overedbyt h
esam 巴scanningproced
ure.Thcs lopecomputationi
sn umer
ical Ncwton-Raphsootechni
que.
andisbasedonforwardfi
rs
td i
ffere
nce.Onccmorc出i schangeinthelowerbound 5
.6 Implemcntab is
ectio
np rocedu
reforth
er n
inimi
zati
ono f山ef
unc
tio
nofo n
c
i
so nlyneededfortheuppcrboundc a
lculat
ion.UpperBound_m1Var.mi sthe var
iabl
e.Applyittos ol
veExample5.1
.
modifiedupperboundcalcul
ationwhichr elo
catesthelow~r boundtot h
ep oi
nt 5.
7 Forthepolynor
nia1appr d
Ol m
ationimp
lementa
tion,cxt
end出ccod
etodis
play
where theslopeisn ega
tive. The usage and informa
tion from runningthe 出eo ri
gina
lf un
c凶o n加 d出ea pp
rox
imati
ngp o
lynomial
.
GoldSectlon_1Var.mi nco
rporat
ingt hechaogedu pperboundc al
culat
iooare
shownb elow
.Thesamcu sagewitht hcoldUpperBound_1Var.md oesoot
5
.8 F
or出cg o
lde
ns e
cti
oni
mplcm
ent
ati
on,ex
tendt
hecodct
odi
spl
ayt
heo
rig
ina
l
produceanyusef
ulrcsu
lts
. f
unc
tio
nandthcana
lex
ter
nalbo
undsonth
evar
iab
le.
226 NUMERICALTECHNIQUE5-
THEONE.DIMENSIONALPROBLEM

6
5
.9 Veriちr出a
t白eb
oun
dsont
hev
ari
abl
ear
ede
cre
asi
ngby曲esamer
at
io
.Wh
yis
t
hi
sbe
tte
r白a
nth
ebi
sec
tio
nmethod?
5
.10 Howwouldyous
etupthegolde
nse
cti
onmethodt
ode
t巴r
min
etez
h e
roof出巴
fu
nct
ioni
nst
eado
ftheminimum.
5
.11 Combine出eg
old
ens e
cti
on叩 d由ep
oly
nom
iala
ppr
oxi
mat
iont
ofi
ndt
he
mmimumof出efu
nct
ion
.
5
.12 Imp
rov
巴thea
ccu
rac
yoft
hes
olu
tio
ntot
heB
I蹴 i
us叫 蜘1o
vert
hatp
res
ent
ed
i
nthet
ex.
t
5
.13O
bta
in th
es o
luti
ont ot
heB
las
siu
s 巴q
uat
lOn usmg t
hep
oly
nom
ial
NUMERICALTECHNIQUES
a
ppr
oxi
mat
ionme
thod.
FORUNCONSTRAINED
OPTIMIZATION

Thischapterilu
I s住atesmanyn umerica
1t echnique
sf o
rm uJt
ivariableu n
co n
straine
d
opti
mizat
ion.Whileu ncon s
trainedop 出 血a tio
ni sn otacommono c
cu r
renc巴in
engi
neeringdesign,neve
rth e
lessthenumeri ca
1techniquesincIudedh eredemonstrat
e
in
tere
s駐屯 i de
asanda lsoca p
turesomeo ftheearl
yi ntens
iveworki n出ea reaofdesig
n
opti
mi四 tio
n[1].Th eyaIsoprovidethemeanst osolveconstrainedproblemsa f
terthe
y
havebeent ransf
o r
medi n
toa nu n
constrai
ne done(indirec
tm巴出o d
sーC hapter7).
Thisbooki su niquefort hepres
entati
ono fno n
gra die
ntt echniques(Section6.2
)
which canb eempowered by t heu biq
ui to
usa vailab
ilityo fi n
cr芭dibled eskto
p
computingp o
wer.U ntilv eryrecen
tly.applicat
iono fd esignop t
imizationr e
quire
d
mainframec o
m pu
t er
st hatrelie
donl argep rogramsw r
itteninFORTRAN.T oday'
s
deskt
opc anrunpr ograms白 atreq凶reonlyIimitedprogrammings k
ills
.Thed e
sirefor
globa
Io pt
i m
izationh asb roughtintof o
cu snumeri ca
It echniques也a ta rel ar
gel
y
heu
rist
ic,havelimitednee dforsoph
istic
atedg r
adient-basedmeth ods,requ
i r
elimite
d
programming skiHs. and r eq
uirel i
mited programming r esource
s.U suallys uc
h
tech
niquesr e
quire白紙 t h esoluti
ons paceb es can nedu s
in gal a
rgenumbero f
it
erat
ion
s.Th esemeth odsc anide
allyberunonp ersona
Id esktopsforunlimitedtime
.
Thep r
essぼ巴 ofl im
itedc omputingresourc
e sisnol o n
geras ignif
icantconstra
inton
the
set e
chnique
s.Whilet heymaycompromiseone l eg
anceands oph
isticati
on,iti
s
impor
tantt or ecog
nize出巴 o pportun
ityt oe ngaged es
kt o
pr e s
ourcesf org re
ate
r
use
fulne
ss.

6
.1 PROBLEMDEF1NITION

Theunco
ns町ain
edo
pti
miza
tio
nprob
lemre
qui
reson
l ytheo
bje
cti
vefun
cti
on.The
bookh
aschos
entoe
mphas
izeana
ccomp
anyin
gsetofsi
deco
nst
rai
ntst
ores
tr
ict出巴
227
228 AlTECHNIQUESFOAUNCONSTRAINEDOPTIMIZATION
NUMERIC
6
.
1 PAOBLEMOE円NI
lON 2
T 29
sol
utio
nt o祖 acceptab
leぬ i伊 叩a ce
l隠gi
on.Mostn ume
rica
l附 加i qu白 in出 S
chap
tEragpo白 血e副 ?∞ns回 intsinI叩 ngout恥 method.I t包isu
削s
釦u拘
剖I
d勿y白恥
附 P
仰on
附s凶
討i
bJi

i
町t
yぱ0f
th

恥1
e由
砲 de叩町 t ω
ov町的
er 恥t
h
恥e討d
也cc
副 o

叩n
附lIIn
tsaspa
rto
fhisexpl
orat
io
e
n
of出巴 op
timum.百 ischeck
ingof白csi
de∞n s甘副ntcanbeea
sil
yprog
r a
mm e
dinthe
c
ode.Thus,t
heprob l
emfor出isch
apt
ercanbedefin
edas

'j﹄
引J刊川川目﹄円阿川巾TIl!ll 冶
M
ini
miz
e f(X); 医]"
(
6.
1)


'lli

ι唯44whHM山川川印川仰l'I削
S
ubj
ect
to: x
f$;XI$;x
r
; i
=1,
2,• • • ,
n
(
6.
2)

t
a
-
-
6
.1.
1 Examp'e6
.1

巴r
;;2312::zz;222Z2;2JZem p
oss
ibl
e押 h
ica
Jde
scr
ipt
ior

M
ini
miz ・
e f(X)=f(xl X2)=3+(XI- 1
.52
xl2+(X2_ 2
)2 (
6.3
)
S
ubj
ectt
o
: OSX(S5; OSx2S5
(
6.4
)
0
.5 1
.5 2 2
.5 3 3
.5 4 4
.5 5
F
igu
re6
.1p
rov
ide
sth
eco
nto
urso
f出ep
rob
lema
nd出巴 l
uti
onc
anb
elo
cat
eda
t
f
J
e
)

ぷ ふadratic
X
1
iZL2;arvalueisf=3百 叩 蜘n 吋 h
eso
lut
ion
F
lgu
ro6
.
1Ex
amp
le6
.1
.

6
.1.
2 NecessaryandS
uff
lcl
entCondltlons
TheHessia
nisposi
tiv
ed ef
ini
tecon
side
ringthedeten凶nan
tsa l
one
.Sec6_1_1.m'

2
;江t
rz
z;
::
2j
r2

s 江;t
t
:!
s
Z立 pro
vid
es血E∞d eforth
es y
mboli
ccal
cul
atio
na n
dalsodi
spla
ys白巴 g百phi
回ld白cr
ipt
ion

c
ond
iti
ons
)ar
忠之
e白創出eg
ra
;
:
d
l
?

e

n
tsm
ustv
ani
sha
tth
eso
lut
ion
ωthep
sa
tis
fa
r
c
t
o
i
b
o
l
e
no
m.Ther
fth
e
s
eSOCi
u
lt
d
so
en
t
f白ec
if
ie
al
cul
at
s血脱出巴 s
i
ona
o
lu
r
t
cd
i
o
i
nf
s
p
o
la
rt
y
e
h
di
ed
nt
e
si
h
g
ecommandw
nisam ini
mu
i
m
.
n
dow.百le

6
.1.
3 Elementso
faNumerlcalTechnlque
21=2(Xt-15
ら)=0 (
6.5
a)
τ
'
hee
lem
ent
sofat
yp
i回1num
師 団1t
ech
niq
uco
ral
gor
ith
m,c
anbca
sso
cia
tedw
itht
he
ま叩糾 1句)+2
(X )=
2-2 0 (
6.5
b)
g
o
e
n
n
e
e
r
-
d
i
i
ca
men
s
匂o
io
r
n
i
a
伽ni
1op白n
n位。d
i
zat
u
i
c
o
e
nf
dd
orm
u
u
r
l
i
n
t
i
g 血e d
varia
bl
i
ep
s
r
c
o
b
u
s
l
s
e
i
m
ono
s( C
ft
hap
t
er
h
町 5)
elev
.唄usa
anc
eo
lg
or
ft
it
h
h
mi
e
s
it
era
ti
veandisalsore
fer
redtoa
sas ea
rchalgo
rit
lv
,nastheiter
ati
onsta
keplacebymoving
叫ons(6.5)c叩 beωvedt
Equ oob
tai
nxj=3x
i=2
.Thi
sma
tch
e・
s出eg
rap
h凶 alo
ngasearc
hd irec
tio
noras e
archvect
ordurin
ganite
rati
on.Thωes 国 民h d
irec
tio
nscan

器2
ilj
itM
223 別 :
品官官民法i
C tぉ ;sz
bedetem
p
a
r
i
l
g
m
o
a
r
i
r
il
血m,
山.
ydi
f
e
e
f
x
di
e
nmanyw
r泊 howt
伺 ptfo
a
h
y

r血巴 c
s
cs
o
.Th
e
n
a
r
v
e
c
rg
ed
hd
e
i
r
n
i
f

c
c
f

J
e
r
民 t
s
e
i
o
t
o
nt臨 h
ni
p
s
p
i
ω
n
t
n
a
b
gc
i
l
r
i
q
u
i
t
e
s
h
e
r
s白a
e
i
d

a
ta
.百 l
a
ret
rep隠s

e問 m
hes
a
a
i
n
m
e
n
i
t
n
ef
edi
ge
o
nt
l
e
ra
m
l
h
i
e
m
sc
n
o
t
h
so
s
ta
ap
t
ft
l
e
h
lo
r
e
f
th
em et
hods.Thea Jgori
t h
mc a
nb eexpr
凶l sc
dasfoll
ows.


=ドニl (
6.6
)
I
Fi
le
sl
Obed
own
lon
dedr
ro
mIh
cwe
bsi胞 n
r
ein
di
ca
le
dbyb
ol
dr
ac
eso
nss
e
ri
rIy
p
e.
マHil ﹄
6,
2 N
UME
RIC
A.T
I E
CHN
IOU
E O
ら-N N
GAA
OIE
NTMETHOOS 2
31
230 N
UME
RIC
AlT
ECH
NIO
UESFO
円UN
CON
STR
AIN
EOO
PTI
MIZ
ATI
ON

GeneralAlgorithm伺a η A句orlt
hm:RandomWalk( A6.
2) 、
S
te .ChooseXoN(numbero
p1 fi
ter
atl
ons
)
Stp1
e . Ch∞seXo ・
Stc
p2.F oreachi
ter
ati
oni Se
ti=1
Det
erminese
archdi
rect
ionvec
tor8j S
tep2
.F ore
achit
era
tio
nI
(
ltwouldbenic
eiftheobj
ect
ivedec
r e
ase
dal
ongt
hi
sdi
rec
tio
n)
=
81 Randomvecto
r

S
tcp3
.Calc
ula
tesX, =αsi S
tep3
.Xj+ 1=Xj+α,S
j
N
ote: aX ji
snowafun
cti
onofthes
caIa
r<<
jasSi ,
sknownfromS
tep2
α'
jisde
term
inedbym
ini
miz
ingj
{Xi+I
)

的iscl
a1e
d出es te
psi
zeasitω
tab
lish
es出el en
gthofAXj i←
ーi +1
αji
sd巴term
inedbyMinimizing
f(丸山 whcreX '+ =
I Xj+企X1 l <N00ToS
fi tep2
Here,t
heconv
e r
gcncecri
ter
ia(FOC/SOC),andthesto
ppi
ngcri
tcr
ia(
Is e
lscSωP(
iωr
ati
onse
xce
ede
d)

おs
zz
:;
12
rz
::
;;むれは也事i
de
signcha
nging?Ex
ce e
dingite
rat
ionco
unt?etc
.)mustbech
eck
ed.
i←i
+1; E
Z22
22z
te
l
o
nt
ne
-
h
d
i
sc
im
h
e
a
n
s
p
i
OoToS

t
o
e
r
n
,t
a
t

h
i
lo
e

p
t
p2

sa
i
l
m
i
g
z
o
r
a
i
t
t
i
hmi
cs
nwi
o l
t
ruc
tur
ew il
lb eus
1beimplementedu
c
s
df
i
n
o
gt
ra
h
Ilo
egol
ft
de
h
ns
em
e
c
e
t
t
i
o
ho
d
nm
s.
e
t
τ'
bo
d
e
h
.
圃 l
;
説話器忠告部諜誌記f
s
ignb
a

s
:
e
;
訪問
donat
es
tofrandomn
umb
er.
Example6.1wil
¥beusedtodcvelo
pthcdiff
ercntnu
meric
alm e
thods.
RandomWalk・
m:Tlmrandomwalka
lgo
rit
hmtA62)is i
mpi
eme
ntc
dint
his

6
. s-N
2 NUMERICALTECHNIQUE ONGRAOIENTMETHOOS

τ'
hesemethodsareaJsocaJldz
e e r
o-ord
erm et
hods.τ'heorde
rrefcr
sto山eo rdcrofth
c 1
'
der
ivati
veo ftheobjcc
tivefunctin,n
o ecdedt oesta
blis
ht h
es e
archdirec
tiondurin
g
anyitera
tio
n.Ze roorders i
gni
fiestha
tnod eriv
ative
s制官 u sed[2],whichi ntum
imp
lies白紙 o n
lyf unc
tionv a
luesareu sedto巴S 泊bli
shtbes e
archvecto
r.T herei
s I~唱

anoth
er i mporta
nt s ig
n i
ficanc
e t h
at a ccompanies t b
e m issing deriv
ativ
e
computation-the FOCs houldn otbea pplie
di nt he
sem ethods.Ifwc were
OP6miadon-TMcodeoft
herandomwalkf
unc
tio
nal
soi
ncl
ude
sth
Efo
llo
win
g
computingderiv
ativc
swem ightaswellinc
¥udet h
isinform
ationforest
abli
shingth
e
sear
chv e
ctor
.Onlyt hech a
ngesin白 eo b
j e
ctivcfunc
tionorthedesignvar
iable
sc a
n
prov
id巴 conve
rgence四d/o rstoppin
gcrit
eria
. 出 ec
ontourofthcobj
ecti
vei
sdraw
n .
羽 田 et cc
hniquesareinclu
dedinthissect
ion.Thef i
rs
tisaheuri
sticonebasedon
• Fortwo
-varia
bleproblemstn
• Fortwov
回 a
riablEpr
o bl
e m
st hesuc
cessf
uliter
ati
onsMetra
ckedonthec
ontou
r
randoms e
archdire
ctio
ns.Thes ccondonec yc
lest h
roughasearchdir
ccti
onbasedon
eachvarla
blc.百l elastisP ow
cll'smethodw hichh astbcpropert
yo fq u
adratic dt h
eiter
ati
on"numberi d
ent
ifi
ed.
conve
rgence. .2;:u16vm 油 附d…“…削仲間1 0的 C叩 刊 記df or
th
eone-
dimensi
onals t
epsizecom
putatio
n.


. Themu
ltiva
riab
leup 戸 rboundcalcu
latio
n( d
evelop
edi
nchaptcr5
)isuse
dfor
6
.2.
1 RandomWalk

Ez
: r
1
;
z;
;
,~・t

Thesear
chdir
ectio
nduri
ngeachite
rat
ioni
sarandomd i
rec
tio
n.Randomnumbersand .;
口?
コ江
::
;泣:

広:
2: 1
i I
n
1山 h
ere 出伽
0
… 即 凶 帥hd
叫di
ω
i

吋曲枇
I1
泊e

回cr

.
:

::
二 エ
;
:

肉悶

se
tsofrandomnumbersareusu
al勿avai1a
blethroug
hsoftw
are.MATLABincl
ude
sthe
ab凶tyt og ene
rates e
verJt
a ypcso f random numbers and matr
ice
s. Most i:: e L制 i
gnv
ari
abl
esand山 c
tio
nsf
ora
llo
f
comp
uter-g
enerat
edrandomnumbersar
唱c a
lldp
e seudorandomnumbersasth
eycyc
le
t
hci
tcr
ati
onsa
rcp
rin
ted
.
af
terasuff
jci
entnumberofthemhav 巴beencrea
ted.Theone吋dim
ensio
nalstc
psi
ze
compu
tationi
sdoncbyt cGoldSectlon_nVar.m向 n
h cti
on( C
hapter5
).
i1j
1J
Lii
6
.2N
UME
RIC
ALT
ECH
NIO
UES-N
ONG
RAD
IEN
TMETHODS 233

ll
232 N
UME
RIC
AlT
ECH
NIO
UESF
ORUNCONST
RAlNEDo
pnM
IZA
TIO
N

l i--
Useofpr
eviou
sc o
deiI
Ius町at
escoder
euseandm
odula
rp ro
grammi
ng.Oncemore 3.0804 2.0350 3.0020
r
伺 de
rsar宅str
ong
lyencour
ag e
d10vis
itth
ec o
detoun
derst
andth
巴 位ans
lat
iono
fthe 3.0804 2.0350 3.0020
Jg
a o
ril
Jlmandsubs
equen
tapplic
ati
on. 3.0804 2.0350 3.0020


3.0804 2.0350 3.0020 も 20 iterations
U掴 g
e: ans

3.0804 2.0350 3.0020
Z
RandomWalk('Example6_1', [0.5 0.5],
20,
0.001,
0,1,
20) (
6.7
) .~

Compare 自 問 v aIuωto 山e a ct
ual叫 u tiono fx i=3, xi=2,j*=3 .T出 sis
Inpu
t:(
The
yar
eth
巴it
cmse
ncl
ose
dwi
thi
nth
eou
ter
mos
tpa
ren
the
sisi
nex
pre
ssi
on remark且h
leforamethod出a thasnos ens
eo fpref
erreddirec
tio
n.Iftheexecut
ion15
(
6.7
).) a resatedwithMe n
uca l
i npu
t,me ntimnewsolu
tionwillbeobtaine
d.Figure6
2tracks
th;伽 I gesofthed叫 nv a
ri枇 so ntheco脚 lfp lot
.Themovem 巴ntofi
li
e血 sign
'Examp
le6
_1・
: 百lCfieEx
l ampl e6_1.mw herelleo
J b
jectiv
eisdesc
rib
ed 賞 varia
blesarep air
edw itht hecorzespon
dingi t
era
tionnumber.Therandomw alk
[0.5
0.5
] st
arti
ngdcsignveclor(dvar
O) funct
ionc anb EExECUtedf o
rs eve
raldiff
Erentsta
rtingsetsofd e
signvaria
bles.
It
20 numberofi t
erat
ion
so fthemethod( n
ite
r) shouldnotdisappoi .Th
nt eGoldSection_nVar.mi s山es arn
eonea sinChapler5
0.
001 tol
eran
cefor出eg o
l de
ns ec
tionproced町 e(t
ol
) except白紙 ili
ep r
intinghasb e
ens up
press
ed.
0 in
it
ialste
psiz
ef orscannin
gu pperbound(Iowbound) Whilee xec
uting出eRandomWalk.mt heprintin
go f山 i te
rat
ion山mb?
sl
epinte
rvalforscanning(in
tvI
) cmatesamessa syoua p
proachthesolution
. Y
ouc answitchi
toffbycommenttqgme
20 numberofs c
anningsteps(n肘 aI
s) 旬以(ー・ ) statement-ThgeodeinRandomwalk-ma lsoseIv
esasat e
mplat
eforother
a
lgor
iili
ms.ltisworthe x
ploringindet
ail
.
Out
pu t
:
Avectorofn+1v Ju
a e
sofd e
signva
ria
ble
satt
helas
tit
era
tio
nandt
hevJu
a eofth
e
o
bje
ctivcfun
cti
on.
E
xecutingf u
nct
ion(6.7
)i nlle Command w
J indow p
roduc
esthefoll
owi
ng
i
nfo
rmation(
出ecommentsa readd
e dl
at
er
):
k

- The design vector and function during the iterations


a
m0000000023333333
=RJRd 守 , 守 , 司 , 守 'ιuζu 日Jnunvnununununu
0099998803000000
0011112288444444

....•••••
u
内 nunununununヨnヨヨ3nEnononunDnD

0.5000 5.3125 告 start


0.5000 5.3125 者 did not move
1.0440 4.6481 も decreased function
1.0440 4.6481 告 didnot move
1.0440 4.6481 告 didnot move
1.0440 4.6481 告 didnot move
4
・・・・・・・・・・

0.9756 4.6349 告 decreased function


0.9756 4.6349 告 etc
2.1093 3.0663
2.0481 3.0025
2.0350 3.0020
2.0350 3.0020
2.0350 3.0020
2.0350 3.0020
2.0350 3.0020 0
.
5 1
.5
内回

2.0350 3.0020
F
lgu
re6
.2 Randomw
al
k:Exam
ple6
.1
.
噌司

234 N
UME
AIC
AlT
ECH
NIO
UESF
O円UNCONSTA
AlNEDO
PTI
MIZ
ATI
ON 6
.2N
UME
AIC
AlT
ECH
NIO
UES
-判O
NGA
AOI
ENTMETHODS 235

6
.2.
2 P
att
ernSearch

j j+l
TheP attemS e
archmethodi sam i normodi
fication10lheUtliv
ari
atemethodwitha GoToStep2
maJ orI mpac.
tAst heP atte mSear chusest h
eU niv
aria
temethodt h
el a
tt
erisnot
d iscusseds e
para
tel
y.I nt heU n
ivariatemethod,a1soknown悩 t heCyc
licCoordi
nale TheP
atternSearchmetho
dhas a
fcwadd
itionalstopp in
g c
ritcria
.Thcscar
eb a
sedon
D esc enlmethod,e achd esignv a
r iab
le(considere
dac oordina包)provi
desas ea
rch howmucht hefunc
tioni s
decreasi
ngforeachcyc l
e andhowmuchchangei stakin
g
dir ect
ion.T hi
sisa1sor efe汀e dtoa sac oordina
ted i
rec
tion, 四diseas
ilyexpre
ssed pl
aceinthc
designvaria
blei
tsel
f.Forth
elatt
erthisI
l1format
ionisba
sedontheleng
th
t hrough恥th
1
聡e
恥 un
叩山1 ofth
echangeinthed
e s
ignvectorfo
rthecy
cle.Onceagaintheapproachissimple
and
n
削u mb邑rぱ
釘 ofva
副r油
i
a叫
bl
es
ωs山 th
ei mplemen
t a
tionisd irect
.Programmings uc hat echn
iquewillnotbct o
o
d
也e鈴
側s
討ig
伊nv a
riabl
es)氏
ite
rat
ion
叩 son efor巴悶a
c
凶hofthens
白 earchd
irect
ions.I
tcanbeshownbv fo
rbiddi
ng.
app ic
I at i
on伽 tf orprobl emsw it
hc on
sider
ablen o
nline均, t
a h
eUnivadatem
et130J
ten dstog e
tl o
ck叫 i n
toa z
討igz
却ag仰p
att

悦E
emofs
叩 叩mm

】a PatternSearch.m: Toc o In
nl ue出ee xposu
r e10MA Tu.Bprogramming出i s
meth o
d
由巴 s叩olu
J

山t
11
0n
叩 . i
si mpleme
ntedv erydif
fere1
ntyfromt heotheralgorit
hmsthathavebcentrans
lated
τllePat旬mSearchprc
問 dur
ea t
tem
ptstodisru
ptt h
iszigzagb e
bavio
rbyexe
cuti
ngone in
toc od
es of
i訂 .I
tisas ta
nd-a1oneprogra
m.T hercarep ro
mptsf o
r山 erinpu
tsw i山
add
iti
o n
aliter
ati
onforea
chcy
cle.Ine
achcycle,at白ee ndof11Univ
aria
tedi
rec
tio
nsth
ーe app
ropri
ated efau
ltv al
uesi nc as巴 th
eu serd ecid
esn ott oentera valu
e.The
n+lsea 陀 hdir
ecti
onisass
embl伐1asa伽In

I
I
即1

巴悶
脚a
即rc
ω
∞o

叩m蜘
1
1
】b one-
dimensio
na lstep
sizecomp u
tationisimpl e
m e
ntedby血em ul
tivar
iab
leg olde
n
d

伽町附c
伽“on
悶s聞削d曲 eoptimum叫 u
恥 凶eof山
th
l
恥e
巴蹴 p
阿討z悶efo a
叫 td i
rectio
n 正
. o ne
-dim叩 io
nal se
ctionmctho
d .Thei n
tere
sti
n gfeat
u問 sar
ea sfol
1ows.
opt
imalsteps
izeis白en∞m p
uted佃 dthenextc y
cleo fi
ter
ationbeg
Il
1s
.
.I
tisaf
ree
sta
ndi
ngp
rog
ram
.
A勿o
rit
hm:P
att
ernSearch伺6
.3) ・ 百l
efi
lec
ont
aI
l1i
ngt
heo
bje
cti
vef
unc
tio
niss
ele
cte
dth
rou
ghal
is
tbo
x.
S
tep1 ,
.ChooseX1Nc(
nu m
bero
fcy
cIe
s) • S
cver
alprogramcon
tro
lpar宙nete
rsareen
ter
edf
romt
hek
eyb
oar
daf
tera
j()=j(X Xc(
1 ,
;
)
1)=X , s
uit
abl
epromptin
dic
ati
ngd
efl
lul
tvalu
es.
E
・,E
2:tol
eranc
eforsto
p p
ingcr
ite
ria • Dcf
aul
tv a
lue
sa r
cini
tia
liz
edi
fth
eu s
erchoo
scsno
t10en
tcrt
heva
lue
s.
S
etj=I( i
nit
ial
izec
yclecou
nt) • Thcdes
ignvcct
oristr
acke
dandpri
ntcda
ftc
rthcp
rogr
amisst
opp
ed.
S
tep2
.Foreac
hc yc
lej • S
incetheupp
erboundcal
cula
tio
nsarcb ase
donposi
tivcv
alu
csofs
tep
siz
e,th
c

Fori=111 s
earc
hd ir
ect
ioni
s陀 vcr
s吋 if由 巳 問 tumedst
eps
izeis出esameasthelow
cr
b
ound.
S;=会(u
niv
ari
ate山 p
)
X ,
+ =X;+αβ,
;
• I
t
• F
o
er
a
rt
w
t
o
i
o
-
v
nc
ar
i
o
a
u
b
l
nt
sa
ep
ro
r
b
l
er
e
e
c
mt
h
or
eo
b
d
j
e
d
e
c
.
ti
vef
unc
tio
nco
nto
ursa
rep
lot
ted
.
α
/isdet
ermi
nedb ym
i n
imizi
ngj
(X;
+,)
(
sto
reva
lue
so f
α.iandS/)
. Thef
ir
stnin
eo rI
cssi
ter
ati
onsaret
rac
edon出巴 c
ont
our
pl.
otThcU
niv
ari
ate
and
th
epatte
ms t
epsarec
o)orcodc
d.
cndofForl
oop
n
U掴 g
e: PatternSearch (
6.
8)
号=玄α:;S;aX

肺 -X, (Pattcm取 肘 Thep
rob
)emi
sExample6.
1.百l
efi
] sEx
ei ample6_1.m.

Xj=X
n+ +C
ちi,
S
j
v
ec
Output(MAT
tor[43
]th
l
ef
o
.
l
BCommandw
A
low
inga
rew
rit
t
i
e
n
do
nt
w)
:With山ed
ot
h
e
faul
tv a
)
eCommandwindow.
ue
sandt
hes
tar
tin
g

X心・+1 )←Xs J "心・


+1 再)(
)=j( sto
r巴c
yclev
alu
es)
S
tep
3. 6j=1
r U+1)-1rωAX=X I)-X,
.
u
c
ω+ >> PatternSearch
Ifl
.
1j
lSE"s t
op The function for which the minimum is sought must be a
IfAX T.1xS~. s
top MATwa functionM - File. Given a vectordependentvariable
I
fj=N s
to
"
,p it must return a scalar value. This is the function to be
MINIMIZED. Please select function name in the dialog box
X ,←~
and hit return:
236 N
UME
AIC
ALT
ECH
NIO
UESF
OAU
NCO
NST
AAI
NEDO
PTI
MIZ
ATI
ON 6
.2N
UME
AIC
ALT
ECH
NIO
UE9-NO
NGA
ADI
ENTMETHODS 237

The function you have chosen is ::Example6_1 2.9998 1.9999 3.0000 0.0000
maximum number of cycles [1000]: 2.9998 1.9999 3.0000 0.3398
convergence tolerance for difference in f[le・8]: 2.9998 1.9999 3.0000 0.0000
convergence tolerance on change in design x [le-8]: 2.9998 1.9999 3.0000 0.0000

itill--
Input the starting design vector. This is mandatorv as 2.9998 1.9999 3.0000 0.2020
there is no default vector setup. The length of our シ Toverify白 紙 出eprogrami se xe
cutingthea1gorihm
t,s c佃 thedesignveclo
rs岡 山E
vector indicates the number of unknowns. Please enter it
now and hit return: f
irs
tlWoc olu
mns.Theu ni
vari
a l
es te
psc a
nb巴r ecognizedwh巴no necomponento fth
e
[
4 3] vec
10rc ha
ngesw hile由巳 o therm ai
ntainsitsvalue
.Thep atte
rnd ir
ectio
nsc anbe
. r
;
1 eco
gnizedwhenb othc ompo
n entsc ha
nge.
The initial design vector [4.00 3.00] ~: Thenumbero fiter
atio
nsisas ign
ific
antamoun.tOner eas
onisthatthetole
rance
s
Convergence in f : 3.999E 009 reached in 10 iterations
嗣 ar
emuchs m
aller
.I tcanben otedthat由巳 differe
nceb elwe
enlwoi lera
tion
sch 叩 ge
s
Number of useful calls to the Golden Section Search i
Inea
rly.Suchm eth odsaree xpec1edtor unf o
ral ar
genumbero fiter
ati
ons
.The
Method: 31 1 p
: rogr
,amcon佐01p a
r羽 田t e
rscontroltheacc町 冨cyof出er e
sul
tsasw el
la s由enumber
Total number of calls to the Golden Section Search ofite
rat
ion
s.Thes olutio
nismorea ccu
rat巴thantheRandomWa 1 kme 出od.
Method: 40 Figure6.3iI
Iu s
trals出ea
e 1gorithmg r
aphica
lly.Theu nivar
iatea ndthep aUer
n
The values for x and f are dir
ecti
onsarequite d
isti
ngui
shable. Wh e
n executedon yourmachine t
h邸巳 stepsare
ex
plic
itlycol
orc oded.Readersaree ncoura
g ed10goo verthecode.andmodifyi 1t
o
4.0000 3.0000 4.2500 0
4.4992 3.0000 4.0000 0.4996
4.4992 2.6924 3.6916 0.3081
4.3868 2.7616 3.6398 0.2254 E

4.1432 2.7616 3.5801 0.2446


4.1432 2.5287 3.4022 0.2339 4.
5
3.8229 2.2224 3.2890 1.3148
3.3338 2.2224 3.0494 0.4896
3.3338 2.1543 3.0343 0.0681
3.1750 2.1321 3.0180 0.3248
3.1980 2.1321 3.0175 0.0234
3.1980 2.0916 3.0121 0.0405
3.1944 2.0980 3.0118 0.1579
3.1473 2.0980 3.0096 0.0471
3.1473 2.0682 3.0067 0.0298
3.0346 1.9969 3.0016 2.3916
2.9958 1.9969 3.0000 0.0391
2.9958 1.9981 3.0000 0.0013
2.9971 1.9981 3.0000 0.0322
2.9972 1.9981 3.0000 0.0001
2.9972 1.9986 3.0000 0.0005
2.9972 1.9988 3.0000 0.4563
2.9977 1.9988 3.0000 0.0005
2.9977 1.9990 3.0000 0.0002
2.9999 1.9999 3.0000 4.9305 0
.5 1.
5 3
2.9998 1.9999 3.0000 0.0002
Rgure6
.3P
all
ems
ear
ch:Exam
ple6
.1
.
﹁11川川イ川引叩1 f H {
62 N
UME
AIC
ALT
ECH
NIQ
UEら斗唱O
NGR
ADI
ENTMETHODS 239
238 N
UME
AIC
ALT
ECH
NIQ
UESFOAU
NCO
NST
AAI
NEDO
PTI
MIZ
ATI
ON

r
ef
l配 tt
h巴i
rpref
erenc
e.Thenumbero
fli
nesi
sar
oun
d25
0.Wea
t琶 湖r
tin
gtog
eti
nto Xf=X
n++α戸j,
s
enousprogrammmg. Xc
U )←Xf; fcU+恥 f(
+1 Xj)(
s附 yc
c I
e叫 附
S
te .!
p3 :
i
f=fcU+1
)一
五,U
);d1{ XcU+1
)-Xc(
j=
)
6
.2.
3 Powell'sM
e'肋 od l
fld
flSE"st
op
fd1{TdXSE
l 2.st
op
lft he
rew ereo nly one z e
ro- or
der method 白紙 must be p rogranuned,t he
overwhelmingc h
oicewouldbePowe l
1'smethod[ 3
].Thep r
incipa
lr easonf o
r曲e If j=Nc• sωp
dec
isionwouldb et h
atith a
st hep rop
e r
t yofq l
ladr
aticc onvergenc
e, namely,fora X,
← XJ
quad
raticproblemwithnv ari
ablesc on
v ergenc巴wil
lb each i
evedinlessthano requ
a l j←j+l
tonPowe l
1cy c
I e
s.A q uadra
ti cp roblemi sa nuncon s
住温i nedminimizationo fa GoToStep2
func
tionthatisexpressedasaq l.ωdraticpolynomial-ap o
lynomialw ithnot e
r m
having ad egr
eeg reat
ert hant wo. Example6 .1i sa n example ofaq u
adratic APPMeattonofpoweII'sMethod:Thetra
nsl
ati
onofth
ealgo
rit
hmintoMATLAB
polynomia
li ntwov aria
bles
.E ng in
eerin gdesignoptimizatio
np roblemsa rerョrely COd
eisle
ftasm exe
rcisefo
rth
estud
ent
.St
ep-by
-ste
papp
lica
GontoExample6.
1is
desc
ribedbyaq ua
draticpolynomi al
.百世sd oesnotimplythatyouc an
notu sePowe l
1
's
shownh
ere
.Example6
.1i
sre
s旬飽das
method.Wh a
tthismeansi sthatt hes o
l ut
ions ho
uldn otbee xpe
ctedt oc onver
g e
qu
adrati
call
y.F ornonquadrat
icp r o
b l
e ms,ast h
es o
lutionisa pproa
che diter
ativ
ely,
出eo bje
ctivecanbea pprox
imate dveryw ellbyaq uad
raticf u
nctio
n.Itisat山i sstage Exam
ple
6.1
出att h
Thea
eq
c
u
a
t
d
ua
r
副 cc
laJgo
o
r
n
v
it
e
h
rg
enc巴p

m(A6.
r
)i
4
oper
sas
tyi
i
sr
mp
e
l
aJi
e(
z
e
t
h
dinthec
ewordi
om
sn
pu
o
ta
t
tb
i
e
o
i
n
n
s.
gu sedIightly) Minimize f
(X)=f(x"X2)=3+(
x ,
-1
.5X
2)2+(
xーが
2 (
6.3
)
modifi
cationtothePattemS earc halgorithm.lneachc ycJe(a仇er出ef irs
t),inste
a d
6.
( 4
)
ofus i
ngu niva
riatedirect
ionsi nt hefirstni ter
atio
ns.t hes e
archd irect
ionsa re
obtaine
dfromt h
ep reviou
sc ycJe.Thenews earchdirection
sa reobtainedbyI ψ
sh
iftin
gt hedirec
tionsoft h
ep reviouscy cJe
.I n出iswayah isto
ryo fthep revi
ous X=[g:~lfl仲 5.3125; E,
, =
sear
chd ir
ection
sisu sedtoestablisht h
en x.
e tWitht h
isc hange.Powell'smethod
shouldconvergeatmosti nthreec ycJesf orExamplc6 .1r athe
rt hant hesever
al
, =[~]

li
stedinthep r
evioussectio
n. S =[6]; S
2

A匂orit
hm:P owe l
l'sMethod仰 6 .4) j=l
S
te .ChooseX" Nc(numberofc
p1 ycle
s) S
tep2
.j=1
J
tl)=j {X1);Xc{l)=X , X2431+αl 国 =??l
E
S
,E

et
2:t
j=1(
ol
er
i
n
a
i
n
t
c
i
ef
a
li
o
z
rs
eP
t
o
w
o
e
p
l
p
in
lc
gc
yc
r
l
i
te
ec
r
i
o
a
un
t) 2
. 吋 =1
/4; X2= 防l
Fori=1 ,n
;=~; (
X3 =問+句砕[o.~ユ1
S univa
riat
es t
ep)
S
tep2
.F ore achyc
.clej i 2
:=
Fori=l.n
Ifj注2, S;←S ;+ , 444615;X4zj;沢民)=4.5576

+仰輔自)[~]=[ぷ5]
X;+ =X;+αISI
α;isdet e
n nin
edbym inim
izingJtXi
+'
) i=3: S
)=0
.25[
6]
endo fForl


o
o

Sj=S;+=Iα;
S
p

;=Xn
+ XJ
, ,
- a
(ptt
ems
tep
)
X4=[03251 ベ
ぷ i
5]
2
40 N
UME
RIC
ALT
ECH
NIQ
UESF
ORU
NCO
NST
RAI
NEDOP
TlM
IZA
TlON
6
.3 N
UME
RIC
ALT
ECH
NIQ
UEs-GR
ADI
ENT
.BA
SEDM
ETH
ODS 2
41
α
;=0.
423
5;
L
=
11
:5
7
0; f(X
4)=4.
4843
6
. s-GRADIENT-BASEDMETHODS
3 NUMERICALTECHNIQUE
Ste
p3.l.
dfl=1
.353>EI
'cont
inu
e
I
nl i
gh
tofthepre
viou
sdefin
iti
on.the
sewouldbere
fer
redtoasf
irst
.ord
erm巴出ods.
T
l
dX dXl=1.89
92>Ez.co
nti
nue Thesea
rchdi
rec
tio
nswil
lb eco
nstru
ctedus
ingt
hegra
dien
toftheobje
cti
vefun
cti
on.
}=2:Onecyc
leove
r Sin
ceg ra
die
ntsareb ei
ngc ompute
d. 出eK uhn-T
uckerc on
diti
ons (F
OC) for
GoToStep2 unc
onst
凶 nedprob
lem.V
s f=O.c a
nb eus
edtoche
ckforconv
ergen
ce.TheSOCa re
har
dlyeverappl
ied.Oneo fthereas
onsis血a titw ou ldinvolvethec omputa
t ionofan
-
S
tep2:}=2
- nX1s econdderiva
tivem atrixwhichi sc o
n sid巴redcompu ぬt io
nall
ye xpensiv
e.


M
xJ0.855 り gu par
tic
ular
lyif出ee valua
tionoft h
e0何回t i
vef unction問 quiresacalltoaf i
ni
tee lemen
t
J=1
11
11c'7n:
.
l57 1
0'
l α・=-0 .
14111'
¥
'Y 川.85581 methodforgenera
t i
ngr equir
叫 i nf
ormali
on.A noth erreasonf ornotc a
lculatin
gt h
e
.2
1- 吋..l ~OO; 1
¥ =1.0
1 1
041;f(X)=4.
2 414
5
Hessi
anis血a ttheexislenceof白es econdd erivativeinar eald esignproblemisn o
t
c
ertai
ne venthoughitiscomputatio
nallyp ossibleo rfeasi
ble.Fo rproblemsthatcan

二1
1
1i
Z
];
島イ



叶ら
吋2

沼払 S2=[0 25J叫 =
山0
ω
附ω
伺0

的お
仰3
4

防5叫
b
o
ed
fs
W
e
e
i
s
c
t
c
o
h
r
i
n
o
be
dd
u
db
er
i
ys
va
tSOCt
t
i
y
v
mb
巴a
he
ol
tt
s
i

em
cc
h
a
ep
et
l
o
h
c
s
o
u
l
s
d
a
i
t
b
l
sr
i
on
es
eq
s
.MA
o
u
l
i
r
ut
i
eu
o
11.ABs
na
ser
n
'
di
sv
h o
u
岱 e
igi
l
i
l
db
g
a
e
n
c
ea
nv
et
a
b
l
l
u
oe
et
es
n
oh
.
s
u r
andl
ec

e白 紙 t
o
m

h
es
pu

o
t

l
a

u
t

t
i
o

i
o
n

n
i=3
:_
v _
10.
956
71 ~ r
0.
10ω
11 rll
obtai
nedisaminimumr athe
r山a namaximumo ras ad d
lep oin.As
t impl巴 way10
.1966J~3 =伊.0396/:α3=20以~ =/

ilillit---
'

U 2
/
;f(X =3 ver
ify出isi stope r
turbt heobj巴ct
ivef un
c tio
nt hroughp e目u r
bationint h巴d esi
gn


吋 - 4)
var
iabl
esatthesoluti
ona ndverif
yitisalocalm i nim um.Thisb ringsupani mportan
t

ご抗出
土::
ニi;;32!emd 恥 C
叫 u
tat
ion
sin出i e
rci
se蹴 s
top
ped
p
t
r
ot
op
h
町o
e
巴 de
f
s
t
i
h
g
es
nw
em
he
e
r
血ods-theyo
et hei tera
ti
n
1
o
n
yf
sa
in
r
dl
eb
oc
e
a
g
lo
un
pt
.B
im
e
u
f
m
o
s
r
.U
ec
s u
o
a
l
n
c
l
l
yt
ud
h
i
i
sw
n
i
gt
l
h
lb
ed
ec
e
10
si
g
s
e
n
山itE:27 忠;:Jr:atJ;;::::wouldit叫 h
ere
?You蹴 巴 … a
gedt
o
e
d
x
i
p
l
s
o
c
r
o
v
a
e
t
io
ri
n.i
fo
ti
th
sn
e
ecess釘 Yt
rminimums巴x
oexe
i
c
s
ut
ta
et
n
hem
ds e
e
l
e
t
c
ho
tt
df
h
r
eb
oms
es
e
to
ve
n
r
als
eb
ta
yh
rt
i
e
n
a
gp
dt
oi
oh
n
tst
e
a
o
d
compa
rison.Theb ulko fe xisti
ngu nconstra ineda ndc on st
ra in
edo ptimizati
on
-ηlem
eth
odo
nlyt
ookt
woc
ycl
est
oco
nve
rge(
ase
xpe
cte
d)・ methodsbelongto出i sc ateg
ory.
・Thee
xte
nto
fcompu凶 o
nis恥 s
amea
sth
ePa
tte
mS即 c
hb川 l
enumberof Fourm cthod
sa represente
d.Thef ir
stist hcSt e
e pe
stD escentm ethod.W hil巴 t
hi
s
i
ter
ati
onsi
ssi
gni
fic
ant
lysma1
l
er
. methodisnotusedinp r
actic
e.itprov
idesa ne x
c e
l l
ente xampl eforunderstandingth
c

・2:;;212S22;お訟は:rsecondmleiS叩
alg
orith
micprinc
iplesfor臨 g r
adie
nt-basedt echni
q ue
s.Thes econdistheConjugate
t
iv
e.H
恥E
叩nc
町町
即 e
印附 Gradi
enttechniq
uew hichisac la
ssic
alw orkhor sepa 凶cu l
arlyini ndus町 usage.The
t
hirdandfourt
hb elongtothec a
tegor
yo fVar iableM etr
i cmethods.o rQuasi-Newton
• Thest
eps
izefo
rthel
as
ti t
cra
tio
nis20ぉ.Thes up
por
tin
gal g
ori
thmfo
r me出o dsωtheya realsocall
ed.Thesem ethodsh a vcbeenp op 叫釘 f o
rsomet ime.回 d
;;:
::!
1gandg
olde
nse
cuonmustbeab
let pt
O凶 t h
eminimum剖
at伽 elar w
illpossib
lys t
aythatwayf oral on
gt imetoc o me.


Thcg cn
eralproblema nds pe
cif
ice xamplear 志 向p roducedf o
rc onveni
en c
e

z r
• Wh討
iil
enot
ilh
uslm
即tεdhmer
E
久.t
h el
sa
制x
対i
mlu
1 nm
m叩Il川叩
umb
凶?
引e
r'0fc
句y

c1e
ω
stω
o∞
co
nv
刊e
r
:gen
1c
印e
fl
or
:
L :
:
z2
】 削 加
凶I
犯 回 鈴
吋凶 恥
町 凧 恥
白恥 剛3
机刷

削町
叩 】 印 ぱ 屯 に
伺町 白 日

ぷ1;
a

::
抗払忠
:
立 f
:ユ 沈
均衣な :f曲 目 町gp
oin
tY
. M
ini
miz
e j
(X)
; [
X]" 6.
( 1
)
S
ubj
ect
ω XI~Xj~xlt; i=I.2.....n (
6.2
)

訪協2
m
a

c
t
ou
n
.
j
z
r
i
g
a


:
3
x
2
i
fi
:
.l
舵c


5
1
3
fs
ya
r
2
t
e
a
c
i
:誌記;容認
帥 d

ire
cti
ons品
Sj
. a吋d号a町o
佃n 叩n吋~u
叩昭g伊at,e除 d
i
廿悶e
c“∞
α
o眠
伽n
E
M
i

S
u
n

b
i
m

j
e
i

c
z
e j

tt
o
(X)=f
(X

: OSXIS
.X2)=3+(
I

5:
XI- 1
.5x
2)2+(X2- 2

oSX2S5
)2 (
6.3
)

(
6.4
)

SJ
[U]Sj=0 6
.3.
1 SteepestDescentMethod
(
6.9
)
V
eri今 i
fi
ti
str
ucf
ort
hce
xam
ple
. Thi
smethodp
rov
ide
san a
tur
alevo
luti
onfo
rthegra
die
ntbas
edtec
hni
que
s[ 4
].
Thegr
adi
ento
fafun
cti
onatapo
intisth
edi
rec
tio
nofthem
ostra
pidin
cre
asein
242 N
UME
RIC
AlT
ECH
NIQ
UESF
ORU
NCO
NST
RAI
NEDO
PTI
MIZ
ATI
ON 6
.3N
UME
RICAlT
ECH
NIQ
UEs-GR
ADI
ENT
-BA
SEDMETHODS 243

t
hevalueoft
hefunct
ionattl
la
tpoint
.Thede
scentd
ir巴cti
oncanbeobt
ainedre
versi
nl!
Output(wri
tte
nto白eCommandw ind
ow):A c o
upl
eofi
ter
ati
onsa
t出es
ta
rtanda
t
t
hegradie
nt(ormultip
lyingi
tby- 1
).Thenextstepwouldbetorega
rdtl
1edesce
nt 司 自EE nd(o
utof20i
terat
ion
s)M
e c
opiedb-
l o
w.
v
eclo
ra sas ear
chd i
rect
ion,af
teral
lwea reaUempting10decr
easetl
1efuncti
on
5.3
125 5.296
9
t
a
l
h
r
g
o
o
u
r
i
g
t
hs
h
u
m
cce
ssiveite
rat
ions
.Thisser
iesofst
epsgiveris
eto白eS te
epestDes
cent
j 0
0
.
.
5
5
0
9
0
9
0
6
0
0
.
.
0
.
5
9
8
0
0
4
8
4
0
3
2
9
4
4
.
.
7
3
8
3
7
2
6
6
2.
3.
84
11
1379
1
.0701
A匂'ori
thm
:Stl僧 P白 t Descent伺6 .勾
0
.0507
S
tepJ.ChooseX,J N( numbero
fit
era
tio
ns) I~ 2
.690
1 1
.8659 3
.029
8
0.0
462
2
.7455 1.
8502 3.
023
3
!
.()=j
l {X1
)
;X.(
l)=X1(
sto
rev
alu
es) 1
.8960 3.
018
1 0.031
6
2.
7585
E

S
e
JE
2
ti
'E
J
=1(
:(
in
i
to
ia
t
l
e
1i
r
z
a
n
ei
c
t
e
ef
r
o
a
t
rs
i
t
o
o
nc
p
p
o
u
i
n
n
gc
t
er
r
i
)
te
ria
)
jFigure6.4rep sentsthegraphicalrnotionofthedesignvariablesfor20itErations.

Thegrap
hica
lp i
ctu
reandthechangesinthedesignarEnotimPEE
SSiE・TheS
V tee
pest
S
te .S
p2 j=-
Vf(
X/)
(出i
siscomputedi
nSt
ep3
)
Desce
ntmEthodiSWOE
ful
lyMadequatECompazedt oPowe
ll-smethodeveni
fth
elatt
er
X
;+l=X;+α~; isazero-
orde
rme t
l
1od.MO[1回ver,白isconclusioni
sdrawnw ithrωpectl
oa n回 sy
的i
sde
ter
min
edbym
ini
miz
ing
f(X
;+I
) problem(qu
adra
tic
)Example6 .1.百i sp erforman
cej us
tif
iestl
1elac
ko fseri
ous
X
s(i+1)←X件 1
; 五(
i+1
)=f(X+
il)(
sto
reva
1ue
s) int
ere
stinth
eS t
ecpe
stDcsc
e n
tmet h
o d
.
S
tep
3.a
J =!
.(i+
l)ーぶりaX=X s
(i+1)-Xs(i
)
I
flaJ
l~EI; 陶p (
func
tionn
otc
han
ging)
T
faX aX~ E
I 2
; stop(de
sig
nno
tchan
ging)
[
fi+1=N; s t
op 5

I
fVf
(X;
+ll
Vf(
Xi )~ E
+l 3; c
onv
erg
ed
i←i+1
4
.5

GoToStep2

t
SteepestDescen.m: Thisisanm-f
ile白a1e x
ecuωa
t 1go
rithmA6.
5.Ituses白e
gol
densec
tinandt
o l1eu
ppe rbounds
canni
ngPI1凹e
ss.百leたaωresof
thi
sprogramar
e
asfo
llo
ws.

• Fortwov
ari
abl
esi Id
twi
J rawt
l
1ec
ont
ourp
lo.
t
• Fortwova
ria
ble
sthedesi
gnvectorc
han
gesc
anb
ese
eng
rap
hic
all
yins
low
moti
onwit
l
1step
sindi
ffe
rentc
olo
r.
• Thedesi
gnv a
ria
bls,
e 出ef un
ctinva
o 1ue,and出eS q
Uar巴oft
l
1elegt
n l
1of曲巴
gr
adie
ntvec
tor(c
a11
edKTv
al u
e)ateachit
era
tionare
disp
lay
edint
l
1eCommand
windowatcom
pleti
onoft
l1enumberofit
erat
ions
.
• Thegra
dien
1oft
l
1efun
cti
oni
snume
ric
allycomput叫 usi
ngfir
stf
orw
ardf
is
Ite
di
ffe
ren
ce.Theg
rad
icn
tcomp
uta
tio st
ni l
1er
efo陀 a
utom
atic.
• Fromaprogrammingp
ers
pec
tiv
e,b
asi
cst
rin
gha
ndl
ingt
och
ang
eli
nec
olo
ris
in
tro
clu
ced
.
0
.5

Usage: SteepestDescent('Example6_1',(0.5 0.5],


20,0.0001,0,1,20) (
6.1
0) 円g
ure6
.4 S
le邑p
estdesωn
:tExa
mpl
e6.
1.
244 N
UME
AIC
泊LTE
CHN
IQU
ESF
OAU
NCO
NST
AAI
NEDOPT1M
IZA ON
Tl
6
.3N
UME
RIC
ALT
ECH ,
NQUEs-GR
AD'
ENT
.BA
SEDMETHODS 245

rJ
巴xp

;
e
c
なお
?
t
ね1
e
2
:
dt
ロ:
J
I出:
241
詰誌な2
oovercom
EZ
巴t


hi
spattem.I
nt h
ecaseofth
eU n
ivar
iat
em仙 odt h
iswas
c
i
o
n
m
c
o
p
r
u
p
t
o
a
t
r
i
a
o
ti
n
n
--
s
gt
. and th巴 succes5ive adjustment of 恥 search direction
h
isv a
lue.~ rep
rese
ntstherat
ioofthesquareofthecurrentgradie
nt
vec
tortoth esquareofthepreviou
sg ra
dien
tv e
ctor
.Thef ir
stthingtonOliceis山at

ac
hEe y
edthro
ughp atF
rnS e
ar c
hmethodint h
ezero-
orde
rfamily.Anit
era
tio
n
adegreeo frobustnes
sisb ui
ltintothemethodbyc arryin
gi nfo
r m
ationfromt h
e
br
eaki時 0円o ft h
ez igz
agp a旧 m (o
rp r
even
tin
gg et
tin
gl oc
kedint
ooIn
EPi5
:

: 九

芯::rro:l
i
z尽

:
:
::立

22
: 口 “e叫
me
仙白o
山d Suc
叫 h】

p

z
r

e
e

r
v
i
onei
oa
o
t
u
e
si
r
a
tt
t
h
t
i
e
o
es
r
n
at
.S
o
lu
i
o
i
t
n
n
i
o
.T
c
n
h
et
isi
h
sIikem
eFOCi
.出 isP訂 ti
a
sb
c
ul
i
a
a
n
s
t
e
ain
in
dont
rfonno
gah
h
fi
el
nc
i
s
e
o
t
n
r
p
o
g
o
r
yo
t
r
ho
at
ft
ft
io
h
h
no
emethoda
eg r
ad
f~ i
i
si
en
n
l
ta
ge
n
b
p
i
e
p
o
i
tf

u
r
o
s
o
a
c
.I
rj
h
i
ft
u
n
s
t
g
h
e
pre
viousilerati
onisclosetothesolu
tion
.thens i
sl ar
geand出巴 p revi
o u
si te
rati
on
6
.3.
2 ConJugateGradient(
Fle
tch
er-
Ree
ves
)Method pla
ysas ignific
antr o
leint hecurr
entiter
ati
on.Ont heo th
erhand,i fsi slarg
e.

z z
sug
gestingt hesoluti
oniss t
il
lf raway,t
a henthec urr
entv a
lueo ftheg radie
nt

詳5;
5
TheCo吋u
gat
eGr
adi
entmethod,
ori
gin
al
Iydueω F
1et
che
ran
dRe
eve
s[],
5 sasma
i Il dete
rminest henews earchdir
ecti
on.



c
宮i
onv

e


e
,叩
;
i
r


g
?
:
en


;
c

巴be
c




a


2
5
g:
;
:
us
混2
et

;
q
i
h


es

:
e
a
?

r

:
1
i
c
能鴇
i
5
;
hdl
I
r
.e
諮;

c
t
u1o3
n
Esa
M
r巴c
ω
0ベ

j

Ij wi
ugate川 t
h陀 s
出 p民削t
叩 tω
oth
eHe
ssi
an
A
w
p
a
r
p
r
l
l
an
ca
tw
tl
o
o
r
'
0
n ConJugateGradlentMethod:Thi
k
ingt hro
ught h
ei te
rat
ion
s.Th esecaIcu
l
s method i
atio
ns,s i
mi
si
l
art
mp
or
oP
t
o
a
n
w
tt
el
l'
o
s
a
Ic
:
ご工幻
:
?xi
:広
E:

:二誌
ば:
ごナ
l
u

“ω叩
on山
.Aq
ul
聞a帥
m巴t
i
ts
e
h
lf
od,c
.Thea
anb
ut
edoneu
h
o
singahandc
rrecommendstheca
Icu
u
l
l
a
a
t
t
o
o
r.u
ra
sin
s白ep
gas
ro
ce
p
陀 a

ssi
ds
ss
h
lo
,o
回 t
wen
rusingMATLAB
oughtodev
elop
anintu
itio
nw orkin
gw iththep a
ltemo fnumb 巴r
s.Int hef oll
owin
ga・ ndunli
ke
Po
well'sm巴t ho
d,on1ythereleva
ntc a
Icu
1atio
nsa rereco
rded.Ther eade
rs h
ould
A匂'o
r/
l的 m:C onJuga俗 Gra
df開 t
j 伺 a句 fo
llowaIoogveri
fyi
ngthenumbersareiod
e e
dcorrect
.
S
tep1. ChooseX" N (
numbe
rofi
ter
ati
on直
)
10.
51
!
s()=j(X,
l )
;X.(
l)=X,
(st
orev
alu
es) S
tep1
.X1=1 o
:
sl
; f
(X,
)=5
.31
25
・, E
E 2・E
3:(tol
eran
ceforstop
pingc
rit
eri
a)
S
eli =I(ini
lia
liz
eiter
ati
oncou
nte
r)
10.5 1 • _._ _
_ ...
. ._ _
_. __ 1 0
.59
961
S
tep
2.I
fi=I ,Sj=-Vj(X )
j S
te ,
.S =12~i51;αi =0
p2 .19
93;f
(αi)=4
.78
31; X2=
1O:94
841
Elses= 可'(xjfVj(Xj
)
Vj
(Xj
_)TVj
l (Xi
_'
) t=2│-1.64591
:s 1;町民)=IO~36571
丸)+s
Si=-Vj( Sj_ , S
tep2 =0
.53
5
11
.91351 131
X
' I=X/+αβt I
2= O:83831;α,i

+ =1.
254
4;f
(叫)=
3.0
; X3=121
α
Iisd
ete
rmi
nedbym
ini
miz
ing
j(Xi
+,
)

S句 3
.!
X
.
j
J
.
I
f
(

l
i+1
=
f
!
J
s(
.
j
)←X;+,;五(i+1)=j
i+l)ーが1); 企X=X.

lsE
町I
μ
; 岬 f
(

向u
m


削n
J
恥E
ω
c


n

削削
刷t
i


刷i
附o
(X
(i+1
nnE

トX。
川)% (
s
.
(
ω陀 V山 巴s
) Con)ugateGradlent.m: Thi
Fortwo吋 a
pro
gressi
r
nt
i
h
ab
l
ed
ep
esi
rob
伊 s
l
e
p
m
a
st
cei
h
e
sr
sm
r
e
-
ew
c
o
f

r
i
l
i
l
d
ew
lb
ed
ille
eac
.Thep
xec
o
r
u
n
o
t
t
o
p
e
et
u
rt
h
rp
eC

yo
l
o
on
to
j

fqua
u
v
e
g
a

合8
t
rw
eG

t
i
h
r
i
Cc
a
c
o
d

n
i

v
e

e
n
h出ei
r
tm

ge
e
t
n
c
t
e
r
h
a
ec
o
t
i
d
.
v
a
e
n
beo bs
ervedぉ t hesolut
ioniso btai
neda ftertwoi te
rat
ion
s. Thisisd e
fini
tely
I
旺f!
.X
J '!
J
.X:$E2
必 stω
op(
des
ignn
otc
han
gin
g) imp
ressivec omparedwith出巴 S t田pestD escentm巴出 od.K田 pi nmind出a tt he
Ifi+I=N; 5tω
op mod
ificati
ont otheaIg
orithmisminor
.As出ev ariou
sc od
esa r
er u
ni nord
er.some
I
fVj
(X+,
i 件
fVj(X,):
$E3
; c
onv
erg
巴d chan
gesint hefig
urecanbeobserve
d.The searelar
g巴lyduetotheuseofsomes t
ring
i~i+1 pro
cessingfunct
ions
.Youa reencourage
dt os eehow白e ya r
ei mp
lemented.The
aut
horiscertai
nthereare出ingsyouwoulddod iffe
ren
tly
.Don othe
sita
t巴to甘y, a
s
GoToS
tep2
白紙 istheon1ywayt olear
ntou s
eMATLABe f
f,c
巴 ti
vel
y.


c ;::P22Jt::2JUlz;ittrtt;123tzr:rn; ぷ
;
。;
:
; 20,
Example6_1',[0.5 0.5],
U蝿 ge:ConjugateGradient(‘
0.0001,0,1,20);
6.
( 11
)
246 N
UME
RIC
ALT
ECH
NIQ
UESFO
円UN
CON
STR
AIN
EDO
PTI
MほA
TIO
N
6
.3N
UME
RIC
ALT
ECH
NIQ
UEふ-GR
ADI
ENT
・BASEDMETHODS 247
Output(Commandwindow)
th
isfar凶lyo fmethodsgobeyondt hat
.Ast hesolu
tionisapproached,theybehavelik
e
Theprobl
em:Example6_1
Newton'smethod( Secti
on6. 4
).Theq ua
d raticconvergenceo fNewton'smethodi s
Thedesi
gnvect
or,fun
ctio
nva
luea
ndKTv
alu
edu
rin
gth
eit
era
tio
ns qui
lei mpressive-itwilllocate山 s o
lut io
nt oaq u
adraticproblemi nolleite
rat
ion
.
ThisNewton- i
Ikebehavioro ft
h eVMM, a sthesolu
tionisapproa c
hed,hasgiventhem
0.
5000 0.
5000 5.
3125 0.2
490 anothernam 巴termedQ uasi-Ne
w tollorNe wton-li
kem ethods
.
0.
5996 0.
9483 4.
7832 2.
8411 TheDFPmethodi spresentedh er
ef o
rh is
tor
icalinter
est血 db ecauseitisalit
tl
e
2.
9995 1.9
982 3.
0000 0
.0001 eas
iertou nd
e rs
tandthan由巴 o t
hers.Infac,tHuang( 7)documentsag e
nericprocedur
e
fromwhichmosto f出ep opularmethodsc anbeo bta
i n
ed,andfromwhichyouc oul
d
Keepinmindthesolut
ionisdepend
entont hetol
era
ncefortheo
ne-
dimen
siona
I als
od eriveyourown.
st
eps
izes
earcha
ndt h
attheder
ivat
ive
sa r
ecomputednur
ner
ica
lly
.Theexe
cutio
no f Th eCo nj
u g
ateGradien
tm ethod'sirnpr
o vementovertheStee
peslDescentmethodwas
白ecodesho
ulddis
playFigu
re6.5inthefi
gur
ewindow.
pos
sibleb ecauseoft heinclus
i onoft h
eh ist
ory針。m t hepreviousiter
ati
on.lnt h
e
quasi-Newtonm ethodst h巴 histo
ryfrom a I
lp reviousi t
era
tionsisa vai
lab
le.T hi
s
6
.3.
3 Davldon-Fletcher-PowellMethod infor
m 岨oni scoll
ectedina nnXnm縮 i xc a
lled血em etr
ic.Them e
tricisupdate
dwi 出
eacbite
r a
tio
n釦 disu sedtoesta
blishthes回 詑hd ire
ctio
n.Ani nit
ialchoic
ef o
rthemetric
TheD a
vidon-
Fletc
her-P
owell(DFP)[ 6
]methodbelongsto山ef amil
yo fVaria
ble i
sa lo明 u田 d
s .Itmustbeaり 刷t e
tバ'
cp o
sitiv
ed ef
tnit
em atr
ix.F ort h
em抽 odt o
Metr
icMethods(VMM).Itwasn rs
tintrodu
cedbyDavidonands e
VEralyEMBlat
er converge,th
emet Icm
l usth oldont oit
sp o
s it
ivedefi
niteproper
tyt hrou
ght h
eiter
ati
ons
.
wasd eve
lopedinitscurr
entf ormbyF let
chr剖 dPowel
e I
. B巴ingawareo fthe h出eDFPmethod,t h
em et
ri capproac
hes由巳 i nvers
eo ftheHessianatUlesol
uti
on.
Conj
ugateGradi
entmethod,th
esemethodswouldnotmerti
I ncIu
sioninth
isbookif
th
eyd i
dn othaveth
eproper
tyo fqu
.ad
raticcon
ver
ge n
ce,whichtheydo.Gene
rally A句orithm:Davidon-
,F制 '
che
r-P
owe
l A6
l( 刀
.
x
.
.[A1l(initialme甘ic},N

屯川崎喝刈話冗一同詔一
S
tep1
.Choos

Ehe
2'e
J:(
tol
era
ncef
ors
top
pin
gcr
i町 i
a)
S
eti=1(
ini
tia
liz
巴it
era
tio
nco
unt
er)
S
te .8=
p2 ,
ー[Aj]Vf(Xj
)
Xi+1= Xi+α,s
u AX=αjS ,
αiisde
t e
r m
indbym
e ini
miz
ing
f(X
i+l
)
S
te .I
p3 fV
f(X
i+I
)TVf(X
i+1
)三e
3; c
onv
erg
ed
ff
I!(X
i )ーf
+l (Xj
)1:
;el; stop (fu
ncti
onnotcha
ngi
ng)
I T
fAX AX~e2・ stop (des
ignnotchan
ging
)
fi+1=N, s
I top (it
era
tini
o I
mil)
E
ls巴

Y=Vf(Xj
+l j
)-Vf(X}
z=[A;]Y
AXaX T
[
B]
=-
--
:-
:::
:;
::
:一
AX'Y

ZZT
[q= ー--~-
V'Z
2 3
.5 4 4
.5 5 [Ai
+
J ,+[
l=[A] B]+[q

i i+1
F
lgu
re6
.5C
oni
uga
teg
rad
len
tme
tho
d:E
xam
ple6
.1
. GoToS
tep2
寸Hjil--J41JHAHill-Jハ ー
248 N
UME
RIC
ALT
ECH
NIO
UESF
ORU
NCO
NST
RAI
NEDO
PTI
MIZ
ATI
ON 6
.3N
UME
RIC
ALT
ECH
NIQ
UEふベ3
RAD
IEN
T.B
ASE
DMETHODS 249

I
nthea
bov
e白 em a
tri
cesar
ee n
clos
edb
ys qu
areb
rac
ket
s.Thein
it
ialch
oic
eoft
he iteration number: 1
m
etr
ici
sapos
iti
vedef
ini
tema
trix
.Thei
den
tiym
t at
rixi
sasafec
hoi
ce. s
0.4990 2.2467
DFP.m: TheDFPa lgo
rith
m(A6.
7)iscode
din山ism-f
ile
.Simil
ar10thepr
evio
us delx =
0.0996
programs,fo
rtwovar
iab
les山edesi
gncha
ngesar
etrac
kedonab a
ckgro
un dc
onto
ur
0.4483
pl
o,t F
igure6.6.Thedef
aul
tin
it
ialme
tri
cisIheid
ent
itymat
rixgen
eratedus
inga y
MATLABb ui
lt-
infu
nct
ion
.
-1.1458
2.6153
U
sag
e:DFP('Example6_1',[0.5 0.51,
4,0.0001,
0,1, 6.
20); (12) z
-1.1458
Output: The ou
tputfromtheabov
ei nvoc
atio
n( c
o p
iedf r
omt he Command 2.6153
window)canbeob
tain
edbyrem
ovi
ngthcscm
i-col
onaf
terthes
tatem
en.
tThevari
abl
e B
de
fini
tio
nsm a
tchtho
sede
fine
dinth
ealgo
rith
m.ForExample6.1 0.0094 0.0422
0.0422 0.1899
=
A

c
01

開 0.1610 0.3676
nU

0.3676 -0.8390
A
0.8483 0.4097
0.4097 0.3509
iteration number: 2
s
1.2443 0.5446
The problem: Example6_1
The design vector,function value and KT value
during the iteど ations
0.5000 0.5000 5.3125 5.2969
0.5996 0.9483 4.7832 2.8411
2.9996 1.9987 3.0000 0.0000

6
.3.
4 Broydon-Fletcher-Goldfart
トShannoMethod

Ifyou weretoprogramo nl
yoneg rad
ient-bas
cdm巴t hod
.t hent hcBroydon-
Fletcher-Goldfarb-Shanno(BFGS)181method would be t he one.It isa
quasi-Nc
wtonmethodandc u
rren
tlyist h
emostp opu
larofth巴V aria
bleMctric
method
s.Itenjoyslhepropcr
lyo fquud
raticconvcrgenccandh a
sr obu
stnes
sb y
car
ryingforwa
rdinformat
ionfromI13
Epreviou
si ter
ation
s.Th
ed iffe
rencEb
Etween
由巳 DFPa ndBFGSi sthewayt hemelri
cisu p
d a
led.Thef orme
rc onver
gestothe
4 4
.5 5
inve
rseoftheHessia
n.w hi
lethelatt
erconvergestotheHessianit
sel
f.Inas e
nse
山eBFGS i s morc dir
ect
. The BFGS h asr eplace
dt heC onju
gateG radi
enl
F
Jgu
re6
.6 DFPM
elh
od:E
xam
ple6
.1
. techn
iquesasaw o
rkhorseinsolvin
gn on
linearequat
ions
.
250 N
UME
RIC
ALT
ECH
NIQ
UESFORU
NCO
NST
RAI
NEDOP
TlM
IZAT
lON 6.
4 N
UME
RIC
ALT
ECH
NIQ
UEs-5ECONDORDER 2
51

制州一附


Forc onve
rgencetheme
tricmustb ep
osi
tivedef
ini
te.Ani ni
ti
alc h
oic
eo f


p
ositi
ved e
finI
巴m
l atr
ixfo
rthemetr
icisus
ual
Jysuff
icien
lloens
urethi
sprop
ert
y


RU
f
orquadr
aticprob
lems
.Theide
nti
tymat
rixi
susu
allyadef
aultc
hoi
ce.

A
lgorit
hm:Bro附加・F倒 的er-Goldfarb-Shanno(BFGS)Method(
A6.却
S
tep1
. ChoωeX"[
Atl(
in
it
ia
lme
tri),
c N
2・
E"E E
3:(
tol
era
ncef
ors
top
pin
gcr
ite
ria
)
S
cti=1(
ini
tia
liz
eit
era
tio
nco
unt
er)
S
tep2
. These
arc
hdir
ect
ioni
sob
tai
neda
sas
olu
tio
nto
[A;
]S=-Vf(X)
, ,

S
tep3
.I
x川=~・+
α
ii
sd
fV
e
t
f(X
en
n
川)
i
n
TV
e

l
CS;
,dJ(=α,
dbyMin
f(X川)三 E
3
S,
旬並 z
ing
f(X川)
・converged
i立ぷ
ふ E cl=│2m-3例 21
-3
.04
29 6
.50
95

fr
II(Xi
+l)ーf(X) ,I・sωp (
1~ E fun
cti
onn
otc
hun
gin
g)
I
f!1
T
X dJ(~ E
2; s
top (de
signn
otc
han
gin
g) 削 S24221; 町 =1お 4
4; X3=[H 胸 =
3.; 帆 )
0 =[g]
fi+1=N,s
I t
op(i
ter
ati
onl
imi
t)
Converged
E
lse
Y= Vf(Xi
+l)- Vf(X,
) Thet ra
nsla
tionoftheBFGSa lg
oril
hmi n
tocodci sle
ftasa ne xe
rciseforthe
yyT stud
ent
.Itisrecommcndedt h
atUlecalc
ulat
ionofthesear
chd i
rect
ioninStcp2be
[
B ーτ一
)= accompli
shedasasol
utiontoasetofli
nea
requat
ions(asl
ist
ed)raU
lerthanin
vert
ing
y
'dJ( th
em atri
xA .Oneo th
ert hin
gt onoteforExample6.1ist h
atift h
ep oly
nomial
appro
ximationwasu se
df ort h
eo ne
-dimen
sionulproce
ss,thec a
lcula
tionofα -
)
Vf(X,Vf(X,
? wouldhaveb ecne
xuc
t( why
?).
[C]=中
Vf
(X;
)'Sj
[A
j d=
+ [A
;]+[
B)+[
c]
if
ーi
- +1 6
.4 NUMERICALTECHNIQUES-
SECONDORDER
GoToS
tep2
S巴cond-
ordermethodsforuncons
traine
do pt
imizat
iona r
enotu sc
db巴c aus巴v
巴 al
ualio
n

A
p
c
s
p
s
l
i
e
n
c
t
沼t
i
a
lo
lc
om
'
0
n BFGSMethod:Themethodi
p
uta
tio
nsa
res
how
n.
sap
pli
cdt
oExample6
.1.Only
o
c
c
ft
o
o
m
p
n
h

v
eH
u
t
e
a
r
t
g
e
e
s
i
n
s
o
c
i
n
a
a
l
ei
nm
l
sv
a
ye
e
t
x
r
r
p
i
e
yi
xd
n
m
s
p
u
i
r
r
v
e
s
i
e
s
n

i
ge
.A s
ve
a
e
c
hi
co
.Ann
n
t
d
-
e
r
-
o
v
a
a
r
r
t
i
d
i
o
e
a
ntheH cs
s
rmethodw
bl
ep robl
i

e
a
nm
i
mc
atr
h白 ep
t
ancon
i
xi

v
r
e
o
r
sc
pe
g
r
ci
o
n
t
si
yo
no
de
fq
n
r

ei
e
u
t
dt
a
d
e
r
r
a
ob
a
t
i
t
o
e
i
c
n
.

c
pI XI=lsl; 川 )=5
1 .31お =[~ ~l
; 凶1 二l

Vf(X1)
Asm

der
iv
e

a
n

t
t
madeonU
i
v
ion
l
e

e, n
db
ed
o
i
e
s
tt
f
o
c
r
r
e
om
e,f
ten
en
o

t
rr
a
i
t
u
o
e
r
a

ns
ld
eo
e
e

c
s

o
i

n
gnp
fsomeo
dd
r

e
o

r
b

i
v
l

a
e

t
m

i
s,
f出 ev
v
e
whered
a
ria
s, i
b
sq
le
ec
isi
s,出巴 e
u
estio
o

n
a
n
x
b
sa
i
l
s
e
r
t
er
en
c
e
q
eo
uir
ft
edt
h
ef
ob
i
r
. Moreovcr, U
e
s
t
l
e
quasi-Newt
onm ethodso f由巳 las
ttwos ec
tionsarea b
let oeffcct
ivel
yf unct
ionas

WSl=lzl; 叫 =0.19耽 X2=ltzzl;Vf叶協'~] s


e
e
s
c
t
i
o
m
n
d
a
-
t
o
i
r
o
d
no
erm
fs
e
e
t
c
h
o
o
n
dsa
dder
i
s出e
vati
v
ya
es
ppro
.Ones
ac
e
h批 solution-andt
cond
-ordermethodi sp
h
r
eyd
ls
巴 en
on
te
o
dh
tn
er
e
ef
edt
o
rt
h
e
h
e
sakeofcomplete
n巴ss.
I n
deed,t h
ereiso n
lyo neb as
ics econd-or
dert echniquef oru ncon
straine
d
step3Y=12Jri;m=ltml opt
imizat
ion.Itisb asedont h
ee xten
siono ftheNewton-Raphsont ech
niqueto
mul
tivari
ableproblcm.Manyd if
fcre
ntc xt
ension
sa reavailab
le,b u
ti nthi
st et,a
x
よ軍部慰霊3 33
252 N
UME
RIC
ALT
ECH
NIQ
UESF
O円U
NCO
NST
RAI
NEOO
PTI
MlZ
ATI
ON 6
.5A
DDI
TIO
NALE
XAM
PLE
S 253

d
ire
ctext
ens
ionre
castin出ege
nera
la l
gorit
hmics釘u
ct町巴 (
A6.1)i
spr
ese
nte
d.Once fi+1= N
I ,st
op (
ite
rat
ioni
Im
it)
a
gaint
hegen
eralpro
b l
e ma
ndsp
eci
ficexamplear
easfol
1ows.
E
lse

準3
M
ini
mie f
z (X)
; [X]n (
6
.1) i i +1
GoToSt
巴p2
S
ubj
ectt
o: x
l三Xi三xjt ,
i=12,
...,
11 (
6.2
)

33却損41131411ffits?hititi--1
M
ini
rni
ze f
(X)=
f(
XI'X
2)=3+(
XI-1
.5x
2)2+(
X2-2
)2 (
6.3
) ApplicationofModifiedNewtonMethod: A
lgori
thm(
A6.
9)i
sus
edt
oso
lve
Example6.1.Onlye
sse
nti
alcom
put
ati
onsarei
ncl
ude
d:
S
ubj
ectt
o: O
::
;;
XI
:豆5
;0:
:;
;x
2:
:;
;5 (
6.4
)
Step1431; f(Xt
)=5.
312
5


﹁トート


抑 協i
z
l

0
-EEE E -E


ModifledNewton'sMethod:TheNewton-Raphsonmethod,u

nU 今

se
dforas
ing
le


QU

M
5
va
riab
le,sol
vestheproblm中(
e )=O
X .Thisequ
atio
ncan問 p
resen
t白eFOCforan

今&


unc
onstr
ainedproble
mi nonevar
iab
le( Ch
apte
r5).Theiter
ati
vecha
ngei
n由e
va
riab
leiscomputedthr
ough
s
,一
¥
=
11~.;~~~
7'~~;;;;
1.5000 ;¥
:
1
l α
' ,
u1
t=
=1
-
Uo
.0
;
: ヮ
, X?
J.v ー
=

1~1
1;

1 f(X
2)=3
"~2
.0; c
onv
erg
ed
(
6.1
3)
d
x=ー単王L
=ーと主主 Asexpectedon
l yasi
nglei
tera
tionwasnecessarytoo
btaint
hes
olut
ion
.Tr
ans
lat
ion
ゆ'
(
X) f
"(x
)
ofthealgor
ithmintoMATLABcodeisonceagainle
ftasanex
erc
ise
.
wherefisth
巴 si
ngl
e-v
aria
bleo
bje
cliv
ef u
nct
ion
.Them
ult
iva
ria
blee
xte
nsi
onl
o
comput
ingasi
mil
archan
gein出evar
iabl
evecl
oris
6
.5 ADDITIONALEXAMPLES
ÅX= ー[問ー '~f(X) (
6.1
4)
Threeaddi
tiona
le xamplesa r
ep re
sentedin出 issec
tion
.Withmanyo fthenumerical
tec
hniquesalready programmed,o btaini
ngt hesolutionisam a
ttero fj ud
ic i
ous
Theo ri
gina
INewton-Raphsonisn otknown foritsr o
bus
tnessors ta
bil
itya n
d
app
licat
ionoft h
en umerica
Ip roc
edur
es.T hissecti
onalsop rese
ntssomec re
ativ
eu se
Equat
ion( 6
.14)sh
arest
hesamedi
s a
dvanta
g e
.Tocont
rolthedes
ignvaria
blechange
s
oft h
e methods a nde x
p l
oresn onq
uad r
aticp roble
ms.百l ef rrs
l examplei s 出e
andtobringitunder由eschem巴ofa1g
orit m(A6.
h l
)theleft
-han
ds i
deisdefin
ed邸
Rosenbrockproblem[ 9]
.百lIsexamplewasamongt hosec re
atedtoc ha
11eng
巴 白e
thesearc
hd i
rec
tionv巴ct
orS followed by ast
andar
do ne-dim
ensiona
Is te
psiz
e
numeri
caltechniquesfo
ru nconst
rainedminimiza
tion.Itisalsosometi mesref
err芭dto
comp
utation.Thi
sister
rne
dthemo
d i
fiedNewtonmethod.Thecompletealgo
rithmi
s
asthebanana
f u
nction.Ifyouhaveacopyo fth巴Optim
i<.ationToolboxfromMATLAB,
asfol
lows.
youwi 1
ls e
e山i sa sparto f出巴 toolboxdemo.Youwi 1a
J lsonote山a tthetoolbox
現i

cont
ainsmanyo f出巴 technique
sd ev
el opedinthi
ss e
ction.Thes ec
on dexamplei sa
Algori的m :ModlfledNewtonMe的 od{A6.9) yva¥u
iftJ

sol
utio
ntoan on
lineartwo
- p
o i
ntboundar eproblemthati
sd ue10由eN avier-
St o
kes
Step1. ChooseX,JN 叫u at
ionsdescr
ibingflowd uet oas p
i nn
ingd i
sk.百1 巴lastisa nunus ua
¥d at
afi凶ng
E"E2'E
3:(tol
eran
cef o
rs t
oppin
gcrit
eri
a) exampleusingBeziercu
rves.Oncea ga
i ntheOp t
irn
iza
tionT o
o lboxpresent
sit
sv ersi
on
Seti=1(ini
ti
ali
7.
ei te
rat
ioncou
nt巴r
) ofthedat
afitt
ingexamplewhenr unnigo
n ptdemoattheMA T LABprompt
Step2.Thes ear
chdirec
tio
ni sobtai
nedasasolut
iont
o
[H(X
j)]
Si=-Vf(X 1; [
) 町i s出eH e
ssian 6
.51 Example6.2-RosenbrockProblem
.
Xi叶 =Xi+α,
/Si; ,
AX=α.SI
αi
"isd
ete
rrn
inedbyM
ini
miz
ingJ(
Xi )
+l
TheR
ose
nbr
ockproblemi
s
S
te .I
p3 fVf(X
川 )TVf(Xi
+I)三E
3' c
onv
erg
ed
r
I
f (X
I )ーf
仲 1 (Xi
)1:
;EI
' s top (func
tionn otcha
ngi
ng) Minimize f
(xl・
X2
)=1
00(
x2-x
T2+(
) 1-X
I)2 (
6.1
5)
TsX:
IfAX :
;
;E
2・SlOp (designnotchanging) ; -
2:
:;
;X
2:
:;
;5
S
ubj
ectt
o: -
2::
;;x
l::
;
;5
254 N
UME
RIC
ALT
ECH
NIQ
UESFORU
NCO
NST
RAI
NEDO
PTI
MIZ
ATI
ON 6
.5A
ODI
TIO
NALE
XAM
PLE
S 255

Thes
idec
ons
tra
int
sar
eus
edf
ord
raw
ingc
ont
our
s.Thes
olu
tio
ntot
hisp
rob
lemi
s
> RandomWalk('Example6_2',[
> 32 ],200,l
.Oe-08, 0,l,20)
;
x=1.0; ;
x=1.0; I=0
.0
The problem: Example6_2
ans
2.0000e+002 1.0000e+000 1.0000e+000 1.2327e-007
Thcp rob
lemisnotoriousfr犯 q
o uiri
ngal ar
genumbero filer
ati
onsforconverg叩 c
es.
Changesindesignares mal
la sthesolu
tionisb e
inga pp
roache
d.Heret h
eRandom Sin
cet h巴r
ea r
enos topp
ingc ri
ter
iabui1
tintothemethod( wa
ss ug
gest
edasan
Walka ndConjugateGradienlmethodsareuse dtoexaminethesolu
tion.Botht h
ese ex
erci
se),th
emethodranfor200iler
ati
ons(
fi
rs
tvalu
e).明 t
efi
nalval
uefort
hed
esi
gn
methodsarec hang
e d10drawa pprop
rialeconlourleve
ls.Toa voidc1utt
er,dis
able V削 orand山eo bj
ect
ivefuncti
onareveryimp
ress
ive:
pri
ntingle
xlinforma
tionon批 l ine
sr e
presen
tingdesignchang
es.A lso,si
nc沼山e se
methodsa
avoi
ded
rer
.Thetr
u
nf
ac
o
巴o
r200i
fthede
t
s
e
i
r
a
g
ti
o
nv
n
a
s,t
r
iab
h
l
e
efma
sont
lp
h
r
ec
i
n
o
t
n
i
t
n
o
u
g1
rp
0t
lo
heCommandwindowi
ti
sp r
ovidedastheoutpu
s
l
randomwalk:;
x=1.0; ;
x=1.0; I=1.23e-07
fromlheprogram,alongwlthIh巴lin
alvalu
es.Ast hefigu
rcisbeingdrawn,i sc
ti 1ear
th
attheprogr
esstot h
es ol
utioni
ss l
ow. Sol
utio
nUslngCo 呼ugateGradlentMethod:Thei
nvo
cat
ionando
utp
utfrom
t
heCommandwindowi
s

Solu
tlonUsingRandomWalkMethod: Fi
gur
e6 .7pre
senl
st heres
ullo f
ex
ecu
tigRandomWalk
n .m f
ort
hl
sex
amp
le.T
h巴p r
ogr
amin
voca
tiona
ndou
tputfr
om

∞njugateGradient('Example6_2',口 ),
2 200,
1.Oe 08,
0,
四 1,
20)
The problem: Example6_2
曲eCommandwindowi
s
No. of iterations: 200
ans
9.6B07e-001 9.3700e-001 1.0222e-003

Thes
olu
tio
nis

c
onj
uga
teg
rad
ien ;=
t:x 0
.96
80;x
7 ;=0
.93
7; r=1.0222e-03
Thi
sapp
ear
snomatchfo
rth
eRandomWalkmethodf
or出i
sin
ves
tig
ati
on.F
igu
re6
.8
t
rack
s由edesi
gnchan
gesonth
econ
tou
rplot
.

N
M
6
.5. ー
2 Example6.3 Three-DlmensionalFlownearaRotatingDisk

Thisexamplerepres
enlsanot
herofIh
ee x
actsolu
tio
nsto出cN avier
-Stoke
se q
uation
s
fromfluidmecha
n i
cs.Then onl
inea
rt wo-
pointbou
ndaryv a
lueproblemdescrib
esa
visco
usf lo
wa r
ou n
daflatdis
k出atrota
tesabou
t四 axisper
pendicu
l釘 toit
splanewi出
ac onst
anta ngularveloc
ity
.A fte
rs uita
ble児 def
mitio
n[ 1
0]t hem at
hematica
l
des
cript
iono ftheproblemisthefol
lowingse
to fcoup
ledn o
nlinea
re q
uatio
nsw it
h
boundarycondi
tionsattwopoin
ls:

2F+H'=0 6.
(16a
)

-
1 。 2 3 4 5 H-G2-F"=0
F2+F' (
6.1
6b)
X唱

F
lgu
re6
.7 Randomw
alkm
eth
od:E
xam
ple6
.2
. 2FG+HG'-G"=0 6.
( 16
c)
256 N
UME
AIC
AlT
ECH
NIQ
UESF
ORU
NCO
NST
RAI
NEDO
PTI
MIZ
ATI
ON 6
.5 A
DDI
TIO
NALE
XAM
PLE
S 257

Y
I Y2 Y
I(O
) O
Y
2, Yi+Y尚一え Y
2(O
)
, ~II (
6.1
9)
Y
3ー Y4 Y
3(0
)
Y
4
Y
;
2
YIY
3+Y
-2Y
I

v'5 Y
4
Y
5
(
(
O
)
O
)

x2

Thcs
tat
ceq
uat
ion
s(6
.19
)釘 .
cin
tcg
ral
edu
sin
gMATLABf
unc
tino
o d
e45
.

.
.
M SolutlontotheProblem:Thet h
ree-
varia
bleproblemissol
vedusingtheDFP
method
. Example6_3.m r 芭tums theobject
ivef un
cti
on.Itcal
lst h
ef unc
tio
n
Ex6_3_state.mwhichr ctu
rnsthesyste
m巴q uat
ionsinsta
tefo
nn.Thec a
lltoth
e
DFPmethodw i
th白ei n
it
ialdesi
gnvecto
ro f[1-18 Jwith20it
era
tio
nsoftheDFP
method,andatole
ranc
eforthegolde
nsectio
no f0.0
001isshownbelo
w.AJsointh
e
ca
llistheinp
uttolheupp
erboundc a
lcu
latio
n.

U
sag
e 'Example6_3',[
: DFP( 1 ・ 18],
20,
0.0001,
0,1,
20) (
6.2
0)

Thef
ina
lva
luef
ort
hed
esi
gna
fte
r20i
ter
ati
onswas
。 2 3
x
t
4 5
x
;( =
ゆ) 0.
510
1; .
t
;
(
t.
t)=
か -0.
615
7;x
j(併ゆ=1
0.7
62;j=
7 5万 08e心06(
6.2
1)

F
lgu
re6
.8C
onj
uga
teg
rad
len
tme
tho
d:E
xam
ple6
.2
. 1
11etol
eranc
ef o
rt h
eg o
ldensec
tio
nwaso nly0.0 01
0 .h i
spo
ssi
blcl
hco
bje
cti
vc
c
annotdec
rcascun
lilasmal巴rt
l o
ler
anc
eissp
ecif
ied.
Thepubli
shedvalu
esforth
edesi
gnvar
iab
lesar巴

)= )=; H(O)=
F
(O 0
;G(
O 1 0 (
6.l
7a) ;
x=0.5101; 弓(物)=-0.6159 (
6.2
2)

F
(∞)=0; G( )=0

(
6.1
7b) whichisr emarka
blyc l
osetoI h
ev al
uesobtainedbyt heDFPm ethod.Thev aJueof
xjisIL
sl
Lall
yn o
ts p
ecifi
edbUIisabout7.Sinceitisasubsti
tuteforinf
iniy,
t theJarg
er
Equat
ion
s( 6
.16)areco
n v
ertedωst
a t
es pa
回 f onn(s
白 Chapt
er5,Example5.
3)
.The numbers houldnotbeap robJ
em.
des
ignvari
able
sa rEthemissi
ngboundaryc ondi
6or
tsonF '(
O G'(O)andt
), h
ef i
nal Example6. 3isnott r
ivi
alp ro
blem.Thei nteg
rationish i
ghlys e
nsiti
vet othe
val
ueoftheindepen
dentvar
iabl
e(inlie
uof∞ .Theo
) bj
ect
ivefun
cti
onis出esquar
吋 ini
tia
lv alue
s.A r easona
bles t
arti
ngp o
inti sessen
tialtop reventthei n
tegra
tion
cr
rorint
heintegr
atedvaJ
uealthefi
nalcond
ition. fromg enerat
ingNaN' s( n
olan umber).Thes econddesignv ari
ablemuslhavea
ncgativ
es ign.Theexampl巴 i ll
ustr
ate
st hea pp
licationofs tandar
do ptimi
zation
TheO
ptl
mlz
ati
onProblem techniquetos oJv
ean o
nlineardiff
ere
ntials y
stem.A s imila
ra ppJi
cationcanb e
madet oproblemsi ns yslemdynamicsando ptima1contro.
lI tise ss
enti
alt o
understand白紙 t h
ea lg
orithmsoutli
nedherea r
en umerica
lt oo
1s出 attranscen
dany
Minimize f
(xl'x2
・x3
)
: Y
I(X
3)2+Y
3(x
3)2 (
6.1
8)
parti
cuJardisc
ipli
ne.
Ther
ea renumerica
Jt ech
niques山ata d
d r
esst wo-p
ointn on
1inearboundaryvalue
whereth
csl
alcv
ari
ab1
esa
reo
bla
ine
dfr
omt
hes
olu
tio
noft
hcf
oll
owi
ngi
ni
ti
alv
alu
e problemsmoree f
fici
ent
ly.However ,
computingr es
ources,
especia
llyonaPC, arenot
probl
em: aconcern.Theref
ore,t
11
ep roc
cdureadoptedin由iscxamplei sanaccepta
b1eapproach
258 N
UME
RIC
ALT
ECH
NIQ
UESF
ORU
NCO
NST
RAI
NEOO
PTI
MIZ
ATI
ON 6
.5A
OOI
TIO
NALE
XAM
PLE
S 259

f
orth
iscla
sso
fpr
obl
ems
.Event
heRandomWalkmethodi
sim
pre
ssi
vei
n出i
s
m
sta
nce.

'
1
6
.5. .4-
3 Example6 F
itt
lngBezierParametrlcCurves
0
.8 ー
8 2
"
/ ,
Theexamplei ntr
oduc
esan on
trad
iti叩 a
la nda nunusualcurvefiu
ill
gp roc
edure
. ,
a
,、 、 / ,ノ'
/i
Givenas e
to fdat
apointsaBeziercur
v e01user
-chos
eno r
derisfi
l10thedat
a.Bezier 0.
7
curve
sa repa r
ametr
icc urv
es自 制 御 官 as p
ecialcas
eo fu n
iformB-spli
nes.Bezier ,f ¥ / ,
para
metriza
tionisb ased on theB emsteinb as
isf u
ncti
ons. Any poit P on a
n 0
.6 ..、~
、 ./'町
~今占

、 〆

-、~
.,
,、---
1
Iwo-dime
nsionalBeziercurve(anyparamet
ricc u
rve
)isa C
lual
lyobtaine
dぉ P (x
(v), 圃 J

y(
v)),where0SvS1.百l eact
ualrela
tionsare 805 ー
,, ~同.一,


~、,
p ~.、
,/ " 、 ,
1
~〆、,
0
.4


1
(
6.2
3)

(

P例

v)=
[ドx升 BJ
y)= 却んn

即.
1川
(い
v 1 .
.
. /
/ 、

l'

0
.3 /
1
、 ,、
;
=0
,1
/
/ J

J
II
.;
(v
) や
)
ゾ (
1-ν
)".
1 0
.2 ノ

,/
' " ふ
.
'/
1 /
ー四一-

C
!
I
E3
0
.1
whereB;紅 E白 ev e
rtice
so f出ep o
lygontha
td et
ermin巴sth
ec ur
v .B
e ;rep
rese
ntap a
ir
ofvaluesint wo-dimensio
n alspace
.Theo rderofthecurveislI-th 巴hig
hestpower B唱

φ


ームー
i
nl hebasisf unc
tion
s.Thea clu
alc om
putat
ionso fthepo
inlSonI heC U
lveω'eell
sie
r 0
.2 0.
4 1
.6 2
usin
gm atrixalgebma ndarew e
llexplai
n巴danddocumentedi nR e
ference11
.F ig
ure xd
ata
6.9represenL~ acubicB巴z ierc u
rve.Thef ollowi
ngaresome0' 1lhemostu se
ful
F
lgu
re6
.9 A
cub
lcB自z
l日r
cur
ve.
prop凶 ie
so ft hecurveaso bs巴rve
dint h
efigu
re:

• Thecur
vei
sco
mpl
ete
lyd
efi
nedbyt
hep
oly
gono
bta
inc
dbyj
oin
ingt
hev
ert
ice
s
ino
rde
r. exampleisg e
nericasmostd eci
sionsa陀 basedon白 et ex
tfilethatcontai
nsth edata
・τ'hedegreeof由epolynomi必definingthecurveisoneless出anthenumberof tobef i
ue
programi
d.1
sn
1c
o
a
ll
t凶 v
sonm叩 ym
ial
.Amorei
-fi
m
l
e
p
s
o
.TheB
r
tan
e
t隠 a
z
s
i
o
erc
nf
a
o
I
ri
cu
t
l
si
a
n
t
i
c
o
l
n
u
sa
s
io
ref
ni
ai
s白a
r
lym
t,i
o
fu
d
u
n
l
d
a
e
r
r
.T
s t
o
h
o
is
d,
ve
rt白 s
i o
fthepolyg
o n
.
i
ts igna
lsar easonabl
em atur
ityw ithMATLABp ro g
r amm
i n
g.Morei mpor
tanlly,it
. Thefir
slandla
stpoi
ntsofthec
urvea
recoi
nci
dcn
twit
hthef
ir
sta
ndl
as
tve
rte
x.
exempli
fies出ewayt oe x
ploiltheimmensepowero fbui
lt-i
nMATLABsuppo 目.Th e
Thcremainin
gv e
rtexpoi
ntsdono
tlypi
cal
lyi
Ieont
hccu
rvc
.
authorencour
agestheusertoexer
tsomce ffo
rttra
cingtheprogressofthecalcu
l a
tions
. Thesl
opcsalt
heend
softhec
urvch avet
hesamed
irec
tio
nasth
esi
deso
fth
e 血r ough白ec ode.A 101ofprogramc on
trolisbasedon出eu ser
'sc hoiceconceming
pol
ygon theo rd
ero ftheB e
zierc u
rve.A ls
ot heini
tia
lv a
luesf orthed esig
nv aria
blesa re
. Thecu
rveisco
nta
inedw
ith
intheconvexhu
llof山epo
lygon. generatedautom
aticalか
"basedont h
ed a
ta10befitt
ed.Thef unc
tioncallin
gs equence
usedin出i sexamplec anbebett
crunderstoo
dbyt hef o
llowingstruc
ture
:
I
nthisex創 npl
et hecon
veni
e n
tm at
rixrepre
sen
tat
ionsfort
hccurvear
cu se
d.Theyare
n
otdiscussedhere,how
ever.butareav
ailab
lcint
hecodc.For由isex
am p
le.th
edcsign
v
ariabl
esa r
et h
ei ns
idepo
ly gonver
tic
es.Fo =
rn 5, th
crear
c6v e凶c ω.Thefi
rstand Example6_5_3.m
CaUsuig
etf
ilctopikup山e(
c *.
tx
t)日Ic山atcon
tainstwo-columnda
ta白atwillbe
l
as
tv cr
texareknownfromt h
ed a
tapoin
ts.Thi
sleav
es4v e
rtic
esor8d巴s i
gnva
riab
les
f
it(Ex6_
5_3.txt)
n=
for 5
.
τ'
hrowsupani n
putd
ialo
gboxt oobta
intheord
eroffitfromtheuse
r(0 5 ) =
Ca
llscoeff.mw i
ththeord
eri n
forma
tion
Example6_ 4.m: 百 l
ism-f
i
Ici
sas t
and
-alo
neprogramtoru
nt hccxamplcint
hi
s C
allscomblnatlon.m-c alcu
lati
o 1c
n0' ombin
ationforBcrns
teinb
asi
s
sc
cti
on.TypingExample6_4alth
epromptsho
uldstar
tthcpro
gram.Actual
lyth
e C
all
sFactorial.m-c acu
I la
tesfa
cto
ria
lofani n
teger
260 NUMERICALTECHNIQUESFORUNCONSTRAINEDOPTIMIZATION 6
.5 ADDITIONALEXAMPLES 2
61

C
all
sC urv
e_fit
.m whichhandlest heo pt
imi祖 t ion objective funcヒionvalue: 0.2497
CaIsDFP
l iteration number: 3
CaIsBez
l 一Sq_Err.m一c alc
ul ationofO~対je
郎:ct“iv
刊 ef
unc
tio
n gradient length squared: 0.0546
Ca
llsgr
i
悶's
df
伽un.m-c alculat
io no fder
iva

叫tiv巴s objective function value: 0.1830
Ca
llsGold_Section一nV a
創ι
r
川'
.m

首官 - 1Ds t
epsi ze iteration number: 4
Call
sUpperBound_nVar.m-b ra
c kett heminimum gradient length squared: 0.1322
objective function value: 0.1605
Si
ncethe
reareeig
htdesi
gnv a
ria
bls,
e a
11o ftheinform
ati
onexc
eptfo
rite
rat
ion iteration number: 5
num
ber.conve
rgen
cecri
ter
ia,and白巴 obj巴cti
vef un
ctio
nissupp
res
sedfr
omt he gradient length squared: 0.0573
Commandwindowtopr
eventsc
rol
lin
ga ndlos
so fcomp
rehen
sio
n. objective function value: 0.1467
百lesi
gni
fic
ante
lem
entsin出iscodea
r芭a sfollo
ws: iteration number: 6
gradient length squared: 0.0374
• Pick
sup白ed at
af i
lethroug
baf il
es e
lec
tionbox. objective function value: 0.1437
• Usesaninputdia
10gboxt oqueryt h
euseront h
eorderofthec町 ve
. iteration number: 7
gradient length squared: 0.0071
• Theord巴rdete
rminesthesiz
eo fthecoe
ffic
ien
tm at
rixAa ndi
tisa u
tomatica
11y
gen
erat凶.
objective function value: 0.1433
iteration number: 日
• Thenumbero fde s
ignv a
ria
blesisautoma
ticall
yd e
termi
ned.Oncea gainitis gradient length squared: 0.2793
basedon曲巴 orderofthecurv
e. objective function value: 0.1415
・ Theini
tia
lv a
luesforthedesignareautom
atic
a l
lygener
atedb a
sedont heda胸 iteration number: 9
tobefi.
t gradient length squared: 0.4337
・ TheDFPm etho
di susedtofindtheoptimum. objective funcヒionvalue: 0.1401
• Theobjec
tivefuncti
oniscomputedinthegene
r cf
i i
IeBeziecSq_Err.m.The U
I
Fromt hedataa boveitappearsthatt hee町o risa round0 .14andisd i
ffi
culttor αiu
ce
dat
as p
eci
ficto出e巴x amplearepassedthrough出eMATLABg lo
balstate
m en.
t fu
rth
er.Ita l
soa ppearsther edu
ctioni nt h
eo bject
i v
eisa c companiedbyt heincrea
se
・ Theorigi
naldatasetand白巴 B ez
ierc u
rvefit
tingth
ed a
taar,d
巴 is
playe
da tthe "
' i
nt h
eg radi
ent.afteracertainnumbero fite
rations
. l
tismovingawayf roms at
i s
fyin
g
end
. th
eFOC.Theb e
stv alu
ef ortheFOCi sa bo
ut0 .007a nds ta
rtstowo rse
nw ithf u
rthe
r
・ Theobj配 t
ivefuncti
ona ndth巴convergen
ced at
aforeachitera
tio
na r
epri n
ted
'
1
1
'
it
era
tIons
.Itisq uitepossible白紙 n umer ic
ali naccuraci
e smayb eap roblema sther
e

叩訓I d - - R 崎浦W岨 43
toth
eCommandw indo
w . ae巴x
r tensivec omputationsi nvolvedi ne achi terat
ion.I tisa lsolikely白 at白e
numerica1gradientc om
puta ti
onmayn eedtober efin
ed.C urren
t l
y出egr 叫 ient
s釘 e
ObJ
ectlv
eF un
ctlon
:Th巴 o
bjec
tiv
efu
nct
ioni
sthe1開 s
tsq
uarede
rro
rov e
rallo
f computedu singf orwardfini
tedifferencewi thas tepofO .O .T
O1 hesearep aramete
rs
t
hedat
apoi
ntsbet
wee
n出eact
ualdat
aan
dthefi
tt
edBe
z ie
rcu
rve
.Iti
sexp
r'巴sse
das tl
ta
tn 田 dt ob巴 巴x ploredi noptimi zationast h
e r
ei snou niversalseto fv al
ues
fo
ra l
lc lasseso fpr oble
m s.
Figure6 .1
0i llu
stra
tes出eo rigina
1d ata叩 dt heB eziercurvea 白er出el a
sti t
erat
ion
.
エI
IIDa

Mi
nim
ize
: 六X): y-Y
BT ,
帥 (
6.2
4) Thepol ygonsa r
en otshowna so u
re fforti
st og en巴ra
tet hec町v e.τhefitisdefin
itel
y
1
<=1
'" .
J
acc
eptablean dthereisprobablyli
t t
le白eB e
zi ercurveca ndoa boutac o
u p
leo fpoin
ts
﹄ドヨ丸山

The f
oll
owin
gi nf
orm
ationiscop
iedf
romt
heCommand window (
thef
il
eis th
ataren otv erysm oothlylocat
ed.I tisp r
o bablyt he
sep ointstha
tdon ota110wt h
e
Ex6
_5_3.tx
ta d出eo
n rd
eris5
): obj
ectivefunctIontod ec
reasef u
rtherw itho
uti ncreasi
ngt h巴gradien.
tThisc onclud
es
t m

ano
theri nnovativeu seo fu n
constrainedo ptimizatio
n.百l ea uthorhasu sedt he
se
itt

持 Bxample6_4 cur
vest ooptimallyd es
igna ir
foi
lsf o
rl ow-spee dflig
h.
t
iteration number: 1
Eli--

gradient length squared: 5.0001 NoteonFOCf orUnconstrainedMinimiz


a t
ion:明 白 examplehasal
ert
edus
objective function value: 0.5302 toth
eq u
est
ionofFOCVf=O .Ifa
nal
yti
calcomput
ationofth
eder
ivat
ivei
spos
sib
le
iteration number: 2 foraprobl
em.the
nFOCh asthelik
eli
lto
odofb ei
ngmet.lndes
ignprob
lemsli
ke
gradient length squared: 5.6890 Example6,
4
.w h
e r
etheele
mentsoft
hegrad
ientvec
torha
v eth
eform
H
262 NUMERICALTECHNIQUESFORUNCONSTRAINEDOPTIMIZATION PROBLEMS 263

;
e 5.Fl
etche
r ,R
.,a n
dR eevcs,R .M.,F uncti
onM inimi
zationb yC onj
ugaleGradi
e nt
s.The

川印一
-邸岨一

蜘附一
OB-

aEF--
4

n"au-

hv--

t
f
l7, 0,

:
.Vo pp.1 4
9 -18 19
64.

o
Compute rJoumal .

d

Ed-
-

u
au-
圃一
6.Davidon,W.C .,V ar
iableM e
tricM ethodsf orMinimizalion,U.S.A lomicE nergy
Commissi onR e
searcha ndD evelopmentR e
p o
rlN o.ANL-5 990,ArgonneN ati
onal
5
1且
Labor
atory,1 95
9.
7.Huang,H .Y .,Unif
iedApproachωQua 命凶caJlyC onv
ergen tA1gorit
hmsforFu nct
ion
Min回国. ti
onJoumalo
, fOp 肋 uw ton刀'
I aor
yandA pp
lica
tio/
ls,Vo.5
l ,p
p.405-4 23,19
70.
{SEEE幅 窃 帽 巴)S咽司・‘
a
a守 句

8.Vand
erp1aa t
s,G .N .,Nl/lneri
calO ptim
izatio
/l Te
chniquesf orE n
gineer
ingD esi
gn,
McGraw-Hi , NewY
l
1 or k,1 9
84.

9.Hock W.
, ,andSchittk
ow ski,K
.
,T estExamplesforNonL inearProgrammilgCodes
! ,
Lect
ureN o t
esI nEconom ica ndM at
hematicalS y
stems,18 7,Spri
nger-V
erlag,Berli
n,

aq

‘ 1980
.
h、 1
0.Sch
lich
t ing,H.,BoundaηILa yerTheory,McGraw-H , NewY
i
l
I ork,1979.

。 1
1.Rogers
, G.F.,andAdams, J.A.,MathematicalElemen
tsforComputerG raphic
s ,2nded
.,

,同

h、 McGraw-H , NewY
i
l
I ork ,1 9
90.
、 、
弘 、
1
1- α、o、o PROBLEMS

。‘
・ 4

e
..
._
σ-e.
.


可)o. 0 6
.1 Applyt
heRandomWalkmethodt
oExample5
.2.


。 三三土9 6
.2 S
olv
eus
ingt
heRandomWalkm
eth
od:
0
.5
x・d
ata(
rea
dfromf
ll
e)
1
.5 2 2
.5
Minimize !
(X.,
x2
) x
=1-2み2+ x1+~-2x. +4
6
.3 Applyt
heP
att
emS
ear
chmethodt 巴5
oExampl .
2.
F
lgu
re6
.10O
rlg
lna
lda
taa
ndB
ezl
erc
urv
e.
6
.4 S
olv
eus
ingt
hePattemS
ear
chm巴白 o
d:
Minimize !
(.
x.
,x)=x
2 1-2
x
1X2+x
i +
.
q-2
x..4
6
.5 Modi,
均t heP atemS
も e
archs otha
tprogramcon
tro
lp紅 白ne
tersforconto
ur

怖い)
i
pl
otti
ng,go
l dens e
cti
on,andupperboundcal
cul
ati
oncanbesetby由 巳 国er
.
Inc
lude曲巴 promptanda llo
wf o
rdefa
ultv
alue
sincaset
heuse
rd e
cide
snotto
ta
kea d
vantageofi.
t
6
.6 Tra
nslatet
hePowe1methodi
l ntoworkingMATLABc
ode.Ver
ifyt
heso
luti
onto
Examples6.
1and5.2
.StartfTomsevera
lpoin
tsandve
rif
yt h
att
henumberof
andwhicharebes
tcomputednu
meric
aly,
l somesp
ecif
ica
tio
nsar
eneededreg
ardi
ng cyc
lestoconve
rgei
s出esame.
der
iva
tivec
om p
utati
onsifth
eyaret
obeusedfo
renfo
rcin
gthen
eces
saryco
ndit
ion
s. 6
.7 V
eri
fy白紙曲es ea
rchdi
rec
tio
nsa
rec
onj
uga
tew
ith児 s
pec
ttot
heH
ess
ianm
atr
ix
f
orExa
rnp
les6
.1加 d5
.2.
6
.8 So
l v
eu singPow
ell'sm巴山od叩 d白a
tveri
fyanytwosear
chd
ire
cti
onsa
re
REFERENCES co吋ugatewi白 r
esp
ecttot
heHe
ssi
anm
atr
ixatt
heso
lut
ion
:

.F
1 e
ltc
her
.R P
rac
tic
alM
etl
lOds
forO
叫pti
miw
tin,
o Vo1
,W
.
1 i
ley,
NewYork
,19
80.
Minimize !
(.
x.
,x)=x
2 1-2
x
1X2+x
i +
.
q-2
x.+4
2
.Bren
t,R .P
.,A l
gor
ithmsfo
rMi
lli
miz
ati
onw
ith
outD
eri
vat
ive
s,加 問t
ice
-Ha
ll, 6
.9 So
lveExample5.
2us
ingt
heS
tee
pes
tDe
sce
nt,C
onj
uga
teG
rad
ien
t,DFP
,and
E
ng1ew
oodC
lif
fs,
NJ,19
73. BFGSme 曲ods
.

3
.Powel
.M.J
J .D.,
NOl
lli
nea
rOp
tim
iWl
io,A
n c
ade
micP
res
s,NewY
ork
.19
81. 6
.10Solv巴 us
ingt heS t
eep
es ,
t Conjugate Gradient,DFP,and BFGS
t Descen
methods自己 problem
4
.Fox,R.L.
.Op
tim
iza
tio
llMethodsforElgi
nee
rin
gDe
sig
n.A
ddi
son
-We
sle
y.R
ead
ing,
i+
.q-
!
MA.1971
. 附 凶 凶z
e f
(x
.OX
2)=x
1-2
x
1X2+x 2x
.+4
7
264 N
UME
RIC
ALT
ECH
NIO
UESF
ORU
NCO
NST
RAI
NEDO
PTI
MIZ
ATI
ON

6
.11Ve
rif
yt h
ev a
lue
sinS巴c
tio
n6.
3.3us
ingac
alc
ula
tor
.Ve
rif
yift
hem
atr
ixAa
t
出esol
utio
nis山einv
ers
eofth
eHes
sian
.
6
.12Ve
rif
yifthem
atr
ixAa
tth
eso
lut
ioni
sth
ein
ver
seo
fth
eHe
ssi
anf
orDFP
me出odfo
r
Minimize f(I,
X x)=
2 x1-2xtx2+xJ+x~ -2x1+4
6
.13 Develop山eBFGSmethodi ntoMATLABc odeandveri
fythecaJcu
lati
onsin

6
.1
Sect
ion6.
4 Developt
3.
4
h
.
eM odi
fiedNewtonmcthodi ntoMATLABc odeanda pplyitto
NUMERICALTECHNIQUES
Example5.2. FORCONSTRAINED
6
.15 Howw illyouinc
orpor
ate白es id
econs
tra
intsint
othecod巴f
oraJloft
hevari
ous
methodsinthi
ssecti
on?Implemcnttheminthcnum
erica
lproced
ures. OPTIMIZATION
6
.16S
olv
eExamples6
.2,
6.3
.ad6.
n 4byoneo
the
rm巴t
hodo
fth
ese
cti
on.
6
.17I
den
tif
yands
olv
eas
yst
emdynamicsproblemu
sin
gan
ymethodo
fth
iss
ect
ion
.
6
.18I
den
tif
yan
dso
lvcy
ourownc
urv
efi
tpr
obl
cm.

百li
sc h
apt
erex
plo
resaJg
ori
thms/me
thodstha
thand
le 出eg c
ner
alopt
imi
zat
ion
pr
oble
m.Bothe
qu叫it
yandineq
uaJi
tyco
nstr
ain
tsa
reinc
lud
ed.Forane
ngin
eer
ing
prob
l 巴m thiswil
li nvolveb r
ingingsevera
ln onlinearr e
latio
n sintot h
ed esi
gns pa
ce.
Thisisc erta
intoi 即 応a s
et hedegreeo fdif
ficultyino btaining出cs ol
ution
.F orthe
designer山e reisa nadditi
onalb urde
no fb e
ingmorea tt
entivetot hedesignchanges
andt hecor r
espondingnumberst oc oaxthesolutionifthem athemat i
cald e
finit
ionof
thep roblemisparli
cularl
ys e
vere.InaJloflhes
ep roble mslherearetwoo u tcomesth
at
出巴 a lgorith
mss eekt oaccomp i
¥sh
.百 l efi
rstist oens ur
e曲a tthed esignisf e
asib
le
(s
atis自由aJlc o
nstrain
ts)andt hesecond伽 ti tiso ptimal(satisf
iest h
eKuhn 吊l ck
er
cond
i tio
ns).Wh i
lethef o
cusisond eterminin
g曲es olution,int i
me sofdiff
icul
ty,i
tis
esse
ntial10r ememberI hatf
easib
ili砂ismorei m portant出a toptima
l it
y.Alsou nsta
ted
in出巴 r estof白ec hapteris山a t出eo ptimalsolu t
ionmustbef easib
le.Twod i
stin
ct
approa c
he swi1
1beusedt oh and
let heconstrainedop ti
miza t
ionp r
oblem.Th efirs
t
appr oachistermed出ei ndire
cta pproachands olves山巴 problembyt ransformin
git
intoa nu nconst
rain e
dp roblem.Thes econda pproachi s10h andle出ec ons凶 in
ts
withoul回 n sforma tion-thedirec
ta ppro
ach.
Thei ndir
ectap proachisane xp
ressionofi ncremen
t aldev elopmento fthesubje
ct
tota keadvantageo f出 ecurren
tm ethods.Fore x創 nple,i
tl everagestheDFPmethod
toh andlec onst
rainedo ptima
lp roblems.Twoi nd
irectmethodsa represe
nted.th巴
ExteriorP ena
ltyF unction( EPF)method, and出巴 AugmentedLa grangeM u
ltipli
er
(ALM)m etho.Th
d ed ir
ectapproachhandlesthec o
nstraint
sandt h
eo bje
ctivetogeth
er
wi山outany凶 n s
for m
ation.Fourmethods蹴 p陀 s ented.百 lemethodsi n出i sbookare
SequentiaJL ine
arProgramming( SLP),SequentialQu adraticP rogramming(SQP),
GeneralizedReducedG radientMethod(GRG), andS equentiaJGra d
ientRestorat
ion
Algo rithm(SGRA).

265
2
66 N
UME
RIC
ALT
ECH
NIQ
UESF
ORC
ONS
TRA
INE
DOP
TIM
IZA
TIO
N 7
.
1PR
OBL
EMD
EFI
NIT
ION 267

7
.1 PROBLEMDEFINπION F
口信

Thes
tand
ardfor
mato
fth
eno
nli
nea
rpr
ogr
amm
ingp
rob
lem(
NLP
)isr
epr
odu
cedh
e陀

fo
rcon
venie
nce
:

M
ini
miz
e f
(x 2,• • • • Xn)
"X (
7.
1)
S
ubj
配 tt
o
: h
k(x
"X2 n)=O
'...• X . k=1
,2,• • • .
1 (
7.2
)

g
j(X
"X2
.・・
..X
n)~ 0,j 1 = m
.2,• • • . (
7.3
) 9<0

XISXj~xll i=I.2.....1
t 7.
( 4
)

nv
I e
cto
rno
tat
ion

M
ini
miz
e f
(X. [
) Xl" (
7.5
)
S
ubj
ectt
o
: [
b(X
)]f=0 (
7.6
)

[
g(X
)]", S0 (
7.
7)
X
1nw
SX:
;;X
"1' (
7.8
)
3 4
F
orthi
schapte
rthefollow
ingind
icesar
er c
serv
ed:I.n
t umberofva
riab
lω;.n
1 umb
er
o
fequa
litycon
str
ain
ls;m.n umbe
ro fine
qua
litycon
stra
int
s.Manyo fIh
ealgor
ithm
s
a
ndm et
hod spre
sen
tar eason
ablelev
elofd i
ffi
cul
ty.A two-
var
iableprob
1em(fo
r 1g
F u
re7
.1G
rap
hic
剖so
lu
1i
onf
o
rEx
amp
le7
.1
.
g
rap
hicli
a 1
lus
tra
tio
n).withas in
gleequa
lityandi ne
qua
lit
yc o
nst
rainti
su s
edto
i
ll
ust
ra
tet h
ev ar
iousalg
ori出ms.Al1o fthefunct
ionsarenonl
ineara1t
houg
ht h
e Fi
gure7.1displa
yst h
egrap
hica
ls o
lut
ionto出巴 prob
lem.Itisc le
arfromthefi
gur
e
c
ons
tra
intfunc
tion
sh av
es i
mplegeome
tricshap
es. t
hatthesolu
tionisatxT=1.xi=1(why?).Thevalueoft hefunct
ionis3
.A simpl
e
a即roachtoth
es o
lut
i o
nofth
ep ro
blemi
s10u印 刷u a
tion(7.lO)1
a 0elimi
nat
eoneof曲e
7
.1.
1 ProblemFormuJatlon-Example7
.1 va
ria
bles針。m山ep roble
m由e re
byredu
cingi
ttoasin
glev
・ a
riab
leconstr
ain
edpro
ble
m.
百li
sisnotdonehe陀 buti
ti
sag oode
xer
cis
e.FIg7_l.m1willcrea
tethefi
gu
re.
Example7 .1i s as i
mplemathemat
icalf orm
ulat
ion.Itdoesnot陀 pr
esen
ta n
y
eng
ineeringprob1em.I
tiscons凶 cte
dtoh a
v easolu
tiono j=1叩 dx
fx i=1f o
r恥 7
.1.
2 NecessaryCondltions
∞nstrainedprob1emandxj=0.8520a dx
n i=0.8520f o
rtheunc
ons回 i
nedprob
1em
.
Thet woc on
str
aintfunct
ion
sh av
es impl
eno n
1ine
ari
ty.The叫 ua
lit
ycon
stra
inti
sa
引l
e n
eces
saryc on
dition
-ort he Kuhn-T
ucker(KT
)c o
ndit
ionsf o
r 由e
ci
四lew hiletheineq
uali
tycon
stra
intisane¥
lips
e.
problem-wasdevcl
opedinChapte
r4.Itisb a
sedonth
emin
imiza
tio
no f出E
Lagra
ngia
nf u
nct
ion(円.Theco
ndi
lion
sare
M
ini
miz
e f(x"X
2: x1-2x ~X2 +x
) Ix~ -2x1
r+X +4 (
7.9
)
Min
imi
ze
S
ubj
ecl
lo: h
(X"
X2: xr+xi-2=0
) (
7.¥
Oa)
F
(xl.'
Xn'A
I..
.A's
f I.
.
.sm)=fxp …xn)+λIhl+…+
( λ内+
g
(x"X
2:0
) .
25x
T+0
.75x~ -1S0 (
7.l
Ob)
P
ぱ1+・ +sg "
, "
, (
7.1
1)
5x
O: l:
55; 0:
5x 55
2: (
7.¥
Oc) 1
F
t田1
! 0bed
own
loa
dedf
rom白 ew
ebs
i旬 a
r
ein
di
ca
le
dbyb
ol
df
ac
esa
nss
e
ri
fIy
pe
.
7
.1 PROBLEMD
EFN汀'
I ON 269
268 N
UME
RIC
ALT
ECH
NIO
UESF
O円C
ONS
TRA
'NE
DOP
TlM
IZA
TIO
N


ぞ A4
L/
sub
j配 tto山econs汀aint
s.百le陀 aen+1+munknownsi
r ntheL a
grang
ian.Thesame xi+xi-2=0 (
7.l
7c)
numbero fe
quati
onsisreq
uII
吋 tos o
lve出巴 pr
oble
m.Thes
ea r
ep ro
videdbyt
heFOC
orKuhn-Tuckercon
ditio
ns.Here
'le q
uati
onsareo
bta
ine
da s E
qua
tio
ns 7.
巴t( 17
)iss
olv
eds
ymb
oli
cal
lyi
nMATLAB.T
hcr
ear
etwos
olu
tio
nst
ha!
s
ati
sfyt
hes
idcc
on回 i
s nt 7.
s( l0
c)
dF d
r • d
h. .• d
h ,
• d81.
=~J +λ 」+ー・ + L - 4 1」+ー・ +P,
.11 d
8m j=1
.2.
...n
.
x
;=1.4142; λ・=0
0


a
xi axaIaxttaxi ta x
i
JS7=0;
dx
t X
;=0;
(
7.1
2)
;
x=0.9275; x
;=1.0676;λ・=-0.1217
1e
qua
tio
nsa
reo
bta
ine
ddi
rec
tlyt
1l
fOugh由ee
qua
lit
yco
nst
rai
nls
80t
ho fthesevio
lae出ei
t n
equ
ali
lycons
tra
int
.InF ig
ure7 .
1.thefi
rs
ts o
luti
on
x・
hi X
2.,
.
...xn)=O; k=1
.2.
...
.1 7.
( 1
3) d
e
d
o
f
c
in
i
sn
te
l
o
ydo
tpro
v
凶 b

id
u
tl
easo
h
es
lut
i
e
o
c
o
n
n
.
disali
lt
led
iff
icu
lt10s
ee.Zoomingsh
ouldhe
lp.Casea

m
mc
qua
tio
nsa
rea
ppl
icdt
hro
ught
he2 c
ase
s
Caseb
: g=O 百l
i
ses
tab
lis
hesf
oure
qua
tio
nsa
s

s
jj=O→i
8 f鳥=0 t
hen 8j<0
4xt-4x内 +2x , -2+x~+2 λ x , +0.
5sX1=0 (
7.1
8a)
島>0 7.
( 14
)
f8j=0 l
i hen
, .5ß~=O
-2xf+2xx2+2入X2+1 (
7.1
8b)
TheKTc
ond
iti
onsa
ppl
yon
lyi
fth
epo
int
saer
r e
gul
ar(
seeExample4
.3)
.
xi+x~ -2=0 (
7.1
8c)
A
ppl
lca
tio
n0't
heKTC
ond
iti
ons
:百 eLagrangian
0
.25x~+O万 x~ -1=0 (
7.1
8d)
F(x"x2• λß): x~ -2xTx2+xT+x,x~ -
2x
, +4+
Equ
ati
ons(7.
18)脱 s
olv叫 s
ymb
oli
cal
lyandl
heo
nlys
olu
tio
nsa
tis
fyi
ngI
hes
ide
λ(ヰ +~-2)+ 戸(0.25 x
i+0.75~ -1) (
7.15
) c
ons
tr剖nt
ss,

; t i -a-
r
Theee
qua
tio
nsa
res
etupt
hro
ugh
x
i=1
.; 弓=1
0 .0
; i
.
.
"=-0.
500
0; s"=O

dF (
7.1
6a)
E;=44-4xtX2+2XI+xi-2+2hi+05PXl=0 whichwase x
pected(fo
rthedes
ignv a
riab
lcsnotlh
em u
lti
pli
crs
).Thevalu
co fs"=0
i
sn o
te x
pecledaslhi
sisanact
iveconst
raint
.TheKTc ond
ition
scanbeconsi
dered10
bew e
aklysalis
fie
da ssisnotst
rct
i 1yposit
ive
.Asi nChapt
er6.where
verp o
ssib
le.
(
7.1
6b)
dF
ァ = ー2xT+2xx2+2i
C
1X2
.x
・ ,
2+1
.5sX2=0
出eKTc on
ditio
nsareusedtocheckforconver
gen
ce.

h=xi+x~ -2 。= (
7.16
c)
7
.1.
3 ElementsofaNumericalTechnlque

T
hereisad ist
inc
Idi仔e renceinthenumer
icaltechniqu
esw it
hi ncor
porati
ono ft
he.
Thef
our
lhe
qua
tio
ni e
sdev10pedt
hro
ugh c
onst
rain
lS.eveniflheideaofusi
ngas e
archdir
ectio
nv e
clori
ssti
llusefu.
lThemajor
d
iffer
encesi
nt ea
h 1gorithmsofth
ep r
eviou
schapterwas山巴 wayt hesearc
hdirec
tio
ns
Casea
: s=O Witht
hi
sin
for
mat
ionEqu
ati
ons(
7.16
)become wer
ee sta
bli
shed.Tou nders
tandthenecess
aryc han
ges.theg e
ne r
ala pproa
chfor
u
nconstr
ainedoptim
izationasseeninthepre
viouschapte
rw a
s:

4x1-4Xx2+2x 1 十 x~-2+2 λ x, =O 7.
( 17
a)
GeneralAlgorlthm伺6
.1)
-2xT+2x x2+2,
λx2=0 (
7.1
7b) Ste
p1. ChooseXo
270 N
UME
RIC
ALT
ECH
NIO
UESFORC
ONS
TRA
INE
DOP
TIM
IZA
TIO
N 7
.21
NDI
REC
TMETHODSFORC
ONS
TRA
INE
DOP
TIM
IZA
TlON 2
71

S
tep2
.Fo
rea
chi
ter
ati
oni it
era
tio
n.百l eu nc ons
住a in
eda lgorith
mi t
selfexecutesmanyi t
era
tion
s.T hiswould
叫u
r i陀 ar obustu nc
onstraine
dm inimizert oha n
dleal a
rgeclassofp robems.Th e
D
ete
nni
nes
ear
chd
ire
cti
onv
ect
orS
j
BFGSmethodi sr ob
ustandi mpressi
veo veral ar
geclassofproblems.
(
I
twouldb
eni
cei
fth
eob
jec
tiv
ede
cre
ase
dal
ongt
hisd
ire
cti
on) Ap repr
ocessingl aski n
volvest 叩 f
r ormi n
gt h
ec onstrai
ned problem intoa n
S
tep3
.C alcu
lateAXj=α Sj , unco
nstraine
dp ro bl
em.T hisisl ar
gelyacc omplishe
dbya ugmentingtheo bje
ctive
Note:AXj i
snowafunct
ionofth
escal
ar(Xj
asSji
sknownfromS
tep2 fun
ctionwitha dditi
onalf u
nctions白紙 r ef
lect白 ev iol
ationoft e∞n
h st
rain
tsv ery
j
(X i
scal
led白este
psizeasi
test
abli
she
s白el en
gthofAXj si
gnif
ican
tly.These釦 n c
tionsa r
er efe
rredt oas由ep e n
al,f
η 附 ctio
ns.百l e印 Wお

si
gnifi
cantacti
vityin山i s紅 白 a tonet imewhichl e
dt oenti
refarni
lie
so fdiffe
rent
a
;isde
ter
rni
nedbyM
ini
miz
ing
f(X
;+I
)'where
typ
eso fpenallyf unc
tionmethods[ 2).Thef irs
lo fthesewast heE x
1eriorPenalty
X
j+ ,
1=X +AXj Funct
ion( EPF)m et
hod. Th ef ir
stv ersiono f ANSYS [ ] 白紙 i
3 ncor
pora1ed
opt
imizati
oni nitsfin
iteelemenlprogramr eliedont h
eEP F
.TheEPF( p
resente
din
Asthea bovesteps釘 er eviewed,inS tep2adilemman 民 dstober e
solved:Sh ou
ld 白en extsection
)hads evera
ls hortcomi
ngs.Toa d
dresst h
ose出 eI nte
riorPenalt
y
thesearchdirect
ionS jd ecr
e ae出eo
s bjectivefunction0's ho ul
di tattempttosa t
isf
y Funct
ion( IPF
)methodswered eve
lopedl eading10t h
eV ariabl
eP enal
tyF unctio
n
theconst
raints
?(Itisassumed出a titcann otdob otht houghv eryoftenitwill)S
. inc
e

r
(VPF)m ethods.I n白 istex
,to
. nlyt h
eEPFi sa d
dressedl a
rgel
yduet oa cademic

t古若干抱沼44j532
fea
sibi
lityismorei mp orta
n t出a no pti
ma l
ity,itis回 s iertoi denti
fyt helatt
era sa in
tere
s.
tI nviewo f白ee xcel
lentp erform
an ceof出巴 d ir
ectmethods,thesemethods
sign
ific
antinfluenceind eterrn
iningthedirectio
n.Th isismored ifficuI
tthanitsounds wi
llp robabl
yn otbeu s
cdt odayf orcontinuousp roblems.Theya rconcea gai
n
ase achconstr
aintc a nh avei t
sownf avori
ted ir
e c
tiona tt hec urre
ntp oin.
tSuch impor
tanting lobalo p
timi
zatior
lt echni
quesf orconstrai
nedp rob
lems.Thes econ
d
occasio
nsc a
llforat r ade
-offandt os e
ei fi
ti spossibleton egot
iatead ecreaseint h
e me白odp 民s entedinthi
ss e
ction,leAugmentedLa
h gra
ngeMethod(ALM), islhebesl
objec
tivefunctionasw ell.I
ti scle
art ha
tS tep2w il
li nvolvei nvestmentofe ff
ortand oftheSUMT.l tsexceedingl
ys impleimplementation,it
squalit
yo fsolu
tion,andit
s
somes oph
istic
ation. ab
ili
tyt og e
neratei nfonn
ationont heL agrangem ulti1
pie
rsa llowittos eri
ousl
y
Stp3i
e snotfarb ehindi nthe児 qui回 mentf orsp田 ia
lh andling.On cethed i
rectio
n chal
lenge由巳 directtechn
iques.
i
se sta
blished(Step2 ),whatk i
ndo fstepsizewillbea c
c ep
ta bl
e1S everalresul
tsa re
poss
iblc.Fir
st,thco bjcctivefunctionca nb 巴decreaseda longt hedirec
tion.Second,
curre
nta ct
ivec o
nstraints( incl
uding由巳 e qu
alityc o
nstrain
ts )canbecomei nact
ive, 7
.2.
1 E
xte
rlo 町 Method
rPenaltyFunctlon(EP
viola
ted,orc a
ns t
il
lp 陀 ser
v e白 eactivcstate
.T hird,currentinactiveconst
raintsc a
n
undergoas imil
arc ha nge0"1st
ate
.F ourth, prob
ablymosti mp or
tan ,
t c
urrentviolate
d Thet ran
sform
ati
ono fthcopt
imiz
ati
onproblem(7
.1ー(
) 7.4
)10anu n
cons
tra
ine
d
cons釘aint
sc anbecomea ctiveorinactiv
e.Iti sdi
fficu
ltt oencapsulatethisdiscussio
n problemismadepossi
bleth
roughapena
ltyf
unct
ionfonn
u l
atio
n.Thetra
nsfo
nne
d
inag eneri
ca lgori
thm .Somca l
gorithmscombineS teps2and3i ntoas inglestep
. uncons
train
edproblemis
:
Somed ividethei t
erationintoaf e
asibi
litycomponenlanda noptimalitycomponen .
t
Inessencetheg e
nerica 1gorithmfor白 isc hapte
r,whichi sn otparticul
arly凶 eful,i
s:
Minimize F(X,'
1
1''
g)=f
(X)+p
(X,'
1,
1 '

) (
7.1
9)

GenerlcAlgorlthm(
A7.
1) X::
S
;X/:
S
; ヰ i=1
,2,•• •,
1/ 7.
( 4
)
S
tep1
. Ch∞seXo
S
tep2
.F o
re ac
hite
rat
ioni whereP(X,'h,'
g)isth
epen
alt
yf u
nct
ion
.'1a
1 n
d'ga
rep
ena
ltyc
ons
tan
ts(
als
oca
lle
d
Dete
nninese
archd
ire
cti
onv
ect
orS
j mult与J
li,
es.)
Thep en
altyfu
ncti
onise
xpre
ssedぉ
S
tep3
.Calc
ula
teAX;=αjSj
Xj
+1=Xj+AXj
(X,
p 'h''

,)='h1 "
1
"'
1
k
(L
.
X)
21+'
81 (m阻 {
lt
1
O・ ヱ
め(X)}
)21 (
7.2
0)
7
.2 INDIRECTMETHODSFORCONSTRAINEDOPTIMIZAT10N

Thesemc出o dswered ev
e l
opedt
ot ak
ea dva
ntageofcode
s白 atso
lveuncon
strain
ed nEq
I uatio
n( 7
.2),
0 if白eequal
itycons回 i
ntsar
en o
tzero,
the
irva
luegetssqu
aredand
opt
imiza
tionp r
oblems. They a
rea ls
or efe
rredtoa sSeq
uent
ialU n
constrai
ned m
ult
iplie
dbyt hepena
ltymult
ipli
erandt heng
etsaddedto白 eo
bjec
tivefunc
tion
.I f
Minim
izatio
nT ec
hni q
ues(SUMT)( 1)
.Thei de
abehind山eappro
achistorepe
ated
ly t
h巴ine
qual
itycons
trai
ntisinvio
lati
on,i
tt o
ogetssqua
redandadde
d1 0出巴 obj
ectiv
e
ca
lltheu n
consta,
i/e
1 do pt
imi
zati
o1/algo
rithmu s
ingthesol
uti
ono ftheprevio
us f
unc
tionaft
erbeingamp
lifi
cdby出巴 p ena
ltymul
tipl
ier
s.Inasen
se,i
ft hec
onst
raint
s
2
72 N
UME
RIC
ALT
ECH
NIQ
UESF
ORC
ONS
TRA
INE
DOP
TIM
IZA
TIO
N 7
.
2IN
DIR
ECTM
ETH
ODSF
ORC
ONS
TRA
INE
DOP
TIM
IZA
TIO
N 2
73

ar
eno1sat
isf
ied,then由e yarepen必iz
ed,hencethefun
cti
on'sn創ne.Itcanbesh own白紙 TheEPFi sv erysens
itivetot h
estarti
ngv al
ueoft hem u
ltipli
ersa ndtoth巴sc a
ling
th
c四 l sfo
nncdu n ∞ns凶 n吋 problemsolves出eoriginal∞m凶 nedproblema sthe fa
cto
rsa sw e
ll.D iffe
rentp ro b
lemsr espondf av
orablyt od iffe
rentv a
lu e
so ft he
mu
ltip
lie
rsr", ga
r pproach∞.I no r
derf o
rPt or emai
nf in
il
ea t山ωev alu
eso f山e mu
ltip
li巴rs
.Itisrecommendedt h
atthei n
iti
alvalue
so ft hemu l
tiplie
rsb echos enas
mu
ltip
lie
rs(1即 dcdf orav a
lidsol
uti
on),出ec o
nstr
aint
sm ustbes a
tis
ti
ed.Inc o
mputer th
erati
oo ftheobject
ivefu n
clIontothec orre
spondingt ennin山 p en
altyf u
nctiona1
imp
lement
ation血i sl im
itis陀 pla
cedb yal ar
gevalueins飽ado f∞.Ano th
erf a
cetof th
einit
ia
ld e
sign.T h
ise ns
ures出a tb o
tht heobje
ctiv
ef unctiona ndtheconstr
aintsare
∞mputerimplementationofthi
smethodis白紙 al a
rgeva
lueofthemult
ipli
ersatth
e白百t eq
uallyi mp
ortanti nd e
teロn iningthec h
angesi nt hed esignf o
r白巴 s ucceeding
il
era
tio
nisboundt ocreat
enumeric
aldi
ffi印 l
ti
es
.百l esem叫tip
lie
r百aresta
rte
dwithsma l
1 lt
era
tio
n.
val
ues田 du凶a 凶 gωme 凶 回l
ly明 白 回c hite
rati
on
.百 eu n
conslr
aIn吋 飽chnique,f
or Oner eas
onf orthetennExt eri
orPenaltyistha
tatt hee ndofe achSUMTi terati
on
ex胴 体 DFP,wi 1
¥s o
lveE qua
tion(7.1
9)f o
raknownv alueo f恥 m ul
tip
licr
s.The 出巴 desig
nw illb ei
l砕a sible( u
nti
lt h
es o
luti
oniso btained)
.T hisi mpl
iest hat出c
so
lut
ion剛 山n cdf romtheDFPc anbeconside
r凶 asaf u
nctio
no fth
cm u
ltip
lie
ra ndcan
潤1 methodd e
tenninesd e
signv alues白紙 a rea pp
roaching白 ef easibl
er egionfro mthe
bethou
ghtofas
ou
tsid
e.Thisisas erio
usd rawb a
ckifthem ethodfa
ilsp 陀 matu
r e
ly, a
sitwilloftendo.
Thcinformat
i o
ng enera
teds of a
risv a
luelessasthed esignsw ercneverfeasi
ble.As
X.=X
.(r
"・r) (
7.21
)
8 see
nint h
ee xampleb e
low.t h
eEPFs ev
e r
e l
yi n
crea
ses出en onlinea
rityofthep roblem
TheSUMTi
ter
ati
oni
nvo
lve
sup
dat
ingt
hem
ult
ipl
ier
san
d出ei
ni
ti
ald
esi
gnv
ect
or cre
atin
gc onditionsfort heme 出o dt ofai.
lIli se xp e
cted 白紙 t hei nc
reasei n
an
dcall
ing白eunc
onst
rain
edmin
imiz
eraga
in.In出巴 al
gori
thmi
tisas
sumedt
hat山e non
line
arityisb alance
db yac ¥ose
rs tart
ingvaluef orthed esign,ase achSUMT
DFPmethodi
su se
d( a
lth
oug
ha nymet
hodf r
omC ha
pter6c a
nb eus
ed,BFOSis it
erat
ionsta
rtsc¥ose
rtot hesolutio
nt h
an出cp revi
ouso ne.
巴c
r om
mended). lnthefollowingtheEPFi sa pp
liedtoE xar
nple7.1t hroughas er
iesofcalculat
ions
ra
ther出 anth roug
ht hetrans
l at
ionof山ea lgori
thmi ntoMA TlABcode.The rea r
ea
Algorlthm:Exte
rlo
rPenaltyFunction(EP丹, Method伺又2) coupl
eo fchangesw it
hr espe
c ttoAlgorithm(A7.1)
.Tor esolvet h
ep en
altyfun c
tion
Step1.ChooseXI,N.(
no.o
fSUMTi t
era
tio
ns),
Nu(no
.ofDFPi
ter
ati
ons
) withrespe
ctt o白ei n
equali
tyc onst
raintt
, hecons
traintisa ssu medtoa lwaysb ein
E;
' S(f o
rc o
n vergenceandsto pping ) vio
lati
on80出a t出er e
turnf romthemllxfuncti
onis白 ec ons
traintfuncti
oni t
se
lf.This
r~, r
!( in
it
ialp ena
ltymulti
pli
e r s
) wild
1 r
ivethei nequ
alityconstrai
nttobea cti
vew hichweknowt ob etruefort h
is
examp
le.N um ericali mplementat
iona so utlin
edi nt h
ea l g
orithms houlda llow
Ch.c I(
/ scal
ingv alueformul
tip li
e rs)
dete
nninati
ono finac
tivec o
nstrai
nts
.I n s
teadofn umericali mplementationo fthe
q=1(SUMTi te
rati
oncount
e r)
q uncon
straine
dp ro
blem,ana naly
tica
ls olut
ionisdetermi n
edu singMATLABs ymbolic
S
tep2
.C allDFPt om i
n i
mizeF(X, r% ,r~) compu
tation.Example7 .1isr eprodu
cedf orconve
nience .
Ou tpUl:xq.
S
tep3
.C on ve r
genc eforEPF
fhk=
I 0,fork= 1,2....,1
; M
ini
miz
e f
(Xj
oX2
): x1-2xTx2+xT+XIX~-2xl +4 (
7.9
Ifgj:5O.f o
rj=1 .2.. ..• m; S
ubj
ect
ω: h(x(, X
2): xT+x~-2=0 (
7.l
Oa)
I
fallsideconstr
ain
tsa res ati
sfi
ed
T h
e nC onverged,Sto p g
(x( x沙
, O. 25x r+ O万 x~-1 :
50 (
7.L
Ob)
Slo ppingCriter
ia:
o: 55; 0: 55 (
7.
l0c
)
d.F= Fq F
Q -• q
- 0
-
"
-I dX= Xq* -X(q-I)*
5Xl: 5X2:

I
f( d.F l:5EI
:S t o
p( fu
ncti
onn otc h a
nging
) Figu
re7.2isthccont
o u
rplotofthetrans
forme
du n
constrai
ncdfun
c t
ionforv al
uesof
Els eIfd.XTd.X:5EI:Stop(des ignn o
tc h
angi
ng) rh= 1andら =1.Thei nc
reas
einn o
nlin
ear
ityi
sr ca
d1
iya pp
ar宅ntF
. igure7.3isthepl
ot
日s elfq= N.:S lOp(maximumi t era
tio
nsreac
hed
) fo h=
rr 5a ndrg=5.H an
dling山e sefun
ctio
nsnumerical
1ye v
enwitht h
eBFOSw il
1
Con tinue beac o
nside
rablecha
11enge
.B oththefig
ure
ss u
ggests巴ver
alpoin
ts出 ats a
tisf
yfirs
t
q←q+l orde
rcondi
tion
s.Theirclos
enessm池 田 i
tdif
fic
ultfo
ra nynumer
icaltechniquetofi
nd
rg ← r~'Ch; :←r
r 1・
Cg
theopt
imum
Sec7_2_1-
.ltisc
lear白紙 theEPFs
plolmcontainst heco
e
v
d
ere
lyi
e伽 tg
nc
e
n
r
e
e
a
r
s
a
e
st
t
e
h
st
en
h
o
n
ep
l
l
i
o
n
ea
tS
.
r
i
i
t
n
yo
cet
f
t
h
hep
ec o
r
d
ob
eu
l
em
s
e
.
s
x
q←x
q
.
symbol
icm ani
pula
tion.a c
tual
lyd raw
ingtll
ep l
ott a
kest i
me.Evaluati
ngt hed a
ta
00t
oSt
ep2 Dume
ricall
yw i
llmakeab igdiffer
enc
e.
274 N
UME
RIC
ALT
ECH
NIQ
UESFORC
ONS
TRA
INE
DOP
TIM
IZA
nON 7.
2 I
NDI
REC
TMETHODSFORC
ONS
TRA
INE
DOP
TIM
IZA
TIN 275
O

v
$eer
cno
nll
nea
rlt
ywl
thm
anyl
oc
olm
lnl
mum
s
4卜 ーャ 九
.
.
7;
..
;
..
: 4 ヨ
3 4
1

ヨl
.
.・-
-暗唱 、
、 ..ー曹、 .'" 道 3・ ~ーー-cτ ,.
.

制 N
民 M

。 z 3 4 5
xt
5
xt

F
lgu
re7
.2 E刈 阿o
rPe
nal
tyF
unc
llo
nMe
lho
d:E
xam
ple7
.1(
n.=,rg=
1 1
)
. F
lgu
re7
.3E
xte
rio
rPe
nal
tyF
unc
tio
nMe
tho
d:E
xam
ple7
.1(
n.=5
.fg=5
)
.

A
p
t
i
p
o
l
lc
nf
o
a
tio
r白i
spr
obl
emi
s
'
0
n EPFA句orlthm(
A7.
2):Thec
orr
esp
ond
ingu
nco
nst
rai
nedf
unc
- enter value for rg [default 1
] 25
ans
-1.4125 -0.1015
F(X I .X2 • 九. 'g)=(x~-2x1X2+xf+X1X~-2xl +4)+ -0.8692 1.0980
-0.6263 -1.2107
日(x~ +xi-2
)2+'
8(0 万三一 1)2
お xf+O (
7.2
2) -0.0278 -1.3266
-0.0124 1.3267
Sec7 _2_1_calc.misa nm-fi
Iet ha
tw i
llcalculat
e出esoh 瓜ona ndth evalu
eso f白e -0.0090 -0.0000
func
tion
.f o
rExample7.1.forapre d
e t
erminedsetofvalue
so fthepenaltymul
tipl
ier
s. 0.7893 -1.1267
I
tr e
quire
stwoi n
puts台。mt heu seratdif
fere
ntstages
.Thef ir
sti n
putisthevaluesfo
r 0.9775 1.0165
白 emult
ipli
ersforwhich出es ol
utions h
ouldb eobtain
ed.百 leiIs
to fsoluti
on(ther
e 1.4184 -0.1318
arenineforth
isproblem)i
sd isplayedin由巳 Commandwindow.Theu serfind
s白e Input the design vector chosen for evaluation
solu
tiontha
tsati
sfi
esthesideconstrai
nts(usua
llyo n
e)whichmustb eentere
dut白e [0.9775 1.01651
prompt(not
e:itmustbee n
tereda sav e
ctor
).Theprogramt henprin
tso ut白ev alu
es The design vector [0.9775 1.0165 1
of山ev ariou
sf u
nctio
nsi n
vo lv
edi n白ee xa
mple.Thef ol
lowingisp ostedfromthe objective function: 2.9810
Commandwindowf orbotho fthepenaltymul
tiplie
r百setto25. equality constraint: ー0.0112
inequality constraint: 0.0138
持 Sec7 2 1 calc
enter value for rh [default 1
] 25
7
.2 INDIRECTMETHODSFORCONSTRAINEDOPTIMIZATION 277
276 NUMERICALTECHNIOUESFORCONSTRAINEDOPTIMIZATION

Int h
ea boverun,theequa
lityandt h
ei n
equ
aliy∞n
t s
tr包ntar
芭 notsa
tis
fie
d(箇 Here).i
st hemul
tipli
ervect
ortiedtot
he珂 ual
itycon
s町aints,pisthemul
tipli
er
ex
pected
).T a
ble7.1d ocumentstheres
ult
so ft
heapplic
ationof白 eEPFmethodto vect
ora ss
ocia
tedw il
ht h
ei ne
quali
tycon
str
ains,andr
t handr sa r
et hepena
lty
Example7.1throu
ghSec7 _2_1_calc.m.百l esc
alin
gf a
ctori
s5forbothm
ult
ipl
ier
s. mul
tipli
ersu s
eds imi
lartol h
eEPFm e
thod.F issolveda sanu nco
nstrai
ned
Ag la
ncealTable7.1clea
rlyi1
Ius
tra
testhech
ara
cte
rist
icsoftheEPFmethod.Asthe func
tionforpredeter
minedvalue
so fλp ,r
",andr
g.Therefore,th
es o
luti
onf o
r
val
uesofthemult
iplie
rsinc陀 as
e: eachSUMTi te
rati
onis

. Thed
esi
gna
ppr
oac
hes出eo
pti
malv
alu
e. ・
X.=X(λp,
rh,
rg)
• Thec
ons
tra
intv
iol
ati
onsd
ecr
eas
e.
• Thes
olu
tio
nisb
ein
gap
pro
ach
edf
romo
uls
idet
hef
eas
ibl
ere
gio
n. At山ee ndofth
eSUMTi l
era
tio
nlh
evalu
eso ft
hemult
ipli
ersandp巴n
alt
ycon
stant
s
ar
eupdat
ed.Thela
tte
rareus
uall
yge
ome
trica
llysca
ledbutunl
ikeEPFdonothav
eto
Ani mpor
tantnote日 間d
st obemad巴.百leana
lyt
icalcom
p u
tatio
nu si
ngsymb
olic be合 i
vento∞ f
orconve
rge
nce.
com
pu t
ationappe
ar吋 伺sy.Thesameca
nnotbesai
df o
rthenum
erica
lc o
mpu
tati
on.
es
pecia
1lylook
ingatFig
ure7.
3. Al
gorlthm:AugmentedLsgrangeMu
附i pl
ler伺LM)Method伺 7
.3)
S
tep1 N
.ChooseX1,.(n
o.ofSUMTit
era
tio
ns),

“∞
7
.2.
2 AugmentedLagrangeM
ult
ipl
ier(ALM)Method Nu(
no.o
fDFPi~巴rations)

Ej
'叫
S(
fo
ir
刊co
叩nv
刊巴r
g
唱 e
叩n
c
印ea
nds
top
pin
g)
T
hisist h
em ostrobu
stof白ep ena1tyfunct
ionm et
hods
.Morei mpor
tantl ta
yi 1so ぺ
;
r.r
4
;(O
in副
凶i
t凶
a
i1pen
叩叫a
叫I
ty剛
mI
削l
u
l

Il
t切

i
i

li
e
託隠
p
rovide
si nf
ormat
ionon白 eLa g
r a
ng emul
tipl
iersat山esolut
ion.Thisi
sa c
hievedby
c
Ch, sc
g( a
1ingv
alu
efo
rmu
lti
pli
ers
)
n
otsolvingforthemu
lti
plier
sb utm erel
yu pda
tingthemd ur
ings u
ccess
iveSUMT
v
r~O", r~阻 (maximumal
u eformul
tip
lie
r百)
i
ter
ati
ons[2,4
).Itovercom巴sm anyo ft h
ed i
ffic
ult
iesass
ociate
dw i曲 thepena1t
y
f
uncti
onformula
tionwit
houtanys igni
fic
antoverhe
nd. ν,.
J
I(initi
almult
ipli
erve
c tor
s)
q=1(SUMTi ter
atio
ncounter)
Trans
如r matlontotheUnconstralnedProblem:The gen
era
1o pti
miz
ati
on S
te . Ca
p2 11DFPt ominimizeF(X q,)
.
.q,p r
Zr
", ,:)
pro
blem(
7.1)
ー(7.
4)i
s凶 lsfor
m吋 ωin山 間 山o do fL
agr
ang
em u
lti
pli
ers Output
:xq.
S
tep3
.C onver
ge nceforALM
Minimize


ト∞剖
)+
Ifhk=0, frk=1
o ,2
...., 1
;
府 川 r: f
8) (X) や dX)zd lfg
j 三
: 0,f
orj =1.
(百島 >Oforめ=0)
2,.• .
,m;

ト吋鳥ト 剖)
ト hk (
X) (
7.2
3)
(IfVf+kλ'
I
fal
lsid巴co
k
n
s
V
h
t
k+ 却~Vめ =0)
r
ThenConverged,
a
int
S
sa
to
r
p
esa
tis
fiω

x
l
s巧 Sx!, i=1
.2.
...
.n (
7.4
) S
toppingCri
teria
:
M'=Fq-F q-1・aJ(=x q*-X<q-I
)・

f(M')2SE
l :S
J top(fun
ctionnotchang
ing)
T
abl
e71E
. x
ler
iorP
ena
llyF
unc
tio
nMe
lho
d:Exa
mpl
e7.
1
日seIfaJ(Td.XSEI:S t
o p(de
signnotchan
ging)
I
te
rat
ion r
h r X1 X2 f s El
seIfq=N .:S top(maximumi ter
ati
onsrea
che
d)
8
C
ont
inu
e
'aq,

.0
1 1
.0 .03
91 2
.957
8 ー0.0
687 0
.0227
0
.92
28 1
q←q+l
5
.0 5
.0 0
.94
64 1.
036
4 2
.96
51 -0.
0302 0
.0295
-弓 JA--εJ

2
5.0 25.0 0
.97
75 .0
1 16
5 2
.981
0 -0.
0112 0
.0138 日 ← 日 +2r
hh(X
"O)
1
25 1
25 0
.99
42 1
.0044 2
.99
判 -. 2
0 7 ∞ 0
.0037 q←p
p q+2rl(max也(xq*).-pqI2r8])
6
25 6
25 0
.99
88 1
.00
09 2
.99
88 -
5.9775e-
004 7
.5097
e・004
1
r.
← rrCh;r:←rfCg
278 N
UME
RIC
ALT
ECH
NIO
UESF
ORC
ONS
TRA
INE
DOP
TIM
IZA
TIO
N 7.
2 I
NDI
REC
TME
THO
DSF
ORC
ONS
TRA
INE
DOP
TIM
IZA
TIO
N 279

xq←xq* o
fva
lue
sfora1
1of
theSUMTite
rat
ion
satthet
erm
ina
tio
nof
thep
rog
ram
.Thei
ni
ti
al
00t
oSt
ep2 d
esi
gnvec
tori
s[32].I
ni
ti
alλ=1a nd~ =1.

TheALMa lg
ori出m( A 7.
3)isavail
ableasastand-
alon
ep rogr
aminALM.m.百l e 持 ALM
progra
mislongwhichisnotune
xpecte
d.Th e
sea1g
orit
hrn
sa r
enot凶 v
ial
.Tot r
ans
lat
e 1nput the starting design vector
alg
orith
m(A7.3)int
ow orkingcodeisa佐官mendousa cc
omplishme
n,tpa
rtic
ula
rlyif This is mandatory as there is no default vector setup
yourexpo制限t oMATI.Bo
A cc
urr
edt hr
ough出isbook
.Ther ea
dersho
uldwalkthroug
h The length of your vector indicates the number of
th
ec odel in
eb ylin
e. 百 eo r g
aniz
atio
na nds tru
ctur
ea rek e
pts impl
ea nd unknowns (n)
str
aigh
tfor
wal
'd
.C onunenlsh av巴 beenlibe
ral
lyu sedasa nc ncoura
gementto Please enter it now and hit return for example [1 2
und
erst
.1n
dthec o
de. 3 ...]
[3 2]

ALM.m:Thec od
eg a由e
rsinp
utfromt
heus
ert
hroug
hsev
era
lp r
omp
tsint
he
The initial design vector:
Conunandwind
ow.Th epro
mptsan
d由巳 fi
na
lit
era
tio
nar
芭 cop
iedbe
low
.The 誼t
3 2
si
gnif
ica
ntf
eat
ure
so ft
hec
odear
e:
1nput the minimum values for the design vector. .
• Thes t
artin
gd esignvect
o ri
sthefirs
tinputto山己 progr創n.Thenumbero fdes
ign These are input as a vector. The default values are
varia
blesisautomatical
l yext
ractedfr o
mt h
isi nfo
rmati
o n
. 3 *start value below the start value unless it is zero.
・ 百l elow erandu pperb oun
dson血巴 d esignv 回a bl
es( si
dec o
ns紅白n t
s)釘巴 1n that case it is -5:
obtain
e d出r oughu se
rp rompts(though曲e ya renotusedin山ep ro
grar
n). [
00]
• Numbero fequ a
lityc o
nstra
intsa ndc orr
es po
n d
ingi n
iti
almult
ipli
ers(λ)ぽ巴
promptcd. The minimumvalues for the design variables are 00
• Numbero finequaJit
y叩 n st
rain
tsa ndc o
rrespondinginit
ia
lmulti
plie
rs(日)脱
1nput the maximum values for the design vector.
promptcd.
These are input as a vector. The default values are
• Valuesatc ac
hSUMTi t
crat
ion加 古 pr
intc
di ntheCommandw indow.Wamings 3 *start value above the start value.

-
genera
te dbyMATLAB紅巴 s w
itchedo ff
. 1f start value is 0 then it is +5:

“ 1!
• The DFP.m i su sedf oru ncons回 inedo ptim
izatio
n.T hisp rogramuses
c
[
55 1
GoldSecti on一nV町ar i--
• τ
百oep rograme x
却ε
P氏ct
匂sthefollowi
n g臼e伐st
ωob eavail
able加
in出e伊pa止:
白 The maximum values for the design variables are 55
O
b jec
tivef unct
ion Of un.m
Number of equality constraints [
0] 1
Equali
tyc o
nstrai
nts Hfun.m 1nitial values for lambda 1
I
nequali
tyc onstr
aints Gfun.m
U
n cons
tra i
ne dfunct
Ion FALM.m Number of inequality constraints [
0] 1
• Thep rogramu sesgloba
ls tatem
entst ocommuni catemult
ipli
ervalu
es. 1nitial values for beta 1
・ Thei n
iti
alpenaltym ul
tipli
ersarec omputcda u
t o
matic
ally.
ALM iteration number: 0
• Sever
alp arametersarec od
edi n
to出ep rogram.e s
pecialyt
I hos
en ee
dedforthe Design Vector (X) 32
goldens ec
tionan dtheu ppe
rb oun dcalc
ulatio
n.T hesecanbec hang
edb y出巴 Objective function 64
us巴r
.ifn ec
essary
. Square Error in constraints(h,g ) 1.2100e+002
1.8063e+001
App
licationtoExample7.1
:Thc fo l
lowin
gr ep
res
ent
st hein
iti
alp r
ompts Lagrange Multipliers (lambda beta): 1 1
s
ecnint h
eCommandwindowa n
dt h
ev alu
esf o
rthcsta
rti
ngite
rat
ion
s.O t
her Penalty Multipliers (rh rg): 5.2893e-001 3.5433e+000
i
ter
ati
onsares
im1
iar
lydi
spl
aye
d.Als
oi nc
1udedbelowi
sac on
sol
idate
dp r
inti
ng

3
280 N
UME
AIC
ALT
ECH
NIQ
UESFOAC
ONS
TRA
INE
DOP
TIM
IZA
TIO
N 7
.3D
IAE
CTMETHODSFOAC
ONS
TRA
INE
DOP
TIM
IZA
TIO
N 281

(other iteration omitted) . Thes


tar
tin
gde
sig
nca
nbef
eas
ibl
eori
nfe
asi
ble
.
• Thei
ni
ti
alc
hoi
cesf
ort
h巴m
ult
ipl
ier
s田 nber
ela
xed
.
X not changing O.OOOE+OOO reached in 5 iterations
・Thereisonlyamodestincreaseinthecalculations.
The values for x and f and 9 and h are • Atconver
gen
cet h
eLagrangemul
tipl
ierswi1
lbedriv
en10t
ll
ei
roptimumva
lue
s.
3.0000e+000 2.OOOOe+OOO 6 .4000e+001 1.8063e+001 Thi
sa lowsv
J er
ific
ati
ono fKTc ond
itionsthrou
ghthesi
gnofthemul
tip
lie
rs
1.2100e+002 as
soci
ate 白 血ea
dwi cti
vei n
equ
alit
yc o
n s位a
int
s.
7.9603e-001 7.1223e-001 2.9443e+000 0 7.379ge-001
9.9937e-001 1.0092e+000 2.9995e+000 1.8223e-004
2.9434e-004 7
.3 DIRECTMETHODSFORCONSTRAINEDOPT
lMIZAT
lON
9.9607e-001 1.0013e+000 2.9962e+000 0 2.731ge-005
9.9940e-001 1.0002e+000 2.9994e+000 2.5872e-011 Thedire
ctmethodsi nc
1udeboththeobj
ectiv
e叩 d出.econs
tr凶ntstosear
chf orthe
6.2772e-007 op
timalsol
utio
n.While白emethodsdon o
ti n
volveco
nve
rsiontoadif
fer
entc1assof
:
剖1
9.9940e-001 1.0002e+000 2.9994e+000 2.5872e-011 probl
ems(lik
eS ec
tion7.),
2 mostofthemareb鎚 edonli
nea
riza
tionofth
ef u
n c
lions
6.2772e-007 abo
utt h
ecurrenldes
i 伊 poi
nl.L
inear
izati
onisbasedonexpan
s i
onofthefu n
ction
a
bou
tth
ecu
rre
ntv
ari
abl
eva
lue
sus
ingt
heT
ayl
ors
eri
ω(C
hap
ter4
).
The values for lamda and beta are
1.0000e+000 1.0000e+000
-9.0876e-001 0 Une
sr l
zatlon
:Th eTayl
ors e
rie
sforalWo.
var
iab
leexpandedf
unc
tio
njx
{,y),
-1.6493e・001 9.5663e-001 q
uadr
atic
all
yabou
til
iec
urren
tpoin
t(x
p'Y
p)i
sexpr
ess
eda
s:
9.1192e-002 9.5616e-001
ー7.6430e-002 9.9221e-001

巴p
Th rogramt
ookf
ivei
ter
ati
ons(
lif
thwasn
otn
ece
ssa
ry)t
ofi
ndt
hes
olu
tio
nas
:
的1 [│
ま J
13
創 刊 )│
{J+
=f(x
f"y
/,
)-
1-

x
;
=O
.卯9
4 x=1.0002; r
;; =2.9994; h.=0.0000; g.=0.0007 (7.24) I
!割 削 蒜│叫+劉州側)
L_
.
.I(
x,.
J
I,
)
+2
-
--
-"I
(x
pJ'

) -
"I(
弘司
ト J

r司調咽 宮高崎i一
whichi
sve
ryc
10set
oth
eac
tua
lso
lut
io.Th
n ev
alu
esf
or山em
ult
ipl
ier
s釘巴 If白edisp
lacem
ensa
t reorg
anize
dω acolumnv 郎防 [ ax 8
y].山 e
T xpa
nsi
oni
n

J
Equa
tio
n(7.2
6)canbeex
press
edinacondensedmannerω
y
cJ
'= "=0.9922 u
A
. -
0.0
763
; s (
7.2
5)
ud町

Th
iss ati
sfi
est h
e KTc onditi
ons. However,i nSection7 .1
.2 thev al
ueso ft he
f f
汽(円山)ド吋=ザ吻
.I
ti
m
e
x
u
l
p
t
l
i
a
p
l
i
ie
nt
r
h
s,
ed
o
b
i
t
s
a
c
r
i
e
ne
p
a
du
nc
si
ye
n
x
gs
ce
y
p
mb
tt
ol
os
i
a
ccomp
y白紙 t
ut
h
at
i
es
o
y
n,
mb
a
o
r
l
eq
i
u
cc
i
t
al
ed
cu
i
l
f
a
t
f
i
e
r
o
ent
nfai
le
sd
dt
if
od
f
i
i
c
s
u
c
l
tt
ov
e
o
r L
片[釘
ι


A刈T[
y] 凹仇
H(;
Xn
.
υ
.
Y
凡I
J
n]
川I
]
, I
, .
釘刊(7
sYI
.2
7)
、 ,
t
hisparti
cula
rs olut
ionwhichi si ndeedpossi
ble.百 lev aluesin( 7
.25)ar芭 mo 問
a
cceptab
le山ant hoseinS ec
tion7.1.2consi
dering白eKTc onditi
ons. ForI
tva
ria
ble
s.w
ithXpt
hec
urr
entp
oitand8xt
n hed
isp
lac
eme
ntv
ect
or,
TheALMme 山od ,a
sd em
onstraledabove,i
s釦 effec
liveandu se
fulmethodinsDi
t e
o
fb e
longingtothecla
ssofi n
dire
ctme 山ods.I
th ass
evera
ls igni
fica
ntadvanta
gesove r
t
heotherpena
llyfunctio
nf orm
ulati
ons[2].Som 巴ofthema relis
ledbelo
w: ー 仲 必 )=
f f(X
p)+V
flぽp
) 叩成
T8X+tdXTH 問)

• Themethodi
sno
tse
nsi
tiv
etot
hei
ni
ti
alp
ena
ltym
ult
ipl
ier
sort
hei
rsc
ali
ng Eq
uat
ion(
7.2
8)c
佃 bew
ril
teni
nte
rmso
f白ed
iff
ere
ncei
nfu
nct
ionv
alu
esぉ
st
rat
egy
.
・Themethoddoesn
v
alu
es1
0ωt
abl
ishc
o
o
n
t陀 q
v
erg
e
u
n
i
c
e
r
e山ep
.
ena
ltym
ult
ipl
ier
stobed
riv
ent
oex
tre
me
ザ =f(X
p+尚 一f(X
p)=V
f(X
p) T
TdX+ dX t
町Xp)組 問 )
・ Thee
qua
lit
yanda
cti
vec
ons
tra
intc
anbes
ati
sfi
edp
r
l田 i
sel
y. 2
df=Of+of
7
.3 DIRECTMETHODSFORCONSTRAINEDOPTIMIZATION 283
282 NUMERICALTECHNIQUESFORCONSTRAINEDOPTIMIZATION

whereof=VjTaXi stennd白巴J
e i
rs
tv a
ria
tio
n.o2ji
stes
h eco
ndv a
ria
lionandi
sgive
n 5
by白 es田o ndten
ni ntheabove叫 ua
tio
n.Inlin
ear
iza
tionofthefunct
ionfab
outth
e
curr
entva
lueofdesignXp'onlythef
i附 vari
ati
onisus
ed.Th 巴neig
hboring叫 ueof
4
thefun
cti
onc a
nbee xpr
essedas

l(X =p)+V
p) f(X f(X
p)TaX (
7.30
)
3
Alloft h
ef u
nctio
n s加 山eproblemc 加 b elin
eariz
edsimil釘l
y.Itisess
entiaIt
o
under
stand山 d iff
erencebetweenf(X)andl(X p
)'Thisisil
Iust
rat
edinF i
gur e7.
4
usi
ngt h
eobjec
tivefuncti
onofExnmple7.1expandedaboutthecu
rre
ntd e
signx=3, ,
x2=2.Th巴 curvedi
I nesf(X)arethecon
toursof山eo rigi
naIfun
cti
on.Thes 位Bigh
t N
li
nesJ(Xp)arethecontoursoft
heline
arize
df u
nctio
n( l
ine
sofc o
nstan
tv a
Iueoft h
e M

f
unc
tio
n)o
bta
ine
dth
rou
ght
hef
oll
owi
ng:

x
i -

t222dt
O
rig
inaI印刷i
on: f
(x.X2): x1-2xrX2+ +X,~
) 2x1+4

民主4Af
L
ine
ari
zedf
unc
tio
n:]
(!J
.X'!
I .X2)=ω+92!
J J
.XI-6!
J
.X2

wheret hec oe
fficientsin白己 seconde xpres sioni ncludest h
ee valuationoft he
functionandg r
adien ,
tatx =3, X2=2a nds ubstitutedinE伊 a tion(7.30).InF igure
7.4s e
veralc ontoursa r
eshowna lthoug hth oseofi nt巴re
sta r
ei ntheneighborhood
of出ec urrentdesign.Anyn onlinearf unc tionc anbeexpandedi nthesamem anner. -1
F
d

Ifanotherp oin
twasc hose
n.t hen山es lopes0"1L helineswouldbed if
feren.
t xt
Theq uadrati
ce xpansionoft hefuncti onc anb eobt ai
nedbyu singE qu凶o n(7.
28).
百lee xpan dedcurveswil
lben onlinear(qu adr
甜c )
.百 l eyappearぉ e ll
ipsω nF
i igw芭7 .5 1g
F u
re7
.4l
Ius
tra
tlo
nol
lln
ear
iza
tlo
n.
where s ever
aIc ontourso f曲e 0凶e c
t ivef unctiono fExam p
le 7.1蹴 e xpanded
qua
d r
ati回lIya 加u tXI= 3,X2= 2.Itisimp ortantto附 o gnizetha
t山e contour冨w ouldbe
dif
feren
ti
Fourd
fa
ir
n
e
o
c
the
rp oin
twe
tmethodsa r
陀 c

芭 d
h
i
o
s
s
c
e
u
nf
sse
ore x
dThef
pans
i
r
i
s
on
ti
.
sS eque
ntiaILinearP r
o grarnming
n C
urrentint
ere
stint r
adit
ion
aldes
i伊 opt
i出 回tio
n(白i
schap町),isdi
rec
tedtow
ard
a
ctua
ld e
signappucadonsandmigr
ati
onfmmthemainfmmeandUNIXEnvir
onmen
t
(SLP),wheret h
es oluti
oni so btainedbys uccessivelys olv
ingt hec orresponding
o白ePC(
t li
ke出i sbook)・Forcomp
leten
ess
.t h
esta
ndar
df on
natoftheNLPi s
lin
e a
rizedo ptimiza
t io
np roblem.Thes 民 o nd,S equentiaIQ ua
draticP rogramming
(SQP),u ses山eq uadra
tice xpansionf or出eo bje c
tivef unct
ion.Like出eSUMT,出e rep
roducedher
ef o
rc o
nvenien
ce:
curren
ts o l
utionp rovid
es山es t
artingv aIue sf orthen exti te
rati
on.Thet hir
d.出e
(
7.1
)
GeneraIized ReducedG radientMethod (GRG).d evelopsas oph
isticateds 朗 氏h Mi
nim
ize !
(xoX2.• • • • x
1 ,,
)
dir
e c
tiona ndf ollowsitwithane l
a bo
r ateo ne-d i
men sionalproc
ess.Thef ourth
.L he
I) =o
. k=1,2....• 1
t< (
7.2
)
Sequentia
1GradientR es
torationA lgo rith m(SGRA),u sesat wo-cyc l
ea pproa
c h S
ubj
ect
ω: h X"X2.・
・・ ,
XI

workingonf ea
sibi
lityando pt
imalitya 1tematelyt of indt h
eoptimum.百l e
rea re
め~XI ・ X2.... ,
ん)孟 O
. j=1,2
...,
. m (
7.3
)
severa
1o thermethodsduet omanyr ese archersb ut山e yd iff
erfrom由o selist
edi n
smalld et
ails.Tok 田 pt hel e
ngthoft hisc hapt err eas
onable.出eyhaven otb e
e n XlS
:XiS
:Xr. n
i=1.2...., 7.
( 4
)
i Ju
nc ded.With由ecode叩 do therproce duresa vailablefromt h
issect
ion.itsh oul
dn ot
bedif白culttoprogramt h巴additiona
lt echn iques出a tarew orthexplori
ngf orparti
cular
I
nve
cto
rno
tat
ion
Ja
c s s
esofp rob
lems.
Ex ceptf orspec
ialc l
assesofp roble msi nthef ollo wi
ngtwoc hapler
s .白 i
sc hapter (
7.5
)
i
st hep r
i n
cipalr easonf o
rt heb ook.I tp rovides ar esolut
iono ft hec omple
t e (X
Minimize f )
. 医]"
o
o
pt
rg
i
r
m
e
i
a
z
t
l
at
i
yi
o
m
np
pr
r
o
o
v
b
e
le
dn
ma
um
sp
e
ri
o
c
s
a
ωl
lt
a
e
t
c
e
h
d.F
n
iq
o
u
ω
ral
.百l
o
e
n
r
gt
ei
i m
sal
enowt
oto
he
rehaven
fworkong l
ob
o
a
tb
lo
e
p
e
t
i
nanynew
m i
zatio
n . S
ubj田 t
to: [
h(X
)]=O, (
7.6
)
2
84 N
UME
RIC
ALT
ECH
NIO
UESF
ORC
ONS
TRA
INE
DOP
TIM
IZA
TIO
N 7
.3 D
IRE
CTM
ETH
ODSF
ORC
ONS
TRA
INE
DOP
TIM
IZA
TlON 285

5国百子宮
, M
ini
miz
e: l
(aX)=f
(X)+V
; f(X
;)TaX (
7.3
1)

,, 十

Su
尚氏t
lo
: 月以aX): "
k(X
;)+v
hI(X;)aX=; k=
0 1
,2,...,
1 (
7.3
2)
4

I

, あ(
AX)
: め(
X)+V8
; J
{X;
)TAXS0 ,
; j=12.
...,
m
, (
7.3
3)

J
3ト


A
x!o
w壬a
x;Sax)
I
P
; i=1
,2,.
..,
n 7.
( 34)

, Equ
Al
lo
a
ti
ft
o
n
h
s(
ef
7.
u
n
3
c
1
)
t
i
ー(
on
7
.
si
34
)r
nEqu
e
p
a
t
r
i
e
s
o
e
n
n
s(
laL
7
.3
in
1
)
e
一(
arP
7.4
3
ro
),
g
e
x
r
a
c
m
e
m
p
i
tf
n
o
g(LP
)p
raX.h
r
a
v
ob
l
en
e
u
m(
m
er
C
i
c
h
a
a
pt
lv
e
r3
a
lu
)
.
e
s
2
"
'
" af
te
rs u
bst
itu
tin
gan um
erica
lv ecto
rf o
rX ;.Assumi
nga nLPp ro
gramcodei
s


av
ail
abl
e,i
t回 nbecalle
drepe
atedl
ya f
te
rt h
edesi
gnisupd
ateda
s

X",=X,+AX
件 l-~.i

no
I rdertoi nc
ludeasearchdire
cti
ona ndstc
psizecal
cul
ati
on,出巴企Xi nEq u
atio
ns
(
7.31)ー(7
. 3
3 )i
sc ons
ideredasas o
lut
ionf o
rS( asear
chdirec
tio
na tthecurre
nl
d
esign)
.S tepsiz
ec ompu
tationslra飽gyisn ol ong
ers i
mpl
e.I f巴r
出 ea r
ev i
olat
ed
co
nstra
ints,a1ph
aa t
tempt
st oreduc
e白isv io
lati
on.If白ecurr
entsolu
tioni
sfeas
ible,
出 este
psi
z ewil
la tt
empttoreducethe白 nc
tionwithou
tcausi
ngtheconstr
aIn
tstob e
exce
ssive
l yvio
late
d.Suchs tr
ate
gie
sa r
el a
rge
lyi mple
mente
datthediscre
tio
nof由巳
-
2
・2 -
1 2 3 4 5 algo
r i
thmo rcodedev
elop
er.
x
v
A匂orlt
hm:S equentlalLlnearProgrammlng(SLP)( A又4
)
F
Jgu
re7
.5l
Iu
st
ra
ti
on0
1qu
adr
atl
c9x
pan
slo
n. S
tep1
.C hooseX ',Ns(no
.o fiter
ation
s),
E
;'S(fo
rc onve
rgencea nds t
oppin
g)
[
g(X
)]mS0 (
7.
7) q=1( itera
tio
nc o
unler)
X10wSXSXup S
tep2
.C al
lLPt oo pt
imize(7.31)一(7.
34)
(
7.8
)
Outpu:S
t
E
xam
ple7.
1wi
llb
eus
edt
oiIu
l s
tra
tet
hev
ari
ousa
lgo
rit
hms
. Useac onstr
叫n edα・c alculat
ion(X;=xQ)
AX=α..S
M
ini
miz
e f
( ,.
x xi
)
: x
1-2xix2+xi+xlrz-2xl+4 (
7.9
) Xq+I=Xq+AX
S
tep3
.C onvergenceforSLP
S
ubj
ect
to: h
(X
I,x
:: x
z
) i+r
z-2=0 (
7.1
0的
Ifhk=0, fo
rk=1 ,2,..., 1
;
g
(X.
.X2
): 0.2sxi+0.75~-1 SO (
7.
10b
) IfgJS0 ,f
orj=1 .2,. ..,m;
[fa
lls i
deconst
raintsaresati
sfi
ed
OSXI:
:;
5; OSX2SS (
7
.lc
O)
IfKTc ondit
ionssatis
fied
ThenC onverged,Stop
Stoppi
n gCri
ter
ia:
7
.3.
1 S
equ
ent
lalL
inearProgrammlng(SLP) q
AX=xq+l-x
I
nth
eSLP[
5]al
lofth
efun
cti
onsa
reex
pan
dedli
nea
rl
y.I
fX;i
sco
nsid
ere
d山e
cur
ren
t IfAX TAXSE I:Stop(designnotchangi
ng)
d
esi
gnv
回 t
or出e
, n出eli
nea
riz
edop
tim
alpro
blemcanb
ese
tupas Ifq=N .:SIOp(maximumi ter
atio
ns児 a
che
d)
酒温調掴
2
86 N
UME
RIC
ALT
ECH
NIQ
UESF
ORC
ONS
TRA
INE
OOP
TIM
IZA
TIO
N 7
.3O
IRE
CTM
ETH
ODSF
ORC
ONS
TRA
INE
DOP
TIM
IZA
TIO
N 287

5
C
ont
inu
e
q←q+l
4
00t
oSt
ep2

TheSLPisappli
ed10E xample7.
1b elow
.InC hapter3noe x
pli
citprogra mfo
rs o
lving
白eLPp rogramwa sdevelope
da l
thoughacommand-by-commandw alk白r oughw as
int
rodu
ced.Ap ro
g ramforapp
lying白eSimplexme 白od,pslmplex.mi sinclud
edo n
白ew e
bsite(wi
thoutanycommento rdiscu
ssion)
.U singinst
ructio
nsf romChapter3,
addi
ngsomcp rogramc on
tro
l,a ndo r
ganizingsomeb ookk
ee pingc anp r
ovidea
MATLABp
l
s
o
u
o
pt
bpr
o
oh
bl
e
c
r
l
o
g

mi
r
pl
a
r
ne
mf
an
s
a
c
l
o
a
hi
rLPp
t
ter
at
r

i
o

o
b
e出eSLPa
ni
l
em

sg
s.A
l
r
g
a
o
p
h
l
t
r
i
e
i
c
m
t
h
a
at
mt
e

Iyp
l
ly
oc
r
,M.

e
s
o
e
d
e
nt
百.AB'
.I
ed
Sl
n出i
.Thea
i
n
ss
p
e
r
r

e

ogc anb
con曲el
aofi nt
er
eu

es
s
i
n
tc
e
e
di
a
r
a
i
na
z
nb
ed
c
zoomedandthesolutio
nr e
adf r
omt h
ep l
o.tThisistrea
tedasdX( ins
teadofusingit
asS.Th
) edesi
gnisu pdate
da ndanothe
rp lo
tc anbeo bt
ainedb yrunningthem・f i
le
fo
ranewv al
ueo ft h
ed es
ignvecto
r.Sec7 _3_1- p1t
.m a
o s
sistsind i
s p
layin
gt he
i
Inea
rize
df u
ncti
onsf romwhichs o
lutio
nc anbeo bta
ined.Thee qua
lityc o
nstr
aintis
出egr田 nlin
e.百l er e
disi n
equ
alilycon
str通int百l edesignvectoris回 加p utt
o白e
pro
gram.Th巴∞d eu sessymbol
icc al
cula
tion10solveandd i
splaythesub pr
oblem.

A
ppllca
tlonofSLP
. Xl=
sωP1 (32) -
4 -
3 -
2 o 2 3 4 5
St
e .L
p2 ineari
zeds
ubpro
ble
m r. , OX
1
Min
imize1 (dX)=64+[
92-
6] ~XI II F
lgu
re7
.6E
xam
ple7
.
1SL
Pil
er
at
io
n1.
IsX21

FromFi
gur
e7 .
7(zoomed
)theso
lut
ioni
saxl=ー0
.5,
4ax
2=ー0
.23
.Fo
rth
ene
xt
釦 ゆc
t肱 I
I
(dX
) 1+[
:1 64]I 1
=0 仏21
IX
!
l i
i
ter
ati
onX3=[112
. 5,1
.02
].Rep
eatSte
p2.
-
S
te .L
p2 in
ear
ize
dsu
bpr
obl
em
3 i
-i


f

g
(dX
):4
.25+[
1.53
11 Iso 1
(
. ]Iふ│
z

Minim
回 瓜 )=3
.20
6+[
2.3
957-
0.2
363
j

I
!lX
21
-

l品 "
'
21
FromFigure7.6(zoomed)thesolutionis~ =ax =ー1.3
35,
&2=ax
2=-O.
75.
For


l
t
henex
tite
rat
ionX2=[1.665,1
.2
5].R
epe
atS
tep2
.
S
tep2.Lin巴ar
ize
dsu
b p
ro b
lem 釦 b
jec
t10
:五(広):0.
3060+[
2.2
52.
04]1 的1=0

lι"'
引2
l

]1~XII

M
ini
mi吋 ほ )=6
.79
85+[
13凹 0
5-1
.38
2 i
I
l
ILU21 E

削叫凶
附附)
:川:
氾0ω
06

FromFigu
re7.8(z
初o omeの
)t
d h
es o
lut
ion凶
isd川
x(=一0.ロ
12
笥5,dx2=ー0.02
.F orthenex
t
S雌 ω :百(必):23347+[333251lh│=0 i
ter
ati
onX4=[1 .01 .0].S i
ncethi
sist h
eknowns olu
tion,fur
the
ri t
erat
ion
s釘 芭
I
sX21
la
x.l- s
topp
ed.
gdX川臼9+附 2
( 51.87
5 ISO1
/
的 百leSLPtoo
kthreei t
era
tio
n o
st.fi
ndtheso
lut
ion
.Thisisveryim
pres
sive
.Itistru
e
o
nlyfort
ho
.s
ecase
sw he retenumbero
h .
fequa
lityp
lusact
iveincq
ual
ityco
nstra
intsi
s
288 NUMEAICALTECHNIQUESFORCONSTRAINEDOPTIMIZATION 7
.3 DIAECTMETHODSFOACONSTRAINEDOPTIMlZATION 289

5 5

4 4

3 3

>
N
<0
封同 。
<0

3

ー1

-
2 -
2

-3 -3

4 -4

-
5
・5 4 5 自

1
-
-55
L
-4 -3 -
2 -
1 。 2 3 4 5
SX1

F
lgu
re7
.7E
xam
ple7
.1SLPI
le
ral
lon2
. F
lgu
re7
.8E
xam
ple7
.1SLPI
e
lra
tio
n3.

lhe same as 出e number o fd es


ignv ariables-af ul
lc omp[ement. The main
disadvan
tageo flhemelhoda ppe釘sif白e reisnoful
lcomplement .Inlhatcase出巴 sid
e C組 bee x
ecuted
.Oncea gainlhemovel i
rn
itswi
llinflu
ence出es olu
tio.I
n fthemove
cons位置int
s(7.34)a r
ec r
itica
lto出ed etenninat
i o
no flhesolut
ionas山e yd evelopint
o li
mitsarele
ftatl h
esamev alue,t
hes o
lutio
nw i
llalwaysbeonl h
es quぉew i
thno
activ
ec o
nstr
aints.Inl hesesit
uat
ionslhel i
mitsonl h
es idecons
traint
s創 ec a
lle
dl h
e po
ssib
ilit
yo fconv
ergenc
e.Theselirn
it
smuslbel oweredwith回 chite
rat
ion
.U s
ually
movel im
its
.l n回 seo factivesi
deconst
rninlsI h
emovel imi
lsestabl
isht hevalu
esof the
ya redoneg e
ometr
icallylhro
ughas cali
ngfacl
or.百lisimpli
esl h
ec onv
ergence
lhedesignchanges.Ifl hedesig
nc han
ge sarec o
nsider
吋 a sl h
es ear
chd i陀 ct
ion(s

wi
lldependonl hestra
legyfo
rc han
gingl h
emovel imi
ts,no
ta nappeali
ngsitu
ati
on.
algori
lhm),山e nbo 曲v aJueandd i
rect
iona rea仔巴cted
.Forl h
esec hang
e stob esma
ll TheSLPi snotoneoflhepopu
larmelhods.111
emovel i
rni
tsareavoide
dw i由 l
henext
me出o d
.
aslhesolu
tionisa pp
roac hed
,出emovel imi
tshavet obea d
justed(
lowered )witheve
ry
ite
rati
on.百 lestrnteg
yf or血isadjus
trnentmayi n
fluen
c e白 esolu
tion
.
Example7 .1w ilhoutt h
ei n
equa
lityc on
strain
t,b u
tw ilh白ee qual
it yconst
rain
t 7
.3.
2 SequentlalQuadratlcProgrammlng(SQP)
provide
sa ni l
lus位置liono fthemovel imits
.F igu問 7.9r epr
esentslhel i
n 回riz
ati
on
aboutlhepoit[3
n 2.
, JThemovelimitsi nlhefigu陀 (box)repr
esentlhesideconst
rai
nt Thelac
ko frobu
stne
ssin由eSLPdueto出en eedformoveli
rni
tscanbecount
el吋 by
lim
its in
cludi
nga neleme
ntofn o
nlin回 r
ityi
n白ep rob
lem.The陀 arcse
vera
lwaysl hi
scan
beachi
eved.Onewayi s10requir
elhal山巴 se
archdir
ect
ions(rememberinacωa1
impl
ement
a ti
onsXi sS nE
)i quati
on 7.
s( 31ー
)(7.
34)beli
mite
dbyt h
eunitci
rcl
ewhich
-2~ Lttl 三 2; -2~ÂA1 S2
canbedescri
bed白巴 co
nstr
ain
l:
l
tisc l
earfro
mF i
gure7.9I
hatw
ilho
ulI h
emovelim
itst
hcs
olu
tio
nisunbounded,
whichisno
tveryhel
pf.
lUsingl
u h
esolu
tiono
bta
ine
dinlh
efi
gue,
r lh
ene
xtitera
tio
n STSS
:1 7.
( 35
)
290 N
UME
AIC
ALT
ECH
NIC
UESF
OAC
ONS
TAA
INE
DOP
TlM
IZA
TIO
N 7
.3 D
IAE
CTMETHODSFOAC
ONS
TAA
INE
DOPT
lMI
ZAT
ION 2
91

5 optimum 白紙 MATLAB i mple


ments(aso fthi
sw rit
ing
). Having a
cces
st ot h
e
Opti
mizatio
nToolboxa llow
sNLPt obes o
lvedusin
gSQP.A d et
ail
eddiscu
ssiono
f
th
es o
lutio
nt e
chniquei
sa l
soavai
lab
le[11
].
百l eQPs ubpro
bl e
memployedi nthi
ss ubse
ctio
ni sbasedone xpandin
gt h
c
3 obj
ectiv
ef unct
ionq uad
rati
call
ya bou
tt hec u
rren
td esi
gn. 百lec o
nst
rain
tsa r
e
expandedlin
earl
ya sinSLP[ 8]
.百 isiscall
edsequen
tialquad
rati
cprogramming
2 (SQP)
.

Minimω 1
(d
.X)=
f' r
叫 )+Vf(XidX+
. 伊TV2fl附 dX 間)

zo

、.
S
ubj田 l
to: 九(以):h
k(X
j)+VhI(X,)ほ=0
; k=1
.2.
...
.1(
7.32
)

-1 ~J{ð.X): g
j(X
j)+V {Xj
gJ )Td
.XS0
; j=1.2.....m (
7.33
)
s
x}o j
wSsxSðx~P; i=1
.2,.
・.
.n (
7.3
4)
-
2

nE
I qua ti
o n(7.36)Vす(X, )ist heH e
ssianma t
rix.Ina ctua
li mplementationt h
er e
al
-
3
Hess
i anwilln otb eused.Insteadam etr
ic開]白紙 i supda 飽 dw i出e achi te
rati
onis
us
ed.百世 si sbase don出巴 s ucce
sso ftheV aria
bleMe 凶 cM ethods(V 恥
仏.f)o fthe
-
4
pre
vio uschapte
r.S ever
alr esearc
hers[6.9
]h aveshown出鉱山巴 BFGSu pdateforthe
Hes8
i anp rovid
esa ne 仔icien
ti mplementat
io noftheSQPm ethod.T hisQPi sw e
ll
-
5
; -4 -3 -2 o poseda ndc onvexands houl
dy ieldas o
luti
on.S ol
utiont othissub p
r oblemisat由巳
6x
唱 he
arto f山eSQPm ethod.A c o
nsidera
bleamounto fre se
archh asb eeninvestedin
deve
l opinge f
ficien
t t echniques toh andle 出i s s ubproblem. I n a f ormal
F
lgu
問 7
. Iu
9 lstr
atl
ono
fmoveI
Im
lt
s. impl
e mentationo f恥 SQP山d.Xi nE quations(7.36
)加 d( 7.32)ー(7.34
)m uslbe
回placedbyt h
es earc
hd i
rectionS.TheQPf o
rSa l80modifiest h
ec o
nstrain
te qua
tions
百】巴 ste
psizedetermin
ations h
ouldthena c
countf orthea ctu叫 c hangeinth edesign 80thataf easi
bledirect
ionc anbef oundwi白 r e
spectto白ec u
rrentactivecons
traint
s.
vec
tor. The p robleme xpre
ssed by Eq岡山田 ( 7.31)一( 7.
35)i saq uadmtic Fig
ur e7 .10illu
s岡 鉱S白ec oncema boutmovingl ine
a r
lyt oap ointona na cti
ve
programming( QP)s ubp
r ob
lem.Ani temti
ves o
lutiono fthi
ss ubproblemc血 b eone con8佐ai .XO,
nt thec u
rrentdesignisona na c
t i
veconstra
i ntI
. fthese a
r c
hd ire
ctionSI
formo f恥 SQPme 出o d.This脱 出odi sp opul
arandi suse dw id
ely.Whilet h
eQP fol
low s出巴 l in
earizedfunctionatXO( thetangenttot h
ef unctio
na tt h
atpoint)
.a ny
subprogrami s as imp
len online
arp roblemw ithl inearc o n
s位置ints
.i tiss ti
lla st
epsize.a log自己 E
n 問 見 hd i
rectio
n.howevers mal,w
l i
llc auset h
ec onstr
ainttob e
multi
variablcn o
nlinearp roblem
.F o
rtunate
ly,QP p rob lemsa pp
eari n many vi
olated.Ino r
dertod et
er mi
nean eighborin
gp oi
ntthatwillsti
¥
ls at
isfytheconstm
ints.
disc
iplin
esa n
dt h
ereareeffi
cien
tprocedur
esanda lgorithmstoa ddre
s sthe
sep rob
lerns asearc hdirecti
ons lig
htlylessth朗 自et angentisu se
d.Thi si ntroduc
esal ac
ko f
[6-10
].Oneo fth巴sem ethodsisa nextens
iono ft heS im plexmethodo fLinear con
siste n
cya sthedeviat
i o
nfromt ang
encybecomesam atterofindividua
le xper
ience
Programming. and
pr acti田 .Experimentshaves ug
g e
sted白a t90-95%o fthetangentisausefulfigu
re
百lesoluti
onto白 eQPi swelldocumente
d.Itwouldl r叫u iremuchd isc
us si
ona nd alth
o ughmakingi tascloseto100%i srecommended[ 2].τbes ea
rchd ir
ectio
nf in
ding
ther
eforeisnotintroducedhcr
e.R ea
dersarer e
ferredtot hev ario
usr ef
erences
.T his QPs ub problemis
isalso白 ep rimaryr ea
s o
nwhyt heQPmethodi sa v
ailablei nt heOptimization
Toolboxi nMATLAs.Thef o
rmalmethodsforQPp roblemsa reb asedone f
ficiencyin M
ini
miz
e 7
(S)=f(X)+V
f(X
j)TS
T[H]S (
7.3
7)
1
thevarioussta
gesoft h
ei mpl
ementat
ion.Ani nef
ficientbuts ucces
sfulsolution10the
problemc anbeo btai
nedbyu singIheALMo ft hepre v
iouss e
ctio
nt osolvet heQP S
ubj
ecl
ω: 九(S):cMXi)+VhI(X,
)S=O; k=1
.2.
...,
1 (
7.3
8)
subproblem.Afte
rall
.c omputingres
ource
sa r
en o
tac onstrai
n ttoday
.I nlie
uo fformal
discu
ssion.ani n
tuit
iveunderstan
dingof白en umericalmethodi sa ttemp低 dint h
is あ(
S:c
) i
g<X メ
)+V8
i . x,
)
'
fSS0 .2ぃ
; j=1 ..,m 7.
( 39
)
book.Th etra
nsla
tionofSQPi ntocodei
sn o
ttriv
iala ndthemethodi su su
allyt h
eb a
sis
ofc ommercialsoftwar
e.F ore xampl,SQPi
e stheo n lyal gorith
mf orcon str
ained s
} r
OWSSjSS"
; i=I.2.....n (
7.4
0)
292 円 CONSTRA1NEDOPT1M
NUMERICALTECHN1QUESFO TION
lZA 7
.3 DIRECTMεTHODSFORCONSTRAINEDOPTIMIZATION 293

x
j=x
;'1+αS 聞

7.
( 41
)

mTL-H mでム一円
ーす臼制

r

x
,''E、



X

+
+

m
nu
AV


n


4
κ

.
r


ι
J

e
Mi
nim
ize
: 。.4
2)

x
Jす血制




+
X

+
=

nu


AV

FJ

Rur
A
Jr



M
ini
miz
e: 7.
( 4
3)

J
Equ
ation(7.42)or(7.4
3)canbeusedtoobtain白 evaluegs t
epsiz
eα.Th efuncti
onin
>
<"1 Equa
t i
on( 7.
43)requi
resani m
porta
nto b
servat
ion.S h
o

You might also like