Equate - Maple Help
For the best experience, we recommend viewing online help using Google Chrome or Microsoft Edge.

# Online Help

###### All Products    Maple    MapleSim

Home : Support : Online Help : Equate

Equate

convert a pair of rectangular objects into a list of equations

 Calling Sequence Equate(u, v)

Parameters

 u - list, Array, Matrix, Vector, or algebraic structure representing a vector of the Physics[Vectors] package v - list, Array, Matrix, Vector, or algebraic structure representing a vector of the Physics[Vectors] package

Description

 • The Equate(u,v) command receives the rectangular structures u and v, typically of type list, Array, Matrix or Vector, and returns a list of equations, where the left-hand sides of the equations are taken from u and the right-hand sides from the corresponding components of v. The two input objects, u and v, must have the same shapes and sizes, and if only one is an Array then its indices must start at 1.
 • Equate can also receive two algebraic structures u and v representing vectors of the Vectors subpackage of the Physics package, in which case the list of equations returned is constructed equating the components of u and v. When u and v are projected into different orthonormal basis, the second one is first reprojected onto the basis of the first one; then the components are equated.

Examples

 > $\mathrm{Equate}\left(\left[1,2\right],⟨a,b⟩\right)$
 $\left[{1}{=}{a}{,}{2}{=}{b}\right]$ (1)
 > $\mathrm{Equate}\left(⟨⟨1,2⟩|⟨3,4⟩|⟨5,6⟩⟩,\left[\left[a,b,c\right],\left[d,e,f\right]\right]\right)$
 $\left[{1}{=}{a}{,}{3}{=}{b}{,}{5}{=}{c}{,}{2}{=}{d}{,}{4}{=}{e}{,}{6}{=}{f}\right]$ (2)
 > $\mathrm{Equate}\left(⟨1,2,3⟩,⟨a|b|c⟩\right)$
 $\left[{1}{=}{a}{,}{2}{=}{b}{,}{3}{=}{c}\right]$ (3)
 > $\mathrm{Equate}\left(\mathrm{Array}\left(1..2,1..2,\left[\left[a,b\right],\left[c,d\right]\right]\right),\mathrm{Matrix}\left(\left[\left[1,2\right],\left[3,4\right]\right]\right)\right)$
 $\left[{a}{=}{1}{,}{b}{=}{2}{,}{c}{=}{3}{,}{d}{=}{4}\right]$ (4)
 > $\mathrm{Equate}\left(\mathrm{Vector}\left(3,\left[a,b,c\right]\right),\mathrm{Vector}\left(3,\left[1,2,3\right]\right)\right)$
 $\left[{a}{=}{1}{,}{b}{=}{2}{,}{c}{=}{3}\right]$ (5)
 > $\mathrm{Equate}\left(\mathrm{Vector}\left(3,\left[a,b,c\right]\right),⟨1,2,3⟩\right)$
 $\left[{a}{=}{1}{,}{b}{=}{2}{,}{c}{=}{3}\right]$ (6)
 > $\mathrm{Equate}\left(\mathrm{Matrix}\left(2,2,\left[\left[a,b\right],\left[c,d\right]\right]\right),⟨⟨1,2⟩|⟨3,4⟩⟩\right)$
 $\left[{a}{=}{1}{,}{b}{=}{3}{,}{c}{=}{2}{,}{d}{=}{4}\right]$ (7)
 > $\mathrm{Equate}\left(\mathrm{Array}\left(1..2,1..2,\left[\left[a,b\right],\left[c,d\right]\right]\right),⟨⟨1,2⟩|⟨3,4⟩⟩\right)$
 $\left[{a}{=}{1}{,}{b}{=}{3}{,}{c}{=}{2}{,}{d}{=}{4}\right]$ (8)

This is invalid because the dimensions do not match.

 > $\mathrm{Equate}\left(\left[\left[1,2\right],\left[3,4\right]\right],\mathrm{Array}\left(1..4,\left[a,b,c,d\right]\right)\right)$

