Skip to content

Patch 1#2

Open
phchavesmaia wants to merge 6 commits intoAhlfeldt:mainfrom
phchavesmaia:patch-1
Open

Patch 1#2
phchavesmaia wants to merge 6 commits intoAhlfeldt:mainfrom
phchavesmaia:patch-1

Conversation

@phchavesmaia
Copy link

@phchavesmaia phchavesmaia commented Mar 9, 2026

I am currently implementing this model in Julia and have found what appear to be typos in this MATLAB implementation. In this patch, I state them.

Equation S.31 states that:
phi = LD ./ (K .^ (1-mu))

This would imply:
Vout = LD ./ (K.^0.25)
Looking at comegaoptC.m and comegaoptO.m, one understands that tt86rw and tt06, by extension, are indexed as (workplace, residence) matrices. This appears to be the case for tt86rw, since the estimated epsilon is 6.83, consistent with the paper. 

In camen.m and calcal_adj_TD.m (and all other functions in the repository), the indexing of the travel time matrices changes to (residence, workplace), suggesting that tt06 and ttpub06 are indexed differently from tt86rw. 

To my knowledge, that implies that either:
1) The indexing in comegaoptC.m is wrong, or
2) The indexing in all functions from the application of camen.m onward are wrong.

Since the first option is more probable, I am adding this commit here.
As written, EQQ is not updating across iterations. I believe this should not be the case; thus, I propose changing QT for Q_i in its computing.
The current update rule for theta uses the estimated prices of commercial buildings rather than the guessed prices. Although this substantially improves the convergence rate, it is unusual because theta is then the only endogenous variable defined differently from the others.

I therefore propose updating theta using its guessed value instead.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant