Saturday 26 September 2020

Revision Notes on Thermodynamics

 

  • Thermodynamics:- It is the branch of physics which deals with process involving heat, work and internal energy. Thermodynamics is concerned with macroscopic behavior rather than microscopic behavior of the system.

  • Basic Terminology:-

System

Part of the universe under investigation.

Open System

A system which can exchange both energy and matter with its surroundings.

Closed System

A system which permits passage of energy but not mass, across its boundary.

Isolated system

A system which can neither exchange energy nor matter with its surrounding.

Surroundings

Part of the universe other than system, which can interact with it.

Boundary

Anything which separates system from surrounding.

State variables

The variables which are required to be defined in order to define state of any system i.e. pressure, volume, mass, temperature, surface area, etc.

State Functions

Property of system which depend only on the state of the system and not on the path.

Example: Pressure, volume, temperature, internal energy, enthalpy, entropy etc.

Intensive properties

Properties of a system which do not depend on mass of the system i.e. Temperature, pressure, density, concentration,

Extensive properties

Properties of a system which depend on mass of the system i.e. Volume, energy, enthalpy, entropy etc.

Process

Path along which state of a system changes.

Isothermal process

Process which takes place at constant temperature

Isobaric process

Process which takes place at constant pressure

Isochoric process

Process which takes place at constant volume.

Adiabatic process

Process during which transfer of heat cannot take place between system and surrounding.

Cyclic process

Process in which system comes back to its initial state after undergoing series of changes.

Reversible process

Process during which the system always departs infinitesimally from the state of equilibrium i.e. its direction can be reversed at any moment.

 

  • Kinetic Energy:- Energy possessed  by the atoms or molecules by virtue of their motion  is called kinetic energy.

  • Internal Energy (ΔU):- Sum total of kinetic and potential energies of atoms/molecules constituting a system is called the internal energy of the system.

(a) ΔU is taken as positive if the internal energy of the system increases.

(b) ΔU is taken as negative if the internal energy of the system decreases.

  • Heat:- Heat is the part of internal energy which is transferred from one body to another an account of the temperature difference.
  • Work:- Work is said to be done when a force acting on a system displaces the body in its own direction.

dW = Fdx = PdV

W = P(V-Vi)

(a) If the gas expands, work is said to be done by the system. In this case V> Vi, therefore, W will be positive.

(b) If the gas is compressed, work is said to be done on the system. In this case Vf  < Vi, therefore, work done is negative.

  • Thermodynamic variables or parameters:- The thermodynamic state of system can be determined by quantities like temperature (T), volume (V), pressure (P), internal energy (U) etc. These quantities are known as thermodynamic variables, or the parameters of the system.

  • Equation of state:- A relation between the values of any of the three thermodynamic variables for the system, is called its equation of state.

Equation of state for an ideal gas is PV = RT

  • Equilibrium of a system:- A system is said to be in equilibrium if its macroscopic quantities do not change with time.

  • Relation between joule and calorie:- 1 joule = 4.186 cal

  • First law of thermodynamics:- If the quantity of heat supplied to a system is capable of doing work, then the quantity of heat absorbed by the system is equal to the sum of the increase in the internal energy of the system, and the external work done by it.

dQ = dU+dW

  • Thermodynamic Process:- A process by which one or more parameters of thermodynamic system undergo a change is called a thermodynamic process or a thermodynamic change.

P-V diagram of isothermal, isobaric, isochoric and adiabatic process in a single figure.

(a) Isothermal process:- The process in which change in pressure and volume takes place at a constant temperature, is called a isothermal change. It may be noted that in such a change total amount of heat of the system does not remain constant.

(b) Isobaric process:- The process in which change in volume and temperature of a gas take place at a constant pressure is called an isobaric process.

(c) Isochoric process:- The process in which changes in pressure and temperature take place in such a way that the volume of the system remains constant, is called isochoric process.

(d) Adiabatic process:- The process in which change in pressure and volume and temperature takes place without any heat entering or leaving the system is called adiabatic change.

(e) Quasi-static process:- The process in which change in any of the parameters take place at such a slow speed that the values of P,V, and T can be taken to be, practically, constant, is called a quasi-static process.

(f) Cyclic process:- In a system in which the parameters acquire the original values, the process is called a cyclic process.

