Timeline for Rule for derivatives
Current License: CC BY-SA 3.0
10 events
| when toggle format | what | by | license | comment | |
|---|---|---|---|---|---|
| Aug 5, 2016 at 16:41 | comment | added | Kuba | @jjc385 thanks for reminding me of that question, I will rephrase it because I used things that makes this answer confusing. | |
| Aug 5, 2016 at 15:18 | comment | added | jjc385 | @Kuba What value does placing the rule inside a function add here, seeing as the OP asked for a rule? | |
| Jul 21, 2016 at 11:17 | comment | added | Kuba | @DavidPravos no need to accept so quickly, I will add more explanations later. Some things are needed and some may be confusing, like using FixedPoint, which isn't necessary. | |
| Jul 21, 2016 at 11:15 | comment | added | dpravos | Finally I have opted for defining the rule as Derivative[n_][f][var_] :> Module[{x}, (D[x f[x], {x, n - 1}] /. x -> var)]. I will mark the answer as right because it's equivalent. Thank you for your insights. | |
| Jul 21, 2016 at 11:14 | vote | accept | dpravos | ||
| Jul 21, 2016 at 11:11 | comment | added | dpravos | Trying to understand why this solution works I realized that defining the rule as Derivative[n_][f][x_] :> (D[y f[y], {y, n - 1}]/.y->x) does the job. The only thing left, as mentioned, is to localize the dummy variable y. | |
| Jul 21, 2016 at 11:08 | history | edited | Kuba | CC BY-SA 3.0 | added 12 characters in body |
| Jul 21, 2016 at 11:08 | comment | added | Mr.Wizard | Maybe I'm crazy but at first blush it looks like he is using :> and -> backward, or at least haphazardly. Certainly you changed -> to :> following Derivative[n_][f][x_]. | |
| Jul 21, 2016 at 11:04 | comment | added | Mr.Wizard | Shouldn't you localize x? And wouldn't mentioning RuleDelayed be useful to the OP? | |
| Jul 21, 2016 at 11:02 | history | answered | Kuba | CC BY-SA 3.0 |