Skip to content

Instantly share code, notes, and snippets.

@butchi
Created December 5, 2016 16:38
Show Gist options
  • Save butchi/96aaf57abcebd12e1821e60f752f04fc to your computer and use it in GitHub Desktop.
Save butchi/96aaf57abcebd12e1821e60f752f04fc to your computer and use it in GitHub Desktop.
Mathematicaで使う記号あれこれ ref: http://qiita.com/butchi_y/items/1d13c18cc195f0e9cf36
In[1]:= Map[f, {a, b, c, d, e}]
Out[1]= {f[a], f[b], f[c], f[d], f[e]}
In[1]:= f /@ {a, b, c, d, e}
Out[1]= {f[a], f[b], f[c], f[d], f[e]}
Sin[x]^2 + Cos[x]^2 // FullSimplify
In[1]:= Select[{1, 2, 4, 7, 6, 2}, # > 2 &]
Out[1]= {4, 7, 6}
5 + 3 I
Re[%]
Im[%%]
f[x_] := x + 1
f[x_] := x + 1
Nest[ArrayFlatten[# /. {
1 -> {{1, 1, 1}, {1, 0, 1}, {1, 1, 1}},
0 -> {{0, 0, 0}, {0, 0, 0}, {0, 0, 0}}
}] &, 1, 3]
<|a -> x, b -> y, c -> z|>
In[1]:= f @@ {a, b, c, d}
Out[1]= f[a, b, c, d]
In[1] := "Pen" <> "Pineapple" <> "Apple" <> "Pen"
Out[1] := "PenPineappleApplePen"
In[1]:= FullForm[{a, b, c, d}]
Out[1]= List[a, b, c, d]
In[1]:= Apply[f, {a, b, c, d}]
Out[1]= f[a, b, c, d]
In[1]:= List @@ f[a, b, c, d]
Out[1]= {a, b, c, d}
Graphics@Circle[{5, 3}, 8]
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment