Search All of the Math Forum:

Views expressed in these public forums are not endorsed by NCTM or The Math Forum.

Notice: We are no longer accepting new posts, but the forums will continue to be readable.

Topic: Finding a function within an arbitrary expression
Replies: 4   Last Post: Jul 30, 2013 6:37 AM

 Messages: [ Previous | Next ]
 Ulrich Arndt Posts: 53 Registered: 10/1/09
Re: Finding a function within an arbitrary expression
Posted: Jul 1, 2013 5:39 AM

Try position

a = {3*u[1, 0], u[0, 0]/10., 1/u[1, 0]}
pat = u[1, 0]
Position[a, pat]

Ulrich

Am 30.06.2013 um 09:29 schrieb amannucci:

> I am trying to figure out what that pattern is for the following. The
difficulty here is that I can think textually, but not in Mathematica
patterns.
>
> I am looking for a function u[1,0] within a list of expressions. The

function might not be defined yet. For example, a list of expressions
might be:
>
> {3*u[1,0], u[0,0]/10., 1/u[1,0], ...}
>
> I want to find all the expressions that have the function u[1,0] in

it. There is certainly a way to do this "textually". How would one do
this with patterns? Is it possible? Thank you.
>
>

Date Subject Author
7/1/13 Ulrich Arndt
7/1/13 Bob Hanlon
7/29/13 amannuc1
7/30/13 Bob Hanlon