代写SC3060: Computer Graphics and Visualization SESSION 2024/2025 SEMESTER 1代做留学生SQL 程序

SC3060: Computer Graphics and Visualization

SW Lab or Your Own Computer

Making Images with Mathematics

Lab Experiments 1 - 5

SESSION 2024/2025

SEMESTER 1

COMPUTER SCIENCE COURSE

MAKING IMAGES WITH MATHEMATICS

1. OBJECTIVE

In this coursework you will learn how to visualize curves, surfaces and solid shapes defined by simple mathematical formulas. Each of 5 experiments takes 2 hours. Upon completion of these experiments you will know:

•   How to define shapes by parametric and implicit functions, and

•   How to transform. and animate shapes.

2. EQUIPMENT

You have to install the latest version of ShapeExplorer from the course site. The software is available for Windows, MacOS and Linux (Ubuntu). You can work on the lab assignments using your either the computers in the lab and your own computers.

3. INTRODUCTION

In this labs, you will learn how to define geometric shapes by mathematical formulas which are used to compute coordinates of all the points belonging to the shapes. You will be using ShapeExplorer (Fig.  1) which is an interactive software tool designed to display shapes defined by parametric and implicit function scripts and colors defined by explicit functions. It can run on Windows, MacOS and Linux (Ubuntu) computers. Shape  Explorer is just one interactive window where you can type the definitions scripts and other parameters. The definitions can be saved in a proprietary format and loaded later to the software to continue working with them. Shape  Explorer supports only one shape visualization at the time. Its purpose is to work as a quick all-in-one multi-platform. visualization tool.

Figure 1.   ShapeExplorer at a glance.

Parametric functions in ShapeExplorer are explicit functions of up to three variables u, v, w (which are called parameters) and time t. They can define Cartesian coordinates x,y, Z  of curves, surfaces and solid objects. To define a curve, only one parameter u, v or w  has to be used, to define a surface–any two parameters u ,v , v, w or u, w are required, for solid objects– all three parameters u, v, w have to be used. When t is added, these objects will become time- dependent. The examples of defining parametrically curves, surfaces and sold objects are given in Figs. 2, 3 and 4.

Figure 2. Displaying a parametric curve.

Figure 3. Displaying a parametric surface.

Figure 4 Displaying a parametric solid.

Implicit functions are the functions defined as f(x,y, z, t) =0, where x,y, z  are Cartesian coordinates and tis the time. You will only use them for defining surfaces. The implicit functions are equal to zero for the points located on the surface. By changing this equality into an inequality g = f(x,y, z, t)≥0, known  in computer graphics as FRep, we define not only a surface but the space bounded by this surface, or a half-space. In this case, the function equals to zero for the points located on the surface, positive values of the function indicate points inside the solid object, and negative values are for the points which are outside the object. In the ShapeExplorer script. field, only the left part of the implicit or FRep function has to be written – it is always assumed to be ≥0. The example of defining a surface is given in Fig. 5 and a definition of the solid object using set-theoretic (Boolean) operations is illustrated in Fig. 6.

Defining  shapes  and  animations  may  require  multiple  formulas  and  temporary  variables. ShapeExplorer supports a subset of C# language for writing definition scripts. The following mathematical functions are supported:

abs, sqrt, exp, log, sin, cos, tan, acos, asin, atan, ceil, floor, atan2, mod, round, max, min, cosℎ, ssinℎ, tanℎ, log10.

There is also if{ } else { } operator. Variables, x,y, z are reserved for Cartesian coordinates, while variables u, v, w are parametric coordinates. Variable t is reserved for defining the time. All other variable can be used without declaration—they will be declared as float.

Figure 5 Displaying an implicit surface. Both sides of the surface are visible.

Figure 6 Displaying an implicit solid. The inner surface of the object is not visible in solids.

For defining r,g, b diffuse colors, scripts with explicit functions of coordinates x,y, Z have to be used:

r|g |b = f(x,y, Z, t); r,g, b ∈ [0,1] . Thus the color is defined for any point of the 3D modelling space and it is then sampled by the geometry (see Fig. 7). Constant colors can also be defined as r|g |b = value ∈ [0,1];

Figure 7 Defining diffuse colors as functions of coordinates.

In addition,  in the Visual Appearance fields the Specular Color [0,1], Shininess [0,1] and Transparency [0,1] values can be defined. Specular Color affects overall illumination of the object. It is responsible for displaying reflections or specs on the surface of objects. Parameter Shininess controls the size of such specs. Colors of curves can be only defined if Shininess is set to 1.

