# 301.1. DP2 overview tutorial, cos(Dec) correction factor missing?

**URL:** <https://www.rubin.community/t/301-1-dp2-overview-tutorial-cos-dec-correction-factor-missing/12442>\
**Category:** Support\
**Created:** [August 10, 2026, 4:12pm UTC](https://www.rubin.community/t/301-1-dp2-overview-tutorial-cos-dec-correction-factor-missing/12442 "2026-08-10T16:12:09Z")\
**Posts on this page:** 2\
**Page:** 1

<div class="post-metadata">

**Author:** ![altavilla](https://sea2.discourse-cdn.com/flex002/user_avatar/www.rubin.community/altavilla/32/3148_2.png) [@altavilla](https://www.rubin.community/u/altavilla)\
**Post date:** [August 10, 2026, 4:12pm UTC](https://www.rubin.community/t/301-1-dp2-overview-tutorial-cos-dec-correction-factor-missing/12442/1 "2026-08-10T16:12:09Z")

</div>

Hi, in the _301.1. DP2 overview_ tutorial  
the offset is computed as  
offsets = np.sqrt((visit\_table[‘ra’]-ra)\*\*2 + (visit\_table[‘dec’]-dec)\*\*2)  
(e.g in section _2.2. Filter distributions_, Cell 13, but not only).  
Shouldn’t the offset include the cos(Dec) correction factor for spherical coordinates, i.e.:  
offsets = np.sqrt(((visit\_table[‘ra’]-ra)\*np.cos(np.radians((visit\_table[‘dec’] + dec) / 2)))\*\*2 + (visit\_table[‘dec’]-dec)\*\*2)  
leading to slightly different numbers (e.g _table field\_filt\_dist_)?  
Best  
Giuseppe

---

<div class="post-metadata">

**Author:** ![MelissaGraham](https://sea2.discourse-cdn.com/flex002/user_avatar/www.rubin.community/melissagraham/32/2549_2.png) [@MelissaGraham](https://www.rubin.community/u/MelissaGraham)\
**Post date:** [August 10, 2026, 4:23pm UTC](https://www.rubin.community/t/301-1-dp2-overview-tutorial-cos-dec-correction-factor-missing/12442/2 "2026-08-10T16:23:14Z")

</div>

Yes it absolutely should thank you Giuseppe, the tutorial has been updated.