(g) Free expansion:- Such an expansion in which no external work is done and the total internal energy of the system remains constant is called free expansion.

  • Reversible isothermal and adiabatic curve:-

  Reversible isothermal and adiabatic curve

  • Application of first law of thermodynamics:-

(a) Cooling caused in adiabatic process:- dT = PdV/Cv

(b) Melting:- dU = mLf

(c) Boiling:dU = mLv – P(V-Vi)

(d) Mayer’s formula:- CCv = R

  • Specific heat capacity of gases:- Specific heat capacity of a substance is defined as the amount of heat required to raise the temperature of a unit mass of substance through 1ºC.

(a) Specific heat capacity at constant volume (cv):- Specific heat capacity at constant volume is defined as the amount of heat required to raise the temperature of 1 g of the gas through 1ºC keeping volume of the gas constant.

Molar specific heat capacity, at constant volume (Cv), is defined as the amount of heat required to raise the temperature of 1 mole of gas through 1ºC keeping its volume constant.

CvMcv

(b) Specific heat capacity at constant pressure (cp):- Specific heat capacity, at constant pressure, is defined as the amount of heat required to raise the temperature of 1 g of gas through 1ºC keeping its pressure constant.

Gram molecular specific heat capacity of a gas (Cp), at constant pressure, is defined as the amount of heat required to raise the temperature of 1 mole of the gas through 1ºC keeping its pressure constant.

Cp = Mcp

  • Difference between two specific heat capacities – (Mayer’s formula):-

(a) C- Cv = R/J

(b) For 1 g of gas, ccv = r/J

(c) Adiabatic gas constant, γ = Cp/ Cv = cp/ cv

  • Relation of Cv with energy:-

Cv= 1/m (dU/dT)

(a) Mono-atomic gas (3 degree of freedom):-

Total energy, U = mN 3 [(1/2) KT], Here m is the number of moles of the gas and N is the Avogadro’s number.

Cv = (3/2) R

C= (5/2) R

γ Cp/ Cv = 5/3 = 1.67

(b) Diatomic gas:-

At very low temperature, Degree of Freedom (DOF) = 3

U = (3/2) mRT

Cv = (3/2) R Cp = (5/2) R

γCp/ Cv = 5/3 = 1.67

At medium temperature, DOF = 5

U = (5/2) mRT

Cv = (5/2) R Cp = (7/2) R

γ Cp/ Cv = 7/5 = 1.4

At high temperature, DOF = 7

U = (7/2) mRT

Cv = (7/2) R Cp = (9/2) R

γ Cp/ Cv = 9/7 = 1.29

  • Adiabatic gas equation:- PV γ = Constant

(a) Equation of adiabatic change in terms of T and V:- TV γ-1 = Constant

(b) Equation of adiabatic change in terms of P and T:- γ P1-γ = Constant

  • Comparison of slopes of an isothermal and adiabatic:-

Isothermal and adiabatic curve

(a) Slope of isothermal:- dP/dV = -P/V

(b) Slope of adiabatic:- dP/dV = -γP/V

(c) Adiabatic gas constant:- γ = Cp/Cv

As, Cp>Cv, So, γ>1

This signifies that, slope of adiabatic curve is greater than that of isothermal.

  • Slope on PV diagram:-

(a) For isobaric process: zero

(b) For isochoric process: infinite

  • Work done for isobaric process:- W = P(V2-V1)

  • Work done in an isothermal processWork done for isochoric process:- W = 0
  • Work done in isothermal expansion and compression:-

            ?W = 2.3026 RT log10Vf/Vi  (isothermal expansion)

W = - 2.3026 RT log10Vf/Vi  (isothermal compression)

  • Work done during an adiabatic expansion:-

Work done during an adiabatic expansion

K/1-γ [Vf1-γ – Vi 1-γ] = 1/1-γ [P2V2-P1V1] = R/1- γ [T2-T1]

  • Adiabatic constant (γ):- γ = Cp/Cv = 1+2/f, Here f is the degrees of freedom.

  • Work done in expansion from same initial state to same final volume:-

  • Wadiabatic < Wisothermal < Wisobaric

  • Work done in compression from same initial state to same final volume:-

Wadiabatic < Wisothermal < Wisobaric

  • Reversible process:- It is a process which can be made to proceed in the reverse direction by a very slight change in its conditions so that the system passes through  the same states as in direct process, and at the conclusion of which the system and its surroundings acquire the initial conditions.

