Re: real newbie question

• To: mathgroup at smc.vnet.net
• Subject: [mg64411] Re: [mg64396] real newbie question
• From: Sseziwa Mukasa <mukasa at jeol.com>
• Date: Thu, 16 Feb 2006 03:05:18 -0500 (EST)
• References: <200602150832.DAA06538@smc.vnet.net>
• Sender: owner-wri-mathgroup at wolfram.com

```On Feb 15, 2006, at 3:32 AM, Skip Egley wrote:

> Sorry for the newbieness. This is probably a piece of cake for you
> folks.
>
> I have a set of Brillouin zone data. That is, there's a kx, ky, and
> a kz followed by an energy value. How can I select particular
> directions in the Brillouin zone out of this data and make a 2D
> plot of it. A k value followed by an energy value. For instance,
> say I want to plot along the kx axis. I would need to select all kx
> values such that ky and kz were zero and grab the matching energy
> value for the kx value. Or if I wanted to plot along a (110)
> direction, I would need to grab all kx=ky values with kz=0, along
> with the corresponding energy. Get my drift?

Assuming your data is in the form {{kx1,ky1,kz1,E1},
{kx2,ky2,kz2,E2},...} you can use Select and Map, for the first case

{#[[1]],#[[4]]}&/@Select[data,#[[2]]==#[[3]]==0&]

and for the second

{#[[1]],#[[4]]}&/@Select[data,#[[1]]==#[[2]]&&#[[3]]==0&]

Regards,

Sseziwa

```

• Prev by Date: Re: Using a text editor like interface for Mathematica?
• Next by Date: Re: Question about ScaleFunction in PlotVectorField (using PureFunction)
• Previous by thread: real newbie question
• Next by thread: Re: real newbie question