Description
Count the inclusive overlap as max(0, min(ends) - max(starts) + 1) across two ordered positive ayah ranges.
Source-scoped cultural and historical records preserve an edition, naming convention, or local identifier. Literal agreement is useful bookkeeping but does not establish interpretation, authenticity, or authority.
Count the inclusive overlap as max(0, min(ends) - max(starts) + 1) across two ordered positive ayah ranges.
When to use this tool
Use Public Ayah Range Overlap when you need a precise source-token or range consistency check.
How to use the tool and how it works
- Enter firstStart, firstEnd, secondStart, secondEnd. Use the units and conventions below.
- Run the tool. Correct any format, range, or cross-field input error before interpreting the output.
- Read overlapCount. Use the output convention below.
Count the inclusive overlap as max(0, min(ends) - max(starts) + 1) across two ordered positive ayah ranges.1
| Input field | Meaning and units | Accepted input |
|---|---|---|
| firstStart | First Start | Required. Safe integer; minimum 1. |
| firstEnd | First End | Required. Safe integer. |
| secondStart | Second Start | Required. Safe integer; minimum 1. |
| secondEnd | Second End | Required. Safe integer. |
| Output field | Interpretation | Returned shape |
|---|---|---|
| overlapCount | Overlap Count | Required. Safe integer. |
{
"input": {
"firstStart": 2,
"firstEnd": 6,
"secondStart": 5,
"secondEnd": 8
},
"output": {
"overlapCount": 2
}
} Limitations and assumptions
- Shared coordinate meaning must already be established; surah, edition, and actual verse availability are not checked.
- Inputs must satisfy both the field types and the cross-field conditions above. Invalid input causes an error; a successful false flag or documented placeholder is a different result.
- Numeric calculations use binary floating point unless exact decimal-integer arithmetic is explicitly stated. No hidden measurement tolerance or decimal rounding is added; nonfinite or out-of-contract results are rejected. Numeric signed-zero results are exported as zero.
Alternative or Complementary methods
Consult the source edition and relevant community or scholarly guidance before interpreting or reusing the material.
References
Similar or alternative tools
- Public Manuscript Ayah Range
Subtract firstAyah from lastAyah and add one when includeEnd is true.
- Quran Surah Ayah Range Parser
Parse positive surah:ayah or surah:first-last syntax without leading zeros.