Reference 〉 Function

Utility.mu(quantitiesdict{str:num})

Calculates the marginal utilities of the goods in question on the basis of the entered quantities. Many utility functions, including the CES function, are such that the quantities of all goods are necessary to calculate the marginal utility of any good. Subclasses are required to implement this method.

Parameters

  • quantities dict{str:num}, required

    Current quantities of goods. If the utility function was registered with the same set of goods as the model (see Goods.add()), agent.stocks can be passed straight into this function.

Return Value dict{str:num}

A dict with the marginal utility for each good.

Notes and Examples

  1. Contribute a Note

    Your email address will not be published. Required fields are marked *

    You may use limited HTML for formatting. Please embed blocks of code in <pre><code> </code></pre> tags.