File:Hyperbolic vs. exponential discount rates.svg

Summary

Description
English: A comparison of the time-varying discount rate of hyperbolic discounting with the constant rate of exponential discounting.
Source Own work
Author Moxfyre
Other versions Hyperbolic vs. exponential discount factors.svg
SVG development
InfoField
Source code
InfoField

Python code

import pylab as P
import numpy as N
P.rcParams['svg.embed_char_paths'] = False

x = N.linspace(0, 10, 1000)
hyp_df = 1/(1+x)
exp_df = N.exp(-x)

P.figure(1)
P.plot(x, hyp_df, "-", label="Hyperbolic discounting")
P.plot(x, exp_df, "-", label="Exponential discounting")
P.ylim(-0.05, 1.05)
P.legend(loc="upper right")
P.xlabel("Time from present")
P.ylabel("Discount factor")
P.savefig("Hyperbolic vs. exponential discount factors.svg")

P.figure(2)
#P.twinx()
P.plot(x, N.exp(P.log(hyp_df)/x), "-", label="Hyperbolic discounting")
P.plot(x, N.exp(P.log(exp_df)/x), "-", label="Exponential discounting")
P.ylim(-0.05, 1.05)
P.legend(loc="upper right")
P.xlabel("Time (from present)")
P.ylabel("Discount rate")
P.savefig("Hyperbolic vs. exponential discount rates.svg")

Licensing

I, the copyright holder of this work, hereby publish it under the following licenses:
w:en:Creative Commons
attribution share alike
This file is licensed under the Creative Commons Attribution-Share Alike 3.0 Unported license.
You are free:
  • to share – to copy, distribute and transmit the work
  • to remix – to adapt the work
Under the following conditions:
  • attribution – You must give appropriate credit, provide a link to the license, and indicate if changes were made. You may do so in any reasonable manner, but not in any way that suggests the licensor endorses you or your use.
  • share alike – If you remix, transform, or build upon the material, you must distribute your contributions under the same or compatible license as the original.
Category:CC-BY-SA-3.0#Hyperbolic%20vs.%20exponential%20discount%20rates.svg
GNU head Permission is granted to copy, distribute and/or modify this document under the terms of the GNU Free Documentation License, Version 1.2 or any later version published by the Free Software Foundation; with no Invariant Sections, no Front-Cover Texts, and no Back-Cover Texts. A copy of the license is included in the section entitled GNU Free Documentation License.
Category:License migration redundant#Hyperbolic%20vs.%20exponential%20discount%20rates.svgCategory:GFDL#Hyperbolic%20vs.%20exponential%20discount%20rates.svg
You may select the license of your choice.
Category:Self-published work Category:Temporal discounting
Category:CC-BY-SA-3.0 Category:GFDL Category:License migration redundant Category:Self-published work Category:Temporal discounting Category:Valid SVG created with Matplotlib code