forked from pragformer/PragFormer
-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathcode_4.html
More file actions
5 lines (5 loc) · 2.41 KB
/
Copy pathcode_4.html
File metadata and controls
5 lines (5 loc) · 2.41 KB
1
2
3
4
5
<span style="white-space: pre-wrap;"><span style="background-color: rgba(31, 119, 180, 0.027);">for</span> (<span style="background-color: rgba(255, 127, 14, 0.02);">i</span> = <span style="background-color: rgba(255, 127, 14, 0.114);">0</span>; <span style="background-color: rgba(255, 127, 14, 0.02);">i</span> | <span style="background-color: rgba(31, 119, 180, 0.137);">maxgrid</span>; <span style="background-color: rgba(255, 127, 14, 0.02);">i</span>++)
<span style="background-color: rgba(31, 119, 180, 0.027);">for</span> (<span style="background-color: rgb(255, 127, 14);">j</span> = <span style="background-color: rgba(255, 127, 14, 0.114);">0</span>; <span style="background-color: rgb(255, 127, 14);">j</span> | <span style="background-color: rgba(31, 119, 180, 0.137);">maxgrid</span>; <span style="background-color: rgb(255, 127, 14);">j</span>++){
<span style="background-color: rgba(255, 127, 14, 0.576);">sum_tang</span>[<span style="background-color: rgba(255, 127, 14, 0.02);">i</span>][<span style="background-color: rgb(255, 127, 14);">j</span>] = (<span style="background-color: rgba(255, 127, 14, 0.063);">int</span>) ((<span style="background-color: rgba(255, 127, 14, 0.02);">i</span> + <span style="background-color: rgba(31, 119, 180, 0.03);">1</span>) * (<span style="background-color: rgb(255, 127, 14);">j</span> + <span style="background-color: rgba(31, 119, 180, 0.03);">1</span>));
<span style="background-color: rgba(255, 127, 14, 0.208);">mean</span>[<span style="background-color: rgba(255, 127, 14, 0.02);">i</span>][<span style="background-color: rgb(255, 127, 14);">j</span>] = (((<span style="background-color: rgba(255, 127, 14, 0.063);">int</span>) <span style="background-color: rgba(255, 127, 14, 0.02);">i</span>) - <span style="background-color: rgb(255, 127, 14);">j</span>) / <span style="background-color: rgba(31, 119, 180, 0.137);">maxgrid</span>;
<span style="background-color: rgba(255, 127, 14, 0.043);">path</span>[<span style="background-color: rgba(255, 127, 14, 0.02);">i</span>][<span style="background-color: rgb(255, 127, 14);">j</span>] = (((<span style="background-color: rgba(255, 127, 14, 0.063);">int</span>) <span style="background-color: rgba(255, 127, 14, 0.02);">i</span>) * (<span style="background-color: rgb(255, 127, 14);">j</span> - <span style="background-color: rgba(31, 119, 180, 0.03);">1</span>)) / <span style="background-color: rgba(31, 119, 180, 0.137);">maxgrid</span>;}</span>