Karya, built on 2023-08-29T07:47:28 (patch 7a412d5d6ba4968ca4155ef276a062ccdeb9109a)
Safe HaskellSafe-Inferred

Util.Affine

Description

Affine and instances. module Util.Affine (Affine(..), (.-^)) where

Synopsis

Documentation

class Num (Diff p) => Affine p where Source #

Simplified version of AffineSpace from the vector-space package.

Num gives access to negate and (+) and (*). It's probably technically too much because it also has fromInteger, but I don't think I need the whole AdditiveGroup etc. alternative numeric hierarchy.

Associated Types

type Diff p Source #

Methods

(.-.) :: p -> p -> Diff p infixl 6 Source #

(.+^) :: p -> Diff p -> p infixl 6 Source #

Instances

Instances details
Affine Chromatic Source # 
Instance details

Defined in Util.Affine

Associated Types

type Diff Chromatic Source #

Affine Diatonic Source # 
Instance details

Defined in Util.Affine

Associated Types

type Diff Diatonic Source #

Affine FChromatic Source # 
Instance details

Defined in Util.Affine

Associated Types

type Diff FChromatic Source #

Affine FDiatonic Source # 
Instance details

Defined in Util.Affine

Associated Types

type Diff FDiatonic Source #

Affine UTCTime Source # 
Instance details

Defined in Util.Affine

Associated Types

type Diff UTCTime Source #

(.-^) :: Affine p => p -> Diff p -> p infixl 6 Source #

base types

pitch

newtype Chromatic Source #

Absolute chromatic steps.

Constructors

Chromatic Int 

Instances

Instances details
Show Chromatic Source # 
Instance details

Defined in Util.Affine

Eq Chromatic Source # 
Instance details

Defined in Util.Affine

Ord Chromatic Source # 
Instance details

Defined in Util.Affine

Affine Chromatic Source # 
Instance details

Defined in Util.Affine

Associated Types

type Diff Chromatic Source #

type Diff Chromatic Source # 
Instance details

Defined in Util.Affine

newtype ChromaticSteps Source #

Relative chromatic steps, modulo pc_per_octave.

Constructors

ChromaticSteps Int 

Instances

Instances details
Enum ChromaticSteps Source # 
Instance details

Defined in Util.Affine

Num ChromaticSteps Source # 
Instance details

Defined in Util.Affine

Integral ChromaticSteps Source # 
Instance details

Defined in Util.Affine

Real ChromaticSteps Source # 
Instance details

Defined in Util.Affine

Show ChromaticSteps Source # 
Instance details

Defined in Util.Affine

Eq ChromaticSteps Source # 
Instance details

Defined in Util.Affine

Ord ChromaticSteps Source # 
Instance details

Defined in Util.Affine

newtype Diatonic Source #

Constructors

Diatonic Int 

Instances

Instances details
Show Diatonic Source # 
Instance details

Defined in Util.Affine

Eq Diatonic Source # 
Instance details

Defined in Util.Affine

Ord Diatonic Source # 
Instance details

Defined in Util.Affine

Affine Diatonic Source # 
Instance details

Defined in Util.Affine

Associated Types

type Diff Diatonic Source #

type Diff Diatonic Source # 
Instance details

Defined in Util.Affine

newtype DiatonicSteps Source #

Constructors

DiatonicSteps Int 

Instances

Instances details
Enum DiatonicSteps Source # 
Instance details

Defined in Util.Affine

Num DiatonicSteps Source # 
Instance details

Defined in Util.Affine

Integral DiatonicSteps Source # 
Instance details

Defined in Util.Affine

Real DiatonicSteps Source # 
Instance details

Defined in Util.Affine

Show DiatonicSteps Source # 
Instance details

Defined in Util.Affine

Eq DiatonicSteps Source # 
Instance details

Defined in Util.Affine

Ord DiatonicSteps Source # 
Instance details

Defined in Util.Affine

newtype FChromatic Source #

Constructors

FChromatic Double 

Instances

Instances details
Show FChromatic Source # 
Instance details

Defined in Util.Affine

Eq FChromatic Source # 
Instance details

Defined in Util.Affine

Ord FChromatic Source # 
Instance details

Defined in Util.Affine

Affine FChromatic Source # 
Instance details

Defined in Util.Affine

Associated Types

type Diff FChromatic Source #

type Diff FChromatic Source # 
Instance details

Defined in Util.Affine

newtype FDiatonic Source #

Constructors

FDiatonic Double 

Instances

Instances details
Show FDiatonic Source # 
Instance details

Defined in Util.Affine

Eq FDiatonic Source # 
Instance details

Defined in Util.Affine

Ord FDiatonic Source # 
Instance details

Defined in Util.Affine

Affine FDiatonic Source # 
Instance details

Defined in Util.Affine

Associated Types

type Diff FDiatonic Source #

type Diff FDiatonic Source # 
Instance details

Defined in Util.Affine