다변수·행렬 미분과 헤시안Multivariable and matrix differentiation; Hessians
편미분의 입구에서 전미분·연쇄·Taylor·실제 손실까지 네 묶음Four groups from partial derivatives to total maps, chains, Taylor and actual losses
실습 6종 · 풀이 포함 연습문제 55개6 labs · 55 exercises with solutions
기초Foundations
1. 한 가지 입력만 바뀌는 세상에서 여러 입력으로1. From one changing input to several inputs
직사각형의 넓이 S=xy는 가로 x와 세로 y에 함께 달려 있습니다. 가로만 조금 늘릴 때와 세로만 늘릴 때, 둘 다 바꿀 때는 계산이 다릅니다. x=3 m,y=2 m에서 가로 0.1 m만 늘리면 넓이는 0.2 m² 늘지만, 둘 다 0.1 m 늘리면 0.51 m² 늘어납니다.
9장의 단변수 미분은 한 입력의 변화율을 다뤘습니다. 이제 다른 입력을 고정한 변화율에서 시작해, 여러 입력의 작은 변화를 한 번에 설명하는 선형변환을 만듭니다. 이를 위해 13~17장에서 배운 벡터·내적·행렬이 필요했습니다.
Rectangle area S=xy depends on two lengths. Changing only width differs from changing both inputs. At x=3 m,y=2 m, increasing width by 0.1 m adds 0.2 m²; increasing both by 0.1 m adds 0.51 m².
Start with one-coordinate changes, then build a linear transformation explaining simultaneous small changes. Vectors, inner products and matrices from Chapters 13–17 now become essential.
기초Foundations
2. 입력벡터·정의역·단위를 먼저 정하기2. Specify input vectors, domains and units first
입력 (x,y)를 벡터로 묶어도 두 좌표의 뜻과 단위는 남아 있습니다. 가로·세로의 순서를 바꾸거나, 한 좌표를 mm로 바꾸고 예전 계수를 쓰면 같은 모형이 아닙니다. 미분의 분모가 무엇의 변화인지 계속 기록해야 합니다.
f:U⊆Rn⟶R,a∈U,U open near a
이 장의 전미분 정의는 점 a 주변에 작은 공이 들어가는 열린 정의역에서 사용합니다. ln(x+y)는 x+y>0 안에서 다루고, 경계 x+y=0에 같은 공식을 그대로 적용하지 않습니다. 경계의 한쪽 변화는 별도의 정의가 필요합니다.
실습의 다항함수는 모든 실수 좌표에서 정의되며 단위가 없는 가정 모형입니다. 뒤의 실제 손실에서는 자료와 계수의 단위를 따로 표시합니다. 편미분 계산이 가능하다고 그 좌표를 현실에서 독립적으로 조작할 수 있다는 뜻은 아닙니다.
Bundling inputs into a vector does not erase coordinate meanings or units. Track what changes in each derivative denominator and convert coefficients consistently.
f:U⊆Rn⟶R,a∈U,U open near a
Total differentiation here uses a domain containing a small ball around a. Work with ln(x+y) inside x+y>0; boundary changes require separate definitions.
Polynomial labs use dimensionless hypothetical functions on all real coordinates. Actual loss functions later retain data and parameter units. A computable partial derivative does not establish a real-world independently manipulable input.
기초Foundations
3. 다른 입력을 고정하면 한 변수 곡선이 된다3. Holding another input fixed creates a one-variable slice
가정함수 f(x,y)=x²+xy+2y²를 보겠습니다. y=1을 고정하면 x²+x+2라는 단변수 곡선입니다. x=1에서 그 기울기는 2·1+1=3입니다. 이번에는 x=1을 고정하면 1+y+2y²이고 y=1에서 기울기는 5입니다.
f(x,y)=x2+xy+2y2,fx(1,1)=3,fy(1,1)=5
같은 점에도 어느 좌표만 바꾸는지에 따라 변화율이 다릅니다. 실습은 두 절단곡선을 번갈아 보면서 고정한 값과 움직이는 값을 표시합니다. 3과 5를 더한 8이 함수값이라는 뜻은 아니며 실제 f(1,1)=4입니다.
단변수 미분법을 새로 버리는 것이 아닙니다. 다른 좌표를 상수로 취급하며 이미 배운 정의와 규칙을 적용하는 단계입니다. 단, 두 절단곡선만 알면 주변의 모든 방향이 자동 설명되는지 아직 확인하지 않았습니다.
For f(x,y)=x²+xy+2y², fixing y=1 gives x²+x+2 with slope 3 at x=1. Fixing x=1 instead gives 1+y+2y² with slope 5 at y=1.
f(x,y)=x2+xy+2y2,fx(1,1)=3,fy(1,1)=5
One point can have different coordinate-specific rates. Inspect the fixed and changing coordinates. The values 3 and 5 are derivatives, while f(1,1)=4.
Apply existing one-variable definitions with other coordinates held constant. Whether these slices determine every nearby direction remains a separate question.
기초Foundations
4. 편미분의 정의: h를 바꾸는 동안 다른 좌표는 고정4. The partial-derivative definition holds other coordinates fixed
x편미분에서는 y=b를 끝까지 고정합니다. y편미분에서는 x=a를 고정합니다. ∂ 기호는 여러 입력 중 어느 하나만 바꿨는지 알려 줍니다. 분모 h,k는 0이 아니며 극한에서 0으로 접근합니다.
앞 다항함수의 x차분은 2a+b+h, y차분은 a+4b+2k입니다. h,k를 각각 0으로 보내면 fₓ=2a+b, fᵧ=a+4b를 얻습니다. h=0에 직접 나누는 계산과 극한을 구별하세요.
여러 입력 x₁,…,xₙ에서도 한 좌표만 움직이는 표준방향 eⱼ를 사용합니다. 이 결과는 그 방향의 한 가지 변화율입니다. 정의역의 다른 좌표를 동시에 바꾼 차분을 같은 편미분이라고 이름 붙이면 안 됩니다.
Hold y=b throughout an x derivative, and x=a throughout a y derivative. The ∂ symbol identifies the selected coordinate. Difference quotients use nonzero steps approaching zero.
The polynomial's quotients are 2a+b+h and a+4b+2k, yielding derivatives 2a+b and a+4b. Taking a limit differs from division at step zero.
In n inputs, move only along coordinate eⱼ. A quotient changing several coordinates is not automatically the same partial derivative.
기초Foundations
5. 곱·연쇄·로그 규칙에서 상수로 남는 것5. Track constants in product, chain and logarithm rules
f=xy에서는 x로 미분할 때 y가 상수이므로 fₓ=y이고, y로 미분하면 fᵧ=x입니다. eˣʸ에서는 안쪽 xy의 편미분을 곱해 fₓ=yeˣʸ, fᵧ=xeˣʸ입니다. 한 변수의 연쇄법칙을 절단곡선에 적용한 것입니다.
∂x∂exy=yexy,∂y∂ln(x+y)=x+y1(x+y>0)
ln(x+y)의 두 편미분은 모두 1/(x+y)이지만 정의역은 여전히 x+y>0입니다. 분모가 0이 아닌 곳 전체라고 확대하면 실수 로그의 정의역을 잃습니다.
변수 이름이 같은 문자라고 자동으로 함께 움직이지 않습니다. f(x,y)를 편미분하는 문제와 f(x,y(x))를 한 변수 x로 미분하는 문제는 다릅니다. 뒤의 연쇄법칙에서 이 차이를 정식으로 연결합니다.
For xy, holding y fixed gives fₓ=y, while holding x fixed gives fᵧ=x. For eˣʸ, one-variable chain rules on slices give yeˣʸ and xeˣʸ.
∂x∂exy=yexy,∂y∂ln(x+y)=x+y1(x+y>0)
Both logarithm partials equal 1/(x+y), but the real domain remains x+y>0, not merely nonzero denominator.
Partial differentiation of f(x,y) differs from ordinary differentiation of f(x,y(x)). Later chain rules explain the extra dependence explicitly.
기초Foundations
6. 변화율의 단위와 ‘나머지 고정’의 의미6. Units and the meaning of holding other inputs fixed
S=xy에서 길이가 m이면 Sₓ=y의 단위는 m²/m=m입니다. x를 0.1 m 바꿀 때 2 m·0.1 m=0.2 m²가 됩니다. 편미분 자체의 단위와 그것을 변화량에 곱한 결과 단위를 구별하세요.
[fxj]=[f]/[xj],Δf≈fxjΔxjwhen only xj changes
경제 모형의 가격·수량·소득처럼 단위가 다른 좌표에서는 각 편미분의 단위도 다릅니다. 그 숫자만 보고 ‘더 큰 영향’이라고 비교하면 단위 선택의 결과를 효과 크기로 오해할 수 있습니다.
또한 모형에서 나머지를 고정한다는 계산과, 실제 자료에서 다른 요인을 통제했다는 연구설계는 다릅니다. 이번 장의 실제 사례는 관측으로 정의한 손실의 편미분을 계산하며 관측된 경제의 인과함수를 알아냈다고 주장하지 않습니다.
For area S=xy in square metres, Sₓ=y has unit m²/m=m. Multiplying 2 m by a 0.1 m width change yields 0.2 m². A derivative's unit differs from the resulting output-change unit.
[fxj]=[f]/[xj],Δf≈fxjΔxjwhen only xj changes
Coordinates such as price, quantity and income produce differently dimensioned derivatives. Comparing raw derivative numbers can confuse unit choices with effect sizes.
Holding coordinates fixed in a formula is not proof of statistical control or causal identification. Actual examples differentiate explicitly chosen losses, not an identified causal law of the economy.
기초Foundations
7. 편미분 둘 다 있어도 연속조차 아닐 수 있다7. Existing partials need not even imply continuity
0이 아닌 점에서 f(x,y)=xy/(x²+y²), 원점에서 f(0,0)=0으로 정의합니다. x축이나 y축에서는 값이 항상 0이라 원점의 두 편미분은 0입니다.
Along nonzero y=x the value is 1/2, so continuity fails. Coordinate-axis checks missed another approach.
Existing partials alone do not establish a tangent-plane approximation. Total differentiability requires a remainder small enough for every nearby approach.
기초Foundations
8. 방향미분: 한 직선을 따라 접근하기8. Directional derivatives follow a chosen line
방향 v를 정하고 a+tv로 움직이면 t 하나의 함수가 됩니다. 그 0에서의 미분을 Dᵥf(a)라고 정의합니다. 이 장은 먼저 양쪽 t→0 극한을 사용하고, 단위방향인지도 따로 표시합니다.
Dvf(a)=t→0limtf(a+tv)−f(a)
v=e₁,e₂이면 앞의 편미분입니다. v가 두 배면 같은 t 동안 두 배 빠르게 움직이므로 변화율도 달라질 수 있습니다. ‘거리 한 단위당’ 변화율을 비교할 때는 ‖v‖=1로 정규화합니다.
여러 직선방향의 극한이 있다는 것과, 그 결과를 하나의 선형변환으로 묶을 수 있다는 것은 다른 질문입니다. 다음 반례는 모든 방향을 확인해도 전미분이 자동 보장되지 않음을 보여 줍니다.
Along a fixed direction v, a+tv creates a one-variable path. Define its derivative using a two-sided t→0 limit, specifying separately whether v is unit length.
Dvf(a)=t→0limtf(a+tv)−f(a)
Coordinate directions give partials. Doubling v changes path speed for the same t. Use unit directions when comparing change per unit distance.
Existing line-direction limits need not combine into one linear transformation. The next example separates this condition from total differentiability.
선택 심화Optional extension
9. 선택 반례: 모든 방향미분이 있어도 선형이 아닐 수 있다9. Optional counterexample: all directional derivatives may be nonlinear in direction
0이 아닌 점에서 g(x,y)=x³/(x²+y²), 원점에서 0으로 정의합니다. |g(x,y)|≤|x|이므로 원점에서 연속입니다. 방향 (p,q)≠0에 대해 t를 대입하면 g(tp,tq)=t p³/(p²+q²)여서 양쪽 방향미분이 존재합니다.
D(p,q)g(0,0)=p2+q2p3,gx(0,0)=1,gy(0,0)=0
그러나 방향 (1,1)의 값은 1/2입니다. 편미분을 선형으로 묶었다면 1·1+0·1=1이어야 하므로 일치하지 않습니다. 방향에 따른 미분값이 선형사상이 아닙니다.
이 반례는 ‘방향별로 존재한다’와 ‘하나의 선형근사로 모든 작은 변화를 설명한다’의 차이입니다. 다음 전미분 정의는 직선별 확인보다 강한 전체 나머지 조건을 둡니다.
Define g=x³/(x²+y²) away from zero and g(0,0)=0. The bound |g|≤|x| proves origin continuity. For a nonzero direction (p,q), substitution gives g(tp,tq)=t p³/(p²+q²), so every two-sided directional derivative exists.
D(p,q)g(0,0)=p2+q2p3,gx(0,0)=1,gy(0,0)=0
The direction (1,1) gives 1/2 rather than the linear prediction 1. Directional derivatives therefore fail to define a linear map of the direction.
Existence on every fixed line differs from one linear approximation controlling all nearby changes. Total differentiability adds that stronger remainder condition.
기초Foundations
10. 전미분: 모든 작은 변화를 하나의 선형사상으로10. Total differentiation uses one linear map for all small changes
점 a에서 f의 전미분이 존재한다는 것은 어떤 선형사상 L이 있어 f(a+h)=f(a)+Lh+R(h)로 쓸 수 있고, 나머지가 입력 크기보다 훨씬 작아진다는 뜻입니다. 기호 Df(a)는 이 선형사상 자체를 나타냅니다.
f(a+h)=f(a)+Df(a)h+R(h),h→0h=0lim∥h∥∣R(h)∣=0
이때 ‘훨씬 작다’를 R(h)=o(‖h‖)라고 씁니다. 어떤 한 경로만이 아니라 정의역 안의 모든 접근에서 비율이 0으로 가야 합니다. h=0에서는 비율을 계산하지 않습니다. 근사값 f(a)+Lh는 아핀식이고, 미분 L은 증가분을 보내는 선형식입니다.
Total differentiability at a means one linear map L gives f(a+h)=f(a)+Lh+R(h), with remainder small relative to input size. Df(a) denotes that linear map itself.
f(a+h)=f(a)+Df(a)h+R(h),h→0h=0lim∥h∥∣R(h)∣=0
The notation R=o(‖h‖) means the ratio tends to zero over every nearby approach, not one chosen path. Do not divide at h=0. The approximation is affine; the derivative maps increments linearly.
A finite-dimensional linear map satisfies ‖Lh‖≤C‖h‖, so differentiability implies continuity. Restricting to coordinate directions recovers partial derivatives, which determine the map's coefficients.
기초Foundations
11. 접평면 근사를 실제 나머지와 비교하기11. Compare a tangent-plane approximation with its actual remainder
기본 가정함수 f=x²+xy+2y²를 (1,1)에서 펼치면 함수값 4, 두 편미분 3,5입니다. x=1+h,y=1+k로 대입해 전개하면 아래의 정확한 식을 얻습니다.
f(1+h,1+k)=4+3h+5k+R(h,k)h2+hk+2k2,L(h,k)=3h+5k
h=0.1,k=0.2이면 선형근사는 5.3이고 실제값은 5.41로 차이는 0.11입니다. 두 증가분을 반으로 줄이면 나머지는 0.0275로 1/4입니다. 입력 크기는 절반, 이차 나머지는 1/4이 되어 나머지/입력 비율이 작아집니다.
실습은 함수값·근사값·부호 있는 나머지·절대오차·입력노름을 구별해 보여 줍니다. h=k=0일 때 오차는 0이지만 나머지/입력의 비는 0/0이라 미정의라고 표시합니다. 극한과 한 점의 나눗셈은 다릅니다.
At (1,1), the base polynomial has value 4 and partials 3 and 5. Direct expansion gives an exact remainder.
f(1+h,1+k)=4+3h+5k+R(h,k)h2+hk+2k2,L(h,k)=3h+5k
For h=0.1,k=0.2, the linear approximation is 5.3 and actual value 5.41. Halving both increments quarters the remainder from 0.11 to 0.0275 while halving input size.
Separate value, approximation, signed remainder, absolute error and input norm. At zero increment, error is zero but the ratio 0/0 is undefined; the limit remains a separate statement.
기초Foundations
12. 한 경로 실험에서 모든 경로의 상계로12. From testing a path to bounding every path
몇 개 슬라이더 값이 잘 맞는다고 전미분의 정의를 증명한 것은 아닙니다. 앞 나머지를 모든 (h,k)에 대해 상계해 봅시다. |hk|≤(h²+k²)/2를 쓰면 |R|≤(3/2)h²+(5/2)k²≤(5/2)(h²+k²)입니다.
0≤h2+k2∣R(h,k)∣≤25h2+k2⟶0((h,k)=(0,0))
오른쪽은 접근방향을 가리지 않고 0으로 갑니다. 따라서 이 함수의 전미분은 L(h,k)=3h+5k임을 검증했습니다. 실습의 관찰과 수학적 상계가 서로 다른 역할을 합니다.
상수 5/2가 가장 작은 최적상계일 필요는 없습니다. 미분가능성을 증명하는 데는 입력 크기와 함께 0으로 가는 충분한 상계면 됩니다. 오차의 실제값과 상계를 다시 구별하세요.
Several successful slider settings are not a proof. Use |hk|≤(h²+k²)/2 to bound the remainder by (5/2)(h²+k²).
0≤h2+k2∣R(h,k)∣≤25h2+k2⟶0((h,k)=(0,0))
This controls every approach direction and verifies derivative L(h,k)=3h+5k. Observation and proof serve distinct roles.
The constant need not be sharp. A sufficient vanishing bound establishes differentiability without claiming equality with the actual error.
열린 근방에서 편미분들이 존재하고 a에서 연속이면 전미분이 존재합니다. 이를 사용하는 익숙한 충분조건은 f가 근방에서 C¹, 즉 1차 편미분이 연속이라는 조건입니다. 편미분의 존재만으로 충분하다는 말과 다릅니다.
Df(a,b)(h,k)=fx(a,b)h+fy(a,b)k
증명은 한 번에 두 좌표를 바꾸는 대신 세로·가로로 나눕니다. f(a+h,b+k)−f(a,b)를 [f(a+h,b+k)−f(a,b+k)]+[f(a,b+k)−f(a,b)]로 씁니다. 각 차이에 단변수 평균값정리를 적용하면 가까운 중간점의 fₓ에 h를 곱한 값과 fᵧ에 k를 곱한 값이 나옵니다.
기준 편미분을 뺀 오차는 ε(|h|+|k|) 이하로 만들 수 있고, 이는 √2 ε‖(h,k)‖ 이하입니다. 편미분의 연속성이 모든 중간점의 차이를 작게 해 주므로 나머지/노름이 0으로 갑니다. h나 k가 0인 경우 해당 차이는 그냥 0으로 둡니다.
Partials existing in a neighborhood and continuous at a ensure total differentiability there. The familiar stronger local C¹ condition is sufficient; mere existence is not.
Df(a,b)(h,k)=fx(a,b)h+fy(a,b)k
Split the change into [f(a+h,b+k)−f(a,b+k)]+[f(a,b+k)−f(a,b)]. Apply the one-variable mean-value theorem to each nonzero coordinate change.
Continuity makes the differences between intermediate partials and base partials at most ε. The remainder is bounded by ε(|h|+|k|)≤√2 ε‖(h,k)‖. A zero coordinate change contributes zero directly.
선택 심화Optional extension
14. 선택 연결: 충분조건과 필요조건을 구별하기14. Optional bridge: sufficient is not necessary
g(x,y)=x²sin(1/x)를 x≠0에서 쓰고 x=0에서는 0으로 둡니다. y에는 의존하지 않습니다. 원점에서 |g(h,k)|≤h²≤‖(h,k)‖²이므로 전미분은 0입니다.
gx(x,y)=2xsin(1/x)−cos(1/x)(x=0),Dg(0,0)=0
그러나 x가 0으로 갈 때 −cos(1/x)가 흔들리므로 x편미분은 원점에서 연속이 아닙니다. 전미분이 존재하지만 C¹의 충분조건을 만족하지 않는 예입니다.
정리의 가정을 확인해 사용할 수 없다는 것과 결론이 거짓이라는 것은 다릅니다. 충분조건은 안전하게 적용하는 방법이지 가능한 모든 미분가능함수를 빠짐없이 판별하는 필요조건이 아닙니다. 다음 묶음은 전미분이 존재할 때 그 선형사상을 기울기와 야코비안으로 표현합니다.
Define g=x²sin(1/x) for x≠0 and zero at x=0, independent of y. The bound |g(h,k)|≤h²≤‖(h,k)‖² proves zero total derivative at the origin.
gx(x,y)=2xsin(1/x)−cos(1/x)(x=0),Dg(0,0)=0
The cosine term prevents continuity of this partial derivative at the origin. Differentiability can therefore hold without the sufficient local C¹ condition.
Failure to meet a theorem's sufficient hypothesis does not prove its conclusion false. Next we represent existing total derivatives using gradients and Jacobians.
기초Foundations
15. 기울기 벡터와 미분 행벡터의 역할15. The gradient column and derivative row have different roles
이제 f가 전미분 가능하다고 합시다. 편미분을 세로로 모은 열벡터가 기울기 ∇f입니다. 증가분 h를 출력 변화 하나로 보내는 Df는 이 열의 전치인 행벡터로 표현됩니다.
∇f(a)=fx1(a)⋮fxn(a),Df(a)h=∇f(a)Th
기본함수에서는 ∇f=(2x+y,x+4y)ᵀ입니다. (1,1)에서 열벡터 (3,5)ᵀ이고, 미분은 행 [3,5]로 h에 곱합니다. 숫자는 같지만 모양과 작용을 구별하면 전치를 실수하지 않습니다.
편미분을 모은 목록은 편미분만 존재할 때도 적을 수 있습니다. 그러나 ∇fᵀh가 모든 방향을 설명하는 전미분이라고 하려면 앞 묶음의 미분가능성 조건이 필요합니다. 정의를 모았다는 이유로 반례가 사라지지 않습니다.
Assume f is totally differentiable. Collect its partials in the gradient column ∇f. The derivative mapping an increment to one scalar is represented by its transpose, a row.
∇f(a)=fx1(a)⋮fxn(a),Df(a)h=∇f(a)Th
The base polynomial has gradient (2x+y,x+4y)ᵀ, giving (3,5)ᵀ at (1,1). Its derivative row [3,5] acts on h.
A list of existing partials can be written without total differentiability. Using it as a linear approximation in all directions requires the stronger differentiability condition.
기초Foundations
16. 방향미분은 기울기와 방향의 내적16. A directional derivative is a gradient dot product
전미분의 증가분에 h=tv를 넣으면 f(a+tv)−f(a)=t∇f(a)ᵀv+o(|t|‖v‖)입니다. 고정한 v에서 t로 나눈 극한은 ∇f(a)·v입니다. 이것이 방향미분 공식의 조건과 유도입니다.
Dvf(a)=∇f(a)⋅v,uθ=(cosθ,sinθ),∥uθ∥=1
(1,1)에서 단위방향 u=(3/5,4/5)이면 변화율은 3·3/5+5·4/5=29/5=5.8입니다. 방향의 길이가 1인지 확인한 뒤 ‘거리 한 단위당’이라고 읽습니다. 각 θ는 9장의 라디안·삼각함수와 연결됩니다.
9절 반례처럼 전미분이 없는 함수에서는 편미분 목록과 방향을 내적한 값이 실제 방향미분과 다를 수 있습니다. 공식을 외우는 것과 적용조건을 확인하는 것을 함께 연습하세요.
Insert increment tv into the differentiability expansion and divide by t. For a fixed direction, the vanishing remainder gives the gradient dot-product rule.
Dvf(a)=∇f(a)⋅v,uθ=(cosθ,sinθ),∥uθ∥=1
At (1,1), unit direction (3/5,4/5) gives 29/5=5.8. Check unit length before interpreting change per unit distance. The angle uses radians and trigonometry from Chapter 9.
Without total differentiability, the rule can fail as in Section 9. Formula and applicability conditions belong together.
기초Foundations
17. 가장 가파른 방향과 기울기 0의 예외17. Steepest directions and the zero-gradient exception
단위방향 u에서 ∇f·u≤‖∇f‖라는 Cauchy–Schwarz 부등식을 씁니다. ∇f≠0이면 u=∇f/‖∇f‖에서 최대 변화율 ‖∇f‖를 얻고, 반대 방향에서 최소 −‖∇f‖를 얻습니다.
∥u∥=1maxDuf=∥∇f∥,umax=∥∇f∥∇f(∇f=0)
(1,1)의 최대 단위방향은 (3,5)/√34이고 최대 변화율은 √34입니다. (3,4)/5의 5.8보다 큽니다. 방향을 바꾸면 함수의 1차 변화가 달라진다는 것을 수치로 비교할 수 있습니다.
원점에서는 기본함수의 기울기가 0입니다. 모든 방향의 1차 변화율이 0이므로 유일한 최급방향을 정할 수 없습니다. 0/0으로 정규화하지 않습니다. 실제 함수변화가 모두 0이라는 뜻도 아니며, 이차 항은 뒤의 헤시안에서 봅니다.
Cauchy–Schwarz bounds ∇f·u by ‖∇f‖ for unit u. A nonzero gradient's normalized direction attains the maximum; its negative gives the minimum.
∥u∥=1maxDuf=∥∇f∥,umax=∥∇f∥∇f(∇f=0)
At (1,1), the maximizing direction is (3,5)/√34 and rate √34, exceeding 5.8 in the earlier direction.
At the origin the gradient vanishes. All first-order directional rates are zero, so there is no unique steepest unit direction and no valid gradient normalization. Higher-order changes may still occur.
기초Foundations
18. 최급방향도 좌표의 단위와 거리규칙에 의존한다18. Steepest directions depend on units and the movement metric
길이 m와 비용 원을 한 벡터의 두 좌표로 쓰면 ‘한 단위 이동’이 무엇인지 먼저 정해야 합니다. 두 숫자를 그대로 제곱해 더한 유클리드 거리는 단위와 눈금의 선택입니다. 13장의 혼합단위 거리 문제가 기울기에서도 나타납니다.
기울기의 각 성분은 출력/해당입력 단위입니다. m를 cm로 바꾸면 해당 편미분 숫자는 1/100배가 됩니다. 아무 조정 없이 기울기 화살표의 기울기를 비교하면 같은 물리적 상황에 다른 최급방향이 나올 수 있습니다.
기본함수 실습은 무차원 좌표와 표준 유클리드 노름을 사용합니다. 실제 손실의 계수에서는 단위를 표시하고, 서로 다른 단위의 gradient 성분 숫자만으로 어느 계수가 더 중요한지 순위를 매기지 않습니다. 기준척도나 사전조건화는 뒤의 최적화에서 연결합니다.
A coordinate pair measured in metres and won needs a definition of unit movement. Raw Euclidean distance embeds a unit/scale choice, just as mixed-feature distances did in Chapter 13.
Gradient components have output-per-input units. Converting metres to centimetres divides the corresponding numerical partial by 100. Unadjusted arrow comparisons can therefore change a steepest direction without changing the physical problem.
Labs use dimensionless coordinates and the standard Euclidean metric. For actual parameter losses, report units and avoid ranking heterogeneous gradient components by raw magnitude alone.
기초Foundations
19. 벡터 출력의 미분은 야코비안 행렬이다19. A vector-valued derivative is a Jacobian matrix
g가 n개 입력을 받아 m개 출력을 만들면 각 출력 gᵢ의 편미분을 한 행에 놓습니다. 야코비안 Jg는 m×n이고, i행 j열은 출력 i를 입력 j로 편미분한 값입니다.
g:Rn→Rm,(Jg)ij=∂xj∂gi,Dg(a)h=Jg(a)h
입력 증가분 h는 n×1, 예측 출력변화는 m×1입니다. ‘출력이 행, 입력이 열’이라고 크기로 기억하세요. 스칼라 출력 f의 야코비안은 1×n이고 ∇fᵀ입니다. 모든 야코비안이 기울기 열벡터인 것은 아닙니다.
미분가능성이 있어야 이 행렬이 전체 변화의 선형근사입니다. 여러 출력에서도 각 편미분이 존재한다는 사실만으로 전미분이 자동 보장되지는 않습니다.
For n inputs and m outputs, put the partial derivatives of output gᵢ in row i. The Jacobian is m×n, with output rows and input columns.
g:Rn→Rm,(Jg)ij=∂xj∂gi,Dg(a)h=Jg(a)h
Multiplication maps n×1 increments to m×1 output changes. A scalar function's Jacobian is the row ∇fᵀ, not its gradient column.
Total differentiability is needed to interpret this matrix as an all-direction linear approximation; existence of entries alone is insufficient.
기초Foundations
20. 두 출력의 야코비안을 한 칸씩 계산하기20. Compute a two-output Jacobian entry by entry
g(s,t)=(s²+t,st)라고 두겠습니다. 첫 출력 u는 s에 대해 2s, t에 대해 1입니다. 둘째 출력 v는 s에 대해 t, t에 대해 s입니다. 두 출력을 행으로 적습니다.
g(s,t)=(s2+tst),Jg(s,t)=(2st1s)
(s,t)=(1,1)에서는 출력 (2,1), 야코비안 [[2,1],[1,1]]입니다. 증가분 (h,k)를 넣으면 예측 출력변화는 (2h+k,h+k)입니다. 실제로 전개하면 나머지는 (h²,hk)로 따로 남습니다.
Jg의 행렬식 2s²−t가 0인 점에서는 선형근사의 랭크가 줄어듭니다. 그렇다고 모든 비선형 정보가 없다는 뜻은 아닙니다. 국소 가역성과 임계점은 이후 정리의 추가 조건과 함께 다룹니다.
For g(s,t)=(s²+t,st), differentiate each output across the two input coordinates to obtain the displayed Jacobian.
g(s,t)=(s2+tst),Jg(s,t)=(2st1s)
At (1,1), output is (2,1) and the linear increment is (2h+k,h+k). Direct expansion leaves remainder (h²,hk).
At 2s²−t=0, the Jacobian loses rank. This concerns the first-order approximation, not necessarily every piece of nonlinear information.
기초Foundations
21. 벡터 출력에서도 나머지 전체의 노름을 잰다21. Use an output norm for a vector-valued remainder
벡터 출력의 전미분은 나머지의 절대값 대신 출력벡터의 노름으로 정의합니다. 입력 ℝⁿ과 출력 ℝᵐ의 크기를 각각 알맞게 씁니다.
g(a+h)=g(a)+Jg(a)h+r(h),∥h∥Rn∥r(h)∥Rm→0
앞 예제의 나머지 (h²,hk)는 노름이 |h|√(h²+k²)입니다. 입력노름으로 나눈 비율이 |h|→0이므로 전미분 조건을 직접 확인합니다. 입력 증가분이 0인 점에서는 비율을 계산하지 않습니다.
유한한 m개 출력이 각각 전미분 가능하면 전체 벡터함수도 전미분 가능합니다. 각 나머지를 충분히 작게 만든 뒤 제곱합을 상계하면 됩니다. 무한차원으로의 확장은 다른 조건이 필요하므로 여기서는 유한차원 범위를 유지합니다.
For vector outputs, measure the remainder with an output norm and divide by the input norm in its own space.
g(a+h)=g(a)+Jg(a)h+r(h),∥h∥Rn∥r(h)∥Rm→0
The example remainder (h²,hk) has norm |h|√(h²+k²). Its ratio to input size is |h|→0 for nonzero increments.
Finitely many differentiable component outputs combine into a differentiable vector function by bounding their squared remainders. This statement is kept within finite-dimensional spaces.
기초Foundations
22. 연쇄법칙: 중간 출력에서 미분을 평가한다22. Chain rules evaluate the outer derivative at the intermediate output
스칼라 f(u,v)=u²+uv+2v²에 g(s,t)=(s²+t,st)를 넣어 F=f∘g를 만듭니다. 먼저 g의 출력 (u,v)를 구하고, 그 점에서 f의 미분을 평가한 뒤 Jg를 곱합니다.
At (1,1), g=(2,1), f=8 and ∇f(2,1)=(5,6)ᵀ. Multiplication gives ∇F=(16,11)ᵀ. Evaluating the outer derivative at (1,1) instead would be wrong.
The derivative rows multiply as (1×2)(2×2), producing 1×2. Gradient columns require the transpose. Check intermediate evaluation points and shapes together.
선택 심화Optional extension
23. 선택 증명: 작은 나머지를 합성해도 작은 이유23. Optional proof: composing small remainders preserves differentiability
g가 a에서 미분 가능하고 f가 g(a)에서 미분 가능하며 근처 합성이 정의된다고 합시다. Δ=g(a+h)−g(a)=Jg h+r_g입니다. 선형사상과 작은 나머지 때문에 ‖Δ‖≤C‖h‖로 상계할 수 있습니다.
A bounded fixed linear map keeps the first remainder o(‖h‖). The other satisfies ‖r_f(Δ)‖≤ε‖Δ‖≤εC‖h‖. When Δ=0 use the direct zero bound, without division.
The derivative is therefore the composition of linear maps, hence the ordered Jacobian product. The proof uses total differentiability, not just existing partials.
기초Foundations
24. 시간경로에서는 각 입력의 속도를 곱해 더한다24. A time path combines each input rate
넓이 S=xy에서 x(t)=3+t, y(t)=2+2t라고 합시다. 길이는 m, t는 초이고 입력속도는 각각 1 m/s,2 m/s라는 가정입니다. t=0의 전체 넓이속도는 두 경로를 모두 고려해야 합니다.
Using only the x partial misses the changing y path. Evaluate partials at the current point. Direct expansion S(t)=6+8t+2t² verifies the result.
Observed annual differences remain interval averages. Differentiating an assumed continuous path does not generate new subperiod observations or causal rates.
기초Foundations
25. 좌표변환에서 왜 Aᵀ가 기울기에 붙는가25. Why coordinate changes transpose the matrix in a gradient
x=Az라는 선형 입력변환 뒤에 스칼라 f를 계산한다고 합시다. 증가분은 dx=A dz이고 df=∇ₓfᵀA dz입니다. 이를 z기울기의 전치와 비교하면 ∇_zF=Aᵀ∇ₓf를 얻습니다.
F(z)=f(Az),∇zF=AT∇xf(Az)
A가 m×n이면 f의 입력은 m개, F의 입력은 n개입니다. Aᵀ는 n×m이어서 기울기 열을 알맞은 공간으로 보냅니다. 행렬이 정방이어도 전치를 생략할 수 없습니다.
직교 A는 회전·반사를 포함하는 직교 좌표변환으로 같은 유클리드 기하를 유지합니다. 비직교 척도변환은 입력의 거리규칙과 최급방향 해석도 바꿀 수 있습니다. 연쇄법칙의 미분값과 어떤 물리적 이동을 ‘같은 크기’로 볼지는 구별해야 합니다.
For x=Az, increments satisfy dx=A dz. Comparing df=∇ₓfᵀA dz with the z-gradient representation gives a transpose.
F(z)=f(Az),∇zF=AT∇xf(Az)
If A is m×n, the outer gradient has m components and the new one has n. Aᵀ maps the columns with compatible dimensions, even when the matrix happens to be square.
Orthogonal transformations preserve Euclidean geometry; general rescaling can change the interpretation of equal movement and steepest direction. Distinguish the chain rule from the chosen movement metric.
기초Foundations
26. 이차 편미분은 첫 변화율을 다시 미분한다26. Second partials differentiate a first rate again
fₓ를 x로 다시 미분하면 fₓₓ, y로 미분하면 fₓᵧ입니다. 이 장에서는 fₓᵧ=(fₓ)ᵧ처럼 왼쪽 첨자를 먼저 미분한 것으로 정의합니다. 순서 표기가 다른 책도 있으므로 실제 연산을 확인합니다.
f=x2+xy+2y2,fxx=2,fxy=1,fyx=1,fyy=4
fₓᵧ는 y가 바뀔 때 x방향 변화율이 어떻게 바뀌는지 나타냅니다. 이 기본함수에서는 x편미분 2x+y가 y에 따라 1씩 바뀝니다. 혼합미분을 무조건 ‘둘을 동시에 변화시킨 차이’라고 부르기보다 순서 있는 미분으로 읽으세요.
단위도 두 번 나눕니다. fₓᵧ의 단위는 출력/(x단위·y단위), fₓₓ는 출력/(x단위)²입니다. 실제 손실의 헤시안에서 칸마다 단위가 달라지는 이유입니다.
Differentiate fₓ again in x to obtain fₓₓ, or in y to obtain fₓᵧ. Here fₓᵧ means (fₓ)ᵧ, first x then y; check conventions in other books.
f=x2+xy+2y2,fxx=2,fxy=1,fyx=1,fyy=4
A mixed partial describes how a rate in one coordinate changes with another. In this example, fₓ=2x+y changes by one per unit y.
Units divide by both input units. Diagonal second partials divide by an input unit squared, so Hessian entries can have different units.
선택 심화Optional extension
27. 혼합미분의 순서를 바꿀 충분조건27. Conditions for interchanging mixed partials
열린 근방에서 2차 편미분들이 연속인 C² 함수라면 혼합미분 순서를 바꿀 수 있습니다. 이를 Schwarz 또는 Clairaut 정리라고 부릅니다. 단지 두 반복 편미분 값이 어느 한 점에서 존재한다는 조건보다 강합니다.
f∈C2 near a⟹fxixj(a)=fxjxi(a)
선택 반례로 φ=xy(x²−y²)/(x²+y²)를 원점 밖에서 쓰고 원점에서는 0으로 둡니다. φₓ(0,y)=−y, φᵧ(x,0)=x이므로 이 장의 순서로 φₓᵧ(0,0)=−1, φᵧₓ(0,0)=1입니다.
이 경우 연속인 2차 편미분이라는 가정이 실패합니다. 순서가 다르다는 관찰을 보고 정리가 틀렸다고 하지 않습니다. 뒤의 대칭 헤시안·이차 Taylor에서는 C² 같은 적절한 정칙조건을 명시합니다.
For a C² function on an open neighborhood, mixed partials can be interchanged. This Schwarz/Clairaut condition is stronger than existence of repeated partials at one point.
f∈C2 near a⟹fxixj(a)=fxjxi(a)
For an optional counterexample, set φ=xy(x²−y²)/(x²+y²) away from zero and zero at the origin. Then φₓ(0,y)=−y and φᵧ(x,0)=x, giving φₓᵧ=−1 and φᵧₓ=1 under our convention.
The continuous-second-partial hypothesis fails. Symmetric-Hessian and second-order Taylor statements below retain suitable regularity assumptions such as C².
기초Foundations
28. 헤시안: 기울기 변화의 야코비안28. The Hessian is the Jacobian of a changing gradient
f가 C²이면 기울기 열벡터를 다시 전미분한 행렬이 헤시안 Hf입니다. i행 j열은 기울기의 i성분을 xⱼ로 미분한 값입니다. 혼합미분 정리 때문에 대칭입니다.
Hf=J∇f,Hf=(fxxfyxfxyfyy),Hf=(2114)for the base polynomial
기본함수의 헤시안은 어느 점에서나 같습니다. 작은 증가분 h가 기울기를 얼마나 바꿀지 Hh로 설명합니다. 여기서는 실제로 ∇f(a+h)−∇f(a)=Hh로 정확히 맞습니다.
함수가 C²가 아니면 2차 편미분 숫자를 적은 표만으로 대칭적인 2차 전미분을 보장할 수 없습니다. 스칼라 함수의 헤시안은 정방이지만 일반 벡터함수의 1차 야코비안은 직사각형일 수 있다는 차이도 기억하세요.
For C² f, the Hessian is the derivative of its gradient column. Entry i,j differentiates gradient component i with respect to input j; mixed-partial symmetry makes the matrix symmetric.
Hf=J∇f,Hf=(fxxfyxfxyfyy),Hf=(2114)for the base polynomial
The base Hessian is constant. It predicts the gradient change Hh, exactly for this quadratic function.
A table of existing second partials alone need not supply a symmetric second total derivative. Scalar Hessians are square; general first-order vector Jacobians need not be.
기초Foundations
29. 직선의 이차 변화와 곡선경로의 추가항29. Straight-line curvature and an extra curved-path term
고정한 v에 대해 h(t)=f(a+tv)라 두면 h′(0)=∇f(a)·v, h″(0)=vᵀHf(a)v입니다. 따라서 16장의 이차형식이 한 방향의 이차 변화율을 나타냅니다. f는 경로 주변에서 C²라고 가정합니다.
For fixed v and C² f, the straight path h(t)=f(a+tv) has first rate ∇f·v and second rate vᵀHv, connecting to quadratic forms.
dt2d2f(a+tv)t=0=vTHf(a)v
The base polynomial gives rates 2 and 4 along coordinate directions, and 4 along (1,1)/√2. Rescaling direction multiplies second rates by the squared scale.
A curved path adds ∇f·γ″. The linear function f(x,y)=x has zero Hessian, yet along γ(t)=(t²,t) its second time derivative is 2.
30. 헤시안의 양의 준정부호를 무엇의 부호로 읽는가30. Read Hessian signs as directional quadratic changes
실수 대칭 헤시안의 vᵀHv가 양수이면 해당 방향의 순간 이차 변화가 양수입니다. 기본 H=[[2,1],[1,4]]의 고유값은 3±√2로 모두 양수입니다. 그래서 어느 비영 직선방향에서도 양의 이차 변화율을 갖습니다.
H=(2114),λ±=3±2,vTHv>0(v=0)
x²−y²에서는 H=diag(2,−2)라 방향에 따라 곡률 부호가 다릅니다. x⁴+y⁴의 원점에서는 H=0이지만 함수가 상수라는 뜻은 아닙니다. 2차까지의 정보가 0인 경우 고차 항이 남을 수 있습니다.
헤시안의 부호와 실제 함수의 최솟값 판정은 관련되지만 같은 단계가 아닙니다. 19장에서는 내부·경계·정상점과 필요한 조건을 갖춰 최적조건을 전개합니다. 여기서는 어떤 함수를 어떤 방향으로 두 번 미분했는지 먼저 확인합니다.
A positive vᵀHv means positive instantaneous second change in that direction. The base Hessian has eigenvalues 3±√2, so every nonzero direction has positive second rate.
H=(2114),λ±=3±2,vTHv>0(v=0)
For x²−y² the signs differ by direction. For x⁴+y⁴, the origin Hessian is zero although the function is not constant; higher-order terms remain.
Chapter 19 develops extrema with interior, boundary and stationarity conditions. First keep the function and direction being differentiated explicit.
기초Foundations
31. 다변수 이차 Taylor: 값·기울기·헤시안31. Second-order multivariable Taylor uses value, gradient and Hessian
a의 열린 근방에서 f가 C²이면 증가분 h에 대해 아래 근사를 쓸 수 있습니다. 11장의 단변수 전개와 같지만 일차항은 내적, 이차항은 이차형식입니다. 모든 계수는 전개중심 a에서 평가합니다.
나머지가 o(‖h‖²)라는 것은 모든 접근에서 |나머지|/‖h‖²→0이라는 뜻입니다. 나머지 자체가 항상 정확히 0이라는 뜻도, 어떤 큰 구간에서 무조건 정밀하다는 뜻도 아닙니다.
For C² f on an open neighborhood of a, second-order Taylor replaces scalar slope and curvature with a gradient inner product and Hessian quadratic form, all evaluated at a.
f(a+h)=f(a)+∇f(a)Th+21hTHf(a)h+o(∥h∥2)
The factor one half is essential. For the base Hessian, it converts 2h₁²+2h₁h₂+4h₂² into the actual quadratic term.
The remainder ratio to ‖h‖² tends to zero over all approaches. This does not claim an identically zero remainder or universal large-step accuracy.
선택 심화Optional extension
32. 선택 유도: 선분 위의 단변수 적분나머지32. Optional derivation: a one-variable integral remainder along a segment
a에서 a+h까지의 선분이 C² 근방 안에 있다고 합시다. g(t)=f(a+th), 0≤t≤1을 정의합니다. 연쇄법칙으로 g′(0)=∇f(a)ᵀh, g″(t)=hᵀHf(a+th)h입니다.
f(a+h)=f(a)+∇f(a)Th+∫01(1−t)hTHf(a+th)hdt
기준 헤시안을 적분 밖으로 꺼낸 항은 ∫₀¹(1−t)dt=1/2라 Taylor의 이차항입니다. 남은 적분에는 H(a+th)−H(a)가 들어갑니다. 따라서 나머지 절대값은 선분에서의 헤시안 차이 2노름 최댓값에 ‖h‖²/2를 곱한 값 이하입니다.
헤시안의 연속성 때문에 그 최댓값은 h→0에서 0으로 갑니다. 이것이 모든 방향을 포함한 o(‖h‖²)를 보장합니다. 같은 두 끝점이라도 정의역 밖으로 나가는 선분에는 이 유도를 그대로 쓰지 않습니다.
Keep the segment from a to a+h inside a C² neighborhood and set g(t)=f(a+th). Chain rules give g′(0)=∇f(a)ᵀh and g″(t)=hᵀHf(a+th)h.
f(a+h)=f(a)+∇f(a)Th+∫01(1−t)hTHf(a+th)hdt
The constant-Hessian part integrates to one half. The remaining integral contains H(a+th)−H(a) and is bounded by half the maximum Hessian difference norm times ‖h‖².
Continuity makes that maximum vanish as h→0, proving the little-o remainder. A segment leaving the valid domain does not satisfy these assumptions.
학부 심화 · 선택Advanced undergraduate · optional
33. 수치 오차상계에는 한 단계 더 강한 조건이 필요하다33. A numerical remainder bound needs stronger information
C²만으로 나머지가 작아지는 비율은 알 수 있지만, 명시적인 세제곱 상계를 얻으려면 더 많은 정보가 필요합니다. C³ 근방에서 모든 관련 단위방향의 3차 미분 절대값을 M으로 상계하면 단변수 Taylor로 |R₂|≤M‖h‖³/6을 얻습니다.
∣R2(h)∣≤6M∥h∥3
예를 들어 f(x,y)=eˣ⁺ʸ를 원점에서 전개하면 T₂=1+(h+k)+(h+k)²/2입니다. 선분에서 지수와 세 번째 경로미분을 상계하여 아래 식을 얻습니다. 이는 선택한 함수의 구체적인 상계입니다.
∣eh+k−T2∣≤6e∣h+k∣∣h+k∣3
h=k=0.1이면 T₂=1.22, 실제 오차는 약 0.001403이고 상계는 약 0.001629입니다. 상계와 실제 오차가 같지는 않습니다. h+k=0에서는 이 예의 함수값과 근사가 모두 1이라 오차도 0입니다.
C² gives a vanishing remainder ratio but not a universal numeric cubic bound. In a C³ neighborhood, a bound M on relevant unit-direction third derivatives yields |R₂|≤M‖h‖³/6.
∣R2(h)∣≤6M∥h∥3
For eˣ⁺ʸ at the origin, T₂=1+(h+k)+(h+k)²/2. A direct path bound gives a concrete remainder estimate.
∣eh+k−T2∣≤6e∣h+k∣∣h+k∣3
At h=k=0.1, T₂=1.22, actual error is about 0.001403 and the bound about 0.001629. At h+k=0 both value and approximation equal one.
기초Foundations
34. 정확한 이차함수와 유한한 큰 변화의 한계34. Exact quadratics and limitations at large finite steps
기본함수는 이차다항식이므로 어떤 중심에서도 이차 Taylor가 정확합니다. (1,1)에서 h=0.1,k=0.2라면 T₂=4+0.3+1+0.11=5.41로 실제값과 같습니다. 이것을 일반 함수의 이차근사도 항상 정확하다는 규칙으로 확대하지 않습니다.
더 높은 차수를 썼다고 임의의 큰 단계에서 항상 오차가 작아지는 것도 아닙니다. f(x,y)=1+x+x²−2x³를 원점에서 x=1까지 쓰면 실제값은 1, 일차근사 2, 이차근사 3입니다. 이차근사가 더 나쁩니다. 충분히 작은 단계와 올바른 나머지 조건을 함께 봐야 합니다.
한 변수 사례가 두 입력 함수 안에도 그대로 들어갈 수 있습니다. 11장의 전개중심·범위·나머지 검산이 다변수에서도 중요하다는 뜻입니다. 실제 자료의 적합손실이 이차이면 정확전개를 쓰고, 자료생성과정 전체가 이차라고 주장하지 않습니다.
The base polynomial is exactly quadratic, so its second-order Taylor expression is exact at every center. At increments (0.1,0.2) from (1,1), it gives 5.41 exactly.
Higher order need not improve every large finite step. For 1+x+x²−2x³ at x=1 from the origin, the actual value is 1, first-order approximation 2 and second-order approximation 3.
Center, range and remainder assumptions remain essential. A chosen data-fitting loss may be quadratic without the entire data-generating process being quadratic.
기초Foundations
35. 0 헤시안은 함수가 평평하다는 완전한 결론이 아니다35. A zero Hessian does not fully describe local behavior
원점에서 x⁴+y⁴와 −x⁴−y⁴는 함수값 0, 기울기 0, 헤시안 0이 같습니다. 그러나 원점 주변 값은 서로 반대 부호입니다. 둘째 미분까지 같아도 고차 항의 모습은 다를 수 있습니다.
실습의 quartic 선택에서 원점의 이차곡률 0과 유한 거리에서의 함수변화를 따로 보세요. saddle 선택 x²−y²에서는 헤시안이 이미 방향별 반대 부호를 보여 줍니다. 어느 차수의 정보가 무엇을 구별하는지 점검합니다.
내부 극값의 필요조건과 충분조건은 다음 장에서 체계적으로 다룹니다. 지금 중요한 점은 기울기·헤시안의 수학적 정의와 사용조건을 정확히 연결하는 것입니다. 다음 묶음은 이 정의를 행렬 입력과 실제 제곱손실에 적용합니다.
At the origin, x⁴+y⁴ and its negative have equal value, zero gradient and zero Hessian, yet opposite signs nearby. Higher-order behavior can differ despite matching second-order information.
For the quartic lab, distinguish zero origin curvature from finite-distance changes. The saddle x²−y² already has mixed curvature signs at second order.
Chapter 19 develops necessary and sufficient extrema conditions. The next group first applies our derivative definitions to matrix inputs and actual squared losses.
기초Foundations
36. df는 유한한 실제 변화와 구별한다36. Distinguish a differential from an actual finite change
df=Df(a)[dx]=∇f(a)ᵀdx라고 쓰면 증가분 dx에 작용하는 선형부분을 뜻합니다. 유한한 Δx에 대한 실제 Δf는 이 선형부분에 나머지가 더해집니다. 같은 기호처럼 보인다고 나머지를 없었던 사실로 취급하지 않습니다.
df=∇f(a)Tdx,Δf=Df(a)Δx+o(∥Δx∥)
기본함수에서 dx=(0.1,0.2)는 선형 변화 df=1.3을 주지만 실제 변화는 1.41입니다. 선형함수에서는 나머지가 0이라 같지만 일반 함수에서는 근사입니다.
행렬 입력에서도 ‘미분’은 작은 행렬 증가분을 받는 선형사상입니다. 이를 먼저 구하면 수천 개의 칸을 하나씩 미분하지 않고도 전체 구조를 볼 수 있습니다. 다음 두 절에서 벡터 미분과 같은 정의를 그대로 사용합니다.
df=Df(a)[dx]=∇f(a)ᵀdx denotes the linear action on an increment. An actual finite change includes a remainder; notation does not erase it.
df=∇f(a)Tdx,Δf=Df(a)Δx+o(∥Δx∥)
For the base polynomial and increment (0.1,0.2), df=1.3 while the actual change is 1.41. Equality holds for affine functions but not generally.
A matrix-input derivative is likewise a linear map taking matrix increments. Computing that map reveals structure before listing every scalar partial.
기초Foundations
37. 행렬을 입력받는 미분: X²의 선형사상37. A matrix-input derivative: the map for X²
정방행렬의 함수 F(X)=X²를 생각합니다. 입력 증가분 H를 넣으면 (X+H)²−X²=XH+HX+H²입니다. H에 선형인 두 항을 모은 것이 미분입니다. 행렬곱의 순서를 바꿀 수 없으므로 둘을 무조건 2XH라고 합치지 않습니다.
DF(X)[H]=XH+HX,∥H2∥F≤∥H∥F2
나머지 H²는 입력노름보다 빠르게 작아져 전미분 조건을 만족합니다. X와 H가 서로 교환할 때만 미분을 2XH로 간단히 쓸 수 있습니다. 일반 행렬 증가분에는 그 조건이 없습니다.
출력도 행렬이어서 미분 자체를 X와 같은 크기의 ‘기울기 행렬 하나’라고 부르지 않습니다. 각 칸을 일정한 순서로 벡터화하면 n²개 입력에서 n²개 출력으로 가는 야코비안은 n²×n²입니다. 선형사상 XH+HX는 그 큰 표를 만들지 않고도 작용을 표현합니다.
For F(X)=X², expansion gives (X+H)²−X²=XH+HX+H². The linear action is the sum of the first two terms, not generally 2XH.
DF(X)[H]=XH+HX,∥H2∥F≤∥H∥F2
The quadratic remainder vanishes relative to input norm. Only commuting X and H permit simplification to 2XH.
Because the output is also a matrix, the derivative is not one same-shaped scalar gradient. After a fixed vectorization, its Jacobian has shape n²×n². The operator expression avoids constructing that large table.
기초Foundations
38. 스칼라 출력의 행렬기울기는 Frobenius 내적으로38. A scalar matrix gradient uses the Frobenius inner product
스칼라 f(X)의 미분은 행렬 증가분 H를 숫자로 보냅니다. Frobenius 내적 〈G,H〉F=ΣGᵢⱼHᵢⱼ=trace(GᵀH)로 쓰면 G를 행렬기울기라고 부릅니다. G의 크기는 입력 X와 같습니다.
Df(X)[H]=⟨∇Xf,H⟩F=tr((∇Xf)TH)
고정 C에 대한 f(X)=trace(CᵀX)는 각 칸의 선형합이므로 기울기 C입니다. f(X)=‖X−C‖F²/2에서는 제곱을 펼쳐 Df[H]=〈X−C,H〉F, 기울기 X−C를 얻습니다.
이것은 출력이 스칼라라는 조건에 의존합니다. 37절의 행렬 출력 미분과 구별하세요. 입력 칸들을 열부터 쌓을지 행부터 쌓을지에 따라 벡터화 야코비안 표기는 달라질 수 있으므로, 좌표화할 때는 순서를 고정합니다. 실제 선형작용과 칸별 편미분은 같은 계산을 표현합니다.
A scalar f(X) has a derivative mapping matrix increments to numbers. Represent it through the Frobenius inner product; the matrix gradient has the same shape as X.
Df(X)[H]=⟨∇Xf,H⟩F=tr((∇Xf)TH)
For fixed C, trace(CᵀX) has gradient C. Expanding ‖X−C‖F²/2 gives derivative 〈X−C,H〉F and gradient X−C.
The scalar-output condition matters. Matrix-valued derivatives are different operators. If entries are vectorized, specify row or column stacking consistently.
기초Foundations
39. xᵀAx의 미분에서 대칭부분이 나오는 이유39. Why xᵀAx differentiates through the symmetric part
고정 실수 A에 대해 f(x)=xᵀAx를 펼칩니다. 증가분 h의 일차항은 hᵀAx+xᵀAh입니다. 두 번째 스칼라를 전치하면 hᵀAᵀx이므로 기울기는 (A+Aᵀ)x입니다.
∇(xTAx)=(A+AT)x,Hf=A+AT
A가 대칭일 때만 2Ax,2A로 줄입니다. f=xᵀAx/2라면 다시 1/2가 곱해져 대칭 A에서 기울기 Ax, 헤시안 A입니다. 목적함수 앞의 계수를 빠뜨리지 않습니다.
A=[[1,10],[0,1]]이면 헤시안은 [[2,10],[10,2]]입니다. 비대칭 A를 그대로 2A라고 반환하면 헤시안 대칭성과 실제 칸별 미분에 맞지 않습니다. 이차형식에서 반대칭부분은 xᵀ(A−Aᵀ)x=0이라 함수값에 기여하지 않습니다.
For fixed A, the linear terms in (x+h)ᵀA(x+h) are hᵀAx+xᵀAh. Transposing the second scalar yields gradient (A+Aᵀ)x.
∇(xTAx)=(A+AT)x,Hf=A+AT
Only symmetric A reduces this to 2Ax and 2A. With an objective factor one half, symmetric gradients and Hessians become Ax and A.
For [[1,10],[0,1]], the Hessian is [[2,10],[10,2]], not 2A. The antisymmetric part contributes zero to the scalar quadratic form.
기초Foundations
40. 실제 자료를 고정한 제곱손실의 기울기·헤시안40. Differentiate squared loss with the observations held fixed
X와 y는 고정된 자료이고 β가 바뀌는 계수라고 합시다. 관측 n개, 계수 p개에서 L(β)=‖Xβ−y‖²/(2n)을 선택합니다. 앞 장의 적합은 같지만 목적함수의 배율을 새로 정했으므로 미분의 배율도 따라갑니다.
L(β)=2n1∥Xβ−y∥2,∇L=n1XT(Xβ−y),HL=n1XTX
잔차를 이번에는 e=Xβ−y라 두고 h를 넣어 전개하면 L(β+h)=L(β)+hᵀXᵀe/n+hᵀXᵀXh/(2n)입니다. 이 정확전개에서 기울기와 헤시안을 읽을 수 있습니다. 관측−적합 잔차를 썼던 앞 장과 부호만 다르며 목적함수는 같습니다.
XᵀX는 PSD이고 열이 독립이면 PD입니다. 데이터의 공분산과 손실의 헤시안이 언제나 같은 행렬이라는 뜻은 아닙니다. 어떤 변수를 미분했고 어떤 목적함수·분모를 선택했는지에 따라 달라집니다.
SSE 자체를 목적함수로 쓰면 기울기와 헤시안은 위 값의 2n배입니다. 양수 상수배라 최소화하는 계수는 같지만, 미분값·학습률·오차상계는 같은 숫자가 아닙니다. 실제 사례에서 분모 2n을 공통으로 명시합니다.
Hold data X and y fixed and vary coefficients β. For n observations and p coefficients, choose loss ‖Xβ−y‖²/(2n). The objective scaling changes derivative magnitudes.
L(β)=2n1∥Xβ−y∥2,∇L=n1XT(Xβ−y),HL=n1XTX
Using e=Xβ−y, exact expansion gives L(β+h)=L(β)+hᵀXᵀe/n+hᵀXᵀXh/(2n). This residual sign is opposite to observation-minus-fit but yields the same loss.
The Hessian is PSD, and PD for independent columns. It is not automatically the empirical covariance of the observed data; parameters and objective determine it.
Using SSE itself multiplies these derivatives by 2n. The minimizing coefficients stay the same, but derivative values and step-size interpretation do not.
기초Foundations
41. 실제 국가·가구·기업 손실에서 미분하기41. Differentiate actual country, household and company losses
국가 사례는 2014~2024년 한국의 실질 1인당 GDP 11개 관측을 고정하고 u=연도−2019, 예측 a+bu를 선택합니다. θ=(a,b), L=Σ(a+bu−y)²/22입니다. Σu=0,Σu²=110이므로 헤시안은 diag(1,10)입니다.
기준 θ=(33000,700)에서 기울기는 약 (−290.089779,−544.759285)입니다. GDP 정책의 인과미분이 아니라 선택한 적합손실이 계수에 따라 변하는 속도입니다. 두 성분의 단위도 서로 다르므로 숫자 크기만으로 중요도를 비교하지 않습니다.
가구 사례는 1440분의 실제 주방·세탁 Wh를 각각 상수 a,b로 예측합니다. L=Σ[(주방−a)²+(세탁−b)²]/(2·1440)의 헤시안은 I₂입니다. 앞 장의 경험적 채널 공분산에는 약 9.042896 Wh²의 비대각 항이 있었지만, 이 손실의 계수곡률은 다른 대상입니다.
기업 사례는 실제 FY2023 품목벡터 x와 FY2024 z를 고정하고 예측 αx+δe서비스를 선택합니다. 계수순서는 (α,δ), α는 무차원이고 δ는 백만 미국달러입니다. L=‖αx+δe서비스−z‖²/10의 헤시안은 [[10148585472.6,17040],[17040,0.2]]입니다. 비대각 항의 크기에도 계수단위가 반영됩니다.
The country case fixes 11 Korean GDP-per-person observations from 2014–2024 and predicts a+bu with u=year−2019. Using L=Σ(a+bu−y)²/22 gives Hessian diag(1,10), since Σu=0 and Σu²=110.
At parameters (33000,700), the gradient is approximately (−290.089779,−544.759285). These are derivatives of a fitting loss, not policy effects. The two components have different parameter-based units.
The household case predicts 1440 actual kitchen/laundry Wh pairs by constants a,b. Its loss Σ[(kitchen−a)²+(laundry−b)²]/(2·1440) has Hessian I₂. This differs from the empirical channel covariance with off-diagonal value about 9.042896 Wh².
The company case fixes actual category vectors x from FY2023 and z from FY2024, predicting αx+δeServices. Parameter order is (α,δ), with dimensionless α and million-dollar δ. Loss ‖αx+δeServices−z‖²/10 has Hessian [[10148585472.6,17040],[17040,0.2]], whose entry units reflect those parameter choices.
기초Foundations
42. 수치·차원·단위로 미분을 세 번 검산하기42. Verify derivatives with numbers, shapes and units
먼저 출력 하나가 입력 n개를 받으면 미분 행은 1×n, 기울기 열은 n×1인지 확인합니다. 벡터 출력 m개의 야코비안은 m×n이고, 스칼라 헤시안은 n×n입니다. 곱셈 안쪽 크기가 맞지 않으면 전치나 순서를 점검합니다.
다음에는 각 좌표의 작은 양·음 변화를 넣어 중심차분 [f(a+heⱼ)−f(a−heⱼ)]/(2h)와 편미분을 비교합니다. h≠0이고 정의역 안에 있어야 합니다. 일반적으로 더 작은 h가 항상 좋은 것은 아니며 12장의 절단오차·취소오차가 다시 등장합니다.
정확한 이차손실에서는 중심차분이 정확한 산술에서 기울기와 일치합니다. 컴퓨터에서는 여전히 반올림이 있습니다. 다른 매끄러운 함수에는 적절한 3차 미분 조건에서 O(h²) 오차가 생깁니다. 수치 일치 하나로 미분가능성의 가정을 증명할 수는 없습니다.
마지막으로 손실/계수, 손실/(계수ᵢ·계수ⱼ) 단위를 점검합니다. 관측을 바꾼 차분과 계수만 바꾼 손실미분도 구별합니다. 코드·원자료 해시·분모·변수순서와 함께 검산기준을 기록하면 한영 표기나 소프트웨어가 달라도 같은 문제를 재현할 수 있습니다.
Check shapes first: scalar derivative 1×n, gradient n×1, vector Jacobian m×n and scalar Hessian n×n. Incompatible products suggest an order or transpose error.
Compare coordinate central differences with partials using nonzero steps inside the domain. Smaller steps are not universally better because truncation and cancellation errors trade off.
For an exact quadratic loss, central differences match gradients in exact arithmetic, though floating roundoff remains. General C³ functions instead have suitable O(h²) errors. Numerical agreement alone does not prove differentiability assumptions.
Check derivative units and distinguish changing data from changing parameters of a fixed-data loss. Record source hashes, denominator, parameter order and tolerance rules.
기초Foundations
43. 국가·가구·기업의 실제 미분 사례43. Actual country, household and company derivative cases
국가 사례 · 실제 GDP 자료에 맞춘 식에서 두 계수를 따로 움직이기
한국의 2014~2024년 공개 1인당 실질 GDP 11개를 사용합니다. t=연도−2019(년), 예측식 a+b t를 정하고 관측과의 차이를 제곱한 손실을 만듭니다. a는 2015 USD/명, b는 2015 USD/명/년입니다. 이 장에서 미분하는 함수는 우리가 선택한 적합 손실입니다. 현실의 GDP를 정책으로 바꾸는 인과 함수를 미분하는 것이 아닙니다.
첫 편미분은 b를 고정한 채 a를 조금 움직일 때 손실이 바뀌는 비율입니다. 둘째는 a를 고정하고 기울기 b만 바꿉니다. 두 편미분을 열로 모으면 gradient가 됩니다. n이 아니라 2n으로 나눈 덕분에 제곱을 미분할 때의 2가 없어집니다.
∇L=n1XT(Xθ−y),θ=(a,b)T,H=∇2L=n1XTX=[10010]
중심화한 연도의 합이 0이고 제곱합이 110이라서 교차 성분은 0입니다. H는 gradient가 두 계수 변화에 따라 어떻게 달라지는지 나타냅니다. 이것은 GDP 관측 자체의 공분산 행렬이 아닙니다.
실제 자료로 계산한 기준점과 최적점
항목
기준 (a=33,000, b=700)
손실 최소점
a
33,000.000000
33,290.089779
b
700.000000
754.475929
∂L/∂a
-290.089779
0
∂L/∂b
-544.759285
0
L ((2015 USD/명)²)
100,058.201324
43,144.027508
먼저 생각한 뒤 풀이 보기: gradient 두 숫자의 크기를 그대로 비교해 어느 계수가 더 중요하다고 할까요?
각 편미분의 단위가 다릅니다. ∂L/∂a는 2015 USD/명, ∂L/∂b는 (2015 USD/명)×년입니다. a와 b의 기준 단위나 척도를 바꾸면 숫자 크기도 달라집니다. Hessian의 (a,a) 성분은 무차원, (b,b) 성분은 년²이며 교차 성분의 단위는 년입니다. 서로 다른 단위의 숫자를 중요도 순위로 읽지 않습니다.
2. 정확한 손실·1차 접선·2차 변화를 비교하기
그림은 b=700을 고정하고 기준 a=33,000에서 a만 움직인 계산 시나리오입니다. 점들이 새로 측정한 GDP는 아닙니다. 2차식이 정확한 곡선과 겹치는 것은 이 손실이 이차다항식이기 때문입니다. 일반 함수의 유한 변화에서는 나머지항이 남습니다.
먼저 생각한 뒤 풀이 보기: 최소점에서 a를 100, b를 10만큼 함께 바꾸면?
L(θ+d)−L(θ)=21dTHd=21[1002+10(10)2]=5500
gradient가 0이라 1차항이 사라집니다. 이 값의 단위는 (2015 USD/명)²이며 정부 정책의 비용이나 GDP 증가액이 아닙니다. 이 문제에서는 이차식이므로 유한한 변화에도 위 등식이 정확합니다.
먼저 생각한 뒤 풀이 보기: H의 두 대각 성분이 양수면 각 좌표를 따로 바꾸는 것만 확인하면 되나요?
일반 행렬에서는 교차 성분도 확인해야 합니다. 여기서는 대각 H의 두 성분이 양수이므로 모든 비영 변화 d에 대해 dᵀHd>0입니다. 회사 사례에서는 교차 성분이 0이 아니므로 함께 검토합니다. 일반 함수의 극값 조건은 다음 장에서 정리합니다.
UCI 공개 자료의 같은 하루에서 1,440개 주방·세탁실 에너지 관측(Wh)을 사용합니다. 두 계통을 각각 상수 a,b로 요약하는 모형을 선택합니다. 이는 실제 소비가 하루 내내 일정했다고 주장하거나 실제 계량값을 수정하는 작업이 아닙니다. 각 관측행에 같은 비중을 둔 손실을 만듭니다.
L(a,b)=2n1i∑[(Ei1−a)2+(Ei2−b)2],n=1440
∇L=[a−Eˉ1b−Eˉ2],H=[1001]
실측 열의 평균은 â≈1.411805556 Wh, b̂≈2.907638889 Wh입니다. 각 편미분이 0인 곳은 각 평균입니다. 손실의 단위는 Wh², gradient 성분은 Wh, H의 성분은 무차원입니다. 이 모형에서는 한 열의 상수를 바꿔도 다른 열의 편미분이 바뀌지 않아 교차 성분이 0입니다.
관측 변동을 요약한 C와 선택 손실의 H
행렬
첫 대각 성분
교차 성분
둘째 대각 성분
단위
16장 실제 중심 공분산 C
46.388055073
9.042895930
77.397719425
Wh²
이 장의 손실 Hessian H
1
0
1
무차원
먼저 생각한 뒤 풀이 보기: 실측 두 열이 함께 변하면 Hessian에도 교차항이 꼭 생기나요?
자료의 공변동 C와 어떤 함수를 미분할지 정한 H는 서로 다른 대상입니다. 이 손실은 두 제곱을 따로 더하므로 혼합편미분이 0입니다. 관측 공분산의 교차 성분 약 9.0429 Wh²가 없어졌다는 뜻이 아닙니다. 다른 가중치나 두 계수를 결합한 손실을 선택하면 H도 달라질 수 있습니다.
그림은 b를 실측 평균에 고정하고 a만 그 평균에서 Δa만큼 바꾸는 계산입니다. 원자료 값과 모형 변화는 구분합니다.
먼저 생각한 뒤 풀이 보기: 평균점에서 두 상수를 각각 0.5 Wh, −0.25 Wh 바꾸면 손실은?
ΔL=21[(0.5)2+(−0.25)2]=0.15625Wh2
실제 에너지의 변화량이 아니라 선택한 상수 요약의 적합 손실 변화입니다. 이차식이므로 Hessian으로 계산한 값과 원래 1,440행에 다시 대입한 값이 정확히 같습니다.
먼저 생각한 뒤 풀이 보기: 두 열을 Wh 대신 kWh로 적으면 gradient와 Hessian은?
값과 모형 상수를 모두 1,000으로 나누고 같은 형태의 손실을 kWh²로 정의하면 gradient 숫자는 1,000분의 1이고 Hessian 숫자는 여전히 I입니다. H의 단위는 계속 무차원입니다. 이와 달리 공분산 숫자는 100만분의 1이 됩니다. 무엇의 단위를 바꿨는지 먼저 적어야 미분값을 비교할 수 있습니다.
두 에너지 계통에는 여러 가전이 포함됩니다. 기록된 분별 Wh를 전체 가구의 순간전력 kW로 바꾸어 부르지 않으며, 한 가구의 하루에서 개인 행동이나 전국 소비를 추론하지 않습니다.
Apple의 실제 FY2023 품목 벡터 x로 FY2024 실제 z를 비교합니다. 15장의 동일배수 αx를 확장해 서비스 품목에만 δ를 더하는 참조식 αx+δs를 선택합니다. s=(0,0,0,0,1)입니다. α는 무차원, δ는 백만 명목 USD이고, 모형 값은 실제 공시가 아닙니다. δ를 서비스 사업의 인과효과나 실제 회계 조정이라고 해석하지 않습니다.
L(α,δ)=2n1∥Xθ−z∥22,X=[xs]∈R5×2,θ=(α,δ)T,n=5
∇L=51XT(Xθ−z),H=51[5074292736385200852001]
서비스 행에서는 예측이 α×85,200+δ입니다. α를 바꾸면 서비스 오차가 바뀌고, 따라서 δ 편미분도 바뀝니다. 그 변화가 혼합편미분 Hαδ=Hδα=17,040입니다. 모든 자료가 미분 가능한 다항식 손실에 들어가므로 이 사례는 매끄럽고 혼합편미분의 대칭 조건을 만족합니다.
기준 (α=1, δ=0)에서의 미분값과 단위
항목
값
단위
∂L/∂α
-182,941,167.800
(백만 USD)²
∂L/∂δ
-2,193.800
백만 USD
Hαα
10,148,585,472.600
(백만 USD)²
Hαδ=Hδα
17,040.000
백만 USD
Hδδ
0.200
무차원
먼저 생각한 뒤 풀이 보기: 서비스 편미분 −2,193.8은 어떻게 직접 확인하나요?
∂δ∂L(1,0)=585200−96169=−2193.8
서비스 선택벡터 s가 마지막 행만 고르기 때문입니다. 이 음수는 α를 1로 고정한 채 작은 양의 δ를 주면 선택한 손실이 1차적으로 감소한다는 뜻입니다. 실제 서비스 매출을 정책으로 바꿀 때의 기울기는 아닙니다.
그림은 α=1을 고정하고 δ만 바꾸는 단면입니다. 전체 두 변수의 최적점과, α를 고정한 이 단면의 최소점은 구별합니다. 1차 접선이 음수가 되더라도 실제 제곱손실은 음수가 아닙니다. 접선은 기준점 부근의 1차 근사이며 이차식이 곡률을 보완합니다.
δ를 자유롭게 두면 서비스 행은 맞출 수 있고, α는 나머지 네 제품 행의 손실로 정해집니다. 전체 손실 최소점의 gradient는 (0,0)입니다. 아래 근사치는 실제 공시 매출과 구분해 적었습니다.
공시와 선택한 두 계수 참조식 (백만 USD)
품목
FY2023 실제 x
FY2024 실제 z
두 계수 참조값 (실측 아님)
iPhone
200,583
201,183
200,491.422
Mac
29,357
29,984
29,343.597
iPad
28,300
26,694
28,287.079
웨어러블·홈·액세서리
39,845
37,005
39,826.808
서비스
85,200
96,169
96,169.000
먼저 생각한 뒤 풀이 보기: H의 교차 성분이 있어도 최소점이 유일한가요?
detH=2543483887363>0,Hαα>0
이 실수대칭 2×2 H는 양의 정부호입니다. 모든 비영 변화 d에 대해 dᵀHd>0이므로 이 이차 손실의 최소점은 유일합니다. 다만 서로 다른 단위의 두 계수에서 H의 숫자 고유값이나 gradient 크기를 경제적 중요도라고 부르지 않습니다.
먼저 생각한 뒤 풀이 보기: α를 1에 고정한 단면에서 최소 δ는 전체 최적 δ와 같나요?
고정 단면에서는 서비스 오차만 δ에 따라 변하므로 δ=96,169−85,200=10,969입니다. 두 계수를 함께 조정할 때의 δ≈11,007.899와 다릅니다. “나머지를 고정한다”는 편미분의 조건이 실제 계산 결과를 바꿉니다.
선택한 참조식의 제곱오차 합은 약 11,388,900.951582 (백만 USD)²이며, 이 장의 L은 이를 2n=10으로 나눈 값입니다. FY2023 53주/FY2024 52주와 명목 매출 조건은 그대로 남습니다. 자료에 잘 맞는 식을 찾았다는 것이 미래 예측·기업가치·원인 규명을 보장하지 않습니다.
Country case · Move two fitting coefficients separately
Use eleven Korean real-GDP-per-capita observations from 2014–2024. Let t=year−2019 in years and fit a+b t. The intercept a has constant 2015 USD/person units; b has constant 2015 USD/person/year units. We differentiate our chosen fitting loss, not a causal function describing policy interventions on actual GDP.
The first partial holds b fixed while changing a; the second holds a fixed while changing b. Stack them as a column gradient. The factor 1/(2n) cancels the factor two from differentiating each square.
∇L=n1XT(Xθ−y),θ=(a,b)T,H=∇2L=n1XTX=[10010]
Centered years sum to zero and their squares sum to 110, so the cross entries vanish. H describes how the gradient changes with coefficients. It is not the covariance matrix of GDP observations.
Reference and optimum computed from actual inputs
Quantity
Reference a=33,000, b=700
Loss minimum
a
33,000.000000
33,290.089779
b
700.000000
754.475929
∂L/∂a
-290.089779
0
∂L/∂b
-544.759285
0
L ((2015 USD/person)²)
100,058.201324
43,144.027508
Think first, then reveal: Do the two raw gradient magnitudes rank coefficient importance?
Their units differ: ∂L/∂a has 2015 USD/person units; ∂L/∂b has (2015 USD/person)×year units. Rescaling a coordinate changes its numerical derivative. Hessian entry (a,a) is dimensionless, (b,b) has year² units, and cross entries have year units. Do not rank importance by unlike-unit numbers.
2. Compare exact loss, first-order tangent and second-order change
The plot fixes b=700 and changes a from 33,000. Every point is a calculated scenario, not a new GDP observation. The quadratic expression coincides with exact loss because this loss is a quadratic polynomial. General finite changes can retain a remainder.
Think first, then reveal: At the optimum, what if a increases by 100 and b by 10?
L(θ+d)−L(θ)=21dTHd=21[1002+10(10)2]=5500
The first-order term vanishes at zero gradient. Units are (2015 USD/person)², not a policy cost or GDP increment. The finite-change identity is exact for this quadratic loss.
Think first, then reveal: Is checking positive diagonal entries enough for every Hessian?
Cross entries matter in general. Here H is diagonal with positive entries, so dᵀHd>0 for every nonzero d. The company example includes nonzero cross entries. General extremum conditions follow in the next chapter.
Household case · Is data covariance the Hessian of the loss?
Use the same 1,440 public UCI kitchen/laundry energy observations in Wh. Choose constants a and b to summarize the channels. This does not assert constant actual consumption or alter meter readings. Give each observation row equal weight.
L(a,b)=2n1i∑[(Ei1−a)2+(Ei2−b)2],n=1440
∇L=[a−Eˉ1b−Eˉ2],H=[1001]
Observed column means are â≈1.411805556 Wh and b̂≈2.907638889 Wh. Each partial vanishes at its mean. Loss has Wh² units, gradient components Wh, and Hessian entries are dimensionless. Changing one constant leaves the other partial unchanged, so cross entries are zero.
Observed variation C versus the selected loss Hessian H
Matrix
First diagonal
Cross entry
Second diagonal
Units
Chapter 16 centered covariance C
46.388055073
9.042895930
77.397719425
Wh²
This loss Hessian H
1
0
1
Dimensionless
Think first, then reveal: Must covarying data columns create a cross entry in this Hessian?
Data covariance C and the Hessian H of a specified function are different objects. This loss separately adds two squared errors, so the mixed partial is zero. The actual covariance of about 9.0429 Wh² has not disappeared. Another weighting or coupled loss can give another Hessian.
The plot fixes b at its observed mean and varies a by Δa from its mean. All profile points are calculated model changes, distinct from observations.
Think first, then reveal: At the means, what is the loss increase for changes of 0.5 Wh and −0.25 Wh?
ΔL=21[(0.5)2+(−0.25)2]=0.15625Wh2
This changes the fit of a constant summary, not actual physical energy. Since the loss is quadratic, the Hessian calculation equals substitution into every one of the 1,440 records exactly.
Think first, then reveal: How do gradient and Hessian change when both channels use kWh?
Divide observations and model constants by 1,000 and define the same loss form in kWh². Numerical gradient entries divide by 1,000, while the dimensionless Hessian remains I. Covariance numbers instead divide by one million. Specify the transformed quantities before comparing derivatives.
The circuits contain several appliances. Recorded minute energy in Wh is not instantaneous household power in kW. One household day does not identify personal behavior or national consumption.
Company case · Two reference-model controls create mixed partials
Compare Apple’s actual FY2024 vector z with FY2023 categories x. Extend the common-multiplier reference αx by adding δ only to services: αx+δs, with s=(0,0,0,0,1). α is dimensionless; δ has million nominal USD units. This chosen reference is not a reported figure, a causal services effect or an actual accounting adjustment.
L(α,δ)=2n1∥Xθ−z∥22,X=[xs]∈R5×2,θ=(α,δ)T,n=5
∇L=51XT(Xθ−z),H=51[5074292736385200852001]
The services prediction is α×85,200+δ. Changing α alters its residual and therefore the δ partial. That change gives Hαδ=Hδα=17,040. These polynomial losses are smooth and satisfy the conditions for symmetric mixed partials.
Derivatives and units at reference (α=1, δ=0)
Quantity
Value
Units
∂L/∂α
-182,941,167.800
(million USD)²
∂L/∂δ
-2,193.800
million USD
Hαα
10,148,585,472.600
(million USD)²
Hαδ=Hδα
17,040.000
million USD
Hδδ
0.200
Dimensionless
Think first, then reveal: How is the services partial −2,193.8 checked directly?
∂δ∂L(1,0)=585200−96169=−2193.8
The indicator s selects only the final row. The negative derivative means a small positive δ, with α fixed at one, initially lowers this chosen loss. It is not the causal derivative of actual services sales.
The plot holds α=1 and varies δ. Its restricted minimum differs from the joint two-variable minimum. The first-order tangent can become negative even though exact squared loss cannot. The tangent is local; the quadratic term supplies curvature.
A free δ fits the services row; the other four product rows determine α. The joint optimum has zero gradient. Keep calculated reference values distinct from actual filings.
Filings versus chosen two-coefficient reference (million USD)
Category
FY2023 actual x
FY2024 actual z
Two-coefficient reference (not observed)
iPhone
200,583
201,183
200,491.422
Mac
29,357
29,984
29,343.597
iPad
28,300
26,694
28,287.079
Wearables, Home and Accessories
39,845
37,005
39,826.808
Services
85,200
96,169
96,169.000
Think first, then reveal: Is the minimum unique despite nonzero cross entries?
detH=2543483887363>0,Hαα>0
The symmetric 2×2 H is positive definite. Thus dᵀHd>0 for every nonzero d, giving a unique minimum of this quadratic loss. Different coefficient units still prevent interpreting raw Hessian eigenvalues or gradient magnitudes as economic importance.
Think first, then reveal: With α fixed at one, is the best δ the same as the joint optimum?
No. On that slice only services residual changes, so δ=96,169−85,200=10,969. Joint fitting instead gives δ≈11,007.899. The “hold other inputs fixed” condition changes the actual calculation.
The sum of squared errors is about 11,388,900.951582 (million USD)². This chapter’s L divides it by 2n=10. Unequal 53/52-week fiscal years and nominal units remain. A good fit does not establish forecasting accuracy, valuation or causation.
44. 네 묶음의 재현 과제와 공식 참고 읽기44. Reproduce the four groups and consult primary readings
A에서는 편미분·방향미분·전미분의 정의를 각 반례와 연결하세요. B에서는 행·열과 평가점을 표시한 뒤 합성 야코비안과 기울기를 계산합니다. C에서는 헤시안의 대칭조건·직선/곡선의 이차 변화·Taylor의 나머지를 구별하세요. D에서는 실제 자료를 고정하고 선택한 손실을 직접 전개해 기울기와 헤시안을 얻습니다.
실제 사례의 단위·분모·변수순서를 바꾸었다면 공식 숫자도 함께 바뀌어야 합니다. 다음 장의 극값 이론으로 가기 전에 ‘미분값이 무엇의 변화율인지’와 ‘그 계산이 어떤 조건에서 성립하는지’를 설명할 수 있는지 확인하세요.
Group A connects definitions to counterexamples; B checks shapes, evaluation points and chain rules; C separates Hessian assumptions, path curvature and Taylor remainders; D derives fixed-data loss gradients directly by expansion.
Changing units, denominators or parameter order changes derivative numbers too. Before extrema theory, explain what varies and under which assumptions each derivative represents it.
Layout conventions vary across references. This chapter consistently uses output rows, input columns and gradient columns. Derivations and examples follow this series' prerequisite route.
자료 묶음을 풀고 코드와 실제데이터 폴더를 함께 두세요. 터미널에서 코드 파일이 있는 폴더로 이동해 아래 명령을 실행합니다. 코딩이 처음이라면 손계산과 웹 실습을 먼저 하고, 데이터 사이언스 입문에서 코드를 배운 뒤 돌아와도 됩니다.Extract the bundle, keeping the scripts beside the data folder. In a terminal, enter the script folder and run the commands below. Beginners can complete hand calculations and browser labs first, returning to code after studying introductory data science.
결과 파일은 각 코드에 지정된 결과 폴더에 저장됩니다. CSV 원자료는 덮어쓰지 않습니다.Result files are saved in the result directory specified by each script; the input CSVs are not overwritten.
영상·학자·함께 읽기Videos, thinkers and guided reading
본문의 질문을 넓히는 선택 학습입니다. 영상을 보기 전 질문을 먼저 읽고, 자신의 답을 쓴 뒤 해설과 비교하세요. 자료의 언어·선수 지식은 각 항목에 표시했습니다.Optional extensions to the chapter. Read the question first, write your answer, then compare with the explanation. Language and prerequisites are indicated below.
편미분 입문: 하나를 바꾸고 나머지는 고정하기Partial derivatives, introduction
Khan Academy
본문의 공식 영어 영상에서 두 입력 중 하나를 고정한다는 뜻을 먼저 확인하세요. 회사 사례의 α 고정 단면과 두 변수 동시 최적점이 왜 다른지 연결합니다.Use the official English video to understand holding one input fixed. Connect this to the company’s fixed-α slice versus joint optimum.
교재 안의 YouTube 플레이어에서 재생합니다. 원영상에서 제공하는 자막은 플레이어의 CC·설정에서 선택할 수 있습니다.Playback stays in this chapter’s YouTube player. Available captions can be selected through CC/settings.
보고 읽은 뒤 답하기Respond after watching/reading∂L/∂δ를 계산할 때 α도 함께 바꾸나요?Does α change when computing ∂L/∂δ?
생각을 점검하는 해설Check your reasoning
그 편미분에서는 α를 고정합니다. 두 계수를 함께 바꾸는 방향의 변화는 gradient와 변화벡터의 내적으로 계산하는 다른 질문입니다.Hold α fixed for that partial. Simultaneous changes instead require the gradient paired with a change vector.
루트비히 오토 헤세 · 이차 변화를 표로 정리하기Ludwig Otto Hesse: organizing second-order structure
University of St Andrews · MacTutor
대학 아카이브는 헤세(1811–1874)의 대수함수·불변량 연구와 Hessian determinant를 소개합니다. 행렬 전체와 그 행렬식 한 숫자를 구별해 보세요.The university archive introduces Hesse (1811–1874), algebraic functions, invariants and the Hessian determinant. Distinguish the whole matrix from its determinant.
보고 읽은 뒤 답하기Respond after watching/readingdet H만 알면 모든 함수의 최소점을 판정하나요?Does det H alone classify minima of every function?
생각을 점검하는 해설Check your reasoning
아닙니다. 이 장의 실수대칭 2×2 양의 정부호 검사도 한 대각 성분과 행렬식을 함께 봅니다. 일반 극값에서는 정지점·미분가능 조건과 퇴화한 경우도 확인해야 합니다.No. Even the symmetric 2×2 positive-definiteness test also checks a diagonal entry. General extrema require stationarity, differentiability conditions and care with degenerate cases.
편미분의 극한 정의와 다른 변수 고정Limit definitions and holding other variables fixed
OpenStax · Rice University · Calculus Volume 3 §4.3
정의 (4.12)·(4.13)과 다른 변수를 상수로 두는 설명을 읽습니다. 실측값을 고정하고 선택한 손실의 어떤 매개변수를 미분하는지 적어 보세요.Read definitions (4.12)/(4.13) and the fixed-other-input explanation. Identify the parameter being differentiated while observations remain fixed.
보고 읽은 뒤 답하기Respond after watching/readingGDP 사례의 ∂L/∂a에서 관측한 y도 a에 따라 바꾸나요?Does observed y change with a when calculating the GDP loss partial?
생각을 점검하는 해설Check your reasoning
이 적합 문제에서는 y와 연도를 고정하고 계수만 바꿉니다. 실제 경제에 개입해 y가 변하는 문제는 별도 모형과 자료가 필요합니다.No. Hold observed y and years fixed while varying the coefficient. Intervening in the economy to change y requires another model and evidence.
Gradient의 미분으로 읽는 HessianThe Hessian as the derivative of the gradient
Bright, Edelman and Johnson · MIT 18.S096 Matrix Calculus notes §12.1
인쇄 87~88쪽 §12.1의 gradient·Hessian·2차 변화식을 읽습니다. 이 장의 손실은 매끄러운 이차다항식이라 2차식이 정확하지만 일반 함수에서는 조건과 나머지를 확인해야 합니다.Read §12.1, printed pages 87–88, on gradients, Hessians and second-order change. Our smooth quadratic losses have exact quadratic expressions; general functions need regularity and remainder conditions.
보고 읽은 뒤 답하기Respond after watching/reading1차 근사와 원함수 차이를 Hessian 한 항만으로 언제나 정확히 설명하나요?Does a Hessian term always exactly account for finite change beyond the linear approximation?
생각을 점검하는 해설Check your reasoning
일반적으로는 나머지항이 있습니다. 이 사례들은 이차다항식이므로 더 높은 차수 항이 0인 특별한 경우입니다. 혼합편미분의 대칭도 필요한 매끄러움 조건을 확인합니다.Generally a remainder remains. These quadratic examples have no higher-order terms. Symmetry of mixed partials also requires the appropriate regularity conditions.
연습문제 · 계산에서 설명과 증명까지Exercises: calculation, explanation and proof
먼저 혼자 풀고 풀이를 여세요. 숫자와 함께 단위·포함 기준·계산 이유를 확인하세요.Attempt each problem before opening its solution. Check units, inclusion rules and the reason for the calculation.
1. 두 길이가 함께 변하는 넓이Area with two changing lengths
가로 3 m, 세로 2 m인 직사각형의 두 길이를 각각 0.1 m 늘렸습니다. 실제 넓이 변화와 일차항을 구하세요.
Increase both lengths of a 3 m by 2 m rectangle by 0.1 m. Find actual and first-order changes.
풀이와 확인할 이유Solution and explanation
실제 변화는 3.1·2.1−6=0.51 m²입니다. 일차항은 2·0.1+3·0.1=0.5 m²이고 남은 0.01 m²는 두 증가분의 곱입니다. 어느 한 입력만 변한 계산과 구별합니다.
The actual change is 0.51 m². The first-order change is 0.5 m², leaving the product of increments, 0.01 m².
2. 로그의 열린 정의역The logarithm domain
f(x,y)=ln(x+y)에서 (1,1)과 (1,−1)에 같은 편미분 공식을 적용할 수 있나요?
Can the same partial formula for ln(x+y) be applied at (1,1) and (1,−1)?
풀이와 확인할 이유Solution and explanation
(1,1)은 x+y>0 안에 있어 두 편미분이 1/2입니다. (1,−1)은 로그가 정의되지 않는 경계라 같은 실수 미분을 적용할 수 없습니다. 분모 계산 이전에 정의역을 확인합니다.
The first point lies inside the real domain and gives both partials one half. The second is outside the function domain, so the formula is not applicable.
3. 두 절단곡선Two slices
f=x²+xy+2y²에서 y=1인 곡선과 x=1인 곡선을 쓰고 (1,1)의 각 기울기를 구하세요.
Write the y=1 and x=1 slices of x²+xy+2y² and their slopes at (1,1).
풀이와 확인할 이유Solution and explanation
각각 x²+x+2와 1+y+2y²입니다. 미분하면 2x+1,1+4y여서 기울기는 3,5입니다. 함수값 4와 다른 수이며 어느 입력을 고정했는지 함께 적습니다.
The slices are x²+x+2 and 1+y+2y², with slopes 3 and 5. These differ from the function value four.
4. 정의에서 편미분 얻기Derive a partial from its definition
기본함수의 [f(a+h,b)−f(a,b)]/h를 전개해 fₓ(a,b)를 구하세요.
Expand the x difference quotient of the base polynomial at (a,b).
풀이와 확인할 이유Solution and explanation
분자는 2ah+h²+bh입니다. h≠0에서 나누면 2a+b+h이고 극한은 2a+b입니다. h=0에 직접 대입해 0으로 나눈 것이 아닙니다.
For nonzero h it is 2a+b+h, so the limit is 2a+b. The quotient itself is not evaluated at zero step.
5. 다른 입력은 상수Other inputs are constants
f(x,y)=xy에서 fₓ와 fᵧ를 구하세요. 둘 다 1이라는 답은 왜 틀릴까요?
Find the partials of xy. Why are they not both one?
풀이와 확인할 이유Solution and explanation
각각 y와 x입니다. x로 미분할 때 y는 상수계수이고 반대도 같습니다. x와 y를 동시에 같은 변수처럼 미분하면 원래 편미분 문제를 바꾼 것입니다.
They are y and x. Holding the other coordinate fixed leaves it as a scalar coefficient.
6. 지수함수의 안쪽 미분The inner derivative of an exponential
f=eˣʸ에서 두 편미분을 구하고 (1,2)에서 평가하세요.
Find both partials of eˣʸ and evaluate at (1,2).
풀이와 확인할 이유Solution and explanation
fₓ=yeˣʸ, fᵧ=xeˣʸ입니다. (1,2)에서는 2e²,e²입니다. 안쪽 xy의 선택한 편미분을 각각 곱합니다.
They are yeˣʸ and xeˣʸ, giving 2e² and e² at the point.
7. 편미분과 경로미분Partial versus path derivative
f(x,y)=xy에서 y=x를 대입한 뒤 x로 미분한 값과 fₓ를 비교하세요.
Compare differentiating xy along y=x with the partial fₓ.
풀이와 확인할 이유Solution and explanation
대입한 함수는 x²라 미분은 2x입니다. 편미분 fₓ=y를 y=x에서 평가하면 x입니다. 경로에서는 y도 움직여 fᵧ·dy/dx=x가 추가됩니다.
The path becomes x² with derivative 2x. The partial evaluated there is only x; changing y contributes the additional x.
8. 편미분의 단위Units of partials
출력 f의 단위가 원, 입력 x의 단위가 m입니다. fₓ와 fₓₓ의 단위는?
If f is in won and x in metres, give units of fₓ and fₓₓ.
풀이와 확인할 이유Solution and explanation
각각 원/m와 원/m²입니다. fₓΔx를 만들면 원으로 돌아옵니다. 미분값 숫자만 비교하지 말고 어느 입력단위로 나누었는지 확인합니다.
They are won/metre and won/metre². Multiplying fₓ by a length increment gives won.
9. 축에서는 0이지만 연속이 아닌 예Zero on axes but not continuous
f=xy/(x²+y²), f(0,0)=0에서 원점 편미분과 y=x 경로의 값을 구하세요.
For xy/(x²+y²), set the origin value to zero. Compare partials and the diagonal path.
풀이와 확인할 이유Solution and explanation
두 축의 함수값이 0이라 원점 편미분은 모두 0입니다. 그러나 x=y≠0이면 1/2여서 원점에 연속이 아닙니다. 편미분 존재만으로 전미분을 선언할 수 없습니다.
Both origin partials are zero, but nonzero diagonal points give one half. Continuity and hence total differentiability fail.
10. 모든 방향미분의 비선형 반례A nonlinear collection of directional derivatives
The quadratic bound gives zero total derivative. Its nonzero-x partial oscillates through a cosine term, so the sufficient C¹ condition is not necessary.
16. 기울기 열과 미분 행Gradient column and derivative row
(1,1)에서 기본함수의 ∇f,Df와 증가분 h=(0.2,−0.1)의 일차 변화를 구하세요.
At (1,1), give the base gradient, derivative row and first-order change for (0.2,−0.1).
풀이와 확인할 이유Solution and explanation
∇f=(3,5)ᵀ, Df=[3,5]입니다. 일차 변화는 3·0.2+5·(−0.1)=0.1입니다. 행 1×2와 열 2×1을 곱해 스칼라를 얻습니다.
They are (3,5)ᵀ, [3,5] and 0.1. The compatible row-column product returns one scalar.
17. 단위방향의 변화율Rate in a unit direction
기울기 (3,5), u=(3/5,4/5)에서 방향미분을 구하세요.
Find the directional derivative for gradient (3,5) and u=(3/5,4/5).
풀이와 확인할 이유Solution and explanation
u의 길이는 1이고 내적은 9/5+20/5=29/5=5.8입니다. 단위길이당 변화율로 읽을 수 있습니다. (3,4) 자체를 쓰면 같은 t에서 5배 빠르게 이동합니다.
The unit vector gives dot product 29/5=5.8. Using (3,4) instead changes path speed by a factor of five.
18. 방향벡터의 배율Rescaling the direction
전미분 가능한 f에서 Dᵥf=2입니다. 같은 점의 D_(3v)f는 얼마이며 단위거리 해석은?
If Dᵥf=2 for a differentiable f, find D_(3v)f and interpret it.
풀이와 확인할 이유Solution and explanation
선형성으로 6입니다. 그러나 3v가 단위벡터인지는 별개이므로 곧바로 거리 한 단위당 6이라고 읽으면 안 됩니다. 경로 매개변수의 속도를 바꾼 값입니다.
It is 6 by linearity, but not necessarily per unit distance. Direction length controls path speed.
19. 가장 가파른 단위방향Steepest unit directions
기울기 (3,5)에서 최대·최소 방향미분과 각 단위방향을 구하세요.
Find maximum/minimum rates and directions for gradient (3,5).
풀이와 확인할 이유Solution and explanation
최대는 √34, 방향 (3,5)/√34입니다. 최소는 −√34, 반대 단위방향입니다. Cauchy–Schwarz의 등호조건을 사용했습니다.
The extrema are ±√34 along ±(3,5)/√34, from Cauchy–Schwarz equality.
20. 기울기 0의 정규화Normalizing a zero gradient
원점의 기본함수는 기울기 0입니다. 최급 단위방향을 (0,0)이라고 반환해도 될까요?
May the zero gradient be returned as the steepest unit direction?
풀이와 확인할 이유Solution and explanation
안 됩니다. (0,0)은 단위벡터가 아닙니다. 모든 단위방향의 일차 변화율이 0이라 유일한 최대방향이 없다고 표시합니다. 이차 변화까지 0이라는 뜻은 아닙니다.
No. Zero is not unit length. All unit directions tie at first order; higher-order changes may still occur.
21. m에서 cm로 바꾼 편미분Convert a partial from metres to centimetres
fₓ=200 원/m입니다. 같은 입력을 cm 좌표로 쓰면 편미분 숫자는?
Convert 200 won/metre to the derivative in centimetre coordinates.
풀이와 확인할 이유Solution and explanation
1 m=100 cm이므로 2 원/cm입니다. 0.01 m와 1 cm 모두 출력의 일차 변화가 2원입니다. 단위를 바꾼 숫자 차이가 실제 효과 차이는 아닙니다.
It becomes 2 won/centimetre. A one-centimetre change gives the same first-order output as 0.01 metre.
22. 야코비안의 칸과 작용Jacobian entries and action
g(s,t)=(s²+t,st)의 (1,1) 야코비안과 (h,k)=(0.1,0.2)의 선형 출력변화를 구하세요.
Find Jg at (1,1) for g=(s²+t,st), then its action on (0.1,0.2).
풀이와 확인할 이유Solution and explanation
Jg=[[2,1],[1,1]]입니다. 곱은 (0.4,0.3)입니다. 실제 출력변화에는 나머지 (0.01,0.02)가 더해집니다. 출력이 행, 입력이 열입니다.
The Jacobian is [[2,1],[1,1]], giving linear change (0.4,0.3). Actual change adds remainder (0.01,0.02).
23. 벡터 나머지 비율A vector remainder ratio
r(h,k)=(h²,hk)의 노름과 입력노름에 대한 비율을 구하세요.
Find the norm of (h²,hk) and divide by nonzero input size.
풀이와 확인할 이유Solution and explanation
노름은 √(h⁴+h²k²)=|h|√(h²+k²)입니다. 0이 아닌 입력에서는 비율이 |h|여서 0으로 갑니다. 두 성분을 따로 보는 것과 전체 벡터노름을 보는 것을 연결한 검산입니다.
The norm is |h|√(h²+k²), giving ratio |h|→0.
24. 합성의 올바른 평가점Correct evaluation point in a composition
Compare the Hessian of f(x,y)=x with the second derivative along γ(t)=(t²,t).
풀이와 확인할 이유Solution and explanation
Hf=0이지만 합성은 t²여서 이차미분은 2입니다. ∇f=(1,0), γ″=(2,0)의 내적이 추가항 2를 줍니다. 직선경로 공식을 곡선에 그대로 쓰면 이 항을 놓칩니다.
The Hessian is zero, but the composition is t² with second derivative two. The extra gradient-acceleration dot product supplies it.
34. 헤시안의 고유곡률Hessian eigencurvatures
H=[[2,1],[1,4]]의 고유값을 구하고 이차방향 부호를 판단하세요.
Find eigenvalues and directional quadratic signs for [[2,1],[1,4]].
풀이와 확인할 이유Solution and explanation
특성식은 λ²−6λ+7으로 근은 3±√2입니다. 모두 양수라 모든 비영 v에서 vᵀHv>0입니다. 최소값 판정의 전체 조건은 별도이며 여기서는 이차방향의 부호를 계산했습니다.
The roots are 3±√2, both positive. Every nonzero direction has positive quadratic value; complete extrema conditions require their additional context.
35. 0 헤시안의 두 함수Two functions with zero Hessian
원점에서 x⁴+y⁴와 −x⁴−y⁴의 값·기울기·헤시안을 비교하세요.
Compare origin value, gradient and Hessian of ±(x⁴+y⁴).
풀이와 확인할 이유Solution and explanation
모두 값 0, 기울기 0, 헤시안 0으로 같습니다. 그러나 원점 밖의 부호는 반대입니다. 둘째까지의 정보만으로 모든 고차 거동을 결정할 수 없습니다.
Both have value, gradient and Hessian zero there, yet opposite signs nearby. Matching second-order information does not determine higher-order behavior.
36. Taylor의 1/2The Taylor factor one half
H=[[2,1],[1,4]]에서 h=(h₁,h₂)의 Taylor 이차항을 펼치세요.
Expand half the quadratic form for H=[[2,1],[1,4]].
풀이와 확인할 이유Solution and explanation
(1/2)hᵀHh=h₁²+h₁h₂+2h₂²입니다. 1/2를 빼면 실제 이차항의 두 배가 됩니다. 혼합항 2와 전체 1/2가 각각 어느 전개에서 나오는지 구별합니다.
It is h₁²+h₁h₂+2h₂². Omitting one half doubles the correct Taylor term.
37. 이차 Taylor의 정확 계산An exact quadratic Taylor value
기본함수를 (1,1)에서 h=0.1,k=0.2로 이차 Taylor 전개해 값을 구하세요.
Use second-order Taylor for the base polynomial at (1,1) with increment (0.1,0.2).
풀이와 확인할 이유Solution and explanation
4+3h+5k+h²+hk+2k²=4+0.3+1+0.11=5.41입니다. 이 함수는 이차다항식이므로 나머지가 정확히 0입니다. 일반 함수에서는 추가 나머지를 확인해야 합니다.
The value is 5.41. The remainder is identically zero because the function is quadratic, not because every second-order approximation is exact.
38. 적분에서 1/2가 나오는 이유Why the integral gives one half
선분의 헤시안이 일정할 때 ∫₀¹(1−t)hᵀHh dt를 계산하세요.
Evaluate ∫₀¹(1−t)hᵀHh dt for constant H.
풀이와 확인할 이유Solution and explanation
h와 H는 적분변수 t에 상수라 밖으로 내고 ∫₀¹(1−t)dt=1/2를 곱합니다. 그래서 Taylor 이차항이 hᵀHh/2입니다.
The scalar quadratic value is constant in t; the remaining integral is one half, producing the Taylor coefficient.
39. 지수함수의 실제 오차와 상계Exponential error versus its bound
eˣ⁺ʸ를 원점에서 h=k=0.1로 이차 근사하세요. 값과 3차 나머지 상계를 구하세요.
Approximate eˣ⁺ʸ at (0.1,0.1) from the origin to second order.
풀이와 확인할 이유Solution and explanation
T₂=1+0.2+0.2²/2=1.22입니다. 실제 오차 e^0.2−1.22≈0.001402758, 상계 e^0.2·0.2³/6≈0.001628537입니다. 상계가 오차의 정확값은 아닙니다.
T₂=1.22. Actual error is about 0.001402758, below the bound e^0.2·0.2³/6≈0.001628537.
40. 높은 차수가 항상 나을까Is a higher order always better?
f=1+x+x²−2x³에서 원점 기준 x=1의 실제값과 일차·이차 근사를 비교하세요.
For 1+x+x²−2x³ at x=1, compare actual, first- and second-order values from zero.
풀이와 확인할 이유Solution and explanation
실제 1, 일차 2, 이차 3이라 오차는 1과 2입니다. 큰 유한 단계에서는 차수를 하나 높였다고 항상 개선되지 않습니다. 국소범위와 나머지의 조건이 필요합니다.
They are 1,2,3, so second order is worse at this finite step. Local assumptions and remainder bounds matter.
41. df와 ΔfDifferential versus finite change
기본함수의 (1,1)에서 Δ=(0.1,0.2)입니다. df와 Δf를 구하세요.
For the base function at (1,1), compare df and Δf for increment (0.1,0.2).
풀이와 확인할 이유Solution and explanation
df=3·0.1+5·0.2=1.3입니다. 실제 Δf는 1.41로 나머지 0.11이 더해집니다. df를 실제 유한 변화와 항상 같은 것으로 쓰면 안 됩니다.
The differential is 1.3; the actual change is 1.41, including remainder 0.11.
42. 행렬 제곱의 미분과 나머지Matrix-square derivative and remainder
X=diag(1,2), H=diag(0.1,0.2)에서 F(X)=X²의 미분과 실제 변화의 차이를 구하세요.
For X=diag(1,2), H=diag(0.1,0.2), compare the derivative of X² with its actual change.
풀이와 확인할 이유Solution and explanation
DF[H]=XH+HX=diag(0.2,0.8)입니다. 실제 변화는 diag(0.21,0.84)이고 차이는 H²=diag(0.01,0.04)입니다. 이차 나머지가 선형사상과 분리됩니다.
The derivative is diag(0.2,0.8). Actual change is diag(0.21,0.84), leaving H²=diag(0.01,0.04).
For loss ||αx+δeServices−z||²/(2·5), the actual FY2023 Services entry is 85200 million dollars. Find Hαδ.
풀이와 확인할 이유Solution and explanation
설계의 두 열은 x와 서비스 지시열이므로 내적은 85200입니다. 5로 나누어 Hαδ=17040입니다. α는 무차원, δ는 백만 미국달러라 이 칸의 단위는 손실/(α단위·δ단위)입니다. 큰 숫자만 보고 단위가 다른 Hδδ와 중요도를 비교하지 않습니다.
The column inner product is 85200; dividing by five gives 17040. Its unit follows loss divided by the α and δ units, so raw comparison with differently dimensioned diagonal entries is inappropriate.
자료별 확보일·원행 식별·단위·이용 조건은 출처 기록을 확인하세요. 학습 사본은 제공처의 현재 최신 자료와 다를 수 있습니다.Consult each source record for retrieval dates, row identifiers, units and terms. Teaching copies can differ from current provider releases.