Natural Logarithm

From APL Wiki
Jump to navigation Jump to search
A natural log
This page describes the monadic arithmetic function. For the dyadic logarithm function, see Logarithm.

Natural Logarithm (), or Natural Log, is a monadic scalar function which computes the natural logarithm of the argument. Logarithm shares the glyph with the dyadic arithmetic function Logarithm. The glyph, a composition of the glyphs for Circular () and Exponential (*) to indicate its close mathematical ties with these two functions, is a stylised tree log.


      1 2 (*1) (*10)
0 0.6931471806 1 10


Natural logarithm is a special case of Logarithm with the default left argument of e (*1).

      ((*1)  ) 1 ¯1 0J1
Works in: Dyalog APL

Natural logarithm and exponential * are inverses of each other, except where the natural log is undefined.

      (  *) 0 1 ¯1 0J1
      (  *) 1 ¯1 0J1 ⍝ natural log of zero is undefined
Works in: Dyalog APL

External links


APL built-ins [edit]
Primitive functions
Monadic ConjugateNegateSignumReciprocalMagnitudeExponentialNatural LogarithmFloorCeilingFactorialNotPi TimesRollTypeImaginarySquare Root
Dyadic AddSubtractTimesDivideResiduePowerLogarithmMinimumMaximumBinomialComparison functionsBoolean functions (And, Or, Nand, Nor) ∙ GCDLCMCircularComplexRoot
Structural ShapeReshapeTallyDepthRavelEnlistTableCatenateReverseRotateTransposeRazeMixSplitEncloseNestCut (K)PairLinkPartitioned EnclosePartition
Selection FirstPickTakeDropUniqueIdentitySelectReplicateExpandSet functions (IntersectionUnionWithout) ∙ Bracket indexingIndex
Selector Index generatorGradeIndex OfInterval IndexIndicesDeal
Computational MatchNot MatchMembershipFindNub SieveEncodeDecodeMatrix InverseMatrix DivideFormatExecuteMaterialiseRange
Primitive operators Monadic EachCommuteConstantReplicateExpandReduceWindowed ReduceScanOuter ProductKeyI-beamSpawnFunction axis
Dyadic BindCompositions (Compose, Reverse Compose, Beside, Atop, Over) ∙ Inner ProductPowerAtUnderRankDepthVariantStencilCut (J)
Quad names
Arrays Index originMigration levelAtomic vector
Functions Case convertUnicode convert
Operators SearchReplace