The remaining Animation fields (Fig. 7) contain TimeSpan and CycleInterval. The TimeSpan contains minimum and maximum values of the time values between which it will be incremented in a cyclic manner. These values can be positive and negative. The TimeSpan interval then is mapped to the real time interval CycleInterval in seconds – this is how the animation will be then displayed.

Options fields  (Fig.  7) contain  parameters of the  coordinate axes, an option to toggle to wireframe. visualization mode, and background color. Coordinate axes can be scaled—shorten with the scaling parameters less than 1 or elongated with the scaling parameters greater than 1. Scaling coefficient 0 will toggle off the respective axis.

4. EXPERIMENTS

There are 5 lab sessions comprising 5 experiments:

1. Parametric Curves

12 marks

2. Parametric Surfaces

12 marks

3. Parametric Solids

12 marks

4.  Implicit Surfaces and Solids. Colors and 3D Textures

12 marks

5.  Animation

12 marks

Total:

60 marks

All the experiments are personalized, i.e. each student will have different data to work with. The personalization is based on using two last digits of your matriculation number:

U1234567G

NM

which can be integer numbers from 0 to 9 where 0 will stand for 10. Therefore, the two numbers from 1 to 10 will define your personal variant of the assignments. These numbers will be further referred to as N for penultimate digit and M for the last digit.

This is an individual assignment.

In the remaining part of the manual, you will find the assignment instructions. Each of the five lab assignments will be evaluated and awarded up to 12 marks. Partial marks are indicated in the assignment instructions.

After completion of each of five lab assignment, you have to write a report following the template shown in Fig. 8.

WITHIN ONE WEEK (7*24 HOURS) AFTER THE END OF EACH OF FIVE SCHEDULED LAB SESSION you have to do the following:

1.       Create  a  folder  and   name   it exactly as  your   name   is  written  on your matriculation card and add as a suffix the two last matric number NM, e.g., JAMES BOND 67.

2.       Copy to this folder the scan/photo of your matriculation card with clearly readable name, photo, and at least three last characters of the matriculation number. Do not make any additional subfolders

3.       Copy to this folder the PDF fie of the report and all the relevant *.func files.

4.       Zip your assignment folder. The zipped file must have the same name as your folder, e.g., JAMES BOND 67.zip. Please check that your file can be unzipped to the folder with your name.

5.       Submit the zipped file through the respective digital drop box in the lab website (note that website has been created for each lab group).

6.       Check your email  box  regularly. The lab instructors or subject coordinator will email you if something is wrong.

CZ2003: Lab # 1 {, 2, 3, 4 or 5}

Q1a

A screenshot of the shape displayed with coordinate axes (lab 1-4) or 3 screenshots from animation (lab 5)

Name of the file: Q1a.func (for labs 1-3) or Q1.func (for lab 4 and 5)

Q1b

A screenshot of the shape displayed with coordinate axes (lab 1-4)

Name of the file: Q1b.func (for labs 1-3)

Q1c

A screenshot of the shape displayed with coordinate axes (lab 1-4)

Name of the file: Q1c.func (for labs 1-3)

Q1c

A screenshot of the shape displayed with coordinate axes (lab 1-4)

Name of the file: Q1d.func (for labs 1-3)

Q2

A screenshot of the shape displayed with coordinate axes (lab 1-4) or

3 screenshots from animation (lab 5)

Name of the file: Q2.func

Q3

A screenshot of the shape displayed with coordinate axes (lab 1-4) or

3 screenshots from animation (lab 5)

Name of the file: Q3.func

Figure 8. Template of the report.

4.1 Experiment 1: Parametric Curves

This assignment illustrates Module 3, and it serves a purpose to teach you how to visualize curves defined by parametric functions. To work on this assignment, you have to watch the following TEL lectures:

Module 1:  Lecture 2 (Part 3) - Introduction to Computer Graphics and Foundation Mathematics {Rene Descartes and coordinate systems}

Module 3:  Lecture 1 (Part 2/3) - Geometric Shapes: 2D Curves {straight-lines}

Module 3:  Lecture 1 (Part 3/3) - Geometric Shapes: 2D Curves {straight-lines}

Module 3:  Lecture 2 (Part 1/3) - Geometric Shapes: 2D Curves {circle}

Module 3:  Lecture 2 (Part 2/3) - Geometric Shapes: 2D Curves {circle and beyond}

Module 3:  Lecture 2 (Part 3/3) - Geometric Shapes: 2D Curves {ellipse and summary}

Module 3:  Lecture 3 - Geometric Shapes: 3D Curves

Assignment instructions:

Create folder Lab1.  Download  into  it  from the course-site the file ParametricCurve.func (Fig. 9). Use it as a reference for the following exercises with curves. For each of the displayed curves, you have to select a sampling resolution providing for smooth curve visualization. Each of the curves has to be displayed within 1 sec and using red color with black coordinate axes on the white background.

1.       Using  functions  x (u), y(u), u  ∈  [0,1],  define  parametrically  in  4  separate  files  and display:

a.       A straight line segment spanning from the point with coordinates (-N,-M) to the point with coordinates (M,N).

b.       A circular arc with radius N and the polar angle spanning from  to 2π , centered at point with coordinates (N,M).

c.       An  origin-centered  2D  spiral  curve  which  starts  at  the  origin,  makes N+M

revolutions clockwise (as counted from the positive axis X) and reaches eventually the radius 2*M.

d.      A 3D cylindrical  helix with radius N which is aligned with axis Z and makes M clockwise revolutions about it (as counted from the positive axis X) while spanning from z1  = −N to z2  = M.    (4 marks)

2.       Based  on  the  explicit  definition  of  the  curve  with  number M (Table  1),  derive  its parametric representation x (u), y(u), u ∈ [0,1], and then modify it to scale and translate the curve so that it will make N full periodic oscillations*  within the given x-domain (Fig. 10). Display the curve.   (4 marks)

3.       A so-called “butterfly curve” is defined in polar coordinates by:

r = esin 2cos + sin5  T

Derive its parametric representation in Cartesian coordinates as x (u), y(u), u ∈ [0,1] and display the curve with the centre at coordinates (N, M).    (4 marks)

Figure 9.   Displaying the shape defined in ParametricCurve.func.



热门主题

课程名

mktg2509 csci 2600 38170 lng302 csse3010 phas3226 77938 arch1162 engn4536/engn6536 acx5903 comp151101 phl245 cse12 comp9312 stat3016/6016 phas0038 comp2140 6qqmb312 xjco3011 rest0005 ematm0051 5qqmn219 lubs5062m eee8155 cege0100 eap033 artd1109 mat246 etc3430 ecmm462 mis102 inft6800 ddes9903 comp6521 comp9517 comp3331/9331 comp4337 comp6008 comp9414 bu.231.790.81 man00150m csb352h math1041 eengm4100 isys1002 08 6057cem mktg3504 mthm036 mtrx1701 mth3241 eeee3086 cmp-7038b cmp-7000a ints4010 econ2151 infs5710 fins5516 fin3309 fins5510 gsoe9340 math2007 math2036 soee5010 mark3088 infs3605 elec9714 comp2271 ma214 comp2211 infs3604 600426 sit254 acct3091 bbt405 msin0116 com107/com113 mark5826 sit120 comp9021 eco2101 eeen40700 cs253 ece3114 ecmm447 chns3000 math377 itd102 comp9444 comp(2041|9044) econ0060 econ7230 mgt001371 ecs-323 cs6250 mgdi60012 mdia2012 comm221001 comm5000 ma1008 engl642 econ241 com333 math367 mis201 nbs-7041x meek16104 econ2003 comm1190 mbas902 comp-1027 dpst1091 comp7315 eppd1033 m06 ee3025 msci231 bb113/bbs1063 fc709 comp3425 comp9417 econ42915 cb9101 math1102e chme0017 fc307 mkt60104 5522usst litr1-uc6201.200 ee1102 cosc2803 math39512 omp9727 int2067/int5051 bsb151 mgt253 fc021 babs2202 mis2002s phya21 18-213 cege0012 mdia1002 math38032 mech5125 07 cisc102 mgx3110 cs240 11175 fin3020s eco3420 ictten622 comp9727 cpt111 de114102d mgm320h5s bafi1019 math21112 efim20036 mn-3503 fins5568 110.807 bcpm000028 info6030 bma0092 bcpm0054 math20212 ce335 cs365 cenv6141 ftec5580 math2010 ec3450 comm1170 ecmt1010 csci-ua.0480-003 econ12-200 ib3960 ectb60h3f cs247—assignment tk3163 ics3u ib3j80 comp20008 comp9334 eppd1063 acct2343 cct109 isys1055/3412 math350-real math2014 eec180 stat141b econ2101 msinm014/msing014/msing014b fit2004 comp643 bu1002 cm2030
联系我们
EMail: 99515681@qq.com
QQ: 99515681
留学生作业帮-留学生的知心伴侣!
工作时间:08:00-21:00
python代写
微信客服:codinghelp
站长地图