/[escript]/trunk/escript/src/DataExpanded.cpp
ViewVC logotype

Diff of /trunk/escript/src/DataExpanded.cpp

Parent Directory Parent Directory | Revision Log Revision Log | View Patch Patch

revision 3390 by jfenwick, Thu Dec 2 00:34:37 2010 UTC revision 3468 by jfenwick, Tue Feb 22 06:38:57 2011 UTC
# Line 161  DataExpanded::DataExpanded(const Functio Line 161  DataExpanded::DataExpanded(const Functio
161    
162  }  }
163    
164    DataExpanded::DataExpanded(const FunctionSpace& what,
165                               const DataTypes::ShapeType &shape,
166                               const double v)
167      : parent(what,shape)
168    {
169         ValueType& vec=m_data.getData();
170         //
171         // create the view of the data
172         initialise(what.getNumSamples(),what.getNumDPPSample());
173         // now we copy this value to all elements
174         const int L=getLength();
175         int i;
176         #pragma omp parallel for schedule(static) private(i)
177         for (i=0;i<L;++i)
178         {
179            vec[i]=v;
180         }
181    }
182    
183    
184    
185  DataExpanded::~DataExpanded()  DataExpanded::~DataExpanded()
186  {  {
187  }  }

Legend:
Removed from v.3390  
changed lines
  Added in v.3468

  ViewVC Help
Powered by ViewVC 1.1.26