Technique explanation

Osculation (Vestanam) is a recursive method to test divisibility by reducing the size of a number. For a divisor d, we split a number N into 10a + b. A positive osculator P satisfies 10P - 1 as a multiple of d, checking a + Pb. A negative osculator Q satisfies 10Q + 1 as a multiple of d, checking a - Qb. This is most effective for divisors like 19 (P=2), 29 (P=3), and 31 (Q=3). Trial division remains the fallback for other cases.

Standard fallback: Trial division or standard long division by the specific prime divisor.

Worked examples

Example 1: Is 247 divisible by 19?

1. The positive osculator for 19 is P = (19+1)/10 = 2.

2. Split 247 into 24 and 7. Apply P=2: 24 + 7(2) = 24 + 14 = 38.

3. Repeat for 38: Split into 3 and 8. 3 + 8(2) = 3 + 16 = 19.

4. Check: 19 is divisible by 19.

Check: Verify by multiplication: 19 × 13 = 247.

Result: 247 is divisible by 19.

Example 2: Is 8118 divisible by 31?

1. The negative osculator for 31 is Q = (31-1)/10 = 3.

2. Split 8118 into 811 and 8. Apply Q=3: 811 - 8(3) = 811 - 24 = 787.

3. Repeat for 787: Split into 78 and 7. 78 - 7(3) = 78 - 21 = 57.

4. Check: 31 × 1 = 31, 31 × 2 = 62. 57 is not a multiple of 31.

Check: Standard division: 8118 ÷ 31 = 261 remainder 27.

Result: 8118 is not divisible by 31.