# Limits and transformation rules

I can calculate this limit:

Limit[(c^(1 - g) - 1)/(1 - g), g -> 1]


and obtain the correct value:

Log[c]


but if I try to use a transformation rule (e.g. to plot that function for different values of g), I get an Indeterminate result:

Limit[(c^(1 - g) - 1)/(1 - g), g -> d] /. d -> 1

Indeterminate


I would assume that the transformation rule applies BEFORE the limit is calculated, but apparently that's not the case; and, on the other hand, I don't know how to force Mathematica to apply the rule before the limit is calculated.

Thanks,

pierpa

Unevaluated[Limit[(c^(1 - g) - 1)/(1 - g), g -> d]] /. d -> 1
Hold[Limit[(c^(1 - g) - 1)/(1 - g), g -> d]] /. d -> 1 // ReleaseHold
With[{d = 1}, Limit[(c^(1 - g) - 1)/(1 - g), g -> d]]
Limit[(c^(1 - g) - 1)/(1 - g), g -> #] &@1
Block[{Limit}, SetAttributes[Limit, HoldAll]; Limit[(c^(1 - g) - 1)/(1 - g), g -> d] /. d -> 1]
foo[(c^(1 - g) - 1)/(1 - g), g -> d] /. d -> 1 /. foo -> Limit


all give

(* Log[c] *)


In version 10, you can also use

Activate[Inactive[Limit[(c^(1 - g) - 1)/(1 - g), g ->d]] /. d->1]
Activate[Inactive[Limit][(c^(1 - g) - 1)/(1 - g), g ->d] /. d->1] (* thanks: @ybeltukov *)
Activate[Inactivate[Limit[(c^(1 - g) - 1)/(1 - g), g ->d]] /. d->1] (* thanks: @ybeltukov *)

• A nice comprehensive list :-) For new functionality the proper usage is Inactivate[Limit[...]] or Inactive[Limit][...]. – ybeltukov Feb 1 '15 at 0:14
• Thank you @ybeltukov. All three variants seem work in the Wolfram Cloud platform. – kglr Feb 1 '15 at 0:39
• Perfect, thanks a lot – pierpa Feb 2 '15 at 5:36