Skip to content

Commit 7a4a9d6

Browse files
mmckyclaude
andauthored
[action-translation] resync: harrison_kreps.md (#113)
* 🔄 resync harrison_kreps.md * Restore trailing newline (engine issue tracked in QuantEcon/action-translation#116) Co-Authored-By: Claude Fable 5 <noreply@anthropic.com> --------- Co-authored-by: Claude Fable 5 <noreply@anthropic.com>
1 parent 0ef129f commit 7a4a9d6

2 files changed

Lines changed: 40 additions & 25 deletions

File tree

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,6 @@
1+
source-sha: 774202bff9a46fc56229fe2fb84f15f72772f667
2+
synced-at: "2026-07-18"
3+
model: claude-sonnet-5
4+
mode: RESYNC
5+
section-count: 3
6+
tool-version: 0.17.0

lectures/harrison_kreps.md

Lines changed: 34 additions & 25 deletions
Original file line numberDiff line numberDiff line change
@@ -7,6 +7,24 @@ kernelspec:
77
display_name: Python 3
88
language: python
99
name: python3
10+
translation:
11+
title: 异质信念与泡沫
12+
headings:
13+
Overview: 概述
14+
Overview::References: 参考文献
15+
Overview::Bubbles: 泡沫
16+
Structure of the Model: 模型结构
17+
Structure of the Model::Ownership Rights: 所有权权利
18+
Structure of the Model::Short Sales Prohibited: 禁止卖空
19+
Structure of the Model::Optimism and Pessimism: 乐观与悲观
20+
Structure of the Model::Information: 信息
21+
Solving the Model: 求解模型
22+
Solving the Model::Summary Table: 总结表
23+
Solving the Model::Single Belief Prices: 单一信念价格
24+
Solving the Model::Single Belief Prices::Single Belief Prices as Benchmarks: 单一信念价格作为基准
25+
Solving the Model::Pricing under Heterogeneous Beliefs: 异质信念下的定价
26+
Solving the Model::Insufficient Funds: 资金不足
27+
Solving the Model::Further Interpretation: 进一步解释
1028
---
1129

1230
(harrison_kreps)=
@@ -29,10 +47,9 @@ kernelspec:
2947

3048
除了Anaconda中包含的库外,本讲座还使用以下库:
3149

32-
```{code-cell} ipython
33-
---
34-
tags: [hide-output]
35-
---
50+
```{code-cell} ipython3
51+
:tags: [hide-output]
52+
3653
!pip install quantecon
3754
```
3855

@@ -51,7 +68,7 @@ tags: [hide-output]
5168

5269
让我们从一些标准导入开始:
5370

54-
```{code-cell} ipython
71+
```{code-cell} ipython3
5572
import numpy as np
5673
import quantecon as qe
5774
import scipy.linalg as la
@@ -84,7 +101,6 @@ Harrison-Kreps模型阐述了许多经济学家认同的泡沫概念:
84101

85102
$$
86103
d_t =
87-
88104
\begin{cases}
89105
0 & \text{ if } s_t = 0 \\
90106
1 & \text{ if } s_t = 1
@@ -198,11 +214,9 @@ $P_b$ 的平稳分布约为 $\pi_b = \begin{bmatrix} .43 & .57 \end{bmatrix}$。
198214

199215
现在让我们开始求解模型。
200216

201-
我们将在特定的信念设定和交易限制条件下确定均衡价格,这些设定是从上述规范中选择的
217+
我们将在从上述规范中选择的关于信念和交易限制的特定设定下确定均衡价格
202218

203-
我们将比较在以下不同情况下的均衡价格函数
204-
205-
关于信念的假设:
219+
我们将比较在以下关于信念的不同假设下的均衡价格函数:
206220

207221
1. 只有一种类型的个体,要么是 $a$ 要么是 $b$。
208222
1. 有两种类型的个体,仅在其信念上有所不同。每种类型的个体都有足够的资源购买所有资产(Harrison和Kreps的设定)。
@@ -254,7 +268,6 @@ $P_b$ 的平稳分布约为 $\pi_b = \begin{bmatrix} .43 & .57 \end{bmatrix}$。
254268
今天的价格等于明天的股息和明天的资产价格的预期贴现值:
255269

256270
$$
257-
258271
p_h(s) = \beta \left( P_h(s,0) (0 + p_h(0)) + P_h(s,1) ( 1 + p_h(1)) \right), \quad s = 0, 1
259272
$$ (eq:assetpricehomog)
260273
@@ -347,8 +360,7 @@ $$
347360
= \beta \max
348361
\left\{
349362
P_a(s,0) \bar p^j(0) + P_a(s,1) ( 1 + \bar p^j(1))
350-
351-
,\;
363+
,\;
352364
P_b(s,0) \bar p^j(0) + P_b(s,1) ( 1 + \bar p^j(1))
353365
\right\}
354366
```
@@ -401,26 +413,26 @@ $a$类型的投资者想在状态$1$时卖出资产,而$b$类型的投资者
401413
def price_optimistic_beliefs(transitions, dividend_payoff, β=.75,
402414
max_iter=50000, tol=1e-16):
403415
"""
404-
Function to Solve Optimistic Beliefs
416+
求解乐观信念的函数
405417
"""
406-
# We will guess an initial price vector of [0, 0]
418+
# 我们将猜测一个初始价格向量[0, 0]
407419
p_new = np.array([[0], [0]])
408420
p_old = np.array([[10.], [10.]])
409421
410-
# We know this is a contraction mapping, so we can iterate to conv
422+
# 我们知道这是一个压缩映射,所以我们可以迭代至收敛
411423
for i in range(max_iter):
412424
p_old = p_new
413425
p_new = β * np.max([q @ p_old
414426
+ q @ dividend_payoff for q in transitions],
415-
1)
427+
axis=0)
416428
417-
# If we succeed in converging, break out of for loop
429+
# 如果成功收敛,跳出for循环
418430
if np.max(np.sqrt((p_new - p_old)**2)) < tol:
419431
break
420432
421433
ptwiddle = β * np.min([q @ p_old
422434
+ q @ dividend_payoff for q in transitions],
423-
1)
435+
axis=0)
424436
425437
phat_a = np.array([p_new[0], ptwiddle[1]])
426438
phat_b = np.array([ptwiddle[0], p_new[1]])
@@ -442,8 +454,8 @@ def price_optimistic_beliefs(transitions, dividend_payoff, β=.75,
442454
\check p(s)
443455
= \beta \min
444456
\left\{
445-
P_a(s,1) \check p(0) + P_a(s,1) ( 1 + \check p(1)) ,\;
446-
P_b(s,1) \check p(0) + P_b(s,1) ( 1 + \check p(1))
457+
P_a(s,0) \check p(0) + P_a(s,1) ( 1 + \check p(1)) ,\;
458+
P_b(s,0) \check p(0) + P_b(s,1) ( 1 + \check p(1))
447459
\right\}
448460
```
449461
@@ -480,7 +492,7 @@ def price_pessimistic_beliefs(transitions, dividend_payoff, β=.75,
480492
p_old = p_new
481493
p_new = β * np.min([q @ p_old
482494
+ q @ dividend_payoff for q in transitions],
483-
1)
495+
axis=0)
484496
485497
# 如果成功收敛,跳出for循环
486498
if np.max(np.sqrt((p_new - p_old)**2)) < tol:
@@ -510,8 +522,6 @@ Scheinkman提取了关于金融监管对泡沫影响的见解。
510522
511523
他强调了限制做空和限制杠杆具有相反的效果。
512524
513-
## 练习
514-
515525
```{exercise-start}
516526
:label: hk_ex1
517527
```
@@ -607,4 +617,3 @@ for p, label in zip(opt_beliefs, labels):
607617
```
608618
609619
[^f1]: 通过假设两类个体总是有"足够深的口袋"来购买所有资产,该模型将财富动态排除在外。Harrison-Kreps模型在状态从0变为1或从1变为0时会产生大量交易量。
610-

0 commit comments

Comments
 (0)