Home > Sample essays > Craft Engaging Exploring How Objects Are Modeled w/ Graphics Systems & Fractals

Essay: Craft Engaging Exploring How Objects Are Modeled w/ Graphics Systems & Fractals

Essay details and download:

  • Subject area(s): Sample essays
  • Reading time: 5 minutes
  • Price: Free download
  • Published: 1 April 2019*
  • Last Modified: 23 July 2024
  • File format: Text
  • Words: 1,388 (approx)
  • Number of pages: 6 (approx)

Text preview of this essay:

This page of the essay has 1,388 words.



Graphics systems: how objects are modeled

One of the most important aspects of any graphics system is how objects are modeled.

Most man-made (manufactured) objects are fairly simple to describe, largely because the plans for these objects are be designed "manufacturable".

However objects in nature (e.g. mountainous terrains, plants, and clouds) are often much more complex.

These objects are characterized by a non smooth, chaotic behavior. The mathematical area of fractals was created largely to better understand these complex structures.

One of the early investigations into fractals was a paper written on the length of the coastline of Scotland.

The contention was that the coastline was so jagged that its length seemed to constantly increase as the length of your measuring device (mile-stick, yard-stick, etc.) got smaller.

Eventually, this phenomenon was identified mathematically by the concept of the fractal dimension.

The other phenomenon that characterizes fractals is self similarity which means that features of the object seem to reappear in numerous places but with smaller and smaller size.

In nature, self similarity does not occur exactly, but there is often a type of statistical self similarity, where features at different levels exhibit similar statistical characteristics, but at different scales.

Iterated Function Systems and Attractors:

One of the examples of fractals arising in mathematics involves sets called attractors. The idea is to consider some function of space and to see where points are mapped under this function.

There are many ways of defining functions of the plane or 3-space. One way that is popular with mathematicians is to consider the complex plane.

Each coordinate(a, b) in this space is associated with the complex number a+bi, where i= √−1. Adding and multiplying complex numbers follows the familiar rules:

(a+bi)+(c+di)=(a+c)+(b+d)i and (a+bi)(c+di)=(ac−bd)+(ad+bc)i

Define the modulus of a complex number a+bi to be length of the corresponding vector in the complex plane, .

This is a generalization of the notion of absolute value with reals. Observe that the numbers of given fixed modulus just form a circle centered around the origin in the complex plane.

Now, consider any complex number z. If we repeatedly square this number,

then the number will tend to fall towards zero if its modulus is less than 1, it will tend to grow to infinity if its modulus is greater than 1 and numbers with modulus 1 will stay at modulus 1.

In this case, the set of points with modulus 1 is said to be an attractor of this iterated function system(IFS).

In general, given any iterated function system in the complex plane, the attractor set is a subset of nonzero points that remain fixed under the mapping.

This may also be called the fixed-point set of the system.

Attractor set for an interated function system

5.9.1 Grammar based models

A geometric fractal is a fractal that repeats self-similar patterns over all scales.

5.9.2 Fractals

Random fractals:

In graphics, the term fractal has become widely associated with randomly generated curves and surfaces that exhibit a degree of self similarity.

The curves are used to provide naturalistic shape for representing objects such as coastline, rugged mountains, grass and fire.

The simplest random fractal is formed by recursively roughening or fractalizing a line segment. At each step, each line segment is replaced with a random elbow.

Random fractals

The process is applied to the line segment S having endpoints A and B. S is replaced by the two segments from A to C and from C to B.

For a fractal curve, a point C is randomly chosen along the perpendicular bisector L of S. The elbow lies randomly on one or the other side of the parent segment AB.

Three stages in the fractalization of a segment. In the first stage, the midpoint of AB is perturbed to form point C.

In the next stage, each of the two segment has its midpoint perturbed to form D and E. In the final stage, the new point F … I are added.

Three stages in fractalization

Line L passes through the midpoint M of segment S and is perpendicular to it. Any point C along L has the parametric form

c(t) = M+(B – A)t.

For some value of t, where the midpoint M= (A + B). The distance of c from M is |B – A| |t|, which is proportional to both + and the length of S. So to produce a point C on the random elbow, we let it to be computed randomly.

The fractal curves generated have a power spectral density; is given by

S(f) = 1/F β

Where β, the power of the noise process is a parameter that the user can set to control the jaggeness of the fractal noise where β is x, the process is known as Brownian motion and when β is 1, the process is called 1/f noise. 1/f noise is self similar in a statistical sense. The fractal dimensions of such processes is,

Controlling the spectral density of the fractal curve

One of the feature of fractal curves generated by pseudo random number generator is that they are completely repeatable.

*The value of the factor is given by factor

= 2(1-β/2)

Thus the factor decreases as β increases.

*The factor is computed using the C++ library function pow():

double minlensq, factor;

Void drawfractal (point 2A, point 2B)

{

double beta, std dev;

user inputs beta, minlensq, and the initial stddev

factor = pow(2.0, (1.0 – beta) 12,0);

CVS. move to (A);

fract (A, B, stdDev);

}

5.9.3 Turtle graphics

The turtle program is a Robert that can move in 2 dimensions and it has a pencil for drawing.

The turtle is defined by the following parameters.

a) Position of the turtle (x, y)

b) Heading of the turtle 0 the angle from the x axis.

5.9.4 Ray tracing

Ray tracing is a global illumination based rendering method for generating realistic images on the computer. In ray tracing, a ray of light is traced in a backward direction.

There are two types of ray tracing.

Forward ray tracing: Rays from light source bounce on objects before it reaches the camera is forward ray tracing.

Backward ray tracing: Backward ray tracing tracks only those rays that finally made it to the camera.

Setting up the Geometry of Ray tracing:

Let us consider the camera for example Its eye is at point eye, and the axes of the camera are along the vectors u, v and n.

The near plane lies at a distance N in front of the eye and the frame buffer lies in the near plane.

The camera extends from -H to H in the V direction and from -W to W in the U-direction, where.

H = N tan (θ/2)

W = H aspect.

Ray tracing

The lower left corner of the pixel lies at (uc,vr) given by,

Thus the 3D point is,

eye – Nn + ue u + vr v.

Suppose when the ray lies at eye at t = 0.

and passes through the comer of the pixel of, t = 1, then,

r{t) = eye (1 – t) + (eye – Nn + Ucu + Vr V(t)), r(t) is given by. r(t), eye + dirrc t;

(ii)Reflections and Transparency: The great strengths of the ray tracing method is the ease with which it can handle both reflection and refraction of light.

This allows one to build scenes of exquisite realism, containing mirrors, fishbowls, and lenses.

Reflections and Transparency

When the surface is mirror like or transparent, the light I that reaches the eye may have 5 components.

I = Iamb + Idiff + Ispec + Ireft + Itran.

Iroft is the reflected light component, arising from the light, Ik that is incident at Pn along the direction -r.

r = dir – 2(dir · m)m.

Reaction of Light:

Reaction of Light

When a ray of light strikes a transparent object a portion of the ray penetrates the object. The ray will change direction from dir to + if the speed of light is different in medium1 than in medium2.

If the angle of incidence of the ray is θ1, Snell’s law states that the angle of refraction θ2 will be,

Where C1 is the speed of light in medium 1 and C2 is the speed of light in medium 2. Only the ration C2/C1 is important.

It is often called the index of refraction of medium 2 with medium 1. If θ1 equals zero so does θ2. Light hitting an interface at right angles is not bent.

About this essay:

If you use part of this page in your own work, you need to provide a citation, as follows:

Essay Sauce, Craft Engaging Exploring How Objects Are Modeled w/ Graphics Systems & Fractals. Available from:<https://www.essaysauce.com/sample-essays/2015-10-16-1444990964-2/> [Accessed 16-04-26].

These Sample essays have been submitted to us by students in order to help you with your studies.

* This essay may have been previously published on EssaySauce.com and/or Essay.uk.com at an earlier date than indicated.