Example:- All isothermal and adiabatic process when allowed to proceed slowly, are reversible, provided there is no loss of energy against any type of resistance. Friction, viscosity are other examples.

  • Irreversible process:- A process which cannot be made to be reversed in opposite direction by reversing the controlling factor is called an irreversible process.

Example:-

(a) work done against friction

(b) Joule’s heating effect

(c) Diffusion of gases into one another

(d) Magnetic hysteresis

  • Heat engine:- It is a device used to convert heat into mechanical energy

(a) Work done, W = Q1-Q2

(b) Efficiency:- Efficiency η of an engine is defined as the fraction of total heat, supplied to the engine which is converted into work.

ηW/ Q1 = [Q1- Q2]/ Q1 = 1-[Q2/Q1]

  • Carnot engine – Carnot’s reverse cycle:-

(a) First stroke (isothermal expansion):- W1RT1 loge[V2/V1]

(b) Second stroke (adiabatic expansion):- W2R/γ-1 [T1-T2]

(c) Third stroke (isothermal compression):- W3RT2 logeV3/V4

(d) Fourth stroke (adiabatic compression):- W4R/γ-1 [T1-T2]

(e) Total work done in one cycle, W = W1+ W2+ W3+ W4 = R (T1-T2) loge (V2/V1)

  • Efficiency of Carnot engine:- Efficiency η of an engine is defined as the ratio between useful heat (heat converted into work) to the total heat supplied to the engine.

η = W / Q1 = [Q1- Q2]/ Q1 = 1-[Q2/Q1] = 1- T2/T1

  • Second law of thermodynamics:-

(a) Clausius statement:- Heat cannot flow from a cold body to a hot body without the performance of work by some external agency.

(b) Kelvin’s statement:- It is impossible to obtain a continuous supply of energy by cooling a body below the coldest of its surroundings.

(c) Planck’s statement:- It is impossible to extract heat from a single body and convert the whole of it into work.

  • Refrigerator:- It is a device which is used to keep bodies at a temperature lower than that of surroundings.
  • Coefficient of performance (β):- Coefficient of performance of a refrigerator is defined as the amount of heat removed per unit work done on the machine.

β = Heat removed/work done = Q2/W = Q2/[Q1- Q2] = T2/[T1- T2]

Coefficient of performance of a refrigerator is not a constant quantity since it depends upon the temperature of body from which the heat is removed.

For a perfect refrigerator, W = 0 or Q1= Q2 or β =∞

  • Mean free path:- λ= 1/√2πd2ρn

Here ρn = (N/V) = number of gas molecules per unit volume

d = diameter of molecules of the gas.

  • Heat added or removed:-

(a) For isobaric process:- Q = n CpΔT

(b) For isochoric process:- Q = n CvΔT

(c)For isothermal process:- Q = nRT loge (V2/V1)

(d) For adiabatic process: Q = 0

  • Change in internal energy:-

(a) For isobaric process, ΔU = n CpΔT

(b) For isobaric process, ΔU = n CvΔT

(c) For isothermal process, ΔU = 0

(d) For adiabatic process, ΔU = -W = [nR (T2-T1)]/(γ-1)

  • Mixture of gases:- n = n1+n2

M = n1M1+n2M2/ n1+ n2 = N1m1+N2m2/N1+N2

C_{v}= \frac{n_{1}C_{v_{1}}+n_{2}C_{v_{2}}}{n_{1}+n_{2}}

and

C_{p}= \frac{n_{1}C_{p_{1}}+n_{2}C_{p_{2}}}{n_{1}+n_{2}}

  • Enthalpy (H):-

(a) H = U+PV

(b) At constant pressure:-

dH = dU + pdV

(c) For system involving mechanical work only:-

dH = Q(At constant pressure)

(d) For exothermic reactions:-

dH is negative

(e) For endothermic reactions:-

dH is positive

  • Relation between dH and dU:-

dH = dU + dng RT

Here, dng = (Number of moles of gaseous products - Number of moles of gaseous reactants)

Friday 25 September 2020

Result 25 Sept Python Test

 

Result 25 Sept Python Test


For Complete Video course of CS and IP of class 11 and 12 Download and Install "S P SHARMA CLASSES" Android App Now

https://play.google.com/store/apps/details?id=com.classcast.spsharmaclasses


















Thursday 24 September 2020

