manifolds-0.4.4.0: Coordinate-free hypersurfaces

Copyright(c) Justus Sagemüller 2015
LicenseGPL v3
Maintainer(@) sagemueller $ geo.uni-koeln.de
Stabilityexperimental
Portabilityportable
Safe HaskellNone
LanguageHaskell2010

Data.Manifold.TreeCover

Contents

Description

 

Synopsis

Shades

data Shade x where Source #

A Shade is a very crude description of a region within a manifold. It can be interpreted as either an ellipsoid shape, or as the Gaussian peak of a normal distribution (use http://hackage.haskell.org/package/manifold-random for actually sampling from that distribution).

For a precise description of an arbitrarily-shaped connected subset of a manifold, there is Region, whose implementation is vastly more complex.

Constructors

Shade :: (Semimanifold x, SimpleSpace (Needle x)) => {..} -> Shade x 

Fields

Instances

ImpliesMetric Shade Source # 
IsShade Shade Source # 
(Show (Interior x), Show (Metric' x), WithField PseudoAffine x) => Show (Shade x) Source # 

Methods

showsPrec :: Int -> Shade x -> ShowS #

show :: Shade x -> String #

showList :: [Shade x] -> ShowS #

PseudoAffine x => Semimanifold (Shade x) Source # 

Associated Types

type Needle (Shade x) :: * #

type Interior (Shade x) :: * #

LtdErrorShow x => Show (Shade x) Source # 

Methods

showsPrec :: Int -> Shade x -> ShowS #

show :: Shade x -> String #

showList :: [Shade x] -> ShowS #

(WithField PseudoAffine x, Geodesic (Interior x), SimpleSpace (Needle x)) => Geodesic (Shade x) Source # 
type MetricRequirement Shade x Source # 
type Interior (Shade x) Source # 
type Interior (Shade x) = Shade x
type Needle (Shade x) Source # 
type Needle (Shade x) = Needle x

pattern (:±) :: forall x. () => (Semimanifold x, SimpleSpace (Needle x)) => Interior x -> [Needle x] -> Shade x infixl 6 Source #

Span a Shade from a center point and multiple deviation-vectors.

data Shade' x Source #

A “co-shade” can describe ellipsoid regions as well, but unlike Shade it can be unlimited / infinitely wide in some directions. It does OTOH need to have nonzero thickness, which Shade needs not.

Constructors

Shade' 

Fields

Instances

ImpliesMetric Shade' Source # 
IsShade Shade' Source # 
LtdErrorShow x => Show (Shade' x) Source # 

Methods

showsPrec :: Int -> Shade' x -> ShowS #

show :: Shade' x -> String #

showList :: [Shade' x] -> ShowS #

AffineManifold x => Semimanifold (Shade' x) Source # 
LtdErrorShow x => Show (Shade' x) Source # 

Methods

showsPrec :: Int -> Shade' x -> ShowS #

show :: Shade' x -> String #

showList :: [Shade' x] -> ShowS #

(WithField AffineManifold x, Geodesic x, SimpleSpace (Needle x)) => Geodesic (Shade' x) Source # 
type MetricRequirement Shade' x Source # 
type Interior (Shade' x) Source # 
type Interior (Shade' x) = Shade' x
type Needle (Shade' x) Source # 
type Needle (Shade' x) = Needle x

(|±|) :: forall x. WithField EuclidSpace x => x -> [Needle x] -> Shade' x infixl 6 Source #

Similar to ':±', but instead of expanding the shade, each vector restricts it. Iff these form a orthogonal basis (in whatever sense applicable), then both methods will be equivalent.

Note that '|±|' is only possible, as such, in an inner-product space; in general you need reciprocal vectors (Needle') to define a Shade'.

class IsShade shade where Source #

Methods

shadeCtr :: Lens' (shade x) (Interior x) Source #

Access the center of a Shade or a Shade'.

occlusion :: (PseudoAffine x, SimpleSpace (Needle x), s ~ Scalar (Needle x), RealFloat' s) => shade x -> x -> s Source #

Check the statistical likelihood-density of a point being within a shade. This is taken as a normal distribution.

factoriseShade :: (PseudoAffine x, SimpleSpace (Needle x), PseudoAffine y, SimpleSpace (Needle y), Scalar (Needle x) ~ Scalar (Needle y)) => shade (x, y) -> (shade x, shade y) Source #

coerceShade :: (Manifold x, Manifold y, LocallyCoercible x y, SimpleSpace (Needle y)) => shade x -> shade y Source #

linIsoTransformShade :: (SimpleSpace x, SimpleSpace y, Scalar x ~ Scalar y, Num' (Scalar x)) => (x +> y) -> shade x -> shade y Source #

projectShade :: (Semimanifold x, Semimanifold y, Object (Affine s) (Interior x), Object (Affine s) (Interior y), SimpleSpace (Needle x), SemiInner (Needle y)) => Embedding (Affine s) (Interior x) (Interior y) -> shade y -> shade x Source #

Squash a shade down into a lower dimensional space.

embedShade :: (Semimanifold x, Semimanifold y, Object (Affine s) (Interior x), Object (Affine s) (Interior y), SemiInner (Needle x), SimpleSpace (Needle y)) => Embedding (Affine s) (Interior x) (Interior y) -> shade x -> shade y Source #

Include a shade in a higher-dimensional space. Notice that this behaves fundamentally different for Shade and Shade'. For Shade, it gives a “flat image” of the region, whereas for Shade' it gives an “extrusion pillar” pointing in the projection's orthogonal complement.

Instances

IsShade Shade' Source # 
IsShade Shade Source # 

Lenses

shadeCtr :: IsShade shade => Lens' (shade x) (Interior x) Source #

Access the center of a Shade or a Shade'.

Construction

pointsShades :: (WithField PseudoAffine x, SimpleSpace (Needle x)) => [Interior x] -> [Shade x] Source #

Attempt to find a Shade that describes the distribution of given points. At least in an affine space (and thus locally in any manifold), this can be used to estimate the parameters of a normal distribution from which some points were sampled. Note that some points will be “outside” of the shade, as happens for a normal distribution with some statistical likelyhood. (Use pointsCovers if you need to prevent that.)

For nonconnected manifolds it will be necessary to yield separate shades for each connected component. And for an empty input list, there is no shade! Hence the result type is a list.

pointsCovers :: forall x. (WithField PseudoAffine x, SimpleSpace (Needle x)) => [Interior x] -> [Shade x] Source #

Like pointsShades, but ensure that all points are actually in the shade, i.e. if [Shade x₀ ex] is the result then metric (recipMetric ex) (p-x₀) ≤ 1 for all p in the list.

Evaluation

occlusion :: (IsShade shade, PseudoAffine x, SimpleSpace (Needle x), s ~ Scalar (Needle x), RealFloat' s) => shade x -> x -> s Source #

Check the statistical likelihood-density of a point being within a shade. This is taken as a normal distribution.

Misc

factoriseShade :: (IsShade shade, PseudoAffine x, SimpleSpace (Needle x), PseudoAffine y, SimpleSpace (Needle y), Scalar (Needle x) ~ Scalar (Needle y)) => shade (x, y) -> (shade x, shade y) Source #

linIsoTransformShade :: (IsShade shade, SimpleSpace x, SimpleSpace y, Scalar x ~ Scalar y, Num' (Scalar x)) => (x +> y) -> shade x -> shade y Source #

embedShade :: (IsShade shade, Semimanifold x, Semimanifold y, Object (Affine s) (Interior x), Object (Affine s) (Interior y), SemiInner (Needle x), SimpleSpace (Needle y)) => Embedding (Affine s) (Interior x) (Interior y) -> shade x -> shade y Source #

Include a shade in a higher-dimensional space. Notice that this behaves fundamentally different for Shade and Shade'. For Shade, it gives a “flat image” of the region, whereas for Shade' it gives an “extrusion pillar” pointing in the projection's orthogonal complement.

projectShade :: (IsShade shade, Semimanifold x, Semimanifold y, Object (Affine s) (Interior x), Object (Affine s) (Interior y), SimpleSpace (Needle x), SemiInner (Needle y)) => Embedding (Affine s) (Interior x) (Interior y) -> shade y -> shade x Source #

Squash a shade down into a lower dimensional space.

class (WithField PseudoAffine y, SimpleSpace (Needle y)) => Refinable y where Source #

Class of manifolds which can use Shade' as a basic set type. This is easily possible for vector spaces with the default implementations.

Methods

subShade' :: Shade' y -> Shade' y -> Bool Source #

a subShade' b ≡ True means a is fully contained in b, i.e. from minusLogOcclusion' a p < 1 follows also minusLogOcclusion' b p < 1.

refineShade' :: Shade' y -> Shade' y -> Maybe (Shade' y) Source #

Intersection between two shades.

convolveShade' :: Shade' y -> Shade' (Needle y) -> Shade' y Source #

Instances

Refinable Source # 
Refinable ℝ⁰ Source # 
Refinable ℝ⁴ Source # 
Refinable ℝ³ Source # 
Refinable ℝ² Source # 
Refinable ℝ¹ Source # 
(Refinable a, Refinable b, (~) * (Scalar (DualVector (DualVector (Needle b)))) (Scalar (DualVector (DualVector (Needle a))))) => Refinable (a, b) Source # 

Methods

debugView :: Maybe (DebugView (a, b))

subShade' :: Shade' (a, b) -> Shade' (a, b) -> Bool Source #

refineShade' :: Shade' (a, b) -> Shade' (a, b) -> Maybe (Shade' (a, b)) Source #

convolveMetric :: Functor p => p (a, b) -> Metric (a, b) -> Metric (a, b) -> Metric (a, b) Source #

convolveShade' :: Shade' (a, b) -> Shade' (Needle (a, b)) -> Shade' (a, b) Source #

(SimpleSpace a, SimpleSpace b, Refinable a, Refinable b, (~) * (Scalar a) , (~) * (Scalar b) , (~) * (Scalar (DualVector a)) , (~) * (Scalar (DualVector b)) , (~) * (Scalar (DualVector (DualVector a))) , (~) * (Scalar (DualVector (DualVector b))) ) => Refinable (LinearMap a b) Source # 

subShade' :: Refinable y => Shade' y -> Shade' y -> Bool Source #

a subShade' b ≡ True means a is fully contained in b, i.e. from minusLogOcclusion' a p < 1 follows also minusLogOcclusion' b p < 1.

refineShade' :: Refinable y => Shade' y -> Shade' y -> Maybe (Shade' y) Source #

Intersection between two shades.

coerceShade :: (IsShade shade, Manifold x, Manifold y, LocallyCoercible x y, SimpleSpace (Needle y)) => shade x -> shade y Source #

mixShade's :: forall y. (WithField Manifold y, SimpleSpace (Needle y)) => NonEmpty (Shade' y) -> Maybe (Shade' y) Source #

Weakened version of intersectShade's. What this function calculates is rather the weighted mean of ellipsoid regions. If you interpret the shades as uncertain physical measurements with normal distribution, it gives the maximum-likelyhood result for multiple measurements of the same quantity.

Shade trees

type ShadeTree x = x `Shaded` () Source #

fromLeafPoints :: forall x. (WithField Manifold x, SimpleSpace (Needle x)) => [x] -> ShadeTree x Source #

Build a quite nicely balanced tree from a cloud of points, on any real manifold.

Example: https://nbviewer.jupyter.org/github/leftaroundabout/manifolds/blob/master/test/Trees-and-Webs.ipynb#pseudorandomCloudTree

fromLeafPoints_ :: forall x y. (WithField Manifold x, SimpleSpace (Needle x)) => [(x, y)] -> x `Shaded` y Source #

onlyLeaves_ :: WithField PseudoAffine x => ShadeTree x -> [x] Source #

Left (and, typically, also right) inverse of fromLeafNodes.

indexShadeTree :: forall x y. (x `Shaded` y) -> Int -> Either Int ([x `Shaded` y], (x, y)) Source #

The leaves of a shade tree are numbered. For a given index, this function attempts to find the leaf with that ID, within its immediate environment.

treeLeaf :: forall x y f. Functor f => Int -> (y -> f y) -> (x `Shaded` y) -> Either Int (f (x `Shaded` y)) Source #

positionIndex Source #

Arguments

:: (WithField Manifold x, SimpleSpace (Needle x)) 
=> Maybe (Metric x)

For deciding (at the lowest level) what “close” means; this is optional for any tree of depth >1.

-> (x `Shaded` y)

The tree to index into

-> x

Position to look up

-> Maybe (Int, ([x `Shaded` y], (x, y)))

Index of the leaf near to the query point, the “path” of environment trees leading down to its position (in decreasing order of size), and actual position+info of the found node.

“Inverse indexing” of a tree. This is roughly a nearest-neighbour search, but not guaranteed to give the correct result unless evaluated at the precise position of a tree leaf.

View helpers

entireTree :: forall x y. (WithField PseudoAffine x, SimpleSpace (Needle x)) => (x `Shaded` y) -> LeafyTree x y Source #

onlyNodes :: forall x. (WithField PseudoAffine x, SimpleSpace (Needle x)) => ShadeTree x -> Trees x Source #

Imitate the specialised ShadeTree structure with a simpler, generic tree.

trunkBranches :: (x `Shaded` y) -> NonEmpty (LeafIndex, x `Shaded` y) Source #

Auxiliary types

type SimpleTree = GenericTree Maybe [] Source #

SimpleTree x ≅ Maybe (x, Trees x)

type Trees = GenericTree [] [] Source #

Trees x ≅ [(x, Trees x)]

newtype GenericTree c b x Source #

Constructors

GenericTree 

Fields

Instances

(Functor b, Functor c) => Functor (GenericTree c b) Source # 

Methods

fmap :: (a -> b) -> GenericTree c b a -> GenericTree c b b #

(<$) :: a -> GenericTree c b b -> GenericTree c b a #

(Foldable b, Foldable c) => Foldable (GenericTree c b) Source # 

Methods

fold :: Monoid m => GenericTree c b m -> m #

foldMap :: Monoid m => (a -> m) -> GenericTree c b a -> m #

foldr :: (a -> b -> b) -> b -> GenericTree c b a -> b #

foldr' :: (a -> b -> b) -> b -> GenericTree c b a -> b #

foldl :: (b -> a -> b) -> b -> GenericTree c b a -> b #

foldl' :: (b -> a -> b) -> b -> GenericTree c b a -> b #

foldr1 :: (a -> a -> a) -> GenericTree c b a -> a #

foldl1 :: (a -> a -> a) -> GenericTree c b a -> a #

toList :: GenericTree c b a -> [a] #

null :: GenericTree c b a -> Bool #

length :: GenericTree c b a -> Int #

elem :: Eq a => a -> GenericTree c b a -> Bool #

maximum :: Ord a => GenericTree c b a -> a #

minimum :: Ord a => GenericTree c b a -> a #

sum :: Num a => GenericTree c b a -> a #

product :: Num a => GenericTree c b a -> a #

(Traversable b, Traversable c) => Traversable (GenericTree c b) Source # 

Methods

traverse :: Applicative f => (a -> f b) -> GenericTree c b a -> f (GenericTree c b b) #

sequenceA :: Applicative f => GenericTree c b (f a) -> f (GenericTree c b a) #

mapM :: Monad m => (a -> m b) -> GenericTree c b a -> m (GenericTree c b b) #

sequence :: Monad m => GenericTree c b (m a) -> m (GenericTree c b a) #

Eq (c (x, GenericTree b b x)) => Eq (GenericTree c b x) Source # 

Methods

(==) :: GenericTree c b x -> GenericTree c b x -> Bool #

(/=) :: GenericTree c b x -> GenericTree c b x -> Bool #

Show (c (x, GenericTree b b x)) => Show (GenericTree c b x) Source # 

Methods

showsPrec :: Int -> GenericTree c b x -> ShowS #

show :: GenericTree c b x -> String #

showList :: [GenericTree c b x] -> ShowS #

Generic (GenericTree c b x) Source # 

Associated Types

type Rep (GenericTree c b x) :: * -> * #

Methods

from :: GenericTree c b x -> Rep (GenericTree c b x) x #

to :: Rep (GenericTree c b x) x -> GenericTree c b x #

MonadPlus c => Semigroup (GenericTree c b x) Source # 

Methods

(<>) :: GenericTree c b x -> GenericTree c b x -> GenericTree c b x #

sconcat :: NonEmpty (GenericTree c b x) -> GenericTree c b x #

stimes :: Integral b => b -> GenericTree c b x -> GenericTree c b x #

MonadPlus c => Monoid (GenericTree c b x) Source # 

Methods

mempty :: GenericTree c b x #

mappend :: GenericTree c b x -> GenericTree c b x -> GenericTree c b x #

mconcat :: [GenericTree c b x] -> GenericTree c b x #

(NFData x, Foldable c, Foldable b) => NFData (GenericTree c b x) Source # 

Methods

rnf :: GenericTree c b x -> () #

type Rep (GenericTree c b x) Source # 
type Rep (GenericTree c b x) = D1 (MetaData "GenericTree" "Data.Manifold.TreeCover" "manifolds-0.4.4.0-4U7mLxDASVE34WPYCdNRgy" True) (C1 (MetaCons "GenericTree" PrefixI True) (S1 (MetaSel (Just Symbol "treeBranches") NoSourceUnpackedness NoSourceStrictness DecidedLazy) (Rec0 (c (x, GenericTree b b x)))))

:: c (x, GenericTree b b x) -> GenericTree c b x Source #

U+6733 CJK UNIFIED IDEOGRAPH tree. The main purpose of this is to give GenericTree a more concise Show instance.

Misc

class HasFlatView f where Source #

Minimal complete definition

flatView, superFlatView

Associated Types

type FlatView f x Source #

Methods

flatView :: f x -> FlatView f x Source #

superFlatView :: f x -> [[x]] Source #

shadesMerge Source #

Arguments

:: (WithField Manifold x, SimpleSpace (Needle x)) 
=>

How near (inverse normalised distance, relative to shade expanse) two shades must be to be merged. If this is zero, any shades in the same connected region of a manifold are merged.

-> [Shade x]

A list of n shades.

-> [Shade x]

mn shades which cover at least the same area.

Attempt to reduce the number of shades to fewer (ideally, a single one). In the simplest cases these should guaranteed cover the same area; for non-flat manifolds it only works in a heuristic sense.

allTwigs :: forall x y. WithField PseudoAffine x => (x `Shaded` y) -> [Twig x y] Source #

type Twig x y = (Int, x `Shaded` y) Source #

type TwigEnviron x y = [Twig x y] Source #

flexTwigsShading :: forall x y f. (WithField Manifold x, WithField Manifold y, SimpleSpace (Needle x), SimpleSpace (Needle y), Applicative f) => (Shade' (x, y) -> f (x, (Shade' y, LocalLinear x y))) -> (x `Shaded` y) -> f (x `Shaded` y) Source #

traverseTrunkBranchChoices :: Applicative f => ((Int, x `Shaded` y) -> (x `Shaded` y) -> f (x `Shaded` z)) -> (x `Shaded` y) -> f (x `Shaded` z) Source #

data Shaded x y Source #

Constructors

PlainLeaves [(x, y)] 
DisjointBranches !LeafCount (NonEmpty (x `Shaded` y)) 
OverlappingBranches !LeafCount !(Shade x) (NonEmpty (DBranch x y)) 

Instances

Functor (Shaded x) Source # 

Methods

fmap :: (a -> b) -> Shaded x a -> Shaded x b #

(<$) :: a -> Shaded x b -> Shaded x a #

Foldable (Shaded x) Source # 

Methods

fold :: Monoid m => Shaded x m -> m #

foldMap :: Monoid m => (a -> m) -> Shaded x a -> m #

foldr :: (a -> b -> b) -> b -> Shaded x a -> b #

foldr' :: (a -> b -> b) -> b -> Shaded x a -> b #

foldl :: (b -> a -> b) -> b -> Shaded x a -> b #

foldl' :: (b -> a -> b) -> b -> Shaded x a -> b #

foldr1 :: (a -> a -> a) -> Shaded x a -> a #

foldl1 :: (a -> a -> a) -> Shaded x a -> a #

toList :: Shaded x a -> [a] #

null :: Shaded x a -> Bool #

length :: Shaded x a -> Int #

elem :: Eq a => a -> Shaded x a -> Bool #

maximum :: Ord a => Shaded x a -> a #

minimum :: Ord a => Shaded x a -> a #

sum :: Num a => Shaded x a -> a #

product :: Num a => Shaded x a -> a #

Traversable (Shaded x) Source # 

Methods

traverse :: Applicative f => (a -> f b) -> Shaded x a -> f (Shaded x b) #

sequenceA :: Applicative f => Shaded x (f a) -> f (Shaded x a) #

mapM :: Monad m => (a -> m b) -> Shaded x a -> m (Shaded x b) #

sequence :: Monad m => Shaded x (m a) -> m (Shaded x a) #

(WithField Manifold x, SimpleSpace (Needle x)) => Semigroup (ShadeTree x) Source #

WRT union.

Methods

(<>) :: ShadeTree x -> ShadeTree x -> ShadeTree x #

sconcat :: NonEmpty (ShadeTree x) -> ShadeTree x #

stimes :: Integral b => b -> ShadeTree x -> ShadeTree x #

(WithField Manifold x, SimpleSpace (Needle x)) => Monoid (ShadeTree x) Source # 
(WithField PseudoAffine x, Show x, Show (Interior x), Show (Needle' x), Show (Metric' x)) => Show (Shaded x ()) Source # 

Methods

showsPrec :: Int -> Shaded x () -> ShowS #

show :: Shaded x () -> String #

showList :: [Shaded x ()] -> ShowS #

Generic (Shaded x y) Source # 

Associated Types

type Rep (Shaded x y) :: * -> * #

Methods

from :: Shaded x y -> Rep (Shaded x y) x #

to :: Rep (Shaded x y) x -> Shaded x y #

(NFData x, NFData (Needle' x), NFData y) => NFData (DBranch x y) Source # 

Methods

rnf :: DBranch x y -> () #

(NFData x, NFData (Needle' x), NFData y) => NFData (Shaded x y) Source # 

Methods

rnf :: Shaded x y -> () #

type Rep (Shaded x y) Source # 
type Rep (Shaded x y)

fmapShaded :: (Semimanifold x, SimpleSpace (Needle x)) => (y -> υ) -> (x `Shaded` y) -> x `Shaded` υ Source #

constShaded :: y -> (x `Shaded` y₀) -> x `Shaded` y Source #

zipTreeWithList :: (x `Shaded` w) -> NonEmpty y -> x `Shaded` (w, y) Source #

stiAsIntervalMapping :: (x ~ , y ~ ) => (x `Shaded` y) -> [(x, ((y, Diff y), LinearMap x y))] Source #

type DBranch x y = DBranch' x (x `Shaded` y) Source #

data DBranch' x c Source #

Constructors

DBranch 

Instances

Functor (DBranch' x) Source # 

Methods

fmap :: (a -> b) -> DBranch' x a -> DBranch' x b #

(<$) :: a -> DBranch' x b -> DBranch' x a #

Foldable (DBranch' x) Source # 

Methods

fold :: Monoid m => DBranch' x m -> m #

foldMap :: Monoid m => (a -> m) -> DBranch' x a -> m #

foldr :: (a -> b -> b) -> b -> DBranch' x a -> b #

foldr' :: (a -> b -> b) -> b -> DBranch' x a -> b #

foldl :: (b -> a -> b) -> b -> DBranch' x a -> b #

foldl' :: (b -> a -> b) -> b -> DBranch' x a -> b #

foldr1 :: (a -> a -> a) -> DBranch' x a -> a #

foldl1 :: (a -> a -> a) -> DBranch' x a -> a #

toList :: DBranch' x a -> [a] #

null :: DBranch' x a -> Bool #

length :: DBranch' x a -> Int #

elem :: Eq a => a -> DBranch' x a -> Bool #

maximum :: Ord a => DBranch' x a -> a #

minimum :: Ord a => DBranch' x a -> a #

sum :: Num a => DBranch' x a -> a #

product :: Num a => DBranch' x a -> a #

Traversable (DBranch' x) Source # 

Methods

traverse :: Applicative f => (a -> f b) -> DBranch' x a -> f (DBranch' x b) #

sequenceA :: Applicative f => DBranch' x (f a) -> f (DBranch' x a) #

mapM :: Monad m => (a -> m b) -> DBranch' x a -> m (DBranch' x b) #

sequence :: Monad m => DBranch' x (m a) -> m (DBranch' x a) #

(WithField PseudoAffine x, Show (Needle' x), Show c) => Show (DBranch' x c) Source # 

Methods

showsPrec :: Int -> DBranch' x c -> ShowS #

show :: DBranch' x c -> String #

showList :: [DBranch' x c] -> ShowS #

Generic (DBranch' x c) Source # 

Associated Types

type Rep (DBranch' x c) :: * -> * #

Methods

from :: DBranch' x c -> Rep (DBranch' x c) x #

to :: Rep (DBranch' x c) x -> DBranch' x c #

(NFData x, NFData (Needle' x), NFData y) => NFData (DBranch x y) Source # 

Methods

rnf :: DBranch x y -> () #

type Rep (DBranch' x c) Source # 
type Rep (DBranch' x c) = D1 (MetaData "DBranch'" "Data.Manifold.TreeCover" "manifolds-0.4.4.0-4U7mLxDASVE34WPYCdNRgy" False) (C1 (MetaCons "DBranch" PrefixI True) ((:*:) (S1 (MetaSel (Just Symbol "boughDirection") NoSourceUnpackedness SourceStrict DecidedStrict) (Rec0 (Needle' x))) (S1 (MetaSel (Just Symbol "boughContents") NoSourceUnpackedness SourceStrict DecidedStrict) (Rec0 (Hourglass c)))))

data Hourglass s Source #

Hourglass as the geometric shape (two opposing ~conical volumes, sharing only a single point in the middle); has nothing to do with time.

Constructors

Hourglass 

Fields

Instances

Functor Hourglass Source # 

Methods

fmap :: (a -> b) -> Hourglass a -> Hourglass b #

(<$) :: a -> Hourglass b -> Hourglass a #

Applicative Hourglass Source # 

Methods

pure :: a -> Hourglass a #

(<*>) :: Hourglass (a -> b) -> Hourglass a -> Hourglass b #

(*>) :: Hourglass a -> Hourglass b -> Hourglass b #

(<*) :: Hourglass a -> Hourglass b -> Hourglass a #

Foldable Hourglass Source # 

Methods

fold :: Monoid m => Hourglass m -> m #

foldMap :: Monoid m => (a -> m) -> Hourglass a -> m #

foldr :: (a -> b -> b) -> b -> Hourglass a -> b #

foldr' :: (a -> b -> b) -> b -> Hourglass a -> b #

foldl :: (b -> a -> b) -> b -> Hourglass a -> b #

foldl' :: (b -> a -> b) -> b -> Hourglass a -> b #

foldr1 :: (a -> a -> a) -> Hourglass a -> a #

foldl1 :: (a -> a -> a) -> Hourglass a -> a #

toList :: Hourglass a -> [a] #

null :: Hourglass a -> Bool #

length :: Hourglass a -> Int #

elem :: Eq a => a -> Hourglass a -> Bool #

maximum :: Ord a => Hourglass a -> a #

minimum :: Ord a => Hourglass a -> a #

sum :: Num a => Hourglass a -> a #

product :: Num a => Hourglass a -> a #

Traversable Hourglass Source # 

Methods

traverse :: Applicative f => (a -> f b) -> Hourglass a -> f (Hourglass b) #

sequenceA :: Applicative f => Hourglass (f a) -> f (Hourglass a) #

mapM :: Monad m => (a -> m b) -> Hourglass a -> m (Hourglass b) #

sequence :: Monad m => Hourglass (m a) -> m (Hourglass a) #

Foldable Hourglass (->) (->) Source # 

Methods

ffoldl :: (ObjectPair (->) a b, ObjectPair (->) a (Hourglass b)) => ((a, b) -> a) -> (a, Hourglass b) -> a #

foldMap :: (Object (->) a, Object (->) (Hourglass a), Monoid m, Object (->) m, Object (->) m) => (a -> m) -> Hourglass a -> m #

Show s => Show (Hourglass s) Source # 
Generic (Hourglass s) Source # 

Associated Types

type Rep (Hourglass s) :: * -> * #

Methods

from :: Hourglass s -> Rep (Hourglass s) x #

to :: Rep (Hourglass s) x -> Hourglass s #

Semigroup s => Semigroup (Hourglass s) Source # 

Methods

(<>) :: Hourglass s -> Hourglass s -> Hourglass s #

sconcat :: NonEmpty (Hourglass s) -> Hourglass s #

stimes :: Integral b => b -> Hourglass s -> Hourglass s #

(Monoid s, Semigroup s) => Monoid (Hourglass s) Source # 
NFData s => NFData (Hourglass s) Source # 

Methods

rnf :: Hourglass s -> () #

type Rep (Hourglass s) Source # 
type Rep (Hourglass s) = D1 (MetaData "Hourglass" "Data.Manifold.TreeCover" "manifolds-0.4.4.0-4U7mLxDASVE34WPYCdNRgy" False) (C1 (MetaCons "Hourglass" PrefixI True) ((:*:) (S1 (MetaSel (Just Symbol "upperBulb") NoSourceUnpackedness SourceStrict DecidedStrict) (Rec0 s)) (S1 (MetaSel (Just Symbol "lowerBulb") NoSourceUnpackedness SourceStrict DecidedStrict) (Rec0 s))))

unsafeFmapTree :: (NonEmpty (x, y) -> NonEmpty (ξ, υ)) -> (Needle' x -> Needle' ξ) -> (Shade x -> Shade ξ) -> (x `Shaded` y) -> ξ `Shaded` υ Source #

Triangulation-builders

type TriangBuild t n x = TriangT t (S n) x (State (Map (SimplexIT t n x) (Metric x, ISimplex (S n) x))) Source #

doTriangBuild :: KnownNat n => (forall t. TriangBuild t n x ()) -> [Simplex (S n) x] Source #

breakdownAutoTriang :: forall n n' x. (KnownNat n', n ~ S n') => AutoTriang n x -> [Simplex n x] Source #

External

type AffineManifold m = (Atlas m, Manifold m, AffineSpace m, Needle m ~ Diff m, HasTrie (ChartIndex m)) Source #

The AffineSpace class plus manifold constraints.