Recent content by Hooke's Law

  1. H

    Engineering The components of a circuit with a voltage source and 2 resistors

    Homework Statement The components of a circuit with a voltage source and 2 resistors ( series ) has the following values vs = 10V, R1 = 100 , R2 = 150. With i1 leaving the +ve vs and i2 leaving -ve vs ( i.e. i1 entering node A, i2 is entering in the opposite direction of i1 ) Find: a)...
  2. H

    Programming ( Square Pattern )

    How do you make a robot wait? I was thinking making a function called "Wait(time)", where "time" is 1/1000 of a second. Do you shut down a robot for that time to make it wait? Thanks
  3. H

    Programming ( Square Pattern )

    No, it just makes the robot make a right turn before waiting. Should the robot wait before turning right?
  4. H

    Programming ( Square Pattern )

    Do you mean the robot must stop first then make a right turn? this is a part of the right turn code void turnRight(int stepNum){ int i = 0; while(i<stepNum){ rotateCW(2); // Rotate motor two step rotateCW(1); // Rotate motor one...
  5. H

    Programming ( Square Pattern )

    Homework Statement I want a robot to roll in a path with 4 sides or in other words square, so I made a possible program but I am not sure if it will work. And how do you call 2 source codes into a different code like the one below? ( the 2 are right.hex and the other is DelaySpeed ) right -...
  6. H

    Calculating Initial Speed of 2.7g Ball Launched at 45° with 50V Solenoid Input

    Homework Statement A ball ( 2.7 g ) is launched at a 45 degree angle with a solenoid input of 50V. What is the initial speed of the ball? Homework Equations KE = 0.5mv^2 PE = mgh dy = vy(0)t + 0.5at^2 dx = vx(0)t The Attempt at a Solution Voltage is potential energy and I...
  7. H

    How Do Magnetic Fields and Forces Behave Around Infinite Wires?

    Should there be values for i ( hat ) and j ( hat )?
  8. H

    How Do Magnetic Fields and Forces Behave Around Infinite Wires?

    r1 is the distance r, and 0.05 is the vector in y-direction. They both have the same values. I tried the diagram that you showed me, and I get wire A in -y direction, while wire B will be +X direction. I'm not sure if I'm doing my right hand right with the diagram because of the rotating...
  9. H

    How Do Magnetic Fields and Forces Behave Around Infinite Wires?

    Homework Statement Two infinitely long wires run parallel to the z-axis. Wire a is 5.0 cm along the y-direction from the z-axis and carries a current of 1.5 A out of the page. Wire b is 10.0 cm long along the x-direction from the z-axis carries a current of 0.5 A into the page. a)...
  10. H

    Simple Pseudocode: Test Cases for X & Y

    Do I need to pick other numbers for x and y? Could someone please explain to me what ""least number of different test cases" means? Is it having various numbers for x and y and finding the similar number in them?
  11. H

    Simple Pseudocode: Test Cases for X & Y

    Is that what Mark44 meant by combining cases? But I still can't see how to get the least number of cases.
  12. H

    Simple Pseudocode: Test Cases for X & Y

    What do you mean by "each number range associated with each case"?
  13. H

    Simple Pseudocode: Test Cases for X & Y

    EDIT: Ok. I get why bye is not returned with any number between 0 and 3. So what's next?
  14. H

    Simple Pseudocode: Test Cases for X & Y

    "hello" would be returned if x = 1,2,3,4... "bye" would be returned if x = ...-2,-3,-1,0,1, & 2 There are no conditions when nothing is returned.
  15. H

    Simple Pseudocode: Test Cases for X & Y

    Homework Statement Pseudocode: if ( x is greater than y ) then return "hello" else if ( x is less than y + 3 ) then return "bye" What is the least number of different test cases that I would use to test this coude(eg. What would you use as values for x and y to fully test this piece of code...
Back
Top