Search Results

Search found 7490 results on 300 pages for 'algorithm analysis'.

Page 12/300 | < Previous Page | 8 9 10 11 12 13 14 15 16 17 18 19  | Next Page >

  • C# Algorithm to Tint a Color a Certain Percent

    - by Josh Close
    I have a color and I want get a tint of that color by a certain percent. So 100% is the color itself, 90% is a slightly lighter color, etc. Basically, it's like adding 10% of opacity to the color, if the color is on a white background. I need to convert the color into a hex HTML color value, so I don't want transparency. Is there an algorithm to get a tint of the System.Drawing.Color RGB value?

    Read the article

  • Pseudo LRU tree algorithm.

    - by patros
    A lot of descriptions of Pseudo LRU algorithms involve using a binary search tree, and setting flags to "point away" from the node you're searching for every time you access the tree. This leads to a reasonable approximation of LRU. However, it seems from the descriptions that all of the nodes deemed LRU would be leaf nodes. Is there a pseudo-LRU algorithm that deals with a static tree that will still perform reasonably well, while determining that non-leaf nodes are suitable LRU candidates?

    Read the article

  • Moon / Lunar Phase Algorithm

    - by Scott Bailey
    Does anyone know an algorithm to either calculate the moon phase or age on a given date or find the dates for new/full moons in a given year? Googling tells me the answer is in some Astronomy book, but I don't really want to buy a whole book when I only need a single page.

    Read the article

  • Dijstra shortest path algorithm with edge cost.

    - by Svisstack
    Hello, I have a directed, positive weighted graph. Each edge have a cost of use. I have only A money, i want to calculate shortest paths with dijkstra algorithm, but sum of edges costs on route must be less or equal to A. I want to do this with most smallest Dijstra modification (if I can do it with small modification of Dijkstra). Anyone can help me with this?

    Read the article

  • Neural Net Optimize w/ Genetic Algorithm

    - by ServAce85
    Is a genetic algorithm the most efficient way to optimize the number of hidden nodes and the amount of training done on an artificial neural network? I am coding neural networks using the NNToolbox in Matlab. I am open to any other suggestions of optimization techniques, but I'm most familiar with GA's.

    Read the article

  • Algorithm for 2D Interpolation

    - by Gayan
    I have two shapes which are cross sections of a channel. I want to calculate the cross section of an intermediate point between the two defined points. What's the simplest algorithm to use in this situation? P.S. I came across several algorithms like natural neighbor and poisson which seemed complex. I'm looking for a simple solution which could be implemented quickly EDIT: I removed the word "Simplest" from the title since it might be misleading

    Read the article

  • Word Anagram Hashing Algorithm?

    - by Ahmed Said
    Given set of words, we need to find the anagram words and display each category alone using the best algorithm input: man car kile arc none like output: man car arc kile like none the best solution I am developing now is based on a hashtable, but I am thinking about equation to convert anagram word into integer value exmaple: man = 'm'+'a'+'n' but this will not give unique values any suggestions?

    Read the article

  • Graph spacing algorithm

    - by David
    Hi, I am looking for an algorithm that would be useful for determining x y coordinates for a number objects to display on screen. Each object can be related to another object and there can be any number of relationships and there can be any number of these objects. There is no restriction on the overall size of area on which to display these object. I am writing this in php and would be looking to store the coordinates in an array.

    Read the article

  • Psuedo LRU tree algorithm.

    - by patros
    A lot of descriptions of Pseudo LRU algorithms involve using a binary search tree, and setting flags to "point away" from the node you're searching for every time you access the tree. This leads to a reasonable approximation of LRU. However, it seems from the descriptions that all of the nodes deemed LRU would be leaf nodes. Is there a pseudo-LRU algorithm that deals with a static tree that will still perform reasonably well, while determining that non-leaf nodes are suitable LRU candidates?

    Read the article

  • aother option for modified preorder tree traversal algorithm

    - by poldo
    Hi, been searching for a while now and can't seem to find an alternative solution. I need the tree traversal algorithm in such a way that a node can have more than 1 parent, if it's possilbe (found a great article here: Storing Hierarchical Data in a Database). Are there any algorithms so that, starting from a root node, we can determine the sequence and dependencies of nodes (currently reading topological sorting)? thanks in advance!

    Read the article

  • Draw arrow on line algorithm

    - by nunos
    Does anyone have an algorithm for drawing an arrow in the middle of a given line. I have searched for google but haven't found any good implementation. P.S. I really don't mind the language, but it would be great if it was Java, since it is the language I am using for this. Thanks in advance.

    Read the article

  • What Sorting Algorithm Is Used By LINQ "OrderBy"?

    - by Mystagogue
    Evidently LINQ's "OrderBy" had originally been specified as unstable, but by the time of Orca it was specified as stable. Not all documentation has been updated accordingly - consider these links: Jon Skeet on OrderBy stability Troy Magennis on OrderBy stability But if LINQ's OrderBy is now "stable," then it means it is not using a quicksort (which is inherently unstable) even though some documentation (e.g. Troy's book) says it is. So my question is: if not quicksort, then what is the actual algorithm LINQ's orderBy is using?

    Read the article

  • Algorithm putting point into square with maximal minimum distance

    - by Mikulas Dite
    I'm stuck on this: Have a square. Put n points into this square so the minimal distance (not necessary the average distance) is the highest possible. I'm looking for an algorithm which would be able to generate the coordinates of all points given the count of them. Example results for n=4;5;6: Please don't mention computing-power based stuff such as trying a lot of combination and then nitpicking the right one and similar ideas.

    Read the article

  • Java Algorithm HmacSHA256 not available

    - by user324929
    Hi, I am trying an encryption-decryption code in java. When I am trying to run it with JDK and code in class with main method it is running fine. But when I am trying to run same code in Tomcat, tomcat is throwing exception: java.security.NoSuchAlgorithmException: Algorithm HmacSHA256 not available. Can anybody guide me to proper direction please? Thank you.

    Read the article

  • Most efficient algorithm for merging sorted IEnumerable<T>

    - by franck
    Hello, I have several huge sorted enumerable sequences that I want to merge. Theses lists are manipulated as IEnumerable but are already sorted. Since input lists are sorted, it should be possible to merge them in one trip, without re-sorting anything. I would like to keep the defered execution behavior. I tried to write a naive algorithm which do that (see below). However, it looks pretty ugly and I'm sure it can be optimized. It may exist a more academical algorithm... IEnumerable<T> MergeOrderedLists<T, TOrder>(IEnumerable<IEnumerable<T>> orderedlists, Func<T, TOrder> orderBy) { var enumerators = orderedlists.ToDictionary(l => l.GetEnumerator(), l => default(T)); IEnumerator<T> tag = null; var firstRun = true; while (true) { var toRemove = new List<IEnumerator<T>>(); var toAdd = new List<KeyValuePair<IEnumerator<T>, T>>(); foreach (var pair in enumerators.Where(pair => firstRun || tag == pair.Key)) { if (pair.Key.MoveNext()) toAdd.Add(pair); else toRemove.Add(pair.Key); } foreach (var enumerator in toRemove) enumerators.Remove(enumerator); foreach (var pair in toAdd) enumerators[pair.Key] = pair.Key.Current; if (enumerators.Count == 0) yield break; var min = enumerators.OrderBy(t => orderBy(t.Value)).FirstOrDefault(); tag = min.Key; yield return min.Value; firstRun = false; } } The method can be used like that: // Person lists are already sorted by age MergeOrderedLists(orderedList, p => p.Age); assuming the following Person class exists somewhere: public class Person { public int Age { get; set; } } Duplicates should be conserved, we don't care about their order in the new sequence. Do you see any obvious optimization I could use?

    Read the article

  • How does Dijkstra's Algorithm and A-Star compare?

    - by KingNestor
    I was looking at what the guys in the Mario AI Competition have been doing and some of them have built some pretty neat Mario bots utilizing the A* (A-Star) Pathing Algorithm. (Video of Mario A* Bot In Action) My question is, how does A-Star compare with Dijkstra? Looking over them, they seem similar. Why would someone use one over the other? Especially in the context of pathing in games?

    Read the article

  • Help with this algorithm

    - by user146780
    I want to implement this algorithm here: http://bellard.org/pi/pi_n2/pi_n2.html but I don't understand a good part of it, and would like to understand. Could someone please put it in understandable words, psudocode, or C. Thanks.

    Read the article

  • Diamond square algorithm.

    - by Gabriel A. Zorrilla
    I'm trying to write the Diamond-Square algorithm in Java to generate a random map but can't figure out the implementation... Anyone with some Java code (or other language) so i can check how the loop is made would be greatly appreciated! Thanks!

    Read the article

< Previous Page | 8 9 10 11 12 13 14 15 16 17 18 19  | Next Page >