[yt-users] sphere object without periodicity?

Stephen Skory s at skory.us
Sat Dec 24 06:04:21 PST 2011


Jeff,

> I want to define a sphere with a center that sits on one face of my
> domain, [0., 0.5, 0.5] in unitary coordinates. However, the boundary
> conditions in this case are not periodic, and so I don't want
> periodicity.

I agree that it should be possible to turn off periodicity for a
sphere. Before it's fixed, I think you can use a boolean container
(test this below, I haven't!):

base_sp = pf.h.sphere([0, 0.5, 0.5], 0.25)
box = pf.h.region([0.5]*3, [0.75, 0.25, 0.25], [1, 0.75, 0.75])
sp = pf.h.boolean([base_sp, "NOT", box])

Let me know if you run into trouble.

-- 
Stephen Skory
s at skory.us
http://stephenskory.com/
510.621.3687 (google voice)



More information about the yt-users mailing list