Thread: eulers circuit

  1. #1
    Registered User
    Join Date
    Nov 2004

    eulers circuit

    what code would i need inorder to find out if a graph has a eulers circuit?

  2. #2
    ATH0 quzah's Avatar
    Join Date
    Oct 2001
    You should probably go visit Google before you get flamed into oblivion.

    Hope is the first step on the road to disappointment.

  3. #3
    Mayor of Awesometown Govtcheez's Avatar
    Join Date
    Aug 2001

  4. #4
    Carnivore ('-'v) Hunter2's Avatar
    Join Date
    May 2002
    Isn't that the no-clip cheat for Doom Original?

    **does double-take**
    Hey, how'd you know my password??
    Just Google It. √

    (\ /)
    ( . .)
    c(")(") This is bunny. Copy and paste bunny into your signature to help him gain world domination.

  5. #5
    Registered User
    Join Date
    Jun 2004
    You'll need 1st to learn algorithms tocheck that. Being you graph a class which contains Nodes and Edges the task should be eased up a little.
    Do a Google search. Some of the results are pretty good.

    And for that matter, there are 2 cases to be considered:
    A graph always has a Euler circuit If all nodes have a EVEN number of connections to other nodes, although there is one exception, quoted next...
    A graph has a Euler circuit if only 2 and 2 only nodes have a ODD number of connections to other nodes. All other nodes must have a EVEN number of connection. In this case the circuit stats in one of the ODD nodes and ends in the other.

    And if you want to calculate a euler's circuit, considering this, you only have to choose a starting node, then go all the way through all un-visited Edges. When you visit an Edge, you mark it as visited, then go to the next one, till you reach the end node. You count the number of visited edges. When they're all visited (count equals the number of edges), you have your euler circuit. But be careful when reaching a node to which all linked Edges are visited: it doesn't mean you've found a path. Better to count the number of Edges.

Popular pages Recent additions subscribe to a feed

Similar Threads

  1. Circuit Reliability program
    By Northstar in forum C Programming
    Replies: 1
    Last Post: 12-04-2007, 02:01 AM
  2. approximating euler's number
    By boomer01 in forum C Programming
    Replies: 5
    Last Post: 10-26-2006, 08:10 AM
  3. logic circuit truth table
    By botakis in forum C Programming
    Replies: 3
    Last Post: 11-18-2004, 11:02 AM
  4. circuit
    By theOracle in forum C++ Programming
    Replies: 13
    Last Post: 05-18-2003, 07:14 PM
  5. Euler's number question
    By dpw02 in forum C Programming
    Replies: 3
    Last Post: 03-18-2002, 12:16 PM