Home My Page Projects Code Snippets Project Openings diderot
Summary Activity Tracker Tasks SCM

SCM Repository

[diderot] Annotation of /branches/charisee/ertest/vispaper/volume2-x1/volume2-x1.diderot
ViewVC logotype

Annotation of /branches/charisee/ertest/vispaper/volume2-x1/volume2-x1.diderot

Parent Directory Parent Directory | Revision Log Revision Log


Revision 3066 - (view) (download)

1 : cchiw 3066 field#3(2)[] f= image ("../../../data/ddro.nrrd") ⊛ bspln5;
2 : cchiw 2870 int imgSize = 300;
3 :    
4 :     field#2(2)[2] g = ∇f;
5 :     field#1(2)[2,2] H = ∇⊗∇f;
6 :     field#2(2)[] m=|g|;
7 :     field#2(2)[2] n=g/m;
8 :    
9 :     //Various ways to write ∇M.
10 :     field#1(2)[2] M1=∇(g•g/2);
11 :     field#1(2)[2] M2=∇(m*m/2);
12 :     field#1(2)[2] M3= ((H•g)+(H•g))/2;
13 :    
14 :     //Various ways to write C.
15 :     field#1(2)[] C1= g•M3/m;
16 :     field#1(2)[] C2 = g•((g•H+g•H)/(2*m)); //use to make vis.nrrd
17 :     field#1(2)[] C3 = g•H•g/|g|;
18 :    
19 :     //field#1(2)[] D5= n•M3;//Use b.nrrd
20 :    
21 :     strand fieldTest (int xi, int yi) {
22 :     vec2 pos = [lerp(0.0, 1.0, -0.5, real(xi), real(imgSize)-0.5),
23 :     lerp(0.0, 1.0, -0.5, real(yi), real(imgSize)-0.5)];
24 :    
25 :     //real a = alpha(2, m(pos));
26 :     output tensor[] t2=C3(pos);
27 :    
28 :     update
29 :     {
30 :    
31 :    
32 :     stabilize;
33 :     }
34 :     }
35 :     initially [ fieldTest(xi, yi) | yi in 0..(imgSize-1), xi in 0..(imgSize-1)];
36 :    

root@smlnj-gforge.cs.uchicago.edu
ViewVC Help
Powered by ViewVC 1.0.0