From 0cb6281d4f1b61f49cd430f3938af81da239bef7 Mon Sep 17 00:00:00 2001
From: "jose.ignacio.fagian" <nachofagian@gmail.com>
Date: Sat, 4 Aug 2018 19:14:54 -0300
Subject: [PATCH] Cambios de nomenclatura sen por sin y round. Arreglo de
 grafica de reales.

---
 .../layout/plotter/graph2D/graph2D.component.ts    | 14 ++++++++++----
 .../layout/plotter/graph3D/graph3D.component.ts    |  1 -
 2 files changed, 10 insertions(+), 5 deletions(-)

diff --git a/Frontend Angular 4/src/app/layout/plotter/graph2D/graph2D.component.ts b/Frontend Angular 4/src/app/layout/plotter/graph2D/graph2D.component.ts
index 8585ff3f..57118bf4 100755
--- a/Frontend Angular 4/src/app/layout/plotter/graph2D/graph2D.component.ts	
+++ b/Frontend Angular 4/src/app/layout/plotter/graph2D/graph2D.component.ts	
@@ -60,6 +60,12 @@ export class Graph2DComponent {
                     var num = this.getRandomArbitrary(0,4);
                     var color = colores[num];
 
+                    var tipoGraf;
+                    if (obj.conj.baseDom != 'R'){
+                        tipoGraf = 'scatter';
+                    }else{
+                        tipoGraf = 'polyline';
+                    }
                      functionPlot({
                          target: '#graph2D-container',
                          width: 620,
@@ -70,7 +76,7 @@ export class Graph2DComponent {
                              fn: function(scope) {
                                return fun(scope.x)
                              },
-                             graphType: 'scatter',
+                             graphType: tipoGraf,
                              color: color
                          }]
                        })
@@ -120,9 +126,9 @@ export class Graph2DComponent {
         } else if (exp.kind == 'app') {
         if (exp.fun == 'cos') {
             exp.fun = 'Math.cos'
-        } else if (exp.fun == 'sen') {
+        } else if (exp.fun == 'sin') {
             exp.fun = 'Math.sin'
-        } else if (exp.fun == 'red') {
+        } else if (exp.fun == 'round') {
             exp.fun = 'Math.round'
         }
         expresion = ' ' + exp.fun + '(' + exp.args.map(e => this.generarExpresion(e)).join() + ') ';
@@ -261,7 +267,7 @@ export class Graph2DComponent {
         } else if (exp.kind == 'app') {
             if (exp.fun == 'cos') {
                 exp.fun = 'Math.cos'
-            } else if (exp.fun == 'sen') {
+            } else if (exp.fun == 'sin') {
                 exp.fun = 'Math.sin'
             } else if (exp.fun == 'round') {
                 exp.fun = 'Math.round'
diff --git a/Frontend Angular 4/src/app/layout/plotter/graph3D/graph3D.component.ts b/Frontend Angular 4/src/app/layout/plotter/graph3D/graph3D.component.ts
index 71e76cdb..ea76ae23 100644
--- a/Frontend Angular 4/src/app/layout/plotter/graph3D/graph3D.component.ts	
+++ b/Frontend Angular 4/src/app/layout/plotter/graph3D/graph3D.component.ts	
@@ -27,7 +27,6 @@ export class Graph3DComponent  {
     speed: 1000
   };
   
-
   constructor(ghciService: GHCIService, private zone: NgZone) {
     this.ghciServiceSub = ghciService.messages.subscribe(
       message => {
-- 
GitLab