problems with condition in ReplaceAll
- To: mathgroup at smc.vnet.net
- Subject: [mg91464] problems with condition in ReplaceAll
- From: frhes <frhes at bgu.ac.il>
- Date: Fri, 22 Aug 2008 03:14:49 -0400 (EDT)
Dear discussion list: can anybody help me to find an expression in order to replace only subexpressions of which the numerator is strictly positive in the following ReplaceAll command? \!\(ReplaceAll[1 + 0^\((1\/\(1 - Ï?\_n\))\), If[FreeQ[_, 0^_], 0^_ -> If[Assuming[{0 < Ï?\_n < 1}, Sign[_[\([2]\)]] > 0], 0, Hold[0]], 0^_ -> 1]]\)? I tried to use a sign command for the second part of the subexpression which is to be tested, but obviously the pattern symbol _ is not the correct wildcard symbol. Thank you so much frhes