Looking for a particular function

In summary, the professor is discussing a function that has the following properties: it is continuous, has a continuous derivative, and takes the values 2, 2^2, 2^3, 2^4,..., 2^n. He asks for someone to help him construct the function.
  • #1
Frank Einstein
170
1
Misplaced Homework Thread
TL;DR Summary: I want to find a function with f'>0, f''<0 and takes the values 2, 2^2, 2^3, 2^4,..., 2^n

Hello everyone.

A professor explained the St. Petersburgh paradox in class and the concept of utility function U used to explain why someone won't play a betting game with an infinite expected value.

Then he talked about Kar Meyer's finding of a bounded utility function and still infinite payoff and told us to find a bounded function with the following properties:

f'>0, f''<0 and takes the values 2, 2^2, 2^3, 2^4, ..., 2^n

The values 2, 2^2, 2^3, 2^4, ..., 2^n have to be taken for x=1,2,3,4,..., n.

I have been thinking and reading about this but I have found no answer. I have even read Meyer's article and there he says that if the amount gained per bet is exp(2^n) then the expected value of the logarithm of the gain is infinite.

Thus, I think that either my professor has made a mistake or is trolling my class. However, before writing an email telling him that what he asks is impossible I would like to see if someone here agrees or disagrees with me.

Any answer is appreciated.
Best regards.
 
Physics news on Phys.org
  • #2
Well, there are a few assumptions one needs to make about ##f##. What I understand you mean is:
##f: [1,\infty) \to \mathbb{R}## is a function with the property ##f(n)=2^n##. Furthermore ##f'(x)>0## and ##f''(x)<0## in all the domain.
Then, ##f## is continuous with a continuous derivative and we can use the Mean Value Theorem:
Lets choose ##a_0=1, a_1=2, a_3=3##, applying the MVT twice we get
$$f'(b_0) = \frac{f(a_1)-f(a_0)}{a_1-a_0} = \frac{f(2)-f(1)}{2-1} = 2^2 - 2^1 = 2$$
$$f'(b_1) = \frac{f(a_2)-f(a_1)}{a_2-a_1} = \frac{f(3)-f(2)}{3-2} = 2^3 - 2^2 = 4$$
with ##b_0\in (1,2)## and ##b_1 \in (2,3)##. Now, whatever these values are we can write
$$f''(c) = \frac{f'(b_1)- f'(b_0)}{b_1-b_0} = \frac{2}{b_1-b_0} > 0$$
which is a contradiction to the satatement ##f''(x)<0##.

Now, notice that if the conditions ##f'>0## and ##f''<0## are not applied to the whole domain, and (for example) are only valid for the natural numbers, then the answer is trivial since you can construct functions ##f_n(x)## with the conditions ##f(n)=2^n, f'(n)=1, f''(n)=-1##. Then f(x) can be defined as a piecewise function and will fulfil all the requirements.
 
  • Like
Likes Frank Einstein
  • #3
Thanks for the answer. I will try to understand it.

However, could you please explain to me how to construct the function $f$?

Best regards.
 

FAQ: Looking for a particular function

How can I find a specific function within a large codebase?

To locate a specific function within a large codebase, you can use search tools like `grep` on Unix-based systems or the search functionality in integrated development environments (IDEs) like Visual Studio Code, PyCharm, or Eclipse. These tools allow you to search by function name or specific keywords across multiple files.

What are some effective ways to search for a function in documentation?

Most documentation comes with a search feature that allows you to look up functions by name or keyword. Additionally, online documentation often has an index or table of contents where functions are listed alphabetically or by category, making it easier to locate the desired function.

How do I identify the purpose of a function if I only have its name?

If you have the function name but are unsure of its purpose, you can look at its definition and comments within the code. Reading the function's implementation and any associated documentation or comments can provide insights into its functionality. Additionally, searching for the function name in the project's documentation or online resources may yield useful information.

Can I use code analysis tools to find and understand functions?

Yes, code analysis tools like static analyzers, linters, and code navigation tools in modern IDEs can help you find and understand functions. Tools like SonarQube, ESLint, and PyLint can analyze your codebase and provide a detailed report on function usage, dependencies, and potential issues.

How do I locate a function if I only know what it should do, not its name?

If you know the functionality but not the name of the function, try searching for keywords related to the function's purpose in the codebase or documentation. You can also look at related modules or libraries where such a function might logically reside. Asking colleagues or consulting community forums and Q&A sites like Stack Overflow can also be helpful.

Similar threads

Back
Top