Skip to main content
6 events
when toggle format what by license comment
Nov 21, 2018 at 9:38 comment added chris yes that's what the rule mean.
Nov 21, 2018 at 3:10 comment added R zu If Mathematica can apply the same rule for several times, we only need one rule: Sum[y_ KroneckerDelta[s_, r_], {s_, 1, p_}] :> (y /. s -> r). I will ask a new question about that. Thanks for the answer.
Nov 21, 2018 at 3:05 vote accept R zu
Nov 21, 2018 at 3:05 comment added R zu Does the rest of the rule means: within each occurrence of $\sum_{u=1}^{U}\sum_{v=1}^{V} y \delta_{u, i} \delta_{v, j}$ in the expression, replace every $u$ and $v$ in sub-expression $y$ by $i$ and $j$ respectively.
Nov 21, 2018 at 2:54 comment added R zu Thanks for writing the rule. How does the rule work? :> means to transform lhs to rhs and then evaluate rhs. I guess (y /. s-> r) means to transform expression y such that each s in y is replaced by r... That is not always correct but works in this case. I don't get the rest of the rule.
Nov 21, 2018 at 2:41 history answered chris CC BY-SA 4.0