(double c)
| 552 | } |
| 553 | |
| 554 | @Override |
| 555 | public void mutableAdd(double c) |
| 556 | { |
| 557 | if(c == 0.0) |
| 558 | return; |
| 559 | clearCaches(); |
| 560 | /* This NOT the most efficient way to implement this. |
| 561 | * But adding a constant to every value in a sparce |
| 562 | * vector defeats its purpos. |
| 563 | */ |
| 564 | for(int i = 0; i < length(); i++) |
| 565 | this.set(i, get(i) + c); |
| 566 | } |
| 567 | |
| 568 | @Override |
| 569 | public void mutableAdd(double c, Vec v) |