GeeTwo - MATLAB Cody - MATLAB Central

GeeTwo

128
Rank
54
Badges
10039
Score
51 – 100 of 1,052

GeeTwo submitted a Comment to Problem 59581. Generate a point cloud named `Incremental Lattice Design`

Misleading graphical problem description. Inadequate verbal problem description. Am I just supposed to keep pushing buttons until it works? I get this all the time IRL, but it's disappointing to find it here. The graphic makes it look like we are painting a corner, that is, that the points all have at least one zero value. But it again appears that this is a constituency problem, that is, the sum of every row is one, or in dimensions, every point falls in the plane where the sum of all of the Cartesian coordinates is one. I first encountered these as the sand-silt-clay triangle in the eighties, unless Dennis showed them to me in the seventies and I forgot. But Dennis is big on rocks not soil, so probably not.

on 26 Apr 2025 at 0:55

GeeTwo submitted a Comment to Problem 60441. Generate a point cloud named `Simplex-Lattice Design`

The tests for W are pitiful. I solved this for real, with some real checks in my scratch pad. More specifically, After the check of N, there is a brief, repeatable set of tests which can confirm if W is valid, without providing W in the test. I'm pretty sure any edge cases it misses would be harder to exploit than actually solving the stated problem. assert(isequal(size(W),[N M])) assert(all(ismembertol(W*H,0:H),'all')) WNI=round(W*H); % pretty safe now assert(all(sum(WNI,2)==H)) assert(isequal(size(unique(WNI,'rows')),[N,M])) assert(isequal(unique(WNI,'rows'),WNI))

on 25 Apr 2025 at 23:52

GeeTwo submitted a Comment to Solution 14622763

This solution does NOT leverage any specific orientation of the inputs.

on 24 Apr 2025 at 23:51

GeeTwo submitted a Comment to Solution 14621549

Clue: This solution leverages the fact that all of the inputs are scalars or row vectors. (My 32 point solution does NOT.)

on 24 Apr 2025 at 23:49

GeeTwo submitted a Comment to Problem 58498. Compute the Sisyphus sequence

Yes, the flag only affects the addition of 3 and 5. After the two is used and a_n < the first prime, adding that prime produces an even number less than twice that prime. Half it, and it's smaller than that prime, hence smaller than the next prime as well. first four steps,

on 11 Dec 2024

GeeTwo received Community Group Solver badge for Prime Numbers III

on 10 Dec 2024

GeeTwo submitted a Comment to Problem 59126. Compute the bubble popper fidget spinner sequence

My 39 solution is "clean' - not even a str2num or subtraction of character arrays. My 35 uses str2num() aggressively.

on 6 Dec 2024

GeeTwo submitted a Comment to Problem 58019. Factor a number into Fermi-Dirac primes

Ramon's solutions under 49 used pyrun() calls I don't even pretend to understand. My 36 post is straight MATLAB, though I admit I used str2num() rather strongly.

on 6 Dec 2024

GeeTwo submitted a Comment to Problem 58498. Compute the Sisyphus sequence

I still don't get why 3 is not "unused" in the alternate form on the second climb but is later on the third; it implies that it was "de-used". Is it that your step up can't be a doubling?

on 5 Dec 2024

GeeTwo submitted a Comment to Problem 57815. List numbers such that every sum of consecutive positive integers ending in those numbers is composite

The solutions don't match the problem statement, as 1 is not composite. It should be something like: "numbers m such that no sum of consecutive positive integers ending with m are prime".

on 5 Dec 2024

GeeTwo submitted a Comment to Solution 14430425

Correction to comment: lines 10 and 11, not 9 and 10. Inspired by Tim's line 6. The rest of the code, including that which looks a lot like Tim's line 7, I had already written.

on 4 Dec 2024

GeeTwo submitted a Comment to Solution 10726060

Thanks for line 6, Tim! It made my previous solution both faster and simpler.

on 4 Dec 2024

GeeTwo submitted a Comment to Problem 52664. List the Moran numbers

@Tim, thanks for the idea of using ismember(). It greatly simplified my already simplest solution to date. All I did before was squeeze a literal implementation and make it work just fast enough to fit the one-minute filter..Your inspiration took me from four statements to two.

on 1 Dec 2024

51 – 100 of 1,052
Go to top of page