Results 1 to 30 of 30

Thread: [RESOLVED] complexity of an application

  1. #1

    Thread Starter
    Frenzied Member litlewiki's Avatar
    Join Date
    Dec 2005
    Location
    Zeta Reticuli Distro:Ubuntu Fiesty
    Posts
    1,162

    Resolved [RESOLVED] complexity of an application

    this is becoming a head ache for me .i have my prefinal review on 30th of this month and my professors are asking me to find out the complexity of my project. the funny thing is that they themselves have no clue what complexity of a project means !!

    but what i think is that they are asking for the space and time complexity.that is the amount of memory it consumes and the time taken to execute the logic on average .

    can anyone help me out in solving this ?.should i have to use timers to find the time it takes to execute a particular query? and if so how??

    p.s:my project is abt materials management system(more like inventory management system,i.e bying and selling stuff in a company) written in vb6 and oracle. thanks a million in advance)
    __________________
    ________________0îîî___
    ___îîî0________(___)____
    __(___)_________) _/_____
    ___\_ (_________(_/______
    ____\_)_________________

  2. #2

    Thread Starter
    Frenzied Member litlewiki's Avatar
    Join Date
    Dec 2005
    Location
    Zeta Reticuli Distro:Ubuntu Fiesty
    Posts
    1,162

    Re: complexity of an application

    i dont think this thread is ever going to be resolved
    __________________
    ________________0îîî___
    ___îîî0________(___)____
    __(___)_________) _/_____
    ___\_ (_________(_/______
    ____\_)_________________

  3. #3
    Conquistador
    Join Date
    Dec 1999
    Location
    Australia
    Posts
    4,527

    Re: complexity of an application

    For the time taken for the query count, I'd use the GetTickCount API

    When you call it, it returns the number of ms that the operating system has been running, accordingly:

    VB Code:
    1. Dim lngStart As Long, lngDur As Long
    2. lngStart = GetTickCount()
    3. ' execute query
    4. lngDur = GetTickCount() - lngStart 'Contains the time the query took in ms
    5. 'format the duration and display it or something

  4. #4

    Thread Starter
    Frenzied Member litlewiki's Avatar
    Join Date
    Dec 2005
    Location
    Zeta Reticuli Distro:Ubuntu Fiesty
    Posts
    1,162

    Re: complexity of an application

    looks like u are an experienced poster .did u ever come across this complexity thing

    p.s:thanks for that code
    i will definitely use that .
    __________________
    ________________0îîî___
    ___îîî0________(___)____
    __(___)_________) _/_____
    ___\_ (_________(_/______
    ____\_)_________________

  5. #5
    Conquistador
    Join Date
    Dec 1999
    Location
    Australia
    Posts
    4,527

    Re: complexity of an application

    I've never really done any proper programming, but I have timed certain functions before, to check what's more efficient etc.

  6. #6
    Oi, fat-rag! bushmobile's Avatar
    Join Date
    Mar 2004
    Location
    on the poop deck
    Posts
    5,592

    Re: complexity of an application

    In a lot of cases, the time taken for something is probably going to be inversely proportional to it's complexity. For example, see this thread on counting occurances of a small string within a larger string. Using the built in VB functions it can be done in one line. However the faster solutions get more and more complex.

  7. #7

    Thread Starter
    Frenzied Member litlewiki's Avatar
    Join Date
    Dec 2005
    Location
    Zeta Reticuli Distro:Ubuntu Fiesty
    Posts
    1,162

    Unhappy Re: complexity of an application

    well i will clarify it from my proff.iam going to kill him if he says he has no idea abt complexity of a project.
    the problem with proffs here is that they expect students to do what they cant imagine abt.
    __________________
    ________________0îîî___
    ___îîî0________(___)____
    __(___)_________) _/_____
    ___\_ (_________(_/______
    ____\_)_________________

  8. #8
    I'm about to be a PowerPoster! Hack's Avatar
    Join Date
    Aug 2001
    Location
    Searching for mendhak
    Posts
    58,333

    Re: complexity of an application

    Quote Originally Posted by litlewiki
    looks like u are an experienced poster .did u ever come across this complexity thing
    I've never encountered anything called a "complexity" of a project.

    I've had to do timings before, however. I never wrote code to do that. I used a stop watch.

  9. #9
    Conquistador
    Join Date
    Dec 1999
    Location
    Australia
    Posts
    4,527

    Re: complexity of an application

    I never had reflexes comparable to Hack's so I always used code

  10. #10

    Thread Starter
    Frenzied Member litlewiki's Avatar
    Join Date
    Dec 2005
    Location
    Zeta Reticuli Distro:Ubuntu Fiesty
    Posts
    1,162

    Talking Re: complexity of an application

    nice joke
    __________________
    ________________0îîî___
    ___îîî0________(___)____
    __(___)_________) _/_____
    ___\_ (_________(_/______
    ____\_)_________________

  11. #11
    Lively Member
    Join Date
    Mar 2006
    Location
    Finland
    Posts
    84

    Re: complexity of an application

    Quote Originally Posted by Hack
    I've had to do timings before, however. I never wrote code to do that. I used a stop watch.
    Man I laughed when I read that!
    "Real men don't use backups, they post their stuff on a public ftp server and let the rest of the world make copies."
    - Linus Torvalds

  12. #12
    PowerPoster
    Join Date
    Mar 2002
    Location
    UK
    Posts
    4,780

    Re: complexity of an application

    heres a very long explaination of it from one perspective:

    http://www.embedded.com/98/9803fe1.htm

    Im sure I used to check the complexity of a procedure, by listing how many different ways there were to go through it. Ie

    VB Code:
    1. If thing = "blah"
    2.  
    3.   Select Case MyData
    4.     case 1:  blah
    5.     case 2:  blah2
    6.    case 3:
    7.   End Select
    8.  
    9. Else
    10.  
    11.    If thingthing = "b;ah blah"
    12.  
    13.   Else
    14.  
    15.  Endif
    16.  
    17. End if

    This would give an answer of 5, a split at the second if (2 options) and 3 with the case. Cant remember how this relates or even if it does, still, its a nice subject to talk about .

  13. #13
    Member
    Join Date
    Mar 2006
    Posts
    55

    Re: complexity of an application

    There's quite a bit if you just Google the term complexity or metrics.
    Generally, it doesn't just refer to timings, it's also talking about how well maintained your code is.

    Basically, if your professor had to look at your code, would it be easy for him to figure out what is what? Do your variable names have some kind of logic to them or are they just called anything that came to mind at the time of coding? Is your code commented or do you just know what's going on?

    No doubt they'll also look to see if your doing things efficiently (timing-wise)as well, so you'll need to have a look at any areas where you think you may have overcomplicated things. For this aspect, I found this which you may decide to use (not sure if you're allowed to get someone to measure it for you, but the demo should at least give you an idea on what's happening):
    http://www.aivosto.com/project/analysis-service.html

    Hope this helps a little, like I say, there's a fair bit if you can Google the terms.
    Last edited by l12ngo; Mar 27th, 2006 at 08:39 AM.

  14. #14

    Thread Starter
    Frenzied Member litlewiki's Avatar
    Join Date
    Dec 2005
    Location
    Zeta Reticuli Distro:Ubuntu Fiesty
    Posts
    1,162

    Re: complexity of an application

    li2ngo good post u get a reputation for that .thanks also to grimfort for that

    i uploaded my project to the above mentioned link..i will reply back as soon as i get the report
    __________________
    ________________0îîî___
    ___îîî0________(___)____
    __(___)_________) _/_____
    ___\_ (_________(_/______
    ____\_)_________________

  15. #15
    PowerPoster
    Join Date
    Feb 2006
    Location
    East of NYC, USA
    Posts
    5,691

    Re: complexity of an application

    I'd ask for a definition of "complexity of a project" before even attempting to come up with something the professor may not even have in mind. This exercise (in futility, if you ask me) reminds me of the 6 year old who, upon receiving a new wallet for his birthday, wants to fill out the ID card in the wallet, so he asks his father what "Sex" means. Dad launches into a 30 minute embarrassing (to Dad) explanation. The kid then asks Dad, "How can I put all that into this little box?"

    You can't reach your destination if you have none so, if the professor can't define "complexity of project" it's logically impossible for you to present him with it. If he knows anything about programming, that should sound reasonable to him. If he doesn't, he shouldn't be asking for things he knows nothing about.

  16. #16

    Thread Starter
    Frenzied Member litlewiki's Avatar
    Join Date
    Dec 2005
    Location
    Zeta Reticuli Distro:Ubuntu Fiesty
    Posts
    1,162

    Red face Re: complexity of an application

    Quote Originally Posted by Al42
    I'd ask for a definition of "complexity of a project" before even attempting to come up with something the professor may not even have in mind. This exercise (in futility, if you ask me) reminds me of the 6 year old who, upon receiving a new wallet for his birthday, wants to fill out the ID card in the wallet, so he asks his father what "Sex" means. Dad launches into a 30 minute embarrassing (to Dad) explanation. The kid then asks Dad, "How can I put all that into this little box?"

    You can't reach your destination if you have none so, if the professor can't define "complexity of project" it's logically impossible for you to present him with it. If he knows anything about programming, that should sound reasonable to him. If he doesn't, he shouldn't be asking for things he knows nothing about.
    professors at my univ haha
    sometimes we students feel that we know more than them...
    bunch of useless guys.
    they expect us to write compilers and linkers as mini project(6thsem/8thsem).

    when in the first review i presented my project and told them that it was written in vb .they almost rejected my project(they think vb is for kids ) .just because i had a decent score in the exams i cleared thru my review.
    __________________
    ________________0îîî___
    ___îîî0________(___)____
    __(___)_________) _/_____
    ___\_ (_________(_/______
    ____\_)_________________

  17. #17
    PowerPoster Dave Sell's Avatar
    Join Date
    Mar 2004
    Location
    /dev/null
    Posts
    2,961

    Re: complexity of an application

    I recall reading that IBM developed a metric designed to measure complexity of a software project which counted, among other things, funtion points:

    http://ourworld.compuserve.com/homep...comp/fpfaq.htm

    It says you should be able to count 100 points/hour so you better get started!
    Nobody knows what software they want until after you've delivered what they originally asked for.

    Don't solve problems which don't exist.

    "If I had eight hours to cut down a tree, I'd spend six hours sharpening my axe." --- Abraham Lincoln (1809-1865)

    2 idiots don't make a genius.

  18. #18
    PowerPoster
    Join Date
    Feb 2006
    Location
    East of NYC, USA
    Posts
    5,691

    Re: complexity of an application

    Quote Originally Posted by litlewiki
    when in the first review i presented my project and told them that it was written in vb .they almost rejected my project(they think vb is for kids ) .
    One of the largest Optical Practice Management systems in the world is written entirely in VB. You're right - your professors ... hah! Maybe they should get out of the ivory tower every few decades and see how the world really works.

  19. #19
    PowerPoster Dave Sell's Avatar
    Join Date
    Mar 2004
    Location
    /dev/null
    Posts
    2,961

    Re: complexity of an application

    Thats because VB has been around for about 15 years, and the 1st 10 of those years, they would be right! VB was for kids.

    It is only since VB6 (1999) that it has become a truly robust and high-performance development environment. It is also very-nearly a truly Object Oriented development tool, and if you use it just right, you won't even notice it's not (ignore inheritence).
    Nobody knows what software they want until after you've delivered what they originally asked for.

    Don't solve problems which don't exist.

    "If I had eight hours to cut down a tree, I'd spend six hours sharpening my axe." --- Abraham Lincoln (1809-1865)

    2 idiots don't make a genius.

  20. #20

    Thread Starter
    Frenzied Member litlewiki's Avatar
    Join Date
    Dec 2005
    Location
    Zeta Reticuli Distro:Ubuntu Fiesty
    Posts
    1,162

    Re: complexity of an application

    read that faq ,just trying to figure out wat its all abt. thanks a lot for that link anyway .keep me updated as my dead line is nearing(30th of this month)..i will blabber some crap in front of them he he
    __________________
    ________________0îîî___
    ___îîî0________(___)____
    __(___)_________) _/_____
    ___\_ (_________(_/______
    ____\_)_________________

  21. #21
    I'm about to be a PowerPoster! Hack's Avatar
    Join Date
    Aug 2001
    Location
    Searching for mendhak
    Posts
    58,333

    Re: complexity of an application

    Quote Originally Posted by Al42
    One of the largest Optical Practice Management systems in the world is written entirely in VB. You're right - your professors ... hah! Maybe they should get out of the ivory tower every few decades and see how the world really works.
    The company I work for makes, and sells, Risk Management software that is, price wise, in the 6 figure range.

    It is all written in VB6.

  22. #22
    Conquistador
    Join Date
    Dec 1999
    Location
    Australia
    Posts
    4,527

    Re: complexity of an application

    Hack gets to shrink wrap the packaging

  23. #23

    Thread Starter
    Frenzied Member litlewiki's Avatar
    Join Date
    Dec 2005
    Location
    Zeta Reticuli Distro:Ubuntu Fiesty
    Posts
    1,162

    Talking Re: complexity of an application

    Quote Originally Posted by l12ngo
    There's quite a bit if you just Google the term complexity or metrics.
    Generally, it doesn't just refer to timings, it's also talking about how well maintained your code is.

    Basically, if your professor had to look at your code, would it be easy for him to figure out what is what? Do your variable names have some kind of logic to them or are they just called anything that came to mind at the time of coding? Is your code commented or do you just know what's going on?

    No doubt they'll also look to see if your doing things efficiently (timing-wise)as well, so you'll need to have a look at any areas where you think you may have overcomplicated things. For this aspect, I found this which you may decide to use (not sure if you're allowed to get someone to measure it for you, but the demo should at least give you an idea on what's happening):
    http://www.aivosto.com/project/analysis-service.html

    Hope this helps a little, like I say, there's a fair bit if you can Google the terms.
    thanks l12ngo for suggesting the link i submitted my code yesterday and got this report today ,now this is such a huge report and i have no clue what to do with this .can some one suggest me what to do with this...

    p.s:by the way i asked my proff what he meant by complexity .he actually wanted to ask "What new Features are present in your app. which are not present in other similar commercial applications. he din find a synonym for that so he asked what is the complexity? "

    anyway i found this topic very interesting so i will continue with the actual complexity!!
    Last edited by litlewiki; Apr 13th, 2007 at 02:02 PM.
    __________________
    ________________0îîî___
    ___îîî0________(___)____
    __(___)_________) _/_____
    ___\_ (_________(_/______
    ____\_)_________________

  24. #24
    Member
    Join Date
    Mar 2006
    Posts
    55

    Re: complexity of an application

    Lol, it's just as well you asked your prof what HE meant by complexity cause it sure sounds like no-one else thinks that's what it means

    That's one big report

    The striking things out of it for me would be the Dead Code statistics and the Cyclic Complexity.

    For the most part your CC is good. The report does state though that you have 3 procedures with a complexity of over 20, I'd probably try to have a look at the code and see if I could simplify things here if at all possible. You probably have a couple of procedures in there with huge if else statements and loops and such which should stand out.

    For the Dead code, it's just a case of going through and seeing where you have variables, subs, functions etc declared which aren't used.

    Also, your code re-use isn't really that high, maybe have a look at that.



    As for your profs definition, I think that's a really tough ask as I'm sure someone out there has produced commerical software doing most stuff.

    What I'd probably do is try to identify what my app does and then trawl the internet for software that basically tries to do the same goals but doesn't have certain features that yours does. Then I'd list them as examples.

    A simple analogy would be if you developed an app that is basically a calculator but it allows you to print out your answer, you could find a commercial bit fo software on the net which is just a calculator and then say this software from company x is a similar piece of software, but my application also offers the ability to print out your results. Having said all that, you know your professor better than me and this may or may not be what he's getting at

  25. #25

    Thread Starter
    Frenzied Member litlewiki's Avatar
    Join Date
    Dec 2005
    Location
    Zeta Reticuli Distro:Ubuntu Fiesty
    Posts
    1,162

    Thumbs up Re: complexity of an application

    because of the shortage of time i had tp speed up my coding .i finished it in 2months (All that testing and documentation took away most of my time.though my project is conceptually similar to this one mms (without the inventory management ),but i devloped it for my dads firm .though mine is nothing if compared with the above one .but if asked i would say that it was custom built for my dads firm(right now they have no such sort of a system/application) and is light on system resources blah blah.

    would that be alright or something else could be added

    p.s:i will review my code and do the corrections as required (if time permits ).
    the reason why i din reuse my code much is that it is oracle that does everything,iam just displaying it thru vb!!

    thanks anyway for the suggestions l12ngo
    __________________
    ________________0îîî___
    ___îîî0________(___)____
    __(___)_________) _/_____
    ___\_ (_________(_/______
    ____\_)_________________

  26. #26
    Member
    Join Date
    Mar 2006
    Posts
    55

    Re: complexity of an application

    I'd probably try to look for a worse product to compare my app to. For example if I had an app that was used in Warehouse management, I'd probably use something like Popims (an old but still widely used system) to compare my app against rather than the latest Warehouse Management System on the market. It may be cheating in a way, but it's all about making your app look good

    I'd also do like your suggesting though, which is to play on the fact that it's a bespoke application designed to provide optimal performance for your customer's (dad's) requirements etc etc.

    Anyway, good luck with your results

  27. #27

    Thread Starter
    Frenzied Member litlewiki's Avatar
    Join Date
    Dec 2005
    Location
    Zeta Reticuli Distro:Ubuntu Fiesty
    Posts
    1,162

    Re: complexity of an application

    thanks a lot |12ngo i will work on that
    __________________
    ________________0îîî___
    ___îîî0________(___)____
    __(___)_________) _/_____
    ___\_ (_________(_/______
    ____\_)_________________

  28. #28
    PowerPoster
    Join Date
    Feb 2006
    Location
    East of NYC, USA
    Posts
    5,691

    Re: complexity of an application

    Quote Originally Posted by Dave Sell
    Thats because VB has been around for about 15 years, and the 1st 10 of those years, they would be right! VB was for kids.

    It is only since VB6 (1999) that it has become a truly robust and high-performance development environment.
    I have to beg to differ, but the first VB version of the program I was talking about was written in VB3, and we're not talking about a merely few thousand lines of code. Granted, the VB6 version is more robust, etc., but the VB3 (and TP5.5 before that) versions ran in thousands of offices around the US for years.

    You can smash a window with a large hammer, but if you're careful you can also cut diamonds with it.

  29. #29
    PowerPoster
    Join Date
    Feb 2006
    Location
    East of NYC, USA
    Posts
    5,691

    Re: complexity of an application

    Quote Originally Posted by Hack
    The company I work for makes, and sells, Risk Management software that is, price wise, in the 6 figure range.

    It is all written in VB6.
    In theory, theory and practice are the same. In practice, they're worlds apart, eh Hack?

  30. #30
    New Member
    Join Date
    Mar 2006
    Location
    Minnesota
    Posts
    1

    Re: complexity of an application

    Quote Originally Posted by litlewiki
    professors at my univ ... think vb is for kids ...
    If they got out more, they would be aware that it's the most successful programming language ever invented, from a market perspective.

    Maybe your prof should tell the millions of programmers using it that they're all kids. If he came to my shop, he'd be laughed all the way back to the top of his ivory tower.

    In the meantime, tell him that since he didn't define "complexity" for you, you defined it for him as the total number of lines of code, including white space. You can get that in seconds in any text editor and make a daunting task trivial.

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  



Click Here to Expand Forum to Full Width