condition and pattern matching
- To: mathgroup at smc.vnet.net
- Subject: [mg44885] condition and pattern matching
- From: "ram" <amli at comcast.net>
- Date: Fri, 5 Dec 2003 05:31:55 -0500 (EST)
- Sender: owner-wri-mathgroup at wolfram.com
I would like to integrate the function from {0,h}. \!\(\((E\^\(\(-I\)\ k\ Abs[\(-h\) + z]\)\/Abs[\(-h\) + z] + E\^\(\(-I\)\ k\ Abs[h + z]\)\/Abs[h + z] - \(2\ E\^\(\(-I\)\ k\ Abs[z]\)\ Cos[h\ k]\)\/Abs[z])\)\ Csc[h\ k]\^2\ Sin[k\ \((h - Abs[z])\)]\) Is there any way that I can replace Abs function by its values? I know that the following cases for condition matching work fac[n_ /; n > 0] := n! m /:Greater[m,n]=True; fac[m] gg[m_,n_]:=m-n /; m>n u/:Greater[u,v]=True; gg[u,v] But I can not find a way to apply above ideas when expressions are involved. Thanks for any help. Ram Kochhar
- Follow-Ups:
- Re: condition and pattern matching
- From: Daniel Lichtblau <danl@wolfram.com>
- Re: condition and pattern matching