packages feed

dia-functions 0.2 → 0.2.1

raw patch · 2 files changed

+5/−7 lines, 2 files

Files

Graphics/Diagrams/FunctionGraphs.hs view
@@ -55,17 +55,15 @@  -- | Display an arc given by a function. displayArc-    :: (Fractional a, Real b) +    :: (Fractional a, Real b, Real c)      => Point                -- ^ display area left-bottom corner     -> Point                -- ^ display area right-up corner     -> (Double, Double)     -- ^ parameter interval-    -> (a -> (b, b))        -- ^ arc on the plain+    -> (a -> (b, c))        -- ^ arc on the plain     -> Diagram displayArc a b (k1,k2) f -    = withCoords a b $ joinPoints (arcPoints int f)-  where-    arcPoints (k1,k2) f-        = [ (realToFrac x, realToFrac y)+    = withCoords a b $ joinPoints+          [ (realToFrac x, realToFrac y)           | t <- [k1-0.1, k1.. k2+0.1]           , let (x, y) = f (realToFrac t) ] 
dia-functions.cabal view
@@ -1,5 +1,5 @@ name:                dia-functions-version:             0.2+version:             0.2.1 category:            Graphics, Education synopsis:            An EDSL for teaching Haskell with diagrams - functions description: