Solved


Travel a path
In Cody Problem 60251, minnolina asks us to determine the end point given a string indicating unit movements forward, backward, ...

2 days ago

Solved


Compute the Ramanujan tau function
The Ramanujan tau function is defined by the relation where . The first few values of are 1, -24, 252, -1472, and 4830. W...

2 days ago

Solved


List the segmented numbers
The sequence of segmented numbers begins 1, 2, 4, 5, 8, 10, 14, 15, 16. Notice that none of the terms is the sum of consecutive ...

2 days ago

Solved


List the ways to write 1/n as the sum of two unit fractions
Cody Problem 59841 involved counting the ways that can be written as the sum of two unit fractions (those with a numerator of 1...

2 days ago

Solved


Count the ways to write 1/n as the sum of two unit fractions
The number 1/2 can be written as 1/3+1/6 and 1/4+1/4, and the number 1/9 can be written as 1/18+1/18, 1/12+1/36, and 1/10+1/90. ...

2 days ago

Solved


Solve an ODE: Ekman spiral on a solid surface
Problem Write a function to solve for and as a function of in this system of ordinary differential equations: where , ...

2 days ago

Solved


Update course numbers and abbreviations
Suppose that the educational institution where you teach purchases new software to handle many essential functions, including co...

3 days ago

Solved


List ways to make a sum in Killer Sudoku
In Sudoku, the subject of several Cody problems, one tries to arrange the digits 1 through 9 in a 9x9 grid of 81 cells (or a 3x3...

3 days ago

Solved


Compute the polylogarithm for real arguments
The polylogarithm appears in quantum statistics and quantum electrodynamics, and for special cases of and , it connects to the...

3 days ago

Solved


Count paths between corners of a grid that remain on or below the diagonal
Consider motion from the lower left corner of a square grid to the upper right corner. The motion is constrained in two ways: (1...

3 days ago

Solved


Count the ones in a divisibility matrix
Cody Problem 59506 asked solvers to compute the determinant of matrix consisting of ones in the first column and anywhere the ro...

3 days ago

Solved


Compute the determinant of a divisibility matrix
Consider a matrix consisting of ones in the first column and anywhere the row index divides the column index. The 4x4 matrix is ...

3 days ago

Solved


Compute the sum of distances from a point to the sides of an equilateral triangle
Write a function to compute the sum of the (shortest) distances from a point inside an equilateral triangle to the sides of the ...

3 days ago

Solved


Construct numbers from antidiagonals of stacks of binary numbers
A sequence is constructed in the following way: Express the numbers 1, 2, 3, 4, 5,… in binary and stack them, right-justified. T...

3 days ago

Solved


List lunar triangular numbers without duplication
Triangular numbers—which are the subject of Cody Problems 5, 291, 44289, 44732, 45833, 55680, 55695, and 55705—are the sums of c...

3 days ago

Solved


Determine whether a number is a Higgs prime
If the sequence lists the Higgs primes, then is the smallest prime greater than such that divides the product . The first fo...

3 days ago

Solved


Compute the water table in a layered unconfined aquifer
Write a function to compute the flow per unit width and the elevation of the water table above the bottom of unconfined aquifer ...

3 days ago

Solved


Find the smallest number leading to a maximal product of two numbers that concatenate to another number
Cody Problem 58971 involves the maximal product of numbers that concatenate to a number . For example, if , then the products ar...

3 days ago

Solved


Compute the maximal product of any two numbers whose concatenation is n
Write a function that takes an input and computes the maximal product of numbers that concatenate to . For example, if , then t...

4 days ago

Solved


Find the nine-point circle of a triangle
Cody Problem 1336 asks us to find the circle that circumscribes a triangle, and Cody Problem 58354 asks us to find the circle th...

4 days ago

Solved


Count collisions in an idealized block system
Two blocks, which have masses and , slide along a frictionless, semi-infinite track bounded by a stationary wall. Initially blo...

4 days ago

Solved


Find the altitudes of a triangle
Write a function that takes the x- and y-coordinates of three points describing the vertices of a triangle and returns the coord...

4 days ago

Solved


Determine whether a number is prome
In discussing the unique factorization of numbers in Elementary Number Theory, Underwood Dudley devised a new number system: “C...

4 days ago

Solved


Classify water surface profiles
Problem statement Write a function to classify the water surface profile starting at depth in a channel with longitudinal slop...

4 days ago

Solved


List numbers that cannot be expressed as the sum of fewer than four squares
Lagrange proved that all positive integers can be expressed as the sum of four squares. For example, 27 = 16 + 9 + 1 + 1. Howeve...

4 days ago

Solved


Find the circle inscribed in a triangle
Write a function that takes the x- and y-coordinates of three points describing the vertices of a triangle and returns the cente...

4 days ago

Solved


Compute the critical depth of a channel
Problem statement Write a function to compute the critical depth of a channel with discharge . The unit system will be specifie...

4 days ago

Solved


Compute the normal depth of a channel
For steady uniform flow in a channel of constant cross section and slope, the depth does not change with distance or time. In th...

4 days ago

Solved


Decode a message encrypted with the square root of 2
Cody Problem 58299 asks you to encrypt a message by changing all letters to uppercase and randomly choosing a position of the AS...

4 days ago

Solved


Encrypt a message with the square root of 2
Suppose you want to encrypt the word ‘TWIN’. The ASCII codes for the four letters are 84, 87, 73, and 78. If you consider the fr...

4 days ago

Load more