tinitialize c_phi and c_grad_phi as arrays - sphere - GPU-based 3D discrete ele… | |
git clone git://src.adamsgaard.dk/sphere | |
Log | |
Files | |
Refs | |
LICENSE | |
--- | |
commit bb573640f6d26668f4d5e2efd9641a2b71ff26a3 | |
parent 5e040c9c2c949242cb1a4709a773e054e912801d | |
Author: Anders Damsgaard <[email protected]> | |
Date: Wed, 30 Jul 2014 12:37:25 +0200 | |
initialize c_phi and c_grad_phi as arrays | |
Diffstat: | |
M python/sphere.py | 8 ++++---- | |
1 file changed, 4 insertions(+), 4 deletions(-) | |
--- | |
diff --git a/python/sphere.py b/python/sphere.py | |
t@@ -973,8 +973,8 @@ class sim: | |
self.c_grad_p =\ | |
numpy.fromfile(fh, dtype=numpy.float64, count=1) | |
else: | |
- self.c_phi = numpy.array(1.0) | |
- self.c_grad_p = numpy.array(1.0) | |
+ self.c_phi = numpy.ones(1, dtype=numpy.float64) | |
+ self.c_grad_p = numpy.ones(1, dtype=numpy.float64) | |
if (self.version >= 1.02): | |
self.color =\ | |
t@@ -2507,8 +2507,8 @@ class sim: | |
self.maxiter = numpy.array(1e4) | |
self.ndem = numpy.array(1) | |
- self.c_phi = numpy.array(1.0) | |
- self.c_grad_p = numpy.array(1.0) | |
+ self.c_phi = numpy.ones(1, dtype=numpy.float64) | |
+ self.c_grad_p = numpy.ones(1, dtype=numpy.float64) | |
def setFluidBottomNoFlow(self): | |
''' |