Re: Find the derised results
- To: mathgroup at smc.vnet.net
- Subject: [mg123718] Re: Find the derised results
- From: Bill Rowe <readnews at sbcglobal.net>
- Date: Fri, 16 Dec 2011 05:51:05 -0500 (EST)
- Delivered-to: l-mathgroup@mail-archive0.wolfram.com
On 12/15/11 at 4:56 AM, shlwell1988 at gmail.com wrote:
>{x,y,z,t}.{{x1,y1,z1,t1},{x2,y2,z2,t2},{x3,y3,z3,t3},{x4,y4,z4,t4}}.
>{x,y,z,t}
>How can I find those terms with x1 in the above result by some
>different methods?
Here is one way
In[1]:= f = {x, y, z,
t}.{{x1, y1, z1, t1}, {x2, y2, z2, t2}, {x3, y3, z3, t3},
{x4, y4,
z4, t4}}.{x, y, z, t};
In[2]:= Cases[f, _?(! FreeQ[#, x1] &), \[Infinity]]
Out[2]= {x1,x x1,t x4+x x1+x2 y+x3 z,x (t x4+x x1+x2 y+x3 z)}