Professional Documents
Culture Documents
P02
Saturday 5 May 2012
P-02
Page 1/5
3. Saves the entered circuit to a file (choice of text or binary mode is left to programmer although I recommend the use of a text file as this will allow you to modify its contents even without the use of the program and see whether the desired change reflects in output or not). 4. Load a circuit from a file. The word circuit used here refers to DC-Resistive circuits with independent VS or CS only (i.e. the circuit can contain resistors, VS and CS only. The circuit can have a maximum of 4 essential nodes.
Details:
A circuit is comprised of components and interconnections (what is this; aggregation or composition?). A component creates a branch. A component is connected between two nodes. A node joins at least two branches. An essential node is a node with at least 3 branches connected to it. Let Nx refer to a node, Rx refer to a resistor, Ox refer to a VS and Ux refer to a CS. Trying to assign a unique unambiguous character to each. Where x is a positive integer number, 1, 2, 3, Remember a component for this project only means a Resistor, a VS or a CS. A component is described by three things: 1. Label (e.g. resistor label may be R1, R2, , VS label as O1, O2, and CS label as U1, U2, ) 2. Value (for resistors in Ohms (), for VS in Volts (V) and for CS in Amperes (A)) 3. Two nodes between which it is connected.
Note: Please report any mistake in this write-up as soon as possible so that any mistake and ambiguity be cleared as soon as is possible.
P-02
Page 2/5
C:\> ewb11 <enter> Welcome to Electronic Work Bench (Batch 11 EE) Type help for command help; circuit to enter a circuit; run to find specified outputs. EWB11:\> circuit cir1 <enter> n, N1, N2 cs, U1, 10m, N2 to N1 <enter> r, R1, 3k, N1 to N2 <enter> r, R2, 3000, N1 to N2 <enter> r, R3, 0.003M, N1 to N2 <enter> o, Vt, N1 to N2 done <enter> EWB11:\> run cir1 <enter> Vt = 10 V EWB11:\> save cir1 cir1.ewb <enter> Success: cir1 saved to file cir1.ewb. EWB11:\>
C:\> ewb11 <enter> Welcome to Electronic Work Bench (Batch 11 EE) Type help for command help; circuit to enter a circuit; run to find specified outputs. EWB11:\> load cir1.ewb <enter> Success: 1 circuit loaded ------------------------------------------Circuit: cir1 ------------------------------------------nodes: N1, N2 currentsource: S1 = 0.01, N2 to N1 resistor: R1 = 3k, N1 to N2 resistor: R2 = 3k, N1 to N2 resistor: R3 = 3k, N1 to N2 output: Vt, N1 to N2 ------------------------------------------EWB11:\> run cir1<enter> Vt = 10 V EWB11:\>
P-02
Page 4/5
Grading:
1. Code that does not compile and does not attempt the problem stated here will get ZERO marks. 2. Half of the marks will be allocated based on submitted material. 3. Half of the marks will be allocated based on demo/presentation. 4. If for some reason demo/presentation cannot be held, complete marks will be awarded based on submitted material.
Read all the details once properly to understand everything. Then start from a basic point and decide an abstract overall design of the project. Slowly keep filling in details. If you have strong framework, adding a new functionality is trivial. Remember the code in the main() should be minimal merely showing how inputs are routed to appropriate part of the code. All implementation level details should be off-loaded to appropriate classes/functions.
Submission Schedule:
S# 1 Task Name Design Report a CHART sized UML class diagram listing all the classes you will use in your project and their associated with one another. (50% Weightage of submitted material marks) ZERO marks in the absence of a working code (point 2). 2 Final Submission On SLATE. The submission must include guidelines (readme.txt) on how to use your program plus working code. (50% Weightage of submitted material marks) 27 Apr 12 Submission in class at the start of the class. Deadline Submission deadline
05 May 12
Spr12_RollNo1_RollNo2_RollNo3_P02.zip
P-02
Page 5/5