QP 32177903

Download as pdf or txt
Download as pdf or txt
You are on page 1of 4

Unique Paper Code : 32177903

Name of the Paper : DSE-II Applications of Computers in Chemistry

Name of the Course : B.Sc.(Hons.) Chemistry

Semester :V

Duration : 3 hours

Maximum Marks : 75

Instructions for Candidate


1. Attempt only Four Questions.
2. Question Number 1 is compulsory. Attempt any three questions out of remaining five
questions.
3. Attempt all parts of a question together.

1. Attempt all parts.

a. Explain the following terms


i. Operating System
ii. Debugging
iii. ASCII code

b. Write the full form of the following abbreviations


i. QBASIC
ii. PIXEL
iii. ALU
iv. BIT

c. Write the following algebraic expressions in BASIC


i. 𝐻 = 𝑎𝑛𝑡𝑖𝑙𝑜𝑔(−𝑝𝐻)
𝑛𝑅𝑇 𝑎𝑛2
ii. 𝑝 = 𝑉−𝑛𝑏 − 𝑉2
𝑛2 ℎ 2
iii. 𝐸 = 8𝑚𝑙2
iv. 𝐶 = 𝐴𝑒 −𝑘𝑇

d. Identify and correct the incorrect numeric/string variables (IF ANY)?


i. END
ii. M5
iii. J$6
iv. 2VOL!
v. P*5
vi. PI$
vii. A1
viii. XY%
(3,4,4,4)
2.
a. Write a program in BASIC to calculate cosine series for x=-1 till the contribution
is less than 0.0001
𝑥2 𝑥4 𝑥6 𝑥𝑛
Given: cos(𝑥) = 1 − + − + ⋯ . 𝑛!
2! 4! 6!

b. Write a program in BASIC to read, print and carry out the transpose of following
matrix
3 4 5
|6 7 8|
1 7 9
Note that the printing is to be done along with vertical line whose ASCII value
in decimal is 179.
(10,10)
3.
a. Identify the errors in the following program. Write the correct program.
20 CLS: SCREEN ‘640*480
25 LOCATE (5,25): PRINT IDEAL GAS ISOTHERMS
30 VIEW (-100,100) - (500,400) ,,7
40 FOR T=200 TO 500 STEP 20
50 FOR V= 0.05 TO 0.5 STEP .0001
60 P=0.0821 *T/V
65 PSET V,P
70 NEXT T
80 END

b. Identify which of the following statements, if any are written incorrectlyand write
their correct form
i. ON N$ GOTO 10, 20, 30
ii. IF X^2 < 0 THEN 20
iii. FOR I = 10 TO 0 STEP 2
iv. IF X < A+B THEN 55 ELSE 72
v. FOR K$= 1 TO L STEP2
vi. DEF FN(X)= X^4 – Z^3

c. Write a program in BASIC to assign “CHEMICAL THERMODYNAMICS”to


string variable A$, extracting required string constants from A$ using onlystring
functions/commands print “THERMODYNAMICS CHEMICAL” (Note-None
other string constants to be used).
(6,6,8)
4.
a. Convert the following
i. (422.125)10 to binary.
ii. (11101.1101)2 to decimal.
b. What is the difference between computer screen coordinates and world
coordinates? Give the syntax for changing screen coordinates to world
coordinates.
c. Write a program to find the slope (m) and intercept (c) of the straight-line
equation Y = mX + c for a set of discrete X, Y data points. Total number ofdata
points are N in number. Provide the data using INPUT statement. Use the
following expressions.
𝑛 ∑ 𝑥𝑖 𝑦𝑖 −∑ 𝑥𝑖 ∑ 𝑦𝑖 ∑ 𝑦𝑖 ∑ 𝑥𝑖 2 −∑ 𝑥𝑖 ∑ 𝑥𝑖 𝑦𝑖
slope= 2 𝑎𝑛𝑑 𝑖𝑛𝑡𝑒𝑟𝑐𝑒𝑝𝑡 = 2
𝑛 ∑ 𝑥𝑖 2 −∑ 𝑥𝑖 𝑛 ∑ 𝑥𝑖 2 −∑ 𝑥𝑖

d. Identify the errors in the following Basic Numbers. Also write the correctform for
the incorrect one.
i. 7,102
ii. 4.63E – 0.8
iii. + - 4251
iv. 2.6E + 2
v. Rs123
vi. 6.91
vii. -6.8 × 10-5
viii. 456V3
(4,4,8,4)

5.
a. Differentiate between relational and logical operators.
Let X=1 and Y=2. Determine whether the following relational expressions is true
or false
i. 2*X+Y^2 > Y+3
ii. X > Y OR X > 0 AND Y < 0

b. Explain Simpson’s 1/3 rule for numerical integration. Write a program to


determine the enthalpy asgiven by the expression
𝑇2

∆𝐻 = ∫ (𝐴 + 𝐵𝑇 + 𝐶𝑇 2 )𝑑𝑇
𝑇1
c. Using sorting, write a program in BASIC to arrange the following student’s names
in alphabetical order along with their CGPA
Student Name CGPA
KESHAV 7.5
AMITA 8.8
MEGHA 6.4
DHRUV 8.5
TEENA 7.0
What will be the change required in the program in order to sort the resultin
ascending order of CGPA?
(10,5,5)

6.
a. Write a program in BASIC to find the change in enthalpy (H) of SO2 when the
temperature changes from 300 K to 1100 K using trapezoidal rule and the
following data
T/K 300 500 700 900 1100

Cp/J K-1 mol-1 39.9 46.5 50.8 53.4 54.9

Given that
𝑇2
∫ 𝑑𝐻 = ∫ 𝐶𝑝 𝑑𝑇
𝑇1
What will be the output of above program? Report the value of H.

b. Define subroutines. Write a program in BASIC to read, print and calculatethe


average values of pressure, volume and temperature using subroutine. Given data
Pressure (atm) 26.95 78.55 70.36 88.31 110.46
3
volume (dm ) 0.1 0.3 0.5 0.7 0.9
temperature (K) 273 373 473 573 673
(10,10)

You might also like