Data commit
This commit is contained in:
parent
7387c8f97b
commit
cb5bb5e222
199093 changed files with 3378972 additions and 0 deletions
12
Task/Vector/Mathematica/vector.math
Normal file
12
Task/Vector/Mathematica/vector.math
Normal file
|
|
@ -0,0 +1,12 @@
|
|||
ClearAll[vector,PrintVector]
|
||||
vector[{r_,\[Theta]_}]:=vector@@AngleVector[{r,\[Theta]}]
|
||||
vector[x_,y_]+vector[w_,z_]^:=vector[x+w,y+z]
|
||||
a_ vector[x_,y_]^:=vector[a x,a y]
|
||||
vector[x_,y_]-vector[w_,z_]^:=vector[x-w,y-z]
|
||||
PrintVector[vector[x_,y_]]:=Print["vector has first component: ",x," And second component: ",y]
|
||||
|
||||
vector[1,2]+vector[3,4]
|
||||
vector[1,2]-vector[3,4]
|
||||
12vector[1,2]
|
||||
vector[1,2]/3
|
||||
PrintVector@vector[{Sqrt[2],45Degree}]
|
||||
Loading…
Add table
Add a link
Reference in a new issue