Graph algorithm concerning colors

Hi, all.
Suppose we have a rectangle of width w and height h, which has w*h square grids. At any time each grid can either be empty or be occupied by a colored square. Whenever l squares in a series (horizontal, vertical or diagonal) have the same color, we call them "connected". Note l here is a variable. So I need an algorithm to find out all such connected squares.
I think it is a question in the graph theory field. Anyone got a hint or an idea for me? Many thanks.

But I'm still not so clear about how to resolve my
problem. Suppose BFS is used, do you mean I should
start at any vertex and search for adjacent vertex
that has the same color with the current one, and
iterate like this? If so, I have to apply this
procedure on each occupied grid. Did I go right? If
not, could you be more specific?Let's say this is a Grid which exists of a List of Cells.
[y]
5 (o)-(o)-(o)-(o)-(o)
    |   |   |   |   |
4 (o)-(o)-(x)-(o)-(o)
    |   |   |   |   |
3 (o)-(x)-(x)-(x)-(o)
    |   |   |   |   |
2 (o)-(o)-(x)-(o)-(o)
    |   |   |   |   |
1 (x)-(x)-(x)-(x)-(o)
    1   2   3   4   5 [x]A Cell has (at least) the following methods:
- left(), returns the Cell on the left side of this Cell (or null if x = 1)
- right(), returns the Cell on the right side of this Cell
- up(), ...
- down(), ...
Say we want to examine all connected Cells with the x-color, starting at (1,1),
add that first Cell in a List and perform a BFS on the Grid:
List<Cell> connected = new ArrayList<Cell>();
connected.add(Grid.getCell(1, 1));
BFS(connected);A BFS would look a bit like this:
void BFS(List<Cell> visited) {
  // Get the last Cell in the List
  Cell last = visited.get(visited.size()-1);
  // Get all connected Cells
  Cell left = last.left();
  Cell right = ...
  // If the left Cell is not null, if it's the same color
  // as the last node, and if it's not already in your visited-
  // list: add it and perform a BFS on the new visited-list.
  if(left != null && last.color.equals(left.color) &&
     !visited.contains(left)) {
    visited.add(left);
    BFS(visited);
}Hope it's of help to you.
Good luck.

Similar Messages

  • Graph algorithm question

    Hello.
    I am trying to find a graph algorithm (by graph I mean nodes interconnected to each other,not the sketch of a function).This algorithm should yield the route that passes from as many nodes of the graph as possible,though it is forbidden to step on a node twice,and then ends back to the first node that it started from,thus forming a cycle.
    I am positive that this algorithm must have been researched by now,so in order to avoid thinking it myself I wonder if someone would know to direct me somewhere in the web where I can get it.Since I am a medical student,any terminology help would be also appreciated(as to the name of what I want,keywords to search etc).

    OK. Before you get too geeky here, try a brute force approach. if your graph is small or has limited connectivity, you may not need to get fancy. Its surprising what a computer can do without breaking a sweat. In any case I whipped up a solution as shown below. It is untested and will most likely have bugs (and does not check for null conditions). But as you can see the code is pretty basic and should get you from point A to point B (pun inteneded).     public List<Integer> getLargestCycle( Map<Integer,List<Integer>>graph )
            List<Integer> longestCycle = new Vector<Integer>();
            List<Integer> path = new Vector<Integer>();
            for ( Integer startingPoint : graph.keySet() )
                path.add(startingPoint);
                List<Integer> aCycle = getLargestCycle( graph, path );
                if ( aCycle.size() > longestCycle.size() )
                    longestCycle = aCycle;           
            return longestCycle;
        protected List<Integer> getLargestCycle( Map<Integer,List<Integer>>graph,
            List<Integer> currentPath )
            List<Integer> longestCycle = new Vector<Integer>();
            Integer currentPoint = currentPath.get( currentPath.size()-1 );
            Integer startingPoint = currentPath.get( 0 );
            for ( Integer nextPoint : graph.get( currentPoint ) )
                List<Integer> aPath = new Vector( currentPath );
                aPath.add( nextPoint );
                if ( nextPoint.equals( startingPoint ) )
                    if ( longestCycle.size() == 0 )
                        longestCycle = aPath;
                else if ( currentPath.contains( nextPoint ) )
                    // not a cycle here.
                else
                    List<Integer> aCycle = getLargestCycle( graph, aPath );
                    if ( aCycle.size() > longestCycle.size() )
                        longestCycle = aCycle;
            return longestCycle;
        }

  • XY graph has 'negative colors' when used on PC with XP

    I built an application with windows 2000. I have distributed it. One customer using XP has found that when the XY graph begins to plot the background and gridline colors swap from black to white and visa versa. We have tried our program on an XP machine here, and can not replicate the problem

    This sounds like an issue with the graphics driver on that XP machine. I've seen all kind of weird issues due to driver bugs.
    Is this an older video card? See if there is a new driver available for XP. They might also want to try other display settings e.g. 32bit color, 24bit color, 16bit color.
    Also try to temporarily reduce the graphics acceleration (display control panel..settings..advanced..troubleshooting) by a click or two. Any improvement?
    LabVIEW Champion . Do more with less code and in less time .

  • How to show a one line in line graph in 2 colors?

    I need to create a line graph which shows the data which is forecasted to the future.
    Ex. Today is 8/10/2006.
    Start and end dates for graph are 8/1/06 thru 8/20/06.
    The line graph need to show in red color till 8/10/2006 and from 8/11/06 thru 8/20/2006, the line need to be in blue color. Is there any option to show the graph like this?
    Or are there any alternative ways to show the graph which separates out data in 2 colors conditionally?
    Thanks for ur inputs.

    I think i donot get your point correctly.
    I wrote query like
    select dept, date, act, fst
    from..
    where..
    The data is coming properly like
    Dept Date Actual Forecast
    1      1 12 null
    1      2 11 null
    1      3 14 null
    1      4 15 null
    1      5 14 null
    1      6 null 14
    1      7 null 14
    1      8 null 15
    1      9 null 15
    1      10 null 15
    2      1 20 null
    2      2 17 null
    2      3 13 null
    2      4 15 null
    2      5 14 null
    2      6 null 14
    2      7 null 15
    2      8 null 19
    2      9 null 13
    2      10 null 13
    3      1 19 null
    3      2 14 null
    3      3 14 null
    3      4 13 null
    3      5 14 null
    3      6 null 14
    3      7 null 14
    3      8 null 18
    3      9 null 18
    3      10 null 18
    Next i plotted the line graph selecting "category" as date and dept.
    and Data as Act and Fst.
    In layout tab, Lines were dept
    and group is date.
    And the graph.xml is
    <rw:graph id="CT_2" src="G_dpt_id" groups="period_start_date" series="dpt_name" dataValues="act,fct">
    <!--
    <?xml version="1.0" ?>
    <Graph version="3.2.0.22" markerDisplayed="false" graphType="LINE_VERT_ABS">
    <LegendArea automaticPlacement="AP_NEVER" position="LAP_BOTTOM"/>
    <SeriesItems>
    <Series id="1" color="#ff6666"/>
    </SeriesItems>
    </Graph>
    -->
    </rw:graph>
    But, the graph is not plotting properly. It is showing just as "Series" and "Groups" without showing actual Series and Group values on the axes.
    Do i need to pivot this query to look like what you posted to show the graph correctly?
    Thanks for helping me with this.

  • Advance Graph Algorithm

    Hello guys,
    I am working now on a TSP(traveling salesman problem), I am facing a very challenging problem in fact.
    The Main Problem: I need to find all the possible routes from A to B, I believed that there is no algorithm to provide such thing after a deadly search, so If anyone can help with just a link or a similar algorithm that would be great.
    And if you are interested to know why I need such algorithm;
    1 - I need to have the TSP works on only a part of a big graph, like a big city and I work the TSP only on 4 places.
    2 - So I need to make a small Graph object for the only 4 places, and pass it to TSP.
    3 - I need to make sure that all edges of this graph are set to the shortest paths between every pair of places. But if I found out that this shortest path go through a place which is in the TSP problem, then I have to find another(thats why i need the all routes algorithm).
    4 - (which is the main problem) this short path can't pass through any place which is within the TSP problem(coz TSP go through every place only once).
    (ex if the TSP is interested in places A, B, C, D and the shortest path from A to B passes through D, I can't pass this small graph object to TSP until I find another path connecting A to B and doesn't pass through C nor D -if there is no such path then of course I have to set it with infinity-).
    I hope one of you guys worked on this problem before,
    Thanks & Regrads,
    ES_Coders

    Thanks all,
    I have already solved the problem. I will declare it again here.
    TSP: is to find a cycle that goes through every node only once and goes back to the start point.
    MySystem: consists of nodes from A, B, C, ...., Z.
    Main Idea: user chooses a number of nodes to find their TSP.
    Ex: User wants to find TSP around A, B, C only.
    Problem: if the shortest path (A to B ) go through another node N, and also shortest path(B, C)go through this very same node N. Then the cycle goes through the node N twice which makes the TSP fail.
    Solution:
    1- Use special type of Floyed(or Dijkstra) which finds the shortest paths between every pair of nodes (n1, n2) (n1, n3) ... . But the special part is that this Floyed method takes an array of the nodes considered by TSP lets say{t1, t2, ...}. And it finds the shortest path between (n1, n2) except that this shortest path doesn't go through any of {t1, t2, t3, ...}.
    2- Now when I apply TSP lets say for {A, B, C} I am sure that shortest path from (A to B) doesn't go through node C, but It can go through some other node n which doesn't belong to {A, B, C} -some other node in the system-
    3- After I get my answer from TSP, if i found that this TSP doesn't pass through any place more than once, this is cool, I did it. But if it does pass through the node n more than once. (Here is the trick) I apply TSP for {A, B, C, n} by this way I ll start again whit the special Floyed making sure that every shortest path doesn't pass through n. And when I go for the real TSP the node n won't be passed through twice.
    I hope I was able to declare the problem and the solution,
    Thx a lot guys,
    ES_Coders

  • BI graph change bar color

    Hi All,
    I worked on the PJC BI graph, do you have an idea how to change bars color?
    regards

    The best place for information on the BI Graph is the Reports FAQ page:
    http://www.oracle.com/technology/products/reports/htdocs/faq/Graph_FAQ_with_style.html
    It contains a lot of useful tips on how to customize a BI Graph using the XML tags.
    Hope this helps
    Keith Laker
    Oracle EMEA Consulting
    OLAP Blog: http://oracleOLAP.blogspot.com/
    DM Blog: http://oracledmt.blogspot.com/
    OWB : http://blogs.oracle.com/warehousebuilder/
    DW on OTN : http://www.oracle.com/technology/products/bi/db/11g/index.html

  • Dual graph algorithm

    Hello to all of you!
    Does anyone know a known algorithm to create the dual graph of a planar (undirected) graph? Or could you give me a hint? I tried to devise a DFS approach, which would use the back and cross edges of the DFS tree in order to form the faces. The problem is that I need the set of disjoint minimum cycles. Thus I would need an algorithm to calculate the difference AUB - A^B, for two cycles A,B, where B is a part of A. By the way, is there any recommended representation of a face?
    Thank you in advance and thaks for your time!
    P.S. For those who would ask what is a face, a face is the area defined by a minimum cycle e.g.:
    In this mesh (ignore dots):
    a-b-c
    I . I . I
    d-e-f
    a,b,c,d form a face
    b,c,e,f form a face
    and there is also the external face -which by the way how can it be defined?
    P.S.2 the Dual Graph is the graph formed by representing each face as a node and each edge which separates two faces, as an edge between the two newlly created nodes.

    OK , guess you're right! Since the following graph:
    O     O
    |\   /|
    | \ / |
    |  O  |
    | / \ |
    |/   \|
    O     O
    and this one
    O---
    |    \
    | O  |
    | | \|
    | |  O
    | | /|
    | O  |
    |   /
    O---are the same, however they have a different embedding AND dual graph.
    So, the embedding is defined by the coordinates of the nodes, along with
    their connectivity info.
    This means that for a start I need an algorithm to return the different faces of
    the graph. (at least these ones have to be fixed in number -no?). Then from
    the topological information for each face I should check their neighboring
    relations.
    For the face discovery I have thought of the following algorithm (in language):
    Create the DFS tree
    -Start from the root r of the DFS tree and visit each neighboring node based
    on the preordering number
    -When we reach a node b which has one or more back-edges we have a
    cycle.
    --For each back edge we go back to the node bs, starting from the
    back-edge which leads us to the node bs with the greatest start time
    (gretest preorder number).
    --from this node, bs, visit neighboring nodes, again based on preordering,
    until we find the node b (which will complete the cycle)
    ---While going towards b follow in reverse direction, each backedge that
    terminates a currntly visited node, and starts from a node t whose
    preorder[t] <= preorder[b]  (to avoid bypassing b by going deeper in the tree)
    and
    postorder[t] > postorder[b] (to avoid reaching another branch)
    -When we reach a node, cs,which has a cross edge to another node, ce, of
    the DFS tree (as a cross edge I mean a (u,v) where pre[u]>pre[v] and
    post[u]>post[v]) we have found another cycle, thus a face
    --from ce we go up the DFS, i.e., in reverse preordering, until we find a node
    a whose postorder[a] > post[cs]
    --from a we go down the DFS (in preordering) choosing the neighbor, an,
    whose postorder[an] >= postorder[cs] (equality means we have found cs
    thus we're done).  While descending we follow the same rules as before, in
    the case of the back edge.Of course the implementation of this algorithms has to support two-way movement in the DFS tree. The distinction between tree,back and cross edges is made through the pre and post ordering.
    I'm not sure but i think that, with the restrictions I have put, this algorithm can be ran while discovering and creating the DFS tree, rather after the DFS tree has been fully created.
    So if the algorithm IS correct, I only need a way to derive the connectivity between the produced faces via their topological information. That is, apart from the indisputable fact that if two faces have two nodes in common, they are neighbors, we have to locate all other edges between faces.
    One idea is for each pair of faces to check their min and max, X and Y coordinates. I have a sense that for faces f1and f2 where,
    f1_max_X > f2_max_X and
    f1_min_X < f2_min_X and
    f1_max_Y > f2_max_Y and
    f1_min_Y < f2_min_Y
    (there must be at most one equality (i.e. <=)but I guess its no harm to add all equalities there)
    holds, f1 and f2 are neighbors, thus an edge (f1,f2) must exist in the dual graph.
    Of course I have written a lot but I really would like to know if there's a "good" algortihm to create faces out there and a technique to create edges between faces given the coordinates.
    I propose the ideas in case someone finds something wrong and reports it or otherwise someone else finds my answer useful in the same topic.
    Thank you in advance!
    Message was edited by:
    M.M.

  • Graph Algorithm Research Tool (GART)

    In reference to this thread:
    http://forum.java.sun.com/thread.jspa?forumID=426&threadID=435407
    around reply 20 I mentioned a Graph API but never gave a URL where
    it can be accessed, mainly because it wasn't ready.
    Well, it has just been released as part of a demo application called
    Gart Demo, available at:
    http://www.graphbuilder.com

    Java's Stack extends Vector, so you can insert objects in Java's stack in other positions, not just the top. The Stack in the com.graphbuilder.struc package extends LinkedList. Both stacks (com.graphbuilder.struc and java.util) don't add any additional functionality. The only advantage of extending linked list would be for cases where you need to add or remove something to the bottom without a penalty.
    I did a lot of testing on this in terms of speed. If you need speed, then using an array based stack is much faster. In fact, if you really need speed then you use your own array and maintain your own counter.
    i would like to see an API of the collection that follows the data structure definition.This is kind of like saying, "I only want 3 methods because that is what I was taught was a stack". I agree that the concept of a stack is typically 3 methods, but the implementation of a stack is built on top of either an array or linked list.

  • CR 9 - Need HELP Setting Line Graph colors in the Chart Expert

    Post Author: desselle
    CA Forum: Charts and Graphs
    Hello,
    I created a Crystal Report (CR) based off an existing Trend Analysis report. I have created a VB6 application that calls the .RPT file I created for the report in CR.  The VB6 app sets the report recordset via code that corresponds to the .TTX file, and the parameters .  The report contains a Line graph that plots five pieces of data.  The report & graph work good.  The Problem: CR determines the color of each line on the graph.  However, I need to set the color for each line to correspond to the colors used on our existing reports.  The users are accustom to a certain color representing a certain set of data on the existing reports.   I have tried everything I can think of and from all documentation I can find, and nothing changes the line colors.   I have tried all of the following:
    1.) From the Chart Expert, Option tab, I click the Format button next to Color and setup conditional color settings per each piece of data.   However, when I run the report these conditional color settings are not reflected on the CR graph.     I am using formula fields (based off database fields in the recordset) to produce the report.  However, I only see the database fields to use in the conditional color formatting screen and not the formula fields.    I thought this would possibly be the cause why the colors wonu2019t change on the CR, but I canu2019t find a way to make the formula fields show up in the list.
    2.)Also, I tried right clicking the individual lines of the graph and change the selected item color, but this didnu2019t change the color either.  I do this in Design mode and Preview mode and neither one changes the color of the lines on the graph.
    3.)I have also looked into the CR object model to see if I can change the line colors of the graph via code and it doesn't look like I am given this flexibility.
    Do you know what I am doing wrong here?   I just want to be able to set the color of each line on the CR graph to the color I want instead of using the default colors.  Are there some Hot Fixes that I need to apply to my copy of CR?
    Thanks

    Post Author: desselle
    CA Forum: Charts and Graphs
    Hello,
    I got the problem fixed w/ the line graph not making the data lines the same color on the report as on the frmPlot graph.   Compare the two screen shots below.   The problem was as follows:  When I created the graph (in the Chart Expert) the field u201CReadingDateu201D was not one of the Report Fields, and all the other fields were Report Fields (Reading, LowAlarm, UpperAlarm, LowerLimit, & UpperLimit). See the 3rd screen shot below.  ReadingDate does show up as a Report Field now but it wasnu2019t at first.   Originally, this field was only available in the Chart Expert as a recordset field.  When I changed this field to be a Report Field, the graph then allowed me to change the data series line colors.   This was not obvious at all.   From the beginning when I setup the graph and passed in the recordset from VB it graphed all of the data series fine.   The colors that the Chart Expert chose for each line just didnu2019t match what was on the frmPlot graph.   Anyway, it is working now.     I can at least say I learned (somethingu2019s to-do and somethingu2019s not to-do) a good bit about Crystal Reports in the process.
    Thanks

  • CR XI - Problem Setting Line Graph colors in the Chart Expert

    Post Author: desselle
    CA Forum: Charts and Graphs
    Hello,
    I created a Crystal Report (CR) of an existing Trend Analysis report. I have created a VB6 application that calls the .RPT file I created for the report in CR.  The VB6 app sets the report recordset via code that corrsponds to the .TTX file, and the parameters .  The report contains a Line graph that plots five pieces of data.  The report & graph work good.  CR determines the color of each line on the graph.  However, I need to set the color for each line to correspond to the colors used on our existing reports.  The users are accustom to a certain color representing a certain set of data on the existing reports.   I have tried everything I can think of and from all documentation I can find, and nothing changes the line colors.   I have tried all of the following:
    1.) From the Chart Expert, Option tab, I click the Format button next to Color and setup conditional color settings per each piece of data.   However, when I run the report these conditional color settings are not reflected on the CR graph.     I am using formula fields (based off database fields in the recordset) to produce the report.  However, I only see the database fields to use in the conditional color formatting screen and not the formula fields.    I thought this would possibly be the cause why the colors wonu2019t change on the CR, but I canu2019t find a way to make the formula fields show up in the list.
    2.)Also, I tried right clicking the individual lines of the graph and change the selected item color, but this didnu2019t change the color either.  I do this in Design mode and Preview mode and neither one changes the color of the lines on the graph.
    3.)I have also looked into the CR object model to see if I can change the line colors of the graph via code and it doesn't look like I am given this flexibility.
    Do you know what I am doing wrong here?   I just want to be able to set the color of each line on the CR graph to the color I want instead of using the default colors.
    Thanks,Steve

    Post Author: desselle
    CA Forum: Charts and Graphs
    Hello,
    I got the problem fixed w/ the line graph not making the data lines the same color on the report as on the frmPlot graph.   Compare the two screen shots below.   The problem was as follows:  When I created the graph (in the Chart Expert) the field u201CReadingDateu201D was not one of the Report Fields, and all the other fields were Report Fields (Reading, LowAlarm, UpperAlarm, LowerLimit, & UpperLimit). See the 3rd screen shot below.  ReadingDate does show up as a Report Field now but it wasnu2019t at first.   Originally, this field was only available in the Chart Expert as a recordset field.  When I changed this field to be a Report Field, the graph then allowed me to change the data series line colors.   This was not obvious at all.   From the beginning when I setup the graph and passed in the recordset from VB it graphed all of the data series fine.   The colors that the Chart Expert chose for each line just didnu2019t match what was on the frmPlot graph.   Anyway, it is working now.     I can at least say I learned (somethingu2019s to-do and somethingu2019s not to-do) a good bit about Crystal Reports in the process.
    Thanks

  • 10g Graphs - How to customize the default color of a Bar Graph

    Hi,
    I've posted this thread in Reports section, have received no reply yet. Maybe no one has ever tried this before!!
    I am porting a couple of 6i OGD's to 10g graphics.
    Basically I am invoking reports from a form. The reports contains embedded Graph.
    Here comes the tricky part.
    I have a couple of Graphs in 6i that display each bar of a bar graph in different color.
    Example:
    Value       Bar Color
    Critical     Red
    Major       Orange
    Minor       Yellow
    None       GrayQ) I want to know how to set the color of each bar of a bar graph based on the value it takes. i,e If it's critical the bar should be displayed in red. If it's major, the bar should be displayed in orange.
    I added conditional formatting in 10g Graph, and this is the trigger that was created.
    function CT_1FormatTrigger return boolean is
    begin
      -- Automatically Generated from Reports Builder.
      if (:f19 > -1)
      then
        srw.set_foreground_border_color('yellow');
        srw.set_border_pattern('solid');
        srw.set_foreground_fill_color('yellow');
        srw.set_fill_pattern('solid');
      end if;
      -- Automatically Generated from Reports Builder.
      if (:f20 > -1)
      then
        srw.set_foreground_border_color('red');
        srw.set_border_pattern('solid');
        srw.set_foreground_fill_color('red');
        srw.set_fill_pattern('solid');
      end if;
      return (TRUE);
    end;When I try to invoke the above report from the form, I get the error: FRM-41214: Unable to run report.
    If I remove conditional formatting, I am able to invoke the report from the form with the default color in the embedded graph.
    Hopefully someone has ideas on this!
    Thanks

    Why don't you use the build-in charting capability of reports 10g instead? There is FormsGraph.jar implementation for forms but that might not have the flexibility of what 6i graphs has/had and not "officially" supported - not like the reports 10g charting capability (which is built in and can be customized by editing the related xml files (if necessary). Note: FormsGraph.jar has it's own limitations

  • Marker and color in a graph

    I would like to change the color palette in a graph. How can I do it?
    Also I would like to change the size of the markers in a graph, is it possible?
    Pls. Help!!!

    The easiest way to do this is to use another plot to either overlay the
    other plots and draw points over the other plot, or behind the other
    plots as a filled plot filled to inf or -inf.
    Greg McKaskle
    Nico wrote:
    >
    > Is there a way to draw the background of a graph in different colors,
    > e.g. to mark the region of a ROI, or alternatively draw the points in
    > varying colors?
    >
    > Regards,
    > Nico
    >
    > --
    > Nico Schmidt IPK/IWF eMail : [email protected]
    > Sekr. PTZ 4, Pascalstr. 8-9 Phone : +49-30-39006342
    > D-10587 Berlin

  • Color in a Graph

    Is there a way to draw the background of a graph in different colors,
    e.g. to mark the region of a ROI, or alternatively draw the points in
    varying colors?
    Regards,
    Nico
    Nico Schmidt IPK/IWF eMail : [email protected]
    Sekr. PTZ 4, Pascalstr. 8-9 Phone : +49-30-39006342
    D-10587 Berlin

    The easiest way to do this is to use another plot to either overlay the
    other plots and draw points over the other plot, or behind the other
    plots as a filled plot filled to inf or -inf.
    Greg McKaskle
    Nico wrote:
    >
    > Is there a way to draw the background of a graph in different colors,
    > e.g. to mark the region of a ROI, or alternatively draw the points in
    > varying colors?
    >
    > Regards,
    > Nico
    >
    > --
    > Nico Schmidt IPK/IWF eMail : [email protected]
    > Sekr. PTZ 4, Pascalstr. 8-9 Phone : +49-30-39006342
    > D-10587 Berlin

  • IGS Pie Graph - colors issue

    Hello all,
    I'm displaying an IGS Pie graph in a Web-Dynpro application.
    Since in a pie graph the different parts of the pie are of the same series in different elements,
    I couldn't find a way to set different colors to them using the chart designer.
    When choosing a specific color, all the parts appear in the same color.
    When choosing an automatic color, they appear in different color,
    but then I don't have control over the color.
    Is there a way to define the pie so that every part is of a different series?
    Otherwise, Is there a way (by using the chart designer or by code)
    To achieve an IGS pie graph with the colors of my choice?
    Thanks ahead for any help,
    Anuj

    Hi
    Use this [thread|IGS Pie Graph - colors issue; for IGS Pie Graph - colors issue problem.
    Best Regards
    Satish Kumar

  • 3D Map - Color Code and Cursor Tracking

    Hi, I need some help trying to implement some user interface functionality for a program I am developing.
    This will be a tuning tool for automotive ECU. The program will be reading in two signals (Y-axis is RPM, X-Axis is manifold pressure) and use a 2D interpolation to output a Z value to be used in a calculation. There are two pieces I'd like to add to this. 
    1. Color code the cells based on the cell value in relation to the max and in of the entire 2D-Array
    2. Have a live currsor that tracks the current cell of the 2D array and highlights the cells that are being used in the interp calculation so it makes it easier for the user to make changes and calibrate the tables. 
    3. BONUS: An easy way to be able to select a range of cells and increment them by a set amoun or scale them all by an imput amount (like scale range by 90%).
    Basicly, I'd like to recreate some of the user interface functionality of the software shown below in the second picture and the video linked below. 
    VIDEO:    https://www.youtube.com/watch?v=OkVUJCy0sJ4
    VIDEO:   https://www.youtube.com/watch?v=oeZc-ka6ago      (at 16:45 you can see a good example of the currsor tracking through the cells as teh two inputs change)
    -As you drive and the RPM and loading changes there is a blue ball that tracks on the table the current x-y location of the 2D map and the four coresponding cells around the ball are highlighted to show witch of these cells are being used in the calculation so the user can easily alter these cells in real time to tune the output he is looking for. I'd like to be able to highlight, or blink either a single cell closest to the current value, or the 4 corners around it and have it update real time as the user drives the car. 
    Any ideas of how to implement this kind of functionality? The current VI is attached. I should note the x-array and y-array won't necessarily always be constant spacing between cells.
    Thank you for any help in advance!
    Attachments:
    3D Map Color Coded & Currsor.vi ‏17 KB

    Okay, so I made some progress on this. I was able to use an intensity graph to visually color code the relative position of the cells. Is there a way to make the 2D array translucent and overlay the color array intsity graph behind it? is there a better way to do this. 
    I was able to get the closest current cell value to update as black and track around live on the intensity graph. I did this by temporarily setting the cell's value to 0. Is there a way to somehow highlight the actual cell on the 2D-Array instead? 
    The code is attached. I added a random sine wave input to simultate some signals for the x and y input. The Y array now runs in reverse order which made it tricky to get some of the functions to work properly so I had to use a 2D transpose and 1D reverse array to get it back in the right form. There's probably a better way to do this. 
    Any help is great appreciately and rewarded with Kuddos!  
    Attachments:
    3D Map Color Coded & Currsor (Rev B).vi ‏33 KB

Maybe you are looking for

  • Open window is not visible!!

    Hello Experts, We are using BPC 7.5 M sp04, SQL Server 2008, Office 2007. On one of our client laptops having Windows7 and Office 2007 is having the problem (emerged few days ago) that certain dialog (pop-up) windows appear only in the Windows' taskb

  • Nokia 2330 classic - USB Cable connection.

    Hello all, i have nokia 2330 classic and i want to know that can it be connected to PC via usb cable ???

  • Remove the Enter key binding from a JPopupMenu

    Hi, Does anyone know how to remove the Enter key binding from a JPopupMenu? So when the popupmenu is showing and you type Enter, nothing should happen and the menu should stay where it is. I have tried: popup.getActionMap().put("enter", null); popup.

  • Syncronisation time takes ages

    I recently purchased an Ipod Touch but after connecting to the computer it takes more than 2 hours to syncronise with my IPOD Touch - I thought this was just because it was the first time - but every time since it takes more than 2 hours - I do not t

  • Slow Internet Please Help "Westell 7500"

    So for the past few days I have been dealing with a slow internet connection.  I called into verizon and they sent 2 tech people out to my house and basicaly said everything was fine.  Although they did pretend they solved a problem.  When they teste