Reciprocal: Difference between revisions

Jump to navigation Jump to search
60 bytes added ,  14:26, 14 July 2020
m
Text replacement - "http://help.dyalog.com" to "https://help.dyalog.com"
m (It is monadic, not dyadic)
m (Text replacement - "http://help.dyalog.com" to "https://help.dyalog.com")
(2 intermediate revisions by 2 users not shown)
Line 21: Line 21:
== Properties ==
== Properties ==


Reciprocal of any real or complex number is equal to 1 divided by that number. Therefore the monadic <source lang=apl inline>÷</source> can be seen as dyadic <source lang=apl inline>÷</source> with default left argument of 1. This applies even to the reciprocal of 0; <source lang=apl inline>÷0</source> and <source lang=apl inline>1÷0</source> show identical behavior for both <source lang=apl inline>⎕DIV←0</source> (raising [[DOMAIN ERROR]]) and <source lang=apl inline>⎕DIV←1</source> (returning 0).
The reciprocal of any real or complex number is equal to 1 [[divide]]d by that number. Therefore the monadic <source lang=apl inline>÷</source> can be seen as dyadic <source lang=apl inline>÷</source> with default left argument of 1. This applies even to the reciprocal of 0; <source lang=apl inline>÷0</source> and <source lang=apl inline>1÷0</source> show identical behavior for both <source lang=apl inline>⎕DIV←0</source> (raising [[DOMAIN ERROR]]) and <source lang=apl inline>⎕DIV←1</source> (returning 0).


<source lang=apl>
<source lang=apl>
Line 41: Line 41:
</source>{{Works in|[[Dyalog APL]]}}
</source>{{Works in|[[Dyalog APL]]}}


== See also ==
* [[Times]]
* [[Negate]]
* [[Root]]
== External links ==
== External links ==


=== Documentation ===
=== Documentation ===


* [http://help.dyalog.com/17.1/#Language/Primitive%20Functions/Reciprocal.htm Dyalog]
* [https://help.dyalog.com/17.1/#Language/Primitive%20Functions/Reciprocal.htm Dyalog]
* [https://www.jsoftware.com/help/dictionary/d130.htm J Dictionary], [https://code.jsoftware.com/wiki/Vocabulary/percent NuVoc]
* [https://www.jsoftware.com/help/dictionary/d130.htm J Dictionary], [https://code.jsoftware.com/wiki/Vocabulary/percent NuVoc]
{{APL built-ins}}[[Category:Primitive functions]][[Category:Scalar monadic functions]]
{{APL built-ins}}[[Category:Primitive functions]][[Category:Scalar monadic functions]]

Navigation menu