This is invalid because the index origins do not match.

 > $\mathrm{Equate}\left(\mathrm{Array}\left(-2..1,\left[1,2,3,4\right]\right),\mathrm{Array}\left(1..4,\left[a,b,c,d\right]\right)\right)$

To handle vectors of the Vectors subpackage of Physics, first load Vectors

 > $\mathrm{with}\left(\mathrm{Physics}:-\mathrm{Vectors}\right)$
 $\left[{\mathrm{&x}}{,}{\mathrm{+}}{,}{\mathrm{.}}{,}{\mathrm{Assume}}{,}{\mathrm{ChangeBasis}}{,}{\mathrm{ChangeCoordinates}}{,}{\mathrm{CompactDisplay}}{,}{\mathrm{Component}}{,}{\mathrm{Curl}}{,}{\mathrm{DirectionalDiff}}{,}{\mathrm{Divergence}}{,}{\mathrm{Gradient}}{,}{\mathrm{Identify}}{,}{\mathrm{Laplacian}}{,}{\nabla }{,}{\mathrm{Norm}}{,}{\mathrm{ParametrizeCurve}}{,}{\mathrm{ParametrizeSurface}}{,}{\mathrm{ParametrizeVolume}}{,}{\mathrm{Setup}}{,}{\mathrm{Simplify}}{,}{\mathrm{^}}{,}{\mathrm{diff}}{,}{\mathrm{int}}\right]$ (9)

Equate the components of two vectors

 > $R≔x\mathrm{_i}+y\mathrm{_j}+z\mathrm{_k}$
 ${R}{≔}{x}{}\stackrel{{\wedge }}{{i}}{+}{y}{}\stackrel{{\wedge }}{{j}}{+}{z}{}\stackrel{{\wedge }}{{k}}$ (10)
 > $V≔-z\mathrm{_i}+\left(y-x\right)\mathrm{_k}$
 ${V}{≔}{-}{z}{}\stackrel{{\wedge }}{{i}}{+}\left({y}{-}{x}\right){}\stackrel{{\wedge }}{{k}}$ (11)
 > $\mathrm{Equate}\left(R,V\right)$
 $\left[{x}{=}{-}{z}{,}{y}{=}{0}{,}{z}{=}{y}{-}{x}\right]$ (12)

When the two vectors are not projected onto the same orthonormal basis, the second one is reprojected onto the basis of the first one. In the following examples $C$ and $S$ are the same vector as $R$ but expressed in cylindrical and spherical coordinates and corresponding orthonormal bases (see Vectors)

 > $C≔\mathrm{\rho }\mathrm{_ρ}+z\mathrm{_k}$
 ${C}{≔}{z}{}\stackrel{{\wedge }}{{k}}{+}{\mathrm{\rho }}{}\stackrel{{\wedge }}{{\mathrm{\rho }}}$ (13)
 > $S≔r\mathrm{_r}$
 ${S}{≔}{r}{}\stackrel{{\wedge }}{{r}}$ (14)
 > $\mathrm{Equate}\left(R,C\right)$
 $\left[{x}{=}{\mathrm{cos}}{}\left({\mathrm{\phi }}\right){}{\mathrm{\rho }}{,}{y}{=}{\mathrm{sin}}{}\left({\mathrm{\phi }}\right){}{\mathrm{\rho }}{,}{z}{=}{z}\right]$ (15)
 > $\mathrm{Equate}\left(R,S\right)$
 $\left[{x}{=}{\mathrm{sin}}{}\left({\mathrm{\theta }}\right){}{\mathrm{cos}}{}\left({\mathrm{\phi }}\right){}{r}{,}{y}{=}{\mathrm{sin}}{}\left({\mathrm{\theta }}\right){}{\mathrm{sin}}{}\left({\mathrm{\phi }}\right){}{r}{,}{z}{=}{r}{}{\mathrm{cos}}{}\left({\mathrm{\theta }}\right)\right]$ (16)

 See Also