Hi guys I want to calculate the number of integer partitions. So that I use this code
But I get the error as " Run time error 28 Out of stuck space".![]()
Please Login or Register to view this content.
What's wrong with my code?
Regards,
Alex
Hi guys I want to calculate the number of integer partitions. So that I use this code
But I get the error as " Run time error 28 Out of stuck space".![]()
Please Login or Register to view this content.
What's wrong with my code?
Regards,
Alex
Last edited by Alex009988; 07-20-2019 at 06:50 AM.
Administrative Note:
We would very much like to help you with your query, however the thread title does not really convey what your request is about.
Please take a moment to amend your thread title. Make sure that the title properly explains your request. Your title should be explicit and not be generic (this includes function names used without an indication of what you are trying to achieve).
Please see Forum Rule #1 about proper thread titles and adjust accordingly. To edit the thread title, open the original post to edit and then click on Go Advanced (bottom right) to access the area where you can edit your title.
(Note: this change is not optional. No help to be offered until this moderation request has been fulfilled.)
Ali
Enthusiastic self-taught user of MS Excel who's always learning!
Don't forget to say "thank you" in your thread to anyone who has offered you help. It's a universal courtesy.
You can reward them by clicking on * Add Reputation below their user name on the left, if you wish.
NB: as a Moderator, I never accept friendship requests.
Forum Rules (updated August 2023): please read them here.
I don't have Excel handy to test with, but my guess is that you are getting a lot of recursive calls to the function from within the function with no control over that recursion. Eventually you run out of stack space. The recursion is caused by using p as both your function name and an array variable within the function. It appears to me that the recursion is not intended or essential to the procedure, so I would write it to avoid the unintentional recursion, by changing either the name of the function or the name of the array variable. Since p is not very descriptive of the function's purpose, I would probably change the function name:![]()
Please Login or Register to view this content.
Originally Posted by shg
E.g,![]()
Please Login or Register to view this content.
A B C D E F G H I J K L M N 1 n \ k 0 1 2 3 4 5 6 7 8 9 10 2 0 1 0 0 0 0 0 0 0 0 0 0C2: =Stirling2nd(n, k) 3 1 0 1 0 0 0 0 0 0 0 0 0 4 2 0 1 1 0 0 0 0 0 0 0 0 5 3 0 1 3 1 0 0 0 0 0 0 0 6 4 0 1 7 6 1 0 0 0 0 0 0 7 5 0 1 15 25 10 1 0 0 0 0 0 8 6 0 1 31 90 65 15 1 0 0 0 0 9 7 0 1 63 301 350 140 21 1 0 0 0 10 8 0 1 127 966 1,701 1,050 266 28 1 0 0 11 9 0 1 255 3,025 7,770 6,951 2,646 462 36 1 0 12 10 0 1 511 9,330 34,105 42,525 22,827 5,880 750 45 1
Last edited by shg; 07-27-2019 at 03:31 PM.
Entia non sunt multiplicanda sine necessitate
There are currently 1 users browsing this thread. (0 members and 1 guests)
Bookmarks