@@ -395,46 +395,66 @@ Data source: [Almaqased Cleansing Calculator](https://almaqased.net/cleansing-ca
395395</div >
396396
397397$$
398- \text{مبلغ التطهير} = \frac{\ text{عدد الأسهم} \times \text{نسبة التطهير} \times \text{عدد أيام التملك}}{365.0 }
398+ \text{مبلغ التطهير} = \text{عدد الأسهم} \times \text{نسبة التطهير} \times \frac{\ text{عدد أيام التملك في السنة }}{\text{إجمالي أيام السنة} }
399399$$
400400
401401<div dir =" rtl " >
402402
403403حيث:
404404- ` عدد الأسهم ` : إجمالي عدد الأسهم المملوكة
405405- ` نسبة التطهير ` : نسبة التطهير السنوية (النسبة المئوية)
406- - ` عدد أيام التملك ` : عدد الأيام التي تم فيها امتلاك الأسهم
407- - ` 365.0 ` : عدد أيام السنة (ثابت )
406+ - ` عدد أيام التملك في السنة ` : عدد الأيام التي تم فيها امتلاك الأسهم في كل سنة على حدة
407+ - ` إجمالي أيام السنة ` : عدد أيام السنة (365 للسنة العادية، 366 للسنة الكبيسة )
408408
409- ### مثال
410- لـ 100 سهم بنسبة تطهير 2.5% تم امتلاكها لمدة 180 يوم:
409+ ** ملاحظة مهمة** : يأخذ النظام بعين الاعتبار السنوات الكبيسة والفترات متعددة السنوات، حيث يتم حساب كل سنة على حدة.
410+
411+ ### أمثلة
412+ لـ 100 سهم بنسبة تطهير 2.5% تم امتلاكها لمدة 180 يوم في السنة العادية:
413+
414+ </div >
415+
416+ $$
417+ \text{مبلغ التطهير} = 100 \times 0.025 \times \frac{180}{365} = 1.233
418+ $$
419+
420+ <div dir =" rtl " >
421+
422+ لنفس المثال في السنة الكبيسة (366 يوم):
411423
412424</div >
413425
414426$$
415- \text{مبلغ التطهير} = \frac{ 100 \times 0.025 \times 180}{365.0 } = 1.23
427+ \text{مبلغ التطهير} = 100 \times 0.025 \times \frac{ 180}{366 } = 1.230
416428$$
417429
418430
419431## Stock Purification Amount Calculation
420432
421- The purification amount for stocks is calculated using the following formula:
433+ The purification amount for stocks is calculated using the following accurate formula that handles leap years and multi-year periods :
422434
423435$$
424- \text{purificationAmount} = \frac{\ text{numberOfStocks} \times \text{purificationRate} \times \text{daysHeld }}{365.0 }
436+ \text{purificationAmount} = \text{numberOfStocks} \times \text{purificationRate} \times \frac{\ text{daysHeldInYear }}{\text{totalDaysInYear} }
425437$$
426438
427439Where:
428440- ` numberOfStocks ` : Total number of stocks held
429441- ` purificationRate ` : Annual purification rate (percentage)
430- - ` daysHeld ` : Number of days the stocks were held
431- - ` 365.0 ` : Days in a year (constant)
442+ - ` daysHeldInYear ` : Number of days the stocks were held in each year separately
443+ - ` totalDaysInYear ` : Total days in the year (365 for regular years, 366 for leap years)
444+
445+ ** Important Note** : The system accounts for leap years and multi-year periods by calculating each year separately.
446+
447+ ### Examples
448+ For 100 stocks with 2.5% purification rate held for 180 days in a regular year:
449+
450+ $$
451+ \text{purificationAmount} = 100 \times 0.025 \times \frac{180}{365} = 1.233
452+ $$
432453
433- ### Example
434- For 100 stocks with 2.5% purification rate held for 180 days:
454+ For the same example in a leap year (366 days):
435455
436456$$
437- \text{purificationAmount} = \frac{ 100 \times 0.025 \times 180}{365.0 } = 1.23
457+ \text{purificationAmount} = 100 \times 0.025 \times \frac{ 180}{366 } = 1.230
438458$$
439459
440460
0 commit comments