参加型シミュレーションの開発に関する研究

Page 49

舅 菫一 翌コ一

︼ 摯 一蝉 一︼ 一

(tl く0)8

(t2 く0) ifTrue:[^nil]

tl)=0 ifTrue:[xl := (((fu nOrma12)

lnst inctStatusYier class

"

instanceVar iablel{ames:

dotProductipl )/ ((fu dOtPrOduct: pl) ))‡ f hll:=((height

‡( f Oxl) r)/( pl r)) ]

lnst i nctStatusVi er

c

I

ass rpthodsFor

:

ifFa:se:[xl :=(kl

'createtindon'

dotProduct:((p2-pl)norma12))/(fu dotProduct:((p2-pl)unitVector)).

oper0n:model

hll := height ].

I ninfu container rindot := Schoduledlindor

statusVier

ifTruo:[x2:=(((fu nornta12)

new.

windor label :' Deci sions status' r i ndor

.

h21:=((height

statusVier : = lnstirrctStatusView model:model.

statusVier i nsideColor :ColorValue rhi te.

I

dotProduct:p2 )/ ((fu dbtProduct: p2) ))*f .

mi n im.nS i ze : 30002{X}.

container := CmositePart ner.

rcde

t2 )=0

I

ifFalse:[x2 :=(k2 dotProdlct:((pl― p2)norma12))/ (fu normai2 dotProduct:((pl― p2)unitVector)). h21 := height ].

myDeperdents statusv i eu. :

statusViei

aspect : Sdoc

i

s

(f Ox2) r)/( p2 r))]

ions.

er s irrulat i onProcess : (tnodel

statusVi

r1 :=(xl 0 hl1)+centre.

process). conta

inor

14 :=(x20h2l ){centre.

statusVier borderedln: (ff10

add:

g0 | inetidth:1.

extent:101 ).

gc Paint :ColorValue whi te. gc displayLirpFron:r1 to:r4. l"

wirdor ccnponent : contai ner.

lrindor open] fork. 0bject subclass:

ellarcs:'

nstanceVar i abl

i

inhabitat

RTSRoonr

ilRTSRocrn

roornld

plan

roon8ase

consi stOf

'

classVariablell,anos: ' ld

poolDictionaries: category

:'

Rea

methodsFor:

' initial ize-release'

cons i stance

:

consistances

lxmin ymin xmax vmax atal | |

'

"

lTineSimu at i on' I

xmin := ynin := 0. consistance := consistances. consi stances do: [ :aConsistacel aConsi stace

rocnr:self]. RTSRoom methodsFor

:'

atall

disPlaYins'

gc perspect i veShapeFronfo i nt : ov direction: s heightFrcrn: height viewAngle: va di sp IayOn

:

l rl

r4

f

ytmx := ymin := aUall rectarEle t@. consistances do:

t :Wl

fu kl k2 Xl

pl p2

hll x2 h21 centre tl 12 1

f := 200 / ((va dbgreesToRadians)tan). fu :=( ((S degreesToRadians )cos )0 ((S

degreesToRadians)Sin) ). ronase d。 :[:gridl

:= xnax mEx:(w

Ylnax

:= ynax max:(r

rectangle top). xmin := xmin min:(w rectangle left). ymin := yrnin min:(w

。V.

p2 :=(grid at:2)― oV. kl := pl― (fu*f).

k2 := p2-(fu=f). tl :=kl

xrnax

rectangle right).

centre := 200 0 150 .

pl :=(grid at:1)―

detect:[:rl true]. afall rectangle risht.

:= coflsistance

)or.tx := xmin :=

dOtPrOduct:fu.

t2 := k2 dotProductifu.

rectangle botton). J.

rocntsase : =0rdoredCol lect ion nefi'

xmin to:xmax bY:1000 do:[:xl roor8ase add: (Ar ray ci th: (xOvni n) ri th: (x0vmax))1.

理綱一“一 蝉

︼ 攣 ¨ ﹃

響 ﹄ 囀 一

攣 一” 一蝉 一響

¨”綺芭一崎


Issuu converts static files into: digital portfolios, online yearbooks, online catalogs, digital photo albums and more. Sign up and create your flipbook.