Skip to content
  • Categories
  • Recent
  • Tags
  • Popular
  • World
  • Users
  • Groups
Skins
  • Light
  • Cerulean
  • Cosmo
  • Flatly
  • Journal
  • Litera
  • Lumen
  • Lux
  • Materia
  • Minty
  • Morph
  • Pulse
  • Sandstone
  • Simplex
  • Sketchy
  • Spacelab
  • United
  • Yeti
  • Zephyr
  • Dark
  • Cyborg
  • Darkly
  • Quartz
  • Slate
  • Solar
  • Superhero
  • Vapor

  • Default (No Skin)
  • No Skin
Collapse
Code Project
  1. Home
  2. General Programming
  3. Visual Basic
  4. Imaginary number

Imaginary number

Scheduled Pinned Locked Moved Visual Basic
tutorial
5 Posts 4 Posters 0 Views 1 Watching
  • Oldest to Newest
  • Newest to Oldest
  • Most Votes
Reply
  • Reply as topic
Log in to reply
This topic has been deleted. Only users with topic management privileges can see it.
  • N Offline
    N Offline
    ncjlee
    wrote on last edited by
    #1

    any way to program so that visual basic 2005 express can calculate imaginary number because i am trying to write a program which is to count the root of cubic for example: dim a as double dim b as double dim c as double a = sqrt(b+c) ' how if the sum of b and C is not positive.. but i wan it to continue the the calculation

    L T D 3 Replies Last reply
    0
    • N ncjlee

      any way to program so that visual basic 2005 express can calculate imaginary number because i am trying to write a program which is to count the root of cubic for example: dim a as double dim b as double dim c as double a = sqrt(b+c) ' how if the sum of b and C is not positive.. but i wan it to continue the the calculation

      L Offline
      L Offline
      Luc Pattyn
      wrote on last edited by
      #2

      You could use a complex number type (class or struct) and teach it the basics. There are several CP articles on this including this one[^]. :)

      Luc Pattyn [Forum Guidelines] [My Articles]


      this weeks tips: - make Visual display line numbers: Tools/Options/TextEditor/... - show exceptions with ToString() to see all information - before you ask a question here, search CodeProject, then Google


      N 1 Reply Last reply
      0
      • L Luc Pattyn

        You could use a complex number type (class or struct) and teach it the basics. There are several CP articles on this including this one[^]. :)

        Luc Pattyn [Forum Guidelines] [My Articles]


        this weeks tips: - make Visual display line numbers: Tools/Options/TextEditor/... - show exceptions with ToString() to see all information - before you ask a question here, search CodeProject, then Google


        N Offline
        N Offline
        ncjlee
        wrote on last edited by
        #3

        Thankx :)

        1 Reply Last reply
        0
        • N ncjlee

          any way to program so that visual basic 2005 express can calculate imaginary number because i am trying to write a program which is to count the root of cubic for example: dim a as double dim b as double dim c as double a = sqrt(b+c) ' how if the sum of b and C is not positive.. but i wan it to continue the the calculation

          T Offline
          T Offline
          Thomas Stockwell
          wrote on last edited by
          #4

          I did end up creating a program for my calculator that returned a string which contained the imaginary number as well as the correct formula formatting, but I had to hard code the logic behind creating an I (imaginary) and for what reason, etc.

          Regards, Thomas Stockwell Programming today is a race between software engineers striving to build bigger and better idiot-proof programs, and the Universe trying to produce bigger and better idiots. So far, the Universe is winning. Visit my homepage Oracle Studios[^]

          1 Reply Last reply
          0
          • N ncjlee

            any way to program so that visual basic 2005 express can calculate imaginary number because i am trying to write a program which is to count the root of cubic for example: dim a as double dim b as double dim c as double a = sqrt(b+c) ' how if the sum of b and C is not positive.. but i wan it to continue the the calculation

            D Offline
            D Offline
            DigiOz Multimedia
            wrote on last edited by
            #5

            ncjlee wrote:

            any way to program so that visual basic 2005 express can calculate imaginary number because i am trying to write a program which is to count the root of cubic for example: dim a as double dim b as double dim c as double a = sqrt(b+c)

            You could use the "SCI" library to do this. See bellow: http://scinet.sourceforge.net/index.php/Home[^]

            Pete Soheil DigiOz Multimedia http://www.digioz.com

            1 Reply Last reply
            0
            Reply
            • Reply as topic
            Log in to reply
            • Oldest to Newest
            • Newest to Oldest
            • Most Votes


            • Login

            • Don't have an account? Register

            • Login or register to search.
            • First post
              Last post
            0
            • Categories
            • Recent
            • Tags
            • Popular
            • World
            • Users
            • Groups