Statistics
| Revision:

root / trunk / src / linad99 / f3arr4.cpp @ 1942

History | View | Annotate | Download (699 Bytes)

1
/*
2
 * $Id: f3arr4.cpp 1942 2014-04-28 22:22:45Z johnoel $
3
 *
4
 * Author: David Fournier
5
 * Copyright (c) 2008-2012 Regents of the University of California
6
 */
7
/**
8
 * \file
9
 * Description not yet available.
10
 */
11
#include "fvar.hpp"
12

    
13
/**
14
 * Description not yet available.
15
 * \param
16
 */
17
dvar3_array operator-(const double d, const dvar3_array& m2)
18
   {
19
     RETURN_ARRAYS_INCREMENT();
20
     dvar3_array tmp;
21
     tmp.allocate(m2);
22
     for (int i=tmp.slicemin();i<=tmp.slicemax();i++)
23
     {
24
       tmp(i)=d-m2(i);
25
     }
26
     RETURN_ARRAYS_DECREMENT();
27
     return tmp;
28
   }
29

    
30
/**
31
 * Description not yet available.
32
 * \param
33
 */
34
dvariable mean(const dvar3_array& m)
35
   {
36
     dvariable tmp;
37
     tmp=sum(m)/double(size_count(m));
38
     return tmp;
39
   }