Skip to main content
Tweeted twitter.com/#!/StackMma/status/401107835180036096
deleted 77 characters in body; edited tags
Source Link
rm -rf
  • 89.3k
  • 21
  • 297
  • 479

Thanks for your attention, I am a biginner of Mathematica. I am confused by the commandcommands @@ and @@@@. From the Helpdocumentation, I learnt that @@ has@@ is the function of applyApply. However, if I input Cos@@5Cos@@5 the output is 5, while if I input Cos@5Cos@5, I gotget Cos[5]Cos[5]. By this it seems that @@ rather than @@@@ has the function of apply"apply".

However, whenWhen I tried the function PlusPlus, Plus@@{1,2}Plus@@{1,2} gave me 33 as wanteddesired, while Plus@{1,2}Plus@{1,2} just gave me {1,2}{1,2}. Could anyone help me with the difference (or relation) between @@ and @@@@?

Thanks for your attention, I am a biginner of Mathematica. I am confused by the command @ and @@. From the Help I learnt @@ has the function of apply. However, if I input Cos@@5 the output is 5, while if I input Cos@5, I got Cos[5]. By this it seems @ rather than @@ has the function of apply.

However, when I tried the function Plus, Plus@@{1,2} gave me 3 as wanted while Plus@{1,2} just gave me {1,2}. Could anyone help me with the difference (or relation) between @ and @@?

I am confused by the commands @ and @@. From the documentation, I learnt that @@ is the function Apply. However, if I input Cos@@5 the output is 5, while if I input Cos@5, I get Cos[5]. By this it seems that @ rather than @@ has the function of "apply".

When I tried the function Plus, Plus@@{1,2} gave me 3 as desired, while Plus@{1,2} just gave me {1,2}. Could anyone help me with the difference (or relation) between @ and @@?

Source Link
user10568
user10568

Difference between @ and @@

Thanks for your attention, I am a biginner of Mathematica. I am confused by the command @ and @@. From the Help I learnt @@ has the function of apply. However, if I input Cos@@5 the output is 5, while if I input Cos@5, I got Cos[5]. By this it seems @ rather than @@ has the function of apply.

However, when I tried the function Plus, Plus@@{1,2} gave me 3 as wanted while Plus@{1,2} just gave me {1,2}. Could anyone help me with the difference (or relation) between @ and @@?