Enable contrast version

# Tutor profile: Srijan A.

Inactive
Srijan A.
Machine Learning Engineer at Quantiphi Analytics
Tutor Satisfaction Guarantee

## Questions

### Subject:Physics (Electricity and Magnetism)

TutorMe
Question:

Is Kirchhoff's Law applicable for non conservative electric fields?

Inactive
Srijan A.

It is not an issue of the field being conservative or not. Ultimately, Kirchhoff's laws are about the relationship between branch currents and node voltages in a network of lumped circuit elements. If you define three kinds of branch elements denoted by R,C,L using the relationships v=Ri , i=C(dv/dt), and v=L(di/dt), respectively, then you may freely use Kirchhoff's current and voltage laws. These defining relationships between voltage and current are idealization and simplification not just for an inductor but also for a capacitor and resistor, as well. In the case of the inductor we ignore all fields outside the coil, and if we cannot because we have an inductive transformer then we include that part explicitly by defining a two-port with a pair of equations, such as v1=L11(di1/dt)+L12(di2/dt) and v2=L12(di1/dt)+L22(di2/dt), and a similar set of equations if you need more ports than two. If the capacitor is physically large then we may encounter problems with the current continuity law and will not be able to neglect the displacement current. Note too that in no sense one could claim that the fields of a voltage or current generator are "conservative", not even for a battery: electrochemistry is not electrostatics. Somewhere, somehow you must impose a phenomenon that is outside of electricity or magnetism. Instead we postulate that certain node pairs have a predefined voltage history, and a given branch has a predefined current history independently of the rest of the circuit and thus represent a voltage or a current source, resp. In other words sources are time dependent boundary conditions. This way as you go around in a loop you must always get 0 voltage, no conservative field is needed. At the next level of abstraction you only need that in an arbitrary loop at any instant every connecting wire the current must be the same. And assuming linear superposition you can derive that the sum of branch currents at any node must be zero. So then the only questions is whether a loop is physically small enough so that the current uniformity holds. Once you have picked the defining lumped element equations between v and i you may say that KVL and KIL have more to do with network topology than actual physics.

### Subject:C Programming

TutorMe
Question:

Is there any problem with the following code?If yes, then how it can be rectified? #include<stdio.h> int* inc(int val) { int a = val; a++; return &a; } int main(void) { int a = 10; int *val = inc(a); printf("\n Incremented value is equal to [%d] \n", *val); return 0; }

Inactive
Srijan A.

Though the above program may run perfectly fine at times but there is a serious loophole in the function ‘inc()’. This function returns the address of a local variable. Since the life time of this local variable is that of the function ‘inc()’ so after inc() is done with its processing, using the address of its local variable can cause undesired results. This can be avoided by passing the address of variable ‘a’ from main() and then inside changes can be made to the value kept at this address.

### Subject:Artificial Intelligence

TutorMe
Question:

‘Customers who bought this also bought this…’ we often see this when we shop on Amazon. What is the logic behind recommendation engines?

Inactive
Srijan A.

E-commerce websites like Amazon make use of Machine Learning to recommend products to their customers. The basic idea of this kind of recommendation comes from collaborative filtering. Collaborative filtering is the process of comparing users with similar shopping behaviors in order to recommend products to a new user with similar shopping behavior. To better understand this, let’s look at an example. Let’s say a user A who is a sports enthusiast bought, pizza, pasta, and a coke. Now a couple of weeks later, another user B who rides a bicycle buys pizza and pasta. He does not buy the coke, but Amazon recommends a bottle of coke to user B since his shopping behaviors and his lifestyle is quite similar to user A. This is how collaborative filtering works.

## Contact tutor

Send a message explaining your
needs and Srijan will reply soon.
Contact Srijan

## Request lesson

Ready now? Request a lesson.
Start Lesson

## FAQs

What is a lesson?
A lesson is virtual lesson space on our platform where you and a tutor can communicate. You'll have the option to communicate using video/audio as well as text chat. You can also upload documents, edit papers in real time and use our cutting-edge virtual whiteboard.
How do I begin a lesson?
If the tutor is currently online, you can click the "Start Lesson" button above. If they are offline, you can always send them a message to schedule a lesson.
Who are TutorMe tutors?
Many of our tutors are current college students or recent graduates of top-tier universities like MIT, Harvard and USC. TutorMe has thousands of top-quality tutors available to work with you.