Graph

 Graph

Graph:

Graph is a non-linear data structure

It consists of a finite set of nodes (or vertices) and a set of edges connecting nodes.

pair (x,y) is referred to as an edge, which communicates that the x vertex connects to the y vertex.

G=(V,E)

V={v1,v2,...............vn}

E={e1,e2,.............en}

Edge: 

An edge connects two vertices.

Circles represent vertices, while lines represent edges.


Graphs are used to solve real-life problems that involve representation of the problem space as a network. Examples of networks include telephone networks, circuit networks, social networks (like LinkedIn, Facebook etc.).

For example, a single user in Facebook can be represented as a node (vertex) while their connection with others can be represented as an edge between nodes.

Each node can be a structure that contains information like user’s id, name, gender, etc.


Types of graphs:

Undirected Graph:

In an undirected graph, nodes are connected by edges that are all bidirectional. For example if an edge connects node 1 and 2, we can traverse from node 1 to node 2, and from node 2 to 1.

An undirected graph can have at most n(n-1)/2 edges.

Directed Graph

In a directed graph, nodes are connected by directed edges – they only go in one direction. For example, if an edge connects node 1 and 2, but the arrow head points towards 2, we can only traverse from node 1 to node 2 – not in the opposite direction.
directed graph can have at most n(n-1) edges, where n is the number of vertices.

Sparse Graph

graph in which the number of edges is much less than the possible number of edges.
Sparse graph is a graph in which the number of edges is close to the minimal number of edges.


Dense graph


 A dense graph is a graph in which the number of edges is close to the maximal number of edges.


Simple Graph

graph with no loops and no parallel edges is called a simple graph.

The maximum number of edges possible in a single graph with 'n' vertices is nC2 where nC2 = n(n – 1)/2.

Degree of Vertex of a Graph

Degree of vertex can be considered under two cases of graphs −

  • Undirected Graph
  • Directed Graph

Degree of Vertex in an Undirected Graph

An undirected graph has no directed edges. Consider the following examples.

Example 1

Take a look at the following graph −




In the above Undirected Graph,

  • deg(a) = 2, as there are 2 edges meeting at vertex 'a'.

  • deg(b) = 3, as there are 3 edges meeting at vertex 'b'.

  • deg(c) = 1, as there is 1 edge formed at vertex 'c'

    So 'c' is a pendent vertex.

  • deg(d) = 2, as there are 2 edges meeting at vertex 'd'.

  • deg(e) = 0, as there are 0 edges formed at vertex 'e'.

    So 'e' is an isolated vertex.

Example 2

Take a look at the following graph −

Undirected Graph 1

In the above graph,

deg(a) = 2, deg(b) = 2, deg(c) = 2, deg(d) = 2, and deg(e) = 0.

The vertex 'e' is an isolated vertex. The graph does not have any pendent vertex.


Indegree of a Graph

  • Indegree of vertex V is the number of edges which are coming into the vertex V.

  • Notation − deg(V).

Outdegree of a Graph

  • Outdegree of vertex V is the number of edges which are going out from the vertex V.

  • Notation − deg+(V).

Consider the following examples.


Example 1

Take a look at the following directed graph. Vertex 'a' has two edges, 'ad' and 'ab', which are going outwards. Hence its outdegree is 2. Similarly, there is an edge 'ga', coming towards vertex 'a'. Hence the indegree of 'a' is 1.

Directed Graph

The indegree and outdegree of other vertices are shown in the following table −

VertexIndegreeOutdegree
a12
b20
c21
d11
e11
f11
g02

Example 2

Take a look at the following directed graph. Vertex 'a' has an edge 'ae' going outwards from vertex 'a'. Hence its outdegree is 1. Similarly, the graph has an edge 'ba' coming towards vertex 'a'. Hence the indegree of 'a' is 1.

Directed Graph 1

The indegree and outdegree of other vertices are shown in the following table −

VertexIndegreeOutdegree
a11
b02
c20
d11
e11



 






Regular graph

a regular graph is a graph where each vertex has the same number of neighbors; i.e. every vertex has the same degree or valency

Eulerian Graph

graph is considered Eulerian if the graph is both connected and has a closed trail (a walk with no repeated edges) containing all edges of the graph. Definition: An Eulerian Trail is a closed walk with no repeated edges but contains all edges of a graph and return to the start vertex.

The Seven Bridges of Königsberg











"Find a trail starting at one of the four islands (ABC, or D) that crosses each bridge exactly once in which you return to the same island you started on."









Determining if a Graph is Eulerian

We will now look at criterion for determining if a graph is Eulerian with the following theorem.

Theorem 1: A graph G=(V(G),E(G)) is Eulerian if and only if each vertex has an even degree.

Consider the graph representing the Königsberg bridge problem. Notice that all vertices have odd degree:

VertexDegree
A3
B5
C3
D3



Graph MCQ - 1


Graph MCQ - 1


1- Which of the following data structure is nonlinear type? 

A). Strings 

B). Lists 

C). Stacks 

D). Graph


2- Which of the following is nonlinear data structure? 

A). Stacks 

B). List 

C). Strings 

D). Trees 


Herder node is used as sentinel in ….. 

A). Graphs 

B). Stacks 

C). Binary tree 

D). Queues 


3- Which of the following statements for a simple graph is correct? 

A). Every path is a trail 

B). Every trail is a path 

C). Every trail is a path as well as every path is a trail 

D). None of the mentioned


4- In the given graph identify the cut vertices.











A). B and E 

B). C and D 

C). A and E 

D). C and B


5- For the given graph (G), which of the following statements is true?












A). G is a complete graph 

B). G is not a connected graph 

C). The vertex connectivity of the graph is 2

D). The edge connectivity of the graph is 1


6- What is the number of edges present in a complete graph having n vertices? 

A). (n*(n+1))/2 

B). (n*(n-1))/2 

C). N 

D). Information given is insufficient


7- The given Graph is regular.











A). True 

B). False


8- A connected planar graph having 6 vertices, 7 edges contains _____________ regions.

A). 15 

B). 3 

C). 1 

D). 11 


9- Which of the following properties does a simple graph not hold? 

A). Must be connected 

B). Must be un-weighted 

C). Must have no loops or multiple edges 

D). All of the mentioned


10- What is the maximum number of edges in a bipartite graph having 10 vertices? 

A). 24 

B). 21 

C). 25 

D). 16


11- For a given graph G having v vertices and e edges which is connected and has no cycles, which of the following statements is true? 

A). v=e 

B). v = e+1 

C). v + 1 = e 

D). None of the mentioned


12- For which of the following combinations of the degrees of vertices would the connected graph be Eulerian?


A). 1, 2, 3

B). 2,3,4 

C). 2,4,5 

D). 1,3,5


13- A graph with all vertices having equal degree is known as a __________ 

A). Multi Graph 

B). Regular Graph 

C). Simple Graph 

D). Complete Graph 


14- Which of the following ways can be used to represent a graph? 

A). Adjacency List and Adjacency Matrix 

B). Incidence Matrix 

C). Adjacency List, Adjacency Matrix as well as Incidence Matrix 

D). None of the mentioned 


15- The number of elements in the adjacency matrix of a graph having 7 vertices is __________ 

A). 7 

B). 14 

C). 36 

D). 49 


16- If A[x+3][y+5] represents an adjacency matrix, which of these could be the value of x and y. 

A). x=5, y=3 

B). x=3, y=5 

C). x=3, y=3 

D). x=5, y=5


Sunday 20 September 2020

 

Tree Traversals    

1 - What is common in three different types of traversals (Inorder, Preorder and Postorder)?

A Root is visited before right subtree
B Left subtree is always visited before right subtree
C Root is visited after left subtree
D All of the above
E None of the above

2 - The inorder and preorder traversal of a binary tree are d b e a f c g and a b d e c f g, respectively. The postorder traversal of the binary tree is:

A d e b f g c a

B e d b g f c a

C e d b f g c a

D d e f g b c a


3 - Which of the following pairs of traversals is not sufficient to build a binary tree from the given traversals?


A Preorder and Inorder

B Preorder and Postorder

C Inorder and Postorder

D None of the Above


4 - Which traversal of tree resembles the breadth first search of the graph?


A Preorder

B Inorder

C Postorder

D Level order


5 - Which of the following tree traversal uses a queue data structure?

A Preorder

B Inorder

C Postorder

D Level order


6 - Which of the following cannot generate the full binary tree?

A Preorder and Inorder

B Preorder and Postorder

C Inorder and Postorder

D None of the Above

20 Sep 2020 DS Result


 20 Sep 2020 DS Result