diff options
Diffstat (limited to 'example_beam_trace.m')
-rw-r--r-- | example_beam_trace.m | 45 |
1 files changed, 45 insertions, 0 deletions
diff --git a/example_beam_trace.m b/example_beam_trace.m new file mode 100644 index 0000000..ada35c9 --- /dev/null +++ b/example_beam_trace.m @@ -0,0 +1,45 @@ +beam.k=[1,-.5]; +beam.origin=[0,0]; +beam.face=NA; + +face.vertex1=[1.1,-1]; +face.vertex2=[2.7,1]; +face.n_right = 1; +face.n_left= 2.5; + +face2.vertex1=[-.1,-3]; +face2.vertex2=[-.1,3]; +face2.n_right = 1; +face2.n_left= 1; + +face3.vertex1=[2.1,-3]; +face3.vertex2=[2.1,3]; +face3.n_right = 1.5; +face3.n_left= 1; + +faces={face,face2,face3}; + + +border1.vertex1=[-5,-5]; +border1.vertex2=[5,-5]; +border1.n_right = 1.; +border1.n_left= 1; + +border2.vertex1=[5,-5]; +border2.vertex2=[5,5]; +border2.n_right = 1.; +border2.n_left= 1; + +border3.vertex1=[5,5]; +border3.vertex2=[-5,5]; +border3.n_right = 1.; +border3.n_left= 1; + +border4.vertex1=[-5,5]; +border4.vertex2=[-5,-5]; +border4.n_right = 1.; +border4.n_left= 1; + +borders={border1,border2, border3, border4}; +beams={beam}; +beam_trace(beams, faces, borders ) |