Closed SebKrantz closed 1 week ago
Dear Sebastian,
Sorry for the late reply. I have been thinking about what you sent me and I must say that I just cannot comprehend what I meant with this footnote. I am actually thinking what I was describing was for something different (this comment on the inversion of the linear system is something you can use in the model without congestion...). I just can no longer make sense of it and we should correct this appendix. This sometimes happens with footnotes that lie around the text and that we never check.
This being said, we wrote this 5 years ago, so I might be missing something today. But I think it should still be possible to solve this case with duality. Let me try to work out a quick note on that and I'll get back to you.
Thanks,
E.
On Sat, Oct 5, 2024 at 11:03 AM Sebastian Krantz @.***> wrote:
Hi @edschaal https://github.com/edschaal. I am trying to implement the dual model with cross-good congestion, because I think this is necessary to do realistic simulations on very large networks. I've started doing this in Julia, but want to implement it in MATLAB as well if I get it to work properly. You can see my inaugural Julia implementation here https://github.com/OptimalTransportNetworks/OptimalTransportNetworks.jl/blob/development/src/models/model_fixed_duality_cgc.jl. One aspekt I don't understand is how to evaluate the Lagrangian with only aggregate flows $Q{jk}$ and invert the linear system defining $Q{jk}^n$ after the optimization - as per Footnote 48 in Section B1 of the Supplementary Material https://raw.githubusercontent.com/OptimalTransportNetworks/OptimalTransportNetworkToolbox/main/docs/paper_materials/OTN_supp_material.pdf. In my reading the flow constraint is $D_j^n + \sumk Q{jk}^n \leq Y_j^n
- \sumk Q{kj}^n$ and the Lagrangian is $\sum_j \omega_j L_j u_j - \sum_j \sum_n P_j^n (D_j^n + \sumk Q{jk}^n - Y_j^n - \sumk Q{kj}^n)$, so I don't understand how this can be evaluated without $Q{jk}^n$. I my preliminary Julia implementation I have defined $Q{jk}^n$ as an additional $ndeg \times N$ optimization variable alongside a constraint that ensures that $Q_{jk} = \left(\sumn m^n (Q{jk}^n)^\nu\right)^{1/\nu}$. This of course limits the value of the dual approach. Your input on this would be much appreciated.
— Reply to this email directly, view it on GitHub https://github.com/OptimalTransportNetworks/OptimalTransportNetworks.jl/pull/24#issuecomment-2394988880, or unsubscribe https://github.com/notifications/unsubscribe-auth/BLML2FDGCSECTJ4HUNZRIRDZZ6TPVAVCNFSM6AAAAABPNEYGRGVHI2DSMVQWIX3LMV43OSLTON2WKQ3PNVWWK3TUHMZDGOJUHE4DQOBYGA . You are receiving this because you were mentioned.Message ID: <OptimalTransportNetworks/OptimalTransportNetworks.jl/pull/24/c2394988880@ github.com>
Hi Sebastian,
In the end, I was able to figure out what I meant by this cryptic footnote. It was not necessarily wrong, but highly incomplete. Also, I think this version of the model is likely to be quite unstable if we solve it with the dual (the dual is not differentiable everywhere), so I would suggest using instead a CES cost function.
I attach here a short note where I explain what I meant and how one could proceed (not tested yet) with the alternative CES specification which I think would work better.
Let me know if you have any questions (there could be plenty of algebraic mistakes in what I wrote).
E.
On Tue, Oct 8, 2024 at 12:03 PM Edouard Schaal @.***> wrote:
Dear Sebastian,
Sorry for the late reply. I have been thinking about what you sent me and I must say that I just cannot comprehend what I meant with this footnote. I am actually thinking what I was describing was for something different (this comment on the inversion of the linear system is something you can use in the model without congestion...). I just can no longer make sense of it and we should correct this appendix. This sometimes happens with footnotes that lie around the text and that we never check.
This being said, we wrote this 5 years ago, so I might be missing something today. But I think it should still be possible to solve this case with duality. Let me try to work out a quick note on that and I'll get back to you.
Thanks,
E.
On Sat, Oct 5, 2024 at 11:03 AM Sebastian Krantz @.***> wrote:
Hi @edschaal https://github.com/edschaal. I am trying to implement the dual model with cross-good congestion, because I think this is necessary to do realistic simulations on very large networks. I've started doing this in Julia, but want to implement it in MATLAB as well if I get it to work properly. You can see my inaugural Julia implementation here https://github.com/OptimalTransportNetworks/OptimalTransportNetworks.jl/blob/development/src/models/model_fixed_duality_cgc.jl. One aspekt I don't understand is how to evaluate the Lagrangian with only aggregate flows $Q{jk}$ and invert the linear system defining $Q{jk}^n$ after the optimization - as per Footnote 48 in Section B1 of the Supplementary Material https://raw.githubusercontent.com/OptimalTransportNetworks/OptimalTransportNetworkToolbox/main/docs/paper_materials/OTN_supp_material.pdf. In my reading the flow constraint is $D_j^n + \sumk Q{jk}^n \leq Y_j^n
- \sumk Q{kj}^n$ and the Lagrangian is $\sum_j \omega_j L_j u_j - \sum_j \sum_n P_j^n (D_j^n + \sumk Q{jk}^n - Y_j^n - \sumk Q{kj}^n)$, so I don't understand how this can be evaluated without $Q{jk}^n$. I my preliminary Julia implementation I have defined $Q{jk}^n$ as an additional $ndeg \times N$ optimization variable alongside a constraint that ensures that $Q_{jk} = \left(\sumn m^n (Q{jk}^n)^\nu\right)^{1/\nu}$. This of course limits the value of the dual approach. Your input on this would be much appreciated.
— Reply to this email directly, view it on GitHub https://github.com/OptimalTransportNetworks/OptimalTransportNetworks.jl/pull/24#issuecomment-2394988880, or unsubscribe https://github.com/notifications/unsubscribe-auth/BLML2FDGCSECTJ4HUNZRIRDZZ6TPVAVCNFSM6AAAAABPNEYGRGVHI2DSMVQWIX3LMV43OSLTON2WKQ3PNVWWK3TUHMZDGOJUHE4DQOBYGA . You are receiving this because you were mentioned.Message ID: <OptimalTransportNetworks/OptimalTransportNetworks.jl/pull/24/c2394988880 @github.com>
Oops. corrected a big typo
On Tue, Oct 8, 2024 at 4:56 PM Edouard Schaal @.***> wrote:
Hi Sebastian,
In the end, I was able to figure out what I meant by this cryptic footnote. It was not necessarily wrong, but highly incomplete. Also, I think this version of the model is likely to be quite unstable if we solve it with the dual (the dual is not differentiable everywhere), so I would suggest using instead a CES cost function.
I attach here a short note where I explain what I meant and how one could proceed (not tested yet) with the alternative CES specification which I think would work better.
Let me know if you have any questions (there could be plenty of algebraic mistakes in what I wrote).
E.
On Tue, Oct 8, 2024 at 12:03 PM Edouard Schaal @.***> wrote:
Dear Sebastian,
Sorry for the late reply. I have been thinking about what you sent me and I must say that I just cannot comprehend what I meant with this footnote. I am actually thinking what I was describing was for something different (this comment on the inversion of the linear system is something you can use in the model without congestion...). I just can no longer make sense of it and we should correct this appendix. This sometimes happens with footnotes that lie around the text and that we never check.
This being said, we wrote this 5 years ago, so I might be missing something today. But I think it should still be possible to solve this case with duality. Let me try to work out a quick note on that and I'll get back to you.
Thanks,
E.
On Sat, Oct 5, 2024 at 11:03 AM Sebastian Krantz < @.***> wrote:
Hi @edschaal https://github.com/edschaal. I am trying to implement the dual model with cross-good congestion, because I think this is necessary to do realistic simulations on very large networks. I've started doing this in Julia, but want to implement it in MATLAB as well if I get it to work properly. You can see my inaugural Julia implementation here https://github.com/OptimalTransportNetworks/OptimalTransportNetworks.jl/blob/development/src/models/model_fixed_duality_cgc.jl. One aspekt I don't understand is how to evaluate the Lagrangian with only aggregate flows $Q{jk}$ and invert the linear system defining $Q{jk}^n$ after the optimization - as per Footnote 48 in Section B1 of the Supplementary Material https://raw.githubusercontent.com/OptimalTransportNetworks/OptimalTransportNetworkToolbox/main/docs/paper_materials/OTN_supp_material.pdf. In my reading the flow constraint is $D_j^n + \sumk Q{jk}^n \leq Y_j^n + \sumk Q{kj}^n$ and the Lagrangian is $\sum_j \omega_j L_j u_j
- \sum_j \sum_n P_j^n (D_j^n + \sumk Q{jk}^n - Y_j^n - \sumk Q{kj}^n)$, so I don't understand how this can be evaluated without $Q{jk}^n$. I my preliminary Julia implementation I have defined $Q{jk}^n$ as an additional $ndeg \times N$ optimization variable alongside a constraint that ensures that $Q_{jk} = \left(\sumn m^n (Q{jk}^n)^\nu\right)^{1/\nu}$. This of course limits the value of the dual approach. Your input on this would be much appreciated.
— Reply to this email directly, view it on GitHub https://github.com/OptimalTransportNetworks/OptimalTransportNetworks.jl/pull/24#issuecomment-2394988880, or unsubscribe https://github.com/notifications/unsubscribe-auth/BLML2FDGCSECTJ4HUNZRIRDZZ6TPVAVCNFSM6AAAAABPNEYGRGVHI2DSMVQWIX3LMV43OSLTON2WKQ3PNVWWK3TUHMZDGOJUHE4DQOBYGA . You are receiving this because you were mentioned.Message ID: <OptimalTransportNetworks/OptimalTransportNetworks. @.***>
Hi @edschaal. I am trying to implement the dual model with cross-good congestion, because I think this is necessary to do realistic simulations on very large networks. I've started doing this in Julia, but want to implement it in MATLAB as well if I get it to work properly. You can see my inaugural Julia implementation here. One aspect I don't understand is how to evaluate the Lagrangian with only aggregate flows $Q{jk}$ and invert the linear system defining $Q{jk}^n$ after the optimization - as per Footnote 48 in Section B1 of the Supplementary Material. In my reading the flow constraint is $D_j^n + \sumk Q{jk}^n \leq Y_j^n + \sumk Q{kj}^n$ and the Lagrangian is $\sum_j \omega_j L_j u_j - \sum_j \sum_n P_j^n (D_j^n + \sumk Q{jk}^n - Y_j^n - \sumk Q{kj}^n)$, so I don't understand how this can be evaluated without $Q{jk}^n$. I my preliminary Julia implementation I have defined $Q{jk}^n$ as an additional $ndeg \times N$ optimization variable alongside a constraint that ensures that $Q_{jk} = \left(\sumn m^n (Q{jk}^n)^\nu\right)^{1/\nu}$. This of course limits the value of the dual approach. Your input on this would be much appreciated.