행렬 곱셈 문서 원본 보기
←
행렬 곱셈
둘러보기로 이동
검색으로 이동
문서 편집 권한이 없습니다. 다음 이유를 확인해주세요:
요청한 명령은 다음 권한을 가진 사용자에게 제한됩니다:
사용자
.
문서의 원본을 보거나 복사할 수 있습니다.
{{위키데이터 속성 추적}} [[파일:Matrix_multiplication_qtl1.svg|섬네일|행렬 곱셈을 위해선 첫째 행렬의 열 갯수와 둘째 행렬의 행 갯수가 동일해야한다. 곱셈의 결과 새롭게 만들어진 행렬은 첫째 행렬의 행 갯수와 둘째 행렬의 열 갯수를 가진다.]] '''행렬 곱셈'''({{lang|en|matrix multiplication}})은 두 개의 [[행렬]]에서 한 개의 행렬을 만들어내는 [[이항연산]]이다. 이 때 첫째 행렬의 열 개수와 둘째 행렬의 행 개수가 동일해야한다. 곱셈의 결과 새롭게 만들어진 행렬은 '''행렬곱'''(matrix product)라 하며, 첫째 행렬의 행 개수와 둘째 행렬의 열 개수를 가진다. 행렬 <math>A</math>와 <math>B</math>의 곱은 간단히 <math>AB</math>로 나타낸다.<ref name=":0">{{웹 인용|url=https://mathvault.ca/hub/higher-math/math-symbols/algebra-symbols/|title=Comprehensive List of Algebra Symbols|date=2020-03-25|website=Math Vault|language=en-US|access-date=2020-09-06}}</ref><ref name=":1">{{웹 인용|url=https://mathinsight.org/matrix_vector_multiplication|title=Multiplying matrices and vectors|last=Nykamp|first=Duane|date=|website=Math Insight|archive-url=|archive-date=|url-status=live|access-date=September 6, 2020}}</ref> 벡터의 [[선형결합]] 또는 [[선형사상]]의 합성 등의 의미를 부여할 수 있다. 행렬 곱셈은 1812년 프랑스의 수학자 [[자크 비네]]가 [[선형 변환]]의 [[함수의 합성|합성]]을 표현하고자 처음으로 사용하였다.<ref>{{MacTutor|id=Binet|title=Jacques Philippe Marie Binet}}</ref> 이후 행렬 곱셈은 [[선형대수학]]의 기초가 되어 [[수학]], [[통계학]], [[물리학]], [[경제학]], [[공학]], [[컴퓨터 프로그래밍]] 등의 분야에서 다양하게 응용되고 있다.<ref name="Physics 1991">{{서적 인용|title=Encyclopaedia of Physics|last1=Lerner|first1=R. G.|last2=Trigg|first2=G. L.|date=1991|edition=2nd|publisher=VHC publishers|isbn=978-3-527-26954-9}}</ref><ref>{{서적 인용|url=https://archive.org/details/mcgrawhillencycl1993park|title=McGraw Hill Encyclopaedia of Physics|last=Parker|first=C. B.|date=1994|edition=2nd|isbn=978-0-07-051400-3|url-access=registration}}</ref> == 표기 == 이 문서에서는 행렬을 굵은 대문자로({{수학|'''A'''}}), [[유클리드 벡터|벡터]]를 굵은 소문자로({{수학|'''a'''}}), 벡터와 행렬의 성분, 또는 요소로 번역되는 entry는 기울임체로({{수학|''A''}}, {{수학|''a''}}) 표기한다. [[첨자표기법]]은 가장 일반적인 방식을 따라 행렬 {{수학|'''A'''}}의 {{수학|''i''}}열 {{수학|''j''}}행 성분은 {{수학|('''A''')<sub>''ij''</sub>}}, {{수학|''A''<sub>''ij''</sub>}}, {{수학|''a''<sub>''ij''</sub>}} 등으로 표시한다. 반면 행렬 성분의 집합은 {{수학|'''A'''<sub>1</sub>, '''A'''<sub>2</sub>}} 등으로 표시한다. == 정의 == === 행렬 곱하기 행렬 === {{수학|'''A'''}}, {{수학|'''B'''}}를 각각 {{수학|''m'' × ''n''}}, {{수학|''n'' × ''p''}} 행렬이라고 하자. : <math>\mathbf{A}=\begin{pmatrix} a_{11} & a_{12} & \cdots & a_{1n} \\ a_{21} & a_{22} & \cdots & a_{2n} \\ \vdots & \vdots & \ddots & \vdots \\ a_{m1} & a_{m2} & \cdots & a_{mn} \\ \end{pmatrix},\quad\mathbf{B}=\begin{pmatrix} b_{11} & b_{12} & \cdots & b_{1p} \\ b_{21} & b_{22} & \cdots & b_{2p} \\ \vdots & \vdots & \ddots & \vdots \\ b_{n1} & b_{n2} & \cdots & b_{np} \\ \end{pmatrix}</math> 행렬곱 {{math|1='''C''' = '''AB'''}}은 다음의 {{math|''m'' × ''p''}} 행렬로 정의된다. 단 이때, 곱셈 기호는 따로 쓰지 않는다.<ref>{{서적 인용|title=Linear Algebra|url=https://archive.org/details/linearalgebra0000lips_a2h3|last1=Lipschutz|first1=S.|last2=Lipson|first2=M.|date=2009|edition=4th|series=Schaum's Outlines|publisher=McGraw Hill (USA)|pages=[https://archive.org/details/linearalgebra0000lips_a2h3/page/n430 30]–31|isbn=978-0-07-154352-1}}</ref><ref>{{서적 인용|url=https://archive.org/details/mathematicalmeth00rile|title=Mathematical methods for physics and engineering|last1=Riley|first1=K. F.|last2=Hobson|first2=M. P.|date=2010|publisher=Cambridge University Press|isbn=978-0-521-86153-3|last3=Bence|first3=S. J.|url-access=registration}}</ref><ref>{{서적 인용|title=Calculus, A Complete Course|last=Adams|first=R. A.|date=1995|edition=3rd|publisher=Addison Wesley|page=627|isbn=0-201-82823-5}}</ref><ref>{{서적 인용|title=Matrix Analysis|last=Horn|first=Johnson|date=2013|edition=2nd|publisher=Cambridge University Press|page=6|isbn=978-0-521-54823-6}}</ref> : <math>\mathbf{C}=\begin{pmatrix} c_{11} & c_{12} & \cdots & c_{1p} \\ c_{21} & c_{22} & \cdots & c_{2p} \\ \vdots & \vdots & \ddots & \vdots \\ c_{m1} & c_{m2} & \cdots & c_{mp} \\ \end{pmatrix}</math> 이 때 {{수학|1=''i'' = 1, ..., ''m''}}, {{수학|1=''j'' = 1, ..., ''p''}}에 대해 {{수학|'''C'''}}의 성분은 다음과 같이 정의된다. : <math> c_{ij} = a_{i1}b_{1j} + a_{i2}b_{2j} +\cdots + a_{in}b_{nj}= \sum_{k=1}^n a_{ik}b_{kj}, </math> 이는 곧 {{수학|'''A'''}}의 {{수학 변수|i}}번째 행과 {{수학|'''B'''}}의 {{수학 변수|j}}번째 열의 성분들을 각각 곱해 더한 것과 같은데, 달리 말하면 {{수학|'''A'''}}의 {{수학 변수|i}}번째 행과 {{수학|'''B'''}}의 {{수학 변수|j}}번째 열의 [[스칼라곱]]인 것이다.<ref name=":02">{{웹 인용|url=https://mathvault.ca/hub/higher-math/math-symbols/algebra-symbols/|title=Comprehensive List of Algebra Symbols|date=2020-03-25|website=Math Vault|language=en-US|access-date=2020-09-06}}</ref> 그런고로 {{수학|'''AB'''}}는 다음과 같이 쓸 수도 있다. : <math>\mathbf{C}=\begin{pmatrix} a_{11}b_{11} +\cdots + a_{1n}b_{n1} & a_{11}b_{12} +\cdots + a_{1n}b_{n2} & \cdots & a_{11}b_{1p} +\cdots + a_{1n}b_{np} \\ a_{21}b_{11} +\cdots + a_{2n}b_{n1} & a_{21}b_{12} +\cdots + a_{2n}b_{n2} & \cdots & a_{21}b_{1p} +\cdots + a_{2n}b_{np} \\ \vdots & \vdots & \ddots & \vdots \\ a_{m1}b_{11} +\cdots + a_{mn}b_{n1} & a_{m1}b_{12} +\cdots + a_{mn}b_{n2} & \cdots & a_{m1}b_{1p} +\cdots + a_{mn}b_{np} \\ \end{pmatrix} </math> 이러한 이유로 첫째 행렬의 열 갯수와 둘째 행렬의 행 갯수가 동일해야 행렬곱이 정의될 수 있는 것이다.<ref name=":12">{{웹 인용|url=https://mathinsight.org/matrix_vector_multiplication|title=Multiplying matrices and vectors|last=Nykamp|first=Duane|date=|website=Math Insight|archive-url=|archive-date=|url-status=live|access-date=September 6, 2020}}</ref> 대부분의 경우 행렬의 성분은 숫자이지만, [[덧셈]]과 [[곱셈]]이 정의되고, 곱셈의 [[결합법칙]]과 덧셈의 [[교환법칙]]이 성립하여 곱셈의 [[분배법칙]]이 성립하게 되는 다른 [[수학적 대상]]들도 성분이 될 수 있다. 가장 대표적인 예시로 성분이 행렬인 [[블록 행렬]]을 생각할 수 있다. === 도해 === [[파일:Matrix_multiplication_diagram_2.svg|오른쪽|섬네일|첫째 행렬의 행과 둘째 행렬의 열이 만나 행렬곱의 성분이 형성된다.]] 오른쪽 그림은 두 행렬 {{math|'''A'''}}와 {{math|'''B'''}}의 곱을 도표로 나타낸 것으로, 곱 행렬의 각 교집합이 {{math|'''A'''}}의 행과 {{math|'''B'''}}의 열에 어떻게 해당하는지 보여준다. <math display="block"> \overset{4\times 2 \text{ matrix}}{\begin{bmatrix} a_{11} & a_{12} \\ \cdot & \cdot \\ a_{31} & a_{32} \\ \cdot & \cdot \\ \end{bmatrix}} \overset{2\times 3\text{ matrix}}{\begin{bmatrix} \cdot & b_{12} & b_{13} \\ \cdot & b_{22} & b_{23} \\ \end{bmatrix}} = \overset{4\times 3\text{ matrix}}{\begin{bmatrix} \cdot & c_{12} & \cdot \\ \cdot & \cdot & \cdot \\ \cdot & \cdot & c_{33} \\ \cdot & \cdot & \cdot \\ \end{bmatrix}} </math> 오른쪽 그림에서 원으로 표시된 교차점의 값은 다음과 같다: <math display="block">\begin{align} c_{12} & = a_{11} b_{12} + a_{12} b_{22} \\ c_{33} & = a_{31} b_{13} + a_{32} b_{23} . \end{align}</math> == 응용 범위 == [[선형대수학]]적 계산을 행렬 곱셈을 통해 더욱 간단하게 할 수 있는데, [[물리학]], [[공학]], [[컴퓨터 과학]] 분야에서 특히 빛을 발한다. === 선형 변환 === {{수학|''n''}}차원 [[행 벡터와 열 벡터|열 벡터]] : <math>\mathbf x=\begin{pmatrix}x_1 \\ x_2 \\ \vdots \\ x_n\end{pmatrix}</math> 를 {{수학|''n''}}차원 [[선형 변환]] 한 것을 : <math>\mathbf y= A(\mathbf x)= \begin{pmatrix}a_{11}x_1+\cdots + a_{1n}x_n\\ a_{21}x_1+\cdots + a_{2n}x_n \\ \vdots \\ a_{m1}x_1+\cdots + a_{mn}x_n\end{pmatrix}</math> 라 하자. 이 때 선형 변환 {{수학|''A''}}는 자연스레 다음과 같은 행렬로 정의할 수 있다. :: <math>\mathbf{A}=\begin{pmatrix} a_{11} & a_{12} & \cdots & a_{1n} \\ a_{21} & a_{22} & \cdots & a_{2n} \\ \vdots & \vdots & \ddots & \vdots \\ a_{m1} & a_{m2} & \cdots & a_{mn} \\ \end{pmatrix} </math> 이제 행렬을 사용해 선형변환을 표현하면 다음과 같이 나타낼 수 있다. : <math>\mathbf y = \mathbf {Ax}</math> {{수학 변수|m}}차원 벡터 공간을 {{수학 변수|p}}차원 벡터 공간으로 변환하는 선형 변환 {{수학 변수|B}} 역시 {{tmath|p\times m}} 행렬 <math>\mathbf B</math>로 나타낼 수 있다. 이 두 변환을 [[함수의 합성|합성]]한 결과인 {{tmath|B\circ A}}도 행렬곱인 <math>\mathbf {BA}</math>로 나타낼 수 있다. 행렬 곱셈에서의 [[결합법칙]]은 {{Slink|2=결합법칙}}에서 다룰 것이다. === 연립 일차 방정식 === [[연립 일차 방정식]]의 일반항은 다음과 같이 쓸 수 있다. : <math>\begin{matrix}a_{11}x_1+\cdots + a_{1n}x_n=b_1 \\ a_{21}x_1+\cdots + a_{2n}x_n =b_2 \\ \vdots \\ a_{m1}x_1+\cdots + a_{mn}x_n =b_m\end{matrix}</math> 위의 여러 방정식들을 행렬을 사용하면 다음과 같이 [[방정식]] 한 개로 간단히 나타낼 수 있다. :<math>\mathbf{Ax}=\mathbf b</math> == 성질 == 행렬 곱셈은 일반적인 산술적 [[곱셈]]과 비슷한 성질을 가지지만, 첫째 행렬의 열 갯수와 둘째 행렬의 행 갯수가 동일할 때에만 정의된다는 특징이 있다. 또한 행렬 곱셈이 정의될 때에도 [[교환법칙]]이 항상 성립하는 것은 아니라는 점에서 차이가 있다.<ref name=":2">{{웹 인용|url=https://mathworld.wolfram.com/MatrixMultiplication.html|title=Matrix Multiplication|last=Weisstein|first=Eric W.|website=mathworld.wolfram.com|language=en|access-date=2020-09-06}}</ref><ref>{{서적 인용|title=Linear Algebra|url=https://archive.org/details/linearalgebra0000lips_a2h3|last1=Lipcshutz|first1=S.|last2=Lipson|first2=M.|date=2009|edition=4th|series=Schaum's Outlines|publisher=McGraw Hill (USA)|chapter=2|isbn=978-0-07-154352-1}}</ref><ref>{{서적 인용|title=Matrix Analysis|last=Horn|first=Johnson|date=2013|edition=2nd|publisher=Cambridge University Press|chapter=0|isbn=978-0-521-54823-6}}</ref> <math>{AB} \neq {BA}</math> 하지만 특수한 조건을 만족하는 경우에는 교환법칙이 성립한다. 다음과 같은 조건을 만족할 때 행과 열의 개수가 같은 정사각행렬 A와 B에 대해 곱셈의 교환법칙이 성립한다.<!-- [3] --> :<math> A + B = A B </math>이면, :<math>A B = B A </math>이다. 행렬 곱셈은 [[결합법칙]]이 성립한다: :<math>(\mathbf{AB})\mathbf{C} = \mathbf{A}(\mathbf{BC})</math><ref group="증명"> 각각 {{수학|''m'' × ''n''}}, {{수학|''n'' × ''p''}}, {{수학|''p'' × ''q''}} 행렬이라고 하자. 곱은 결합 방식에 상관없이 {{수학|''m'' × ''q''}} 행렬이며, :<math>\scriptstyle ((\mathbf{AB})\mathbf{C})_{ij} = \sum_{r=1}^p \left(\sum_{s=1}^n A_{is}B_{sr}\right)C_{rj} = \sum_{s=1}^n A_{is}\left(\sum_{r=1}^p B_{sr}C_{rj}\right) = (A(BC))_{ij}</math> </ref> == 예 == 행렬 <math>A=\begin{bmatrix}a\\b\end{bmatrix}</math>와 <math>B=\begin{bmatrix}c&d\end{bmatrix}</math>가 있을 때, 이 둘의 곱셈은 다음과 같다. :<math>AB=\begin{bmatrix}a\\b\end{bmatrix}\begin{bmatrix}c&d\end{bmatrix} = \begin{bmatrix}ac&ad\\bc&bd\end{bmatrix}</math> :<math>A^TB^T=\begin{bmatrix}a&b\end{bmatrix}\begin{bmatrix}c\\d\end{bmatrix} = ac + bd</math> :<math>BA=\begin{bmatrix}c&d\end{bmatrix}\begin{bmatrix}a\\b\end{bmatrix} = ca + db</math> :<math>B^TA^T=\begin{bmatrix}c\\d\end{bmatrix}\begin{bmatrix}a&b\end{bmatrix} = \begin{bmatrix}ca&cb\\da&db\end{bmatrix}</math> 행렬 <math>A=\begin{bmatrix}a&b\\c&d\end{bmatrix}</math>와 <math>B=\begin{bmatrix}e&f\\g&h\end{bmatrix}</math>가 있을 때, 이 둘의 곱셈은 다음과 같다. :<math>AB=\begin{bmatrix}a&b\\c&d\end{bmatrix}\begin{bmatrix}e&f\\g&h\end{bmatrix}=\begin{bmatrix}ae+bg&af+bh\\ce+dg&cf+dh\end{bmatrix}</math> == 각주 == === 증명주 === {{각주|group=증명}} === 참조주 === {{각주}} {{선형대수학}} {{전거 통제}} [[분류:행렬론]] [[분류:이항연산]] [[분류:곱셈]] [[분류:수치선형대수학]]
이 문서에서 사용한 틀:
틀:Lang
(
원본 보기
)
틀:MacTutor
(
원본 보기
)
틀:Math
(
원본 보기
)
틀:Slink
(
원본 보기
)
틀:Tmath
(
원본 보기
)
틀:각주
(
원본 보기
)
틀:서적 인용
(
원본 보기
)
틀:선형대수학
(
원본 보기
)
틀:수학
(
원본 보기
)
틀:수학 변수
(
원본 보기
)
틀:웹 인용
(
원본 보기
)
틀:위키데이터 속성 추적
(
원본 보기
)
틀:전거 통제
(
원본 보기
)
행렬 곱셈
문서로 돌아갑니다.
둘러보기 메뉴
개인 도구
로그인
이름공간
문서
토론
한국어
보기
읽기
원본 보기
역사 보기
더 보기
검색
둘러보기
대문
최근 바뀜
임의의 문서로
미디어위키 도움말
특수 문서 목록
도구
여기를 가리키는 문서
가리키는 글의 최근 바뀜
문서 정보