tag:blogger.com,1999:blog-633578596992696872024-03-13T07:00:36.309-07:00Computer Science& ResearchRoberto Maestrehttp://www.blogger.com/profile/06687531082974257219noreply@blogger.comBlogger43125tag:blogger.com,1999:blog-63357859699269687.post-38528849239321609792011-10-23T08:17:00.000-07:002011-10-23T08:20:21.794-07:00End.I started this blog many years ago, and i posted new notes while i studied my engineer degree.Now, it is time to close. Best regards.Roberto Maestrehttp://www.blogger.com/profile/06687531082974257219noreply@blogger.com0tag:blogger.com,1999:blog-63357859699269687.post-16669129951980357072011-04-29T00:16:00.000-07:002011-04-29T00:18:15.447-07:00Twitter network viz march 2011 ipad2 launchIn this video, we present the network evolution around March iPad 2 launch conversation. Data was collected using twitter real-time API, on March 2nd, 2011, totalling around 50k tweets+retweetsRoberto Maestrehttp://www.blogger.com/profile/06687531082974257219noreply@blogger.com0tag:blogger.com,1999:blog-63357859699269687.post-64184661526575944142011-01-11T13:14:00.000-08:002011-01-11T14:17:05.831-08:00Nested loop optimized with Java IteratorsFew days ago, i saw a piece of a geoprocessing algorithm code. This algorithm get a vector of points, each point with two spatial coordinates: (x,y), and calculate the euclidean distance between of each point with the whole points of the vector. The result is a beatifull matrix of distance between each points.The problem was the follow: this algorithm use "Iterators" on the vector, as follows:Roberto Maestrehttp://www.blogger.com/profile/06687531082974257219noreply@blogger.com4tag:blogger.com,1999:blog-63357859699269687.post-33845300180932668442010-10-29T03:49:00.000-07:002010-11-08T13:40:40.479-08:00Smart pointers. shared_ptr and normal pointerShared pointer can make our code more secure. shared_pointer is a kind of pointer that allow to others pointer share his container. And when no pointer points to a container, the garbage collector erase the container thus ensuring the reliable of the program in order to no consume the heap of the process.If we use the next code, the above behaviour.The follow code show the common error, creating Roberto Maestrehttp://www.blogger.com/profile/06687531082974257219noreply@blogger.com0tag:blogger.com,1999:blog-63357859699269687.post-23513114307400212292010-10-05T13:52:00.000-07:002010-10-29T04:28:35.944-07:00snGraph. Optimal software to manage scale-free networkssnGraph package provides a flexible and efficient tool for manage graphs representing scale-free network. Can be integrated into others informatic systems. It can be read easily from databases, for example using Hibernate, and build graphs using models. It can serve of bridge between data and software in order to make analisis, for example we can use Ucinet. Also permite design and implement new Roberto Maestrehttp://www.blogger.com/profile/06687531082974257219noreply@blogger.com0tag:blogger.com,1999:blog-63357859699269687.post-30876836396331105772010-06-14T07:16:00.001-07:002010-06-14T07:28:09.484-07:00Caminar los sueñosLa rutina es un papel de lija que desgasta las ilusiones. Demasiadas veces lo cotidiano nos conduce a la monótona repetición de conductas, conversaciones y escaramucillas sin vuelo que transforman las hojas de nuestro calendario en un libro sin texto. Por el contrario, las ilusiones conseguidas son aquellas que quedan impresas para siempre en el libro del mejor recuerdo, esas épocas en las que Roberto Maestrehttp://www.blogger.com/profile/06687531082974257219noreply@blogger.com0tag:blogger.com,1999:blog-63357859699269687.post-76482596389206969392010-04-30T05:31:00.000-07:002010-04-30T05:43:14.950-07:00Parallel algorithms. Java threads. Using multiple cores.Today, computar machines has a multiples cores into his processors. The main problem is that the software engineers do not design the software accord this situation because they ignore this new technology or simply because they doesn´t want design parallel algorithms. This problem imply that the multiple core machines are underused.I propose a simple problem: Adding an integer array of ten Roberto Maestrehttp://www.blogger.com/profile/06687531082974257219noreply@blogger.com0tag:blogger.com,1999:blog-63357859699269687.post-76305460751928379432010-04-30T00:56:00.000-07:002010-04-30T01:19:06.162-07:00Java Readers and Writer. Mutual exclusion.Think about this situation, you have a buffer and into the bufer has one data. We have several elements in this situation: One Writer, that provide tha data into the buffer, and many Readers, thtat need the data into the buffer; and one restriction, only one persona can read or write into the buffer at the same time.In order to resolve this problem we can use a Monitor. A monitor is a Class that Roberto Maestrehttp://www.blogger.com/profile/06687531082974257219noreply@blogger.com0tag:blogger.com,1999:blog-63357859699269687.post-24066615569798985902010-04-29T00:43:00.001-07:002010-04-29T00:45:41.769-07:00Java Process and Threads. TCP Java Server.This post try it to explain how to manage Process, Threads and concurrence.The main goal is explain how is a thread, and how is a process.We can explain very well this topics with follow ilustration of Tanenbaum book :The ilustration show in a) case three process with one thread into each one, in case b) we can see ONE process with three threads into the unique process.The main diference between Roberto Maestrehttp://www.blogger.com/profile/06687531082974257219noreply@blogger.com0tag:blogger.com,1999:blog-63357859699269687.post-74113436039244033742010-03-30T01:12:00.001-07:002010-03-30T01:12:58.990-07:00¿Existe el tiempo?La idea de que el tiempo es un modo de decir que una cosa sigue a otra como resultado de esta otra, parece que es la clave de la verdadera naturaleza del tiempo.Leer más: http://recuerdosdepandora.com/filosofia/existe-el-tiempo/#ixzz0je5PbnJ7Roberto Maestrehttp://www.blogger.com/profile/06687531082974257219noreply@blogger.com0tag:blogger.com,1999:blog-63357859699269687.post-6928654352494612152010-02-05T02:52:00.001-08:002010-02-05T08:10:00.789-08:00Caos que vino del orden el efecto mariposaCaos que vino del orden: el efecto mariposaRoberto Maestrehttp://www.blogger.com/profile/06687531082974257219noreply@blogger.com0tag:blogger.com,1999:blog-63357859699269687.post-53939869920395121962009-10-16T05:31:00.000-07:002009-10-28T01:56:52.263-07:00Java Graph PackageThis Java Class provide an interface to work with graphs (Direct an Undirect raphs). You can get output format to generate "bmp" graphs with Graphviz.PROJECT HOMEJAVADOCStep sample:1. Import class2. Code3. Get results4. Generate graph with output String GraphvizRoberto Maestrehttp://www.blogger.com/profile/06687531082974257219noreply@blogger.com0tag:blogger.com,1999:blog-63357859699269687.post-89915793018513628432009-10-12T03:19:00.001-07:002009-10-27T01:20:22.956-07:00El gen egoistaRoberto Maestrehttp://www.blogger.com/profile/06687531082974257219noreply@blogger.com0tag:blogger.com,1999:blog-63357859699269687.post-87188490780142016422009-08-27T02:32:00.000-07:002009-08-27T03:00:26.653-07:00Floyd algorithmThe problem: We have a Graph, no direct and valued, also, we have a vector with N stages. For example, one stage is between nodes 2 and 5, other stage is between nodes 5 and 1 , ect ...We need the minimun path between first stage and last stage through the middle stages in order.The solution: We use, Floyd algorithm.The graph:The stages :The output:Roberto Maestrehttp://www.blogger.com/profile/06687531082974257219noreply@blogger.com2tag:blogger.com,1999:blog-63357859699269687.post-15154989477341925032009-04-22T00:13:00.000-07:002009-04-28T13:20:35.223-07:00I propose new algorithm problem about rated digraphsThe goal: We should get the minimun value way betwen two nodes, with follows constrains:* The total path value is the sum of the edges in the A->B direction plus double value of B->A direction (if exists) .The graph it´s representated by a adjacency matrix .A graph example :One possible solution is: 1->2->3->4 with total path value* 10 (1->2 [4] 2->3 [5] 3->4 [10])Download pascal code(You need Roberto Maestrehttp://www.blogger.com/profile/06687531082974257219noreply@blogger.com0tag:blogger.com,1999:blog-63357859699269687.post-25955534271271672642009-04-20T00:34:00.001-07:002009-04-20T00:35:29.264-07:00Against Intellectual MonopolyRoberto Maestrehttp://www.blogger.com/profile/06687531082974257219noreply@blogger.com0tag:blogger.com,1999:blog-63357859699269687.post-27601987734890386622009-04-10T05:29:00.000-07:002009-07-23T08:53:05.045-07:00Java Random Double in Range GenerationEstos días he estado pensando sobre como generar números aleatorios en Java dentro de un rango, pues bien, aquí esta mi solución y su análisis:Así, analizando los valores límite, observamos:max(0.0)+min(1-(0.0)) => minmax(0.5)+min(1-(0.5)) => (max+min)/2max(1.0)+min(1-(1.0)) => maxDe una manera gráfica, observamos como los valores están siempre encerrados dentro de los límites:Un análisis Roberto Maestrehttp://www.blogger.com/profile/06687531082974257219noreply@blogger.com1tag:blogger.com,1999:blog-63357859699269687.post-29351776066376057032009-03-27T07:36:00.000-07:002009-04-28T09:30:29.255-07:00Algorithms+MIT - Mathematics+EUI UPM AlgoritmicaRoberto Maestrehttp://www.blogger.com/profile/06687531082974257219noreply@blogger.com0tag:blogger.com,1999:blog-63357859699269687.post-64323000017257799462008-10-28T02:21:00.000-07:002008-10-30T02:00:45.840-07:00Algorítmica en php - The Knight's TourEl juego de The Knight's TourEn un post anterior explicaba el algoritmo minimax (como introducción a la poda alfa-beta). Ahora veremos un poco de algorítmica, mas concretamente el backtracking. Podría decirse (a groso modo) que sería una busqueda minimax o poda alfa-beta pero sin heurística, además, el backtracking nos asegura que siempre encontrará la solución (si la hay) recorriendo así todos Roberto Maestrehttp://www.blogger.com/profile/06687531082974257219noreply@blogger.com0tag:blogger.com,1999:blog-63357859699269687.post-84714013368473802692008-09-10T01:39:00.001-07:002008-09-10T01:40:30.442-07:00Curva de BézierRoberto Maestrehttp://www.blogger.com/profile/06687531082974257219noreply@blogger.com0tag:blogger.com,1999:blog-63357859699269687.post-80372010644198679852008-09-04T01:06:00.000-07:002008-09-05T06:57:43.941-07:00Teoría de códigosIntroducción práctica a la teoría de códigosRoberto Maestrehttp://www.blogger.com/profile/06687531082974257219noreply@blogger.com0tag:blogger.com,1999:blog-63357859699269687.post-91234779303877193132008-08-26T00:06:00.000-07:002008-09-04T04:58:40.452-07:00ProbabilidadEl origen de la probabilidadRoberto Maestrehttp://www.blogger.com/profile/06687531082974257219noreply@blogger.com0tag:blogger.com,1999:blog-63357859699269687.post-50119507412039812622008-07-28T13:16:00.001-07:002008-08-01T10:08:00.582-07:00The Singularity Is NearRoberto Maestrehttp://www.blogger.com/profile/06687531082974257219noreply@blogger.com0tag:blogger.com,1999:blog-63357859699269687.post-47720607264182590422008-05-04T07:24:00.000-07:002008-06-18T14:31:50.156-07:00Inteligencia Artificial - MINIMAX - Clisp Descargar Codigo Fuente / Download Source CodeEn el juego de restar cuadrados, dos jugadores juegan por turno restando cuadrados de números de una cantidad inicial, elegida al azar entre 10 y 1000. El siguiente turno partirá de la cantidad resultante de restar el cuadrado elegido a la cantidad, y así sucesivamente.Por ejemplo, si la cantidad elegida es 17 y juega MAX, éste tendrá cuatro Roberto Maestrehttp://www.blogger.com/profile/06687531082974257219noreply@blogger.com1tag:blogger.com,1999:blog-63357859699269687.post-68357759256923687382008-05-02T13:52:00.000-07:002008-05-05T13:53:10.707-07:00Las máquinas del futuro, ¿podrán llegar a ser conscientes?http://www.redcientifica.com/doc/doc200302140312.html--Roberto Maestrehttp://www.blogger.com/profile/06687531082974257219noreply@blogger.com0