Pattern repeat and yardage
A vertical repeat makes each row, or each curtain cut, long enough to land on the next repeat. Matching a motif across a seam is a different problem.
Simple vertical repeat
If the repeat is greater than zero, the cut length becomes the next multiple of that repeat. A 10 inch piece on a 6 inch repeat uses 12 inches of cloth in that row.
A repeat of zero means there is no repeat. The calculator will not divide by zero, and a negative repeat is rejected.
What is not included
Half-drop repeats, horizontal motif matching, centering a motif on a panel, and plaid or check matching are not calculated.
If your cloth needs one of those, add extra length yourself. The result on this site would understate the cloth if it pretended to match them.