Warning: The magic method Slickr_Flickr_Plugin::__wakeup() must have public visibility in /home/kenbauer/public_kenscourses/tc101winter2015/wp-content/plugins/slickr-flickr/classes/class-plugin.php on line 152

Warning: Cannot modify header information - headers already sent by (output started at /home/kenbauer/public_kenscourses/tc101winter2015/wp-content/plugins/slickr-flickr/classes/class-plugin.php:152) in /home/kenbauer/public_kenscourses/tc101winter2015/wp-includes/feed-rss2.php on line 8
Carolina Romo’s Articles at Courses by Ken https://kenscourses.com/tc101winter2015 Facilitator of Learning Experiences Thu, 07 May 2015 04:41:08 +0000 en hourly 1 https://creativecommons.org/licenses/by/4.0/ Mastery30:: Visualization of data with tools https://kenscourses.com/tc101winter2015/2015/mastery30-visualization-of-data-with-tools/ Thu, 07 May 2015 04:41:08 +0000 https://carolinarmtz.withknown.com/2015/mastery30-visualization-of-data-with-tools

30

El sistema de datos por herramientas es un software libre, libremente disponible para la realización de gráficos 3D por computadora, procesamiento de imagen y visualización. VTK consiste en una biblioteca de clases de C++ y varias capas de interfaz interpretadas como Tcl/Tk, Java, y Python.

 

"The Visualization Toolkit (VTK) is an open-source, cross-platform, software system for 3D computer graphics, image processing, and visualization. Originally written as companion software to the textbook The Visualization Toolkit: An Object-Oriented Approach to 3D Graphics by Will Schroeder, Ken Martin, and Bill Lorensen, VTK provided the motivation to found Kitware.

From initial development in 1993, VTK has grown to be the premier visualization system today through the support and dedication of a global community. Much of this work has stemmed from Kitware, recently including a transition to using Git and Gerrit for distributed version control; the addition of pointer classes to facilitate pointer management; enhancement of the VTK pipeline to suit AMR; improvements to the plotting and charting capabilities in VTK; and general toolkit maintenance."(http://www.kitware.com/opensource/vtk.html)

 

1017

Continue reading ]]>

30

El sistema de datos por herramientas es un software libre, libremente disponible para la realización de gráficos 3D por computadora, procesamiento de imagen y visualización. VTK consiste en una biblioteca de clases de C++ y varias capas de interfaz interpretadas como Tcl/Tk, Java, y Python.

 

“The Visualization Toolkit (VTK) is an open-source, cross-platform, software system for 3D computer graphics, image processing, and visualization. Originally written as companion software to the textbook The Visualization Toolkit: An Object-Oriented Approach to 3D Graphics by Will Schroeder, Ken Martin, and Bill Lorensen, VTK provided the motivation to found Kitware.

From initial development in 1993, VTK has grown to be the premier visualization system today through the support and dedication of a global community. Much of this work has stemmed from Kitware, recently including a transition to using Git and Gerrit for distributed version control; the addition of pointer classes to facilitate pointer management; enhancement of the VTK pipeline to suit AMR; improvements to the plotting and charting capabilities in VTK; and general toolkit maintenance.”(http://www.kitware.com/opensource/vtk.html)

 

1017

]]>
https://creativecommons.org/licenses/by/4.0/
Mastery29:: Data analysis with tools https://kenscourses.com/tc101winter2015/2015/mastery29-data-analysis-with-tools/ Thu, 07 May 2015 04:33:34 +0000 https://carolinarmtz.withknown.com/2015/mastery29-data-analysis-with-tools

29

There are some cases where we create a function in our program destined to receive an special type of value. Here is where we want to ensure that the user enters the correct value and not any other type that will cause our program to crash, thats why we validate the user input by using some tools that I will show you.

1017

 

"El análisis estudia los requisitos que debe de cumplir la aplicación. El resultado del análisis es una hoja de especificaciones en la que aparecen los requerimientos de la aplicación. Esta hoja es redactado por la persona responsable del proceso de creación de la aplicación. Si estás creando algoritmos o programas sencillos, el análisis consistirá en evaluar estos tres pasos fundamentales:

  • Determinar las entradas. Es decir, los datos que posee el programa al comenzar su ejecución. Esos datos permiten obtener el resultado.
  • Determinar las salidas. Es decir, los datos que obtiene el algoritmo como resultado. Lo que el algoritmo devuelve al usuario.
  • Determinar el proceso. Se estudia cuál es el proceso que hay que realizar.

