Answer:
point_dist = math.sqrt((math.pow(x2 - x1, 2) + math.pow(y2 - y1, 2))
Explanation:
The distance formula is the difference of the x coordinates squared, plus the difference of the y coordinates squared, all square rooted. For the general case, it appears you simply need to change how you have written the code.
point_dist = math.sqrt((math.pow(x2 - x1, 2) + math.pow(y2 - y1, 2))
Note, by moving the 2 inside of the pow function, you have provided the second argument that it is requesting.
You were close with your initial attempt, you just had a parenthesis after x1 and y1 when you should not have.
Cheers.
Answer:
Algorith does not work.
Explanation:
One of the ways to obtain the Dekker Algorithm is through a change in the declaration, that is, a declaration that can be executed at the exact moment it leaves the critical section. This way it is possible that the statement,
turn = 1-i / * P0 sets turn to 1 and P1 sets turn 0 * /
It can be changed to,
turn = (turn +1) \% n / * n = number or processes * /
The result will allow to define if it works or not, that is, if it is greater than 2 the algorithm will not be able to work.
Given this consideration we can say that,
<em>- The dead lock does not occur, because the mutual is imposed (if a resource unit has been assigned to a process, then no other process can access that resource).</em>
<em>- There is the possibility of starving if the shift is established in a non-contentious process.</em>
Directly it can be concluded that there is a possibility of starvation so the algorithm could not work, despite the fact that mutual exclusion guarantees that a dead block does not occur.
Answer:
Electroosmotic velocity will be equal to 
Explanation:
We have given applied voltage v = 100 volt
Length of capillary L = 5 mm = 0.005 m
Zeta potential of the capillary surface 
Dielectric constant of glass is between 5 to 10 here we are taking dielectric constant as 
Viscosity of glass is 
Electroosmotic velocity is given as 

So Electroosmotic velocity will be equal to 
Answer:
In engineering, the most basic or primary unit of measurement used for drafting is the <u>millimeter</u> and the <u>meter</u>, followed by the <u>kilometer</u>
Explanation:
Based on the the SI system of units, in engineering, the most basic or primary unit of measurement used for drafting is the millimeter and the meter, followed by the kilometer
The millimeter is used in mechanical and an architectural drawing, the meter is used architectural drawing, while civil dimensioning make use of the kilometer
In the US it is customary to use the inches and a fraction of an inch is used as a scale in scale drawings