Subject: [Boost-bugs] [Boost C++ Libraries] #4917: uBLAS element-wise power function
From: Boost C++ Libraries (noreply_at_[hidden])
Date: 2010-12-01 17:27:10
#4917: uBLAS element-wise power function
---------------------------------------+------------------------------------
Reporter: matwey.kornilov@⦠| Owner: guwi17
Type: Patches | Status: new
Milestone: To Be Determined | Component: uBLAS
Version: Boost Development Trunk | Severity: Not Applicable
Keywords: |
---------------------------------------+------------------------------------
I would like to introduce element-wise power function. There are four
functions in the patch:
* `pow( vector_expression, scalar )`
* `pow( matrix_expression, scalar )`
* `element_pow( vector_expression, vector_expression )`
* `element_pow( matrix_expression, matrix_expression )`
== Synopsis ==
These functions behave naturally. Let `v` is a vector, `m` is a matrix,
`p` is a scalar then
`pow( v, p )` and `pow( m, p )` just raise each element to the power `p`.
`element_pow( v1, v2)` is `v1[i] ^ v2[i]`. `element_pow( m1, m2)` works
similarly.
== Rationalize ==
http://ublas.sourceforge.net mentions "...elements wise basic functions
(sin,cos,log,exp,abs,max,min,etc...)"
== Patch ==
The patch contains implementation and also simple test routines.
-- Ticket URL: <https://svn.boost.org/trac/boost/ticket/4917> Boost C++ Libraries <http://www.boost.org/> Boost provides free peer-reviewed portable C++ source libraries.
This archive was generated by hypermail 2.1.7 : 2017-02-16 18:50:04 UTC