[Yt-svn] commit/yt: sskory: Fixing logic error with the treecode.

Bitbucket commits-noreply at bitbucket.org
Mon Apr 4 14:28:53 PDT 2011


1 new changeset in yt:

http://bitbucket.org/yt_analysis/yt/changeset/c69eb7227847/
changeset:   r4073:c69eb7227847
branch:      yt
user:        sskory
date:        2011-04-04 23:27:57
summary:     Fixing logic error with the treecode.
affected #:  1 file (8 bytes)

--- a/yt/data_objects/derived_quantities.py	Mon Apr 04 17:25:57 2011 -0400
+++ b/yt/data_objects/derived_quantities.py	Mon Apr 04 15:27:57 2011 -0600
@@ -388,7 +388,7 @@
         dzes = na.unique(data['dx']) # order.
         # We only need one dim to figure out levels, we'll use x.
         dx = 1./data.pf.domain_dimensions[0]
-        levels = na.floor(dx / dxes / data.pf.refine_by).astype('int')
+        levels = (na.log(dx / dxes) / na.log(data.pf.refine_by)).astype('int')
         lsort = levels.argsort()
         levels = levels[lsort]
         dxes = dxes[lsort]

Repository URL: https://bitbucket.org/yt_analysis/yt/

--

This is a commit notification from bitbucket.org. You are receiving
this because you have the service enabled, addressing the recipient of
this email.



More information about the yt-svn mailing list