martes, 7 de junio de 2016

Database practice

We have created a database with information ralated with music. We have also made three queries; you can look for information through the name of the group, the name of the song, or the name of  the album.
Click here to see our practice.

DATA BASES






A relational database is a collection of data  items organized in relations as a set of  tables from which data can be accessed or reassembled in many different ways without having to reorganize the database tables. 
 
 

Each table is composed of a set of records and each one is identified by attributes called fields, which contain a unique value. Because of how fields are organized in a table users can access the data in almost unlimited number of ways. 

Database is  used to store lots of information. It enables a quick and very easy  access to information. It's also very easy to add new information  or delete old one. In addition one person can access it at the same like, which means it is multi-access.

Specific information is stored depending on the database's intended use. For example, the police have details of all known criminals in a database (all the crimes they've comitted). When trying to solve a crime they use the database to investigate possible criminals. 

Relational database has two specific types of keys:

  • Primary key: it exists just one particular record for each field in a table. It can´t be repeated.
  • Foreign key:it can relate different types of records by just one table

 

 

miércoles, 11 de mayo de 2016

Digital Sound

DIGITAL SOUND

An audio recording can come in two basic types: analog or digital. Both of these types are created by turning air pressure (the sound) into electrical analog signal. In an analog recording the electrical signals are directly imprinted onto the master tape or master record. These are original copies of an audio tape that can be used to produce other copies. In case of the analog recording, copies of the master tape or master record can be made into cassette tapes or vinyls.  In the other hand digital recording makes a series of number out of the analog signal, which the softerware of a computer will be able to understand. Once the signal is digitalized, The recording can be copied ontp a compact disc, a hard drive etc.




The fidelity of an analog recording depends on the sensitivity of the equipment and the mediums used to record and play back the audio.

The digital audio fidelity, however, depends on the rate at which the recording equipment sampled the original sound wave over a specific period of time. This last concept is known as sample rate and is defined as the number of samples of a sound that are taken per second to represent a sound wave digitally. Another measure of quality of digital adios is the sample formant which is measured by the number of computer bits used to represent each sample. The higher the number of bits used, the more accurate and precise the representation of each sample will be. The number of bits is also relevant because it, maximizes the difference between the loudest and the softest possible sounds (dynamic range). Common sample formants are: 8-bit, 16-bit, 24-bit and 32-bit.








Some people claim that analog sound is better than the digital one because it replicates the sound wave exactly as it was. Nevertheless some people say that high sampling rates and increased precision have erased any distinction that may have existed between these two types of sound. 

ARKANDID GAME

Click here to Download

int y=300;
int x=300;
int yspeed=8;
int xspeed=-6;
int score=0;
int brokenbrick=0;
int cont =0;

void setup(){
size(600,600);
fill(0,0,0);
background(255.255,255);
}

void draw(){
  background(255);
  fill(0);
  text("yspeed:"+ yspeed,10,10);
  text("y:"+ y,10,30);
  text("score:"+score,10,50);
  text("brokenbrick:"+brokenbrick, 10,70);
 text("score:"+score, 10,50);
 fill(x,y,250);
  ellipse (x,y,40,40);
  y=y + yspeed;
  x=x + xspeed;
 if (y<0 || y>600){
   yspeed=yspeed*-1;}
 if (x<0 || x>600){
   xspeed=xspeed*-1;}
 fill(0);
 rect(mouseX,550, 90,20);
 if (x>mouseX && x<mouseX+90 && y>535){
   yspeed=yspeed*-1;
   xspeed=(x-(mouseX+45))/10;
}

if(brokenbrick==0){
 fill(255,153,255);
 rect(100,100,120,30);
}

 if (brokenbrick ==1){ cont= cont+1;}

 if (x>80 && x<240 && y>80 && y<150){
   yspeed=yspeed*-1;
   brokenbrick=1;
   score=score + 10;}
if  (cont==20){
   stop();
   background(102,255,102);
   fill(0,102,0);
   textSize(60);
   text("CONGRATULATIONS!",10,250);
   text("YOU WON:)",120,320);
}

 
if (y>600){
   background(0);
   fill(9,255,240);
   textSize(60);
   text("GAME OVER :(",100,300);
   stop();
   }

}

miércoles, 16 de marzo de 2016

domingo, 7 de febrero de 2016

IMPOSSIBLE IMAGE

Final impossible image:


Images we have need for the impossible image:


 


Links to download the images used:
 
Links to download the final imposible image: