03.10.2012 Views

tr2011004_steps11

tr2011004_steps11

tr2011004_steps11

SHOW MORE
SHOW LESS

Create successful ePaper yourself

Turn your PDF publications into a flip-book with our unique Google optimized e-Paper software.

Number cos [ self asFloat cos ]<br />

Number log [ self asFloat log ]<br />

Float sin { (sin self) }<br />

Float cos { (cos self) }<br />

Float log { (log self) }<br />

Float + aNumber { (+ self aNumber) }<br />

Float - aNumber { (- self aNumber) }<br />

Float * aNumber { (* self aNumber) }<br />

Float / aNumber { (/ self aNumber) }<br />

Float \ aNumber { (% self aNumber) }<br />

Float < aNumber { (< self aNumber) }<br />

Float = aNumber { (= self aNumber) }<br />

Float negated [ 0.0 - self ]<br />

Float truncated { (double->long self) }<br />

Float rounded [ (self + 0.5) truncated ]<br />

Number between: x and: y [ x 0<br />

ifTrue:<br />

[aBlock value: (self at: 0).<br />

self from: 1 to: self size - 1 do: [:elt | bBlock value. aBlock value: elt]].<br />

]<br />

IndexableCollection select: aBlock<br />

[<br />

VPRI Technical Report TR-2011-004<br />

39

Hooray! Your file is uploaded and ready to be published.

Saved successfully!

Ooh no, something went wrong!