Community Profile

# Paul Morant

##### Last seen: Today
581 total contributions since 2019

View details...

Contributions in
View by

Solved

Operate on matrices of unequal, yet similar, size
You may want to add a vector to a matrix, implying that the vector is added to each column of the matrix. Or multiply a 3x4x5 ma...

17 hours ago

Solved

Lunar Arithmetic (Multiplication)
<https://oeis.org/A087061 OEIS link for a description of lunar arithmetic> Simply take the larger digit when adding and take ...

17 hours ago

Solved

<https://oeis.org/A087061 OEIS link for a description of lunar arithmetic> Simply take the larger digit. Example 1: ...

18 hours ago

Solved

Permutation Via Multiplication
Given two numbers a and b, determine if the product ab is a permutation of the digits of a. For example, this is always true for...

19 hours ago

Solved

Better Index Number
Let's say you want to save many, many files and append these files with a certain sortable index number. As you probably know, y...

19 hours ago

Solved

Whole Number Un-Concatenator
Write a function that accepts an integer and an index digit and returns a vector containing two integers which are the leading a...

19 hours ago

Solved

Whole Number Concatenator
Write a function that concatenates whole numbers. For example: numcat(111,222) should return 111222 numcat(1,2,3,4,5) s...

19 hours ago

Solved

The number of trailing zero digit of a factorial
For given positive integer n, take factorial of that number. How many trailing zeros does it have? Example: factorial(11) = 3...

19 hours ago

Solved

arithmetic progression
I've written a program to generate the first few terms of <https://en.wikipedia.org/wiki/Arithmetic_progression arithmetic progr...

21 hours ago

Solved

Divisible by n, prime divisors - 11, 13, 17, & 19
Divisibility checks against prime numbers can all be accomplished with the same routine, applied recursively, consisting of add ...

4 days ago

Solved

Largest Geometric Series
Extension of Ned Gulley's wonderful <http://www.mathworks.com/matlabcentral/cody/problems/317 Problem 317>. In a geometric se...

7 days ago

Solved

Find the stride of the longest skip sequence
We define a _skip sequence_ as a regularly-spaced list of integers such as might be generated by MATLAB's <http://www.mathworks....

7 days ago

Solved

Sum the Infinite Series
Given that 0 < x and x < 2*pi where x is in radians, write a function [c,s] = infinite_series(x); that returns with the...

8 days ago

Solved

A <http://en.wikipedia.org/wiki/Word_ladder word ladder> transforms one word to another by means of single-letter mutations. So ...

8 days ago

Solved

Clockwise or Counterclockwise
Given a list of 2-d points defining the vertices of a polygon, determine whether these points are sorted clockwise. The input...

12 days ago

Solved

Make a Palindrome Number
Some numbers like 323 are palindromes. Other numbers like 124 are not. But look what happens when we add that number to a revers...

14 days ago

Solved

Sums with Excluded Digits
Add all the integers from 1 to n in which the digit m does not appear. m will always be a single digit integer from 0 to 9. no...

14 days ago

Solved

Smallest n, for n! to have m trailing zero digits
For given positive integer n, its factorial often has many trailing zeros, in other words many factors of 10s. In order for n! t...

14 days ago

Solved

Distance of the centroids of the balls
Given *n* balls of radius *r* and the vector *p (nx3)* with all position *(x,y,z)* of the balls, return the symmetric matrix *A ...

14 days ago

Solved

Center of mass
Given a matrix M(m,n), where m is the number of vertices of the geometrical element and n is 2 or 3 (2D-plane figure or 3D-solid...

14 days ago

Solved

Mechanical Advantage of a Gear Train
Calculate the mechanical advantage of a gear train. The mechanical advantage of a gear couple is given by MA = T_o/T_i where ...

14 days ago

Solved

Determine if input is a perfect number
A <http://en.wikipedia.org/wiki/Perfect_number/ perfect number> occurs whent the sum of all divisors of a positive integer, exce...

14 days ago

Solved

Kaprekar numbers
Test if the input is a Kaprekar number: <http://mathworld.wolfram.com/KaprekarNumber.html>. Return a logical true or false. ...

15 days ago

Solved

Numbers on 7-segment
This is a 7-segment: _ |_| |_| It's a 3-by-3 char matrix.It has made by 3 characters: '_' , '|' and ' ' (space...

15 days ago

Solved

Convert from Base 10 to base 5
Convert the input number from base 10 into base 5: for example: if a(in base 10)= 5 then a(in base 5)= 10

15 days ago

Solved

Still more miles to go before I sleep
It's time for more odometer fun. Last problem, my car's odometer hit 56789. It's coming up on 111111 now, which (barring a maj...

15 days ago

Solved

Pattern Sum
Write a function which receives two single digit positive integers, (k and m) as parameters and calculates the total sum as: k...

15 days ago

Solved

Calculate the probability that at least two people in a group share the same birthday.
Calculate the probability that at least two people in a group share the same birthday. Given an integer input n, return to 0.015...

15 days ago

Solved

The Birthday Phenomenon
First off, leap years are not being considered for this. In fact the year that people are born shouldn't be taken into considera...

15 days ago

Solved

Number of digits in an integer
Specifies how many digits in a given integer. Example: in=100 ==> out=3

15 days ago