1 |
|
/* |
2 |
|
* Written by Doug Lea with assistance from members of JCP JSR-166 |
3 |
|
* Expert Group and released to the public domain, as explained at |
4 |
< |
* http://creativecommons.org/licenses/publicdomain |
4 |
> |
* http://creativecommons.org/publicdomain/zero/1.0/ |
5 |
|
*/ |
6 |
|
|
7 |
|
// Adapted from a cilk benchmark |
184 |
|
nv[b] = cell |
185 |
|
+ dtdysq * (prev - twoc + next) |
186 |
|
+ dtdxsq * (east[b] - twoc + west[b]); |
187 |
– |
|
187 |
|
} |
188 |
|
} |
189 |
|
|
190 |
< |
edges(newMat, llb, lub, tu + time * dt); |
190 |
> |
edges(newMat, llb, lub, tu + time * dt); |
191 |
|
} |
192 |
|
|
193 |
|
|
204 |
|
newMat[a][b] = cell |
205 |
|
+ dtdxsq * (oldMat[a+1][b] - twoc + oldMat[a-1][b]) |
206 |
|
+ dtdysq * (oldMat[a][b+1] - twoc + oldMat[a][b-1]); |
208 |
– |
|
207 |
|
} |
208 |
|
} |
209 |
|
|
227 |
|
} |
228 |
|
|
229 |
|
edges(oldm, llb, lub, 0); |
232 |
– |
|
230 |
|
} |
231 |
|
|
232 |
|
/** Fills in edges with boundary values. */ |