2
$\begingroup$

I would like to suppress the argument [0, 0, 0, 0] of K in the output of

Normal[Series[
   K[(Subscript[x, 0] - Subscript[x, 0] 0) t + 
     Subscript[x, 0] 0, (Subscript[x, 1] - Subscript[x, 1] 0) t + 
     Subscript[x, 1] 0, (Subscript[x, 2] - Subscript[x, 2] 0) t + 
     Subscript[x, 2] 0, (Subscript[x, 3] - Subscript[x, 3] 0) t + 
     Subscript[x, 3] 0], {t, 0, 2}]] /. t -> 1

Out

$\endgroup$
2
  • $\begingroup$ You probably want the derivative to look nice. (basing on your last question). Try this $\endgroup$
    – Kuba
    Dec 17, 2014 at 14:10
  • $\begingroup$ I think that the superscript notation is better in this case. $\endgroup$
    – simon
    Dec 17, 2014 at 14:32

1 Answer 1

3
$\begingroup$
Normal[Series[
   K[(Subscript[x, 0] - Subscript[x, 0] 0) t + 
     Subscript[x, 0] 0, (Subscript[x, 1] - Subscript[x, 1] 0) t + 
     Subscript[x, 1] 0, (Subscript[x, 2] - Subscript[x, 2] 0) t + 
     Subscript[x, 2] 0, (Subscript[x, 3] - Subscript[x, 3] 0) t + 
     Subscript[x, 3] 0], {t, 0, 2}]] /. t -> 1

% /. K_[0, 0, 0, 0] -> K

Out

$\endgroup$
2
  • $\begingroup$ What does the underscore mean? $\endgroup$
    – simon
    Dec 18, 2014 at 9:39
  • $\begingroup$ @simon The underscore is called Blank in Wolfram Language and it stands for any expression. You could also use % /. whatever_[0, 0, 0, 0] -> whatever to get the same output. This tutorial gives a nice introduction to the basics of pattern. $\endgroup$
    – Karsten 7.
    Dec 18, 2014 at 11:16

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.