View abbrevs.el
(define-abbrev-table 'global-abbrev-table '(
("alpha" "α" nil 0)
("beta" "β" nil 0)
("gamma" "γ" nil 0)
("theta" "θ" nil 0)
("inf" "" nil 0)
("|@|" "" nil 0)
("forever" "" nil 0)
("jjoin" "μ" nil 0)
("cojoin" "υ" nil 0)
View contracts.scala
* Counterparty A receives: 1.43% absolute on amortising notional (decreasing periodically from an initial notional of £200m).
Counterparty B receives: Previous coupon + 5 x [Max(Ref Index – 6.65%, 0.00%) + Max(2% - Ref Index, 0.00%)] on fixed notional of £200m.
The reference index is CMS EUR 10y set in arrears, available on Reuters website at ISDAFIX2
A Bermudan call option is conferred on Counterparty B who may terminate for 0 payment within a 10 day band every quarter.
Payment dates are quarterly, reset dates and accrual periods are also defined.
View LensTest.scala
import scalaz._
* playing with some of the ideas from the Haskell fclabels library
* using the new Lens functionality in scalaz
object LensTest {
View smtp.hs
import Network.Mail.Mime
import qualified Data.ByteString.Lazy.UTF8 as LU
import qualified Data.ByteString.Lazy as B
import qualified Data.ByteString as S
import Control.Monad
import qualified HaskellNet.SMTP as HN
import Text.Pandoc
import Text.Hamlet
import Text.XHtml.Transitional hiding ( renderHtml )
View OptionGolf.scala
import scalaz._
* A simple example of how applicative functors can shorten code
* adapted from chapter 8? of Real World Haskell
object OptionGolf {