Opened 16 years ago

Closed 16 years ago

#172 closed defect (fixed)

Should the int SVD::solve(const utility::vector& b, utility::vector x) be changed ...

Reported by: Jari Häkkinen Owned by: Jari Häkkinen
Priority: critical Milestone: yat 0.2
Component: utility Version: trunk
Keywords: Cc:


to int SVD::solve(const utility::vector& b, utility::vector& x)? This is an important change of the interface since users may depend on the copy of x. The reason x not to be a const is that the underlying GSL function expects a non-const x.

Change History (4)

comment:1 Changed 16 years ago by Peter

Component: classifierutility
Owner: changed from Markus Ringnér to Jari Häkkinen

This change is more than important because withouth the change the function is just nonsense. As far as I can understand, the function is used to solve Ax=b, which means the user is interested in x and x is unknown (i.e. empty) before the function is called. Therefore the interface must be a non-const reference, right?

comment:2 Changed 16 years ago by Jari Häkkinen

Well, you are right. I didn't actually really read the code (or the GSL manual)! Obviously there is no test case for solving the equation. This should be added.

comment:3 Changed 16 years ago by Jari Häkkinen

Milestone: 0.3 (Public release)0.2
Priority: majorcritical
Status: newassigned

comment:4 Changed 16 years ago by Jari Häkkinen

Resolution: fixed
Status: assignedclosed

(In [719]) Fixes #172.

Note: See TracTickets for help on using tickets.