Community Tip - New to the community? Learn how to post a question and get help from PTC and industry experts! X
The collapsed area contains the function NumberGenerator() that produces a new number for every supplied (integer) number. Three results are shown. Your task is to come up with a/the definition of the function such that it computes the (correct) value associated with 433 (and any other number in Z).
As you will find out, I've limited the function to just the three first input numbers with:
Where the red placeholder should contain the code to implement the actual functionality.
To not spoil the fun for others, I'll accept solutions in Prime or Mathcad as either one of:
- the function NumberGenerator(), limited to the same input range, in a collapsed locked area, dated later than the timestamp above. The password should be the result of NumberGenerator(pw), and pw is supplied along.
- submitted to me in a PM (in case you're limited to express).
Success!
Luc
@LucMeekes wrote:
The collapsed area contains the function NumberGenerator() that produces a new number for every supplied (integer) number. Three results are shown. Your task is to come up with a/the definition of the function such that it computes the (correct) value associated with 433 (and any other number in Z).
Hmmm, "correct" value ???
There is an infinite number of "correct" values - choosing the one you have in mind would mean we have to polish our crystal balls and go into some mindreading session, which I sure am not good at.
Even if you would limit the results to integers, (which you didn't - you only limited the input values to integers) there would be an infinite number of possible functions we could use which all will give the correct result for the three given values, but possibly all different results for 433.
Find one of them attached.
The password is MY "correct" result for 433, but chances are it is not yours - and of course the password is kind of senseless here as anybody could evaluate NumberGenX(433) 😉
EDIT: I added a different puzzle and I apologize because its quite old and well known. Thats also the reason why the collapsed region is not password protected
f(1)=7 f(2)=9 f(3)=11 f(4)=13 f(5)=15 f(6)=19 f(7)=22 f(8)=?
OK, its already Monday and as nobody so far has contributed a solution - at least not the one you had in mind - I hereby do.
Format Prime 4, pw=4711
My function is not limited to integers, but probably one can argue the the results never should be negative ...?
I added one number to the list of allowed numbers to demonstrate
I also added another puzzle
The input numbers have to be positive integers. You may try any number, they are not limited.
Indeed, it's monday. Sorry to have kept you waiting.
I got the following PM's:
TTokoro got the gist of the algorithm, but the implementation was flawed, resulting in NumberGenerator(433)=16909.
Fred also got the gist, and fabricated two implementations, the first also with the result 16909, the second with the (correct!) result 1699.
And today you (Werner) also found that algorithm. I was able to unlock your area with the password generated from 4711. The code of your function doesn't run in Prime express, because it uses programming. On the other hand it does allow floating point numbers, which my implementation doesn't.
Attached is my solution, which now allows a few more input values.
Luc