File tree Expand file tree Collapse file tree 1 file changed +8
-3
lines changed
src/main/clojure/clojure/core Expand file tree Collapse file tree 1 file changed +8
-3
lines changed Original file line number Diff line number Diff line change @@ -1571,7 +1571,9 @@ elements not-equal to the argument are 0.
1571
1571
v))
1572
1572
1573
1573
(defn add
1574
- " Performs element-wise addition on one or more numerical arrays."
1574
+ " Performs element-wise addition on one or more numerical arrays.
1575
+
1576
+ Will broadcast to the smallest shape compatible will addition of all input arrays."
1575
1577
([] 0.0 )
1576
1578
([a] a)
1577
1579
([a b]
@@ -1600,12 +1602,15 @@ elements not-equal to the argument are 0.
1600
1602
1601
1603
(defn add-product
1602
1604
" Adds the element-wise product of two numerical arrays to the first array.
1603
- Arrays should be the same shape."
1605
+
1606
+ Arrays should be the same shape, some implementations may support broadcasting."
1604
1607
([m a b]
1605
1608
(mp/add-product m a b)))
1606
1609
1607
1610
(defn add-product!
1608
- " Adds the product of two numerical arrays to the first array. Returns the mutated array."
1611
+ " Adds the product of two numerical arrays to the first array. Returns the mutated array.
1612
+
1613
+ Arrays should be the same shape, some implementations may support broadcasting."
1609
1614
([m a b]
1610
1615
(mp/add-product! m a b)
1611
1616
m))
You can’t perform that action at this time.
0 commit comments