Si realizas estos pasos antes de comenzar a escribir código independientemente del lenguaje que uses, vas a realizar programas de calidad y vas a eliminar muchos errores que te pueden surgir si no analizas el programa y los requisitos que te piden del programa."(http://aprendecpp.com/blog/programacion-en-c-el-analisis.html#more-118

Continue reading ]]>

29

There are some cases where we create a function in our program destined to receive an special type of value. Here is where we want to ensure that the user enters the correct value and not any other type that will cause our program to crash, thats why we validate the user input by using some tools that I will show you.

1017

 

El análisis estudia los requisitos que debe de cumplir la aplicación. El resultado del análisis es una hoja de especificaciones en la que aparecen los requerimientos de la aplicación. Esta hoja es redactado por la persona responsable del proceso de creación de la aplicación. Si estás creando algoritmos o programas sencillos, el análisis consistirá en evaluar estos tres pasos fundamentales:

  • Determinar las entradas. Es decir, los datos que posee el programa al comenzar su ejecución. Esos datos permiten obtener el resultado.
  • Determinar las salidas. Es decir, los datos que obtiene el algoritmo como resultado. Lo que el algoritmo devuelve al usuario.
  • Determinar el proceso. Se estudia cuál es el proceso que hay que realizar.

Si realizas estos pasos antes de comenzar a escribir código independientemente del lenguaje que uses, vas a realizar programas de calidad y vas a eliminar muchos errores que te pueden surgir si no analizas el programa y los requisitos que te piden del programa.”(http://aprendecpp.com/blog/programacion-en-c-el-analisis.html#more-118

]]>
https://creativecommons.org/licenses/by/4.0/
Mastery28:: Reading and writing of files in C++ https://kenscourses.com/tc101winter2015/2015/mastery28-reading-and-writing-of-files-in-c/ Thu, 07 May 2015 04:13:15 +0000 https://carolinarmtz.withknown.com/2015/mastery28-reading-and-writing-of-files-in-c

28 

To open o create a file in C++, first you must be sure to add the proper library which is , as you can see, in my example the first command in main is "ofstream file", that's to create a file inside your program. Later I name it as Hello.txt, and in there you can put in whatever you want, I just typed in a line that said "Hello dudes", and that text file will remain with that line unless I erase it. After that you just close your file.

1017

Continue reading ]]>

28 

To open o create a file in C++, first you must be sure to add the proper library which is , as you can see, in my example the first command in main is “ofstream file”, that’s to create a file inside your program. Later I name it as Hello.txt, and in there you can put in whatever you want, I just typed in a line that said “Hello dudes”, and that text file will remain with that line unless I erase it. After that you just close your file.

1017

]]>
https://creativecommons.org/licenses/by/4.0/
Mastery27:: Validated user input in c++ https://kenscourses.com/tc101winter2015/2015/mastery27-validated-user-input-in-c-2/ Thu, 07 May 2015 04:08:51 +0000 https://carolinarmtz.withknown.com/2015/mastery27-validated-user-input-in-c

27

Inputs have to be validated before allowing any kind of processing or operations to be performed on it. This is extremely important because , an unhandled wrong input  might have the complete ability to crash a system.  C++ has some  good  validation techniques that  can be used to validate most kind of inputs. This post  discusses some of the techniques and its shortcomings and  what could be done to improve the quality of validation.

Now, consider a program has to accept only integer inputs and reject all the others. So, the developer would have declared to store the integer value in say “int a;”. So “a” will store the input value.

When the user input is accepted using the “cin>>a” statement, we can use the inbuilt methods surrounding the “cin”  statement to test its status.

1017

Continue reading ]]>

27

Inputs have to be validated before allowing any kind of processing or operations to be performed on it. This is extremely important because , an unhandled wrong input  might have the complete ability to crash a system.  C++ has some  good  validation techniques that  can be used to validate most kind of inputs. This post  discusses some of the techniques and its shortcomings and  what could be done to improve the quality of validation.

Now, consider a program has to accept only integer inputs and reject all the others. So, the developer would have declared to store the integer value in say “int a;”. So “a” will store the input value.

When the user input is accepted using the “cin>>a” statement, we can use the inbuilt methods surrounding the “cin”  statement to test its status.

1017

]]>
https://creativecommons.org/licenses/by/4.0/
Mastery26:: Creation and use of matrices https://kenscourses.com/tc101winter2015/2015/mastery26-creation-and-use-of-matrices/ Thu, 07 May 2015 04:06:07 +0000 https://carolinarmtz.withknown.com/2015/mastery26-creation-and-use-of-matrices

26

La sintaxis de una matriz es C++ es la siguiente:

 
int matrix[rows][cols];

En este ejemplo int es el tipo de dato, matrix es el nombre del todo el conjunto de datos y debo de especificar el numero de filas (rows) y columnas (cols).

Las matrices también pueden ser de distintos tipos de datos como char, float, double, etc. Las matrices en C++ se almacenan al igual que los vectores en posiciones consecutivas de memoria.

Podriamos imaginarnos que una matriz es como un tablero, pero en realidad el manejo es como su definición lo indica, un vector de vectores, es decir, los vectores están uno detrás del otro juntos.

Para acceder a los elementos de la matriz es utilizando su nombre e indicando los 2 subíndices que van en los corchetes.

Si coloco int matriz[2][3] = 10; estoy asignando al cuarto elemento de la tercera fila el valor 10.

Es importante tener en cuenta que tanto filas como columnas se enumeran a partir de 0. 

1017

Continue reading ]]>

26

La sintaxis de una matriz es C++ es la siguiente:

 
int matrix[rows][cols];

En este ejemplo int es el tipo de dato, matrix es el nombre del todo el conjunto de datos y debo de especificar el numero de filas (rows) y columnas (cols).

Las matrices también pueden ser de distintos tipos de datos como char, float, double, etc. Las matrices en C++ se almacenan al igual que los vectores en posiciones consecutivas de memoria.

Podriamos imaginarnos que una matriz es como un tablero, pero en realidad el manejo es como su definición lo indica, un vector de vectores, es decir, los vectores están uno detrás del otro juntos.

Para acceder a los elementos de la matriz es utilizando su nombre e indicando los 2 subíndices que van en los corchetes.

Si coloco int matriz[2][3] = 10; estoy asignando al cuarto elemento de la tercera fila el valor 10.

Es importante tener en cuenta que tanto filas como columnas se enumeran a partir de 0. 

1017

]]>
https://creativecommons.org/licenses/by/4.0/
Mastery25:: Creation and use of strings in C++ https://kenscourses.com/tc101winter2015/2015/mastery25-creation-and-use-of-strings-in-c-2/ Thu, 07 May 2015 03:55:55 +0000 https://carolinarmtz.withknown.com/2015/mastery25-creation-and-use-of-strings-in-c

The C-style character string originated within the C language and continues to be supported within C++. This string is actually a one-dimensional array of characters which is terminated by a null character ''. Thus a null-terminated string contains the characters that comprise the string followed by a null.

25 

1017

Example:

Continue reading ]]>

The C-style character string originated within the C language and continues to be supported within C++. This string is actually a one-dimensional array of characters which is terminated by a null character ‘’. Thus a null-terminated string contains the characters that comprise the string followed by a null.

25 

1017

Example:

]]>
https://creativecommons.org/licenses/by/4.0/
Mastery24:: Creation and use of arrays in C++ https://kenscourses.com/tc101winter2015/2015/mastery24-creation-and-use-of-arrays-in-c/ Thu, 07 May 2015 03:52:23 +0000 https://carolinarmtz.withknown.com/2015/mastery24-creation-and-use-of-arrays-in-c

24 

1017

An array is a series of elements of the same type placed in contiguous memory locations that can be individually referenced by adding an index to a unique identifier.

That means that, for example, five values of type int can be declared as an array without having to declare 5 different variables (each with its own identifier). Instead, using an array, the five int values are stored in contiguous memory locations, and all five can be accessed using the same identifier, with the proper index.

Continue reading ]]>

24 

1017

An array is a series of elements of the same type placed in contiguous memory locations that can be individually referenced by adding an index to a unique identifier.

That means that, for example, five values of type int can be declared as an array without having to declare 5 different variables (each with its own identifier). Instead, using an array, the five int values are stored in contiguous memory locations, and all five can be accessed using the same identifier, with the proper index.

]]>
https://creativecommons.org/licenses/by/4.0/
Mastery23:: Creation and use od vectors in c++ https://kenscourses.com/tc101winter2015/2015/mastery23-creation-and-use-od-vectors-in-c/ Thu, 07 May 2015 03:41:20 +0000 https://carolinarmtz.withknown.com/2015/mastery23-creation-and-use-od-vectors-in-c

23

1017

Un vector, también llamado array(arreglo) unidimensional, es una estructura de datos que permite agrupar elementos del mismo tipo y almacenarlos en un solo bloque de memoria juntos, uno despues de otro. A este grupo de elementos se les identifica por un mismo nombre y la posición en la que se encuentran. La primera posición del array es la posición 0.

Podríamos agrupar en un array una serie de elementos de tipo enteros, flotantes, caracteres, objetos, etc.

Crear un vector en C++ es sencillo, seguimos la siguiente sintaxix: Tipo nombre[tamanyo];

Ejemplo:

Continue reading ]]>

23

1017

Un vector, también llamado array(arreglo) unidimensional, es una estructura de datos que permite agrupar elementos del mismo tipo y almacenarlos en un solo bloque de memoria juntos, uno despues de otro. A este grupo de elementos se les identifica por un mismo nombre y la posición en la que se encuentran. La primera posición del array es la posición 0.

Podríamos agrupar en un array una serie de elementos de tipo enteros, flotantes, caracteres, objetos, etc.

Crear un vector en C++ es sencillo, seguimos la siguiente sintaxix: Tipo nombre[tamanyo];

Ejemplo:

]]>
https://creativecommons.org/licenses/by/4.0/
Mastery22:: When to use what type of repetition in a program https://kenscourses.com/tc101winter2015/2015/mastery22-when-to-use-what-type-of-repetition-in-a-program-4/ Thu, 07 May 2015 03:37:51 +0000 https://carolinarmtz.withknown.com/2015/mastery22-when-to-use-what-type-of-repetition-in-a

#f5f5dc;">22

#f5f5dc;">Repetition structures, or loops, are used when a program needs to repeatedly process one or more instructions until some condition is met, at which time the loop ends. Many programming tasks are repetitive, having little variation from one item to the next. The process of performing the same task over and over again is called iteration, and C++ provides built-in iteration functionality. A loop executes the same section of program code over and over again, as long as a loop condition of some sort is met with each iteration. This section of code can be a single statement or a block of statements (a compound statement). (http://www.cs.fsu.edu/~cop3014p/lectures/ch5/index.html)

 

Two types of repetition structures: pretest and posttest loops

Pretest:

  1. Loop condition appears at beginning of pretest loop
  2. Determines number of times instructions w/in loop body are processed


Types of pretest loop:

  • while
  • for

Posttest:

  1. Loop condition appears at end of posttest loop
  2. Determines number of times instructions w/in loop body are processed
  3. HOWEVER, instructions processed at least once–the first time

1017

EXAMPLE!!!

Continue reading ]]>

http://www.cs.fsu.edu/~cop3014p/lectures/ch5/index.html)

 

Two types of repetition structures: pretest and posttest loops

Pretest:

  1. Loop condition appears at beginning of pretest loop
  2. Determines number of times instructions w/in loop body are processed


Types of pretest loop:

  • while
  • for

Posttest:

  1. Loop condition appears at end of posttest loop
  2. Determines number of times instructions w/in loop body are processed
  3. HOWEVER, instructions processed at least once–the first time

1017

EXAMPLE!!!

]]>
https://creativecommons.org/licenses/by/4.0/
Mastery21:: Use of recursion for repetitive algorithms https://kenscourses.com/tc101winter2015/2015/mastery21-use-of-recursion-for-repetitive-algorithms-5/ Thu, 07 May 2015 03:29:27 +0000 https://carolinarmtz.withknown.com/2015/mastery21-use-of-recursion-for-repetitive-algorithms

Una función es recursiva cuando se define en función de si misma, pero no todas la funciones pueden llamarse a si mismas. Deben estar diseñadas especialmente para que sean recursivas, de otro modo podrían conducir a bucles infinitos, o a que el programa termine inadecuadamente.

C++ permite la recursividad. Cada vez que se llama a una función, se crea un juego de variables locales, de este modo, si la función hace una llamada a si misma, se guardan sus variables y parámetros, usando la pila, y la nueva instancia de la función trabajará con su propia copia de las variables locales. Cuando esta segunda instancia de la función retorna, recupera las variables y los parámetros de la pila y continua la ejecución en el punto en que había sido llamada.

La mejor manera de explicar lo que es la recursividad en c++ es con la practica de la WSQ12....

1017

21

Continue reading ]]>

Una función es recursiva cuando se define en función de si misma, pero no todas la funciones pueden llamarse a si mismas. Deben estar diseñadas especialmente para que sean recursivas, de otro modo podrían conducir a bucles infinitos, o a que el programa termine inadecuadamente.

C++ permite la recursividad. Cada vez que se llama a una función, se crea un juego de variables locales, de este modo, si la función hace una llamada a si misma, se guardan sus variables y parámetros, usando la pila, y la nueva instancia de la función trabajará con su propia copia de las variables locales. Cuando esta segunda instancia de la función retorna, recupera las variables y los parámetros de la pila y continua la ejecución en el punto en que había sido llamada.

La mejor manera de explicar lo que es la recursividad en c++ es con la practica de la WSQ12….

1017

21

]]>
https://creativecommons.org/licenses/by/4.0/