Algorithm Accuracy and Execution Time, CNF and DNF, Derivatives and Exponential Time Hypothesis

ProgrammingCSC344
UKAdelphi University

Algorithm Accuracy and Execution Time, CNF and DNF, Derivatives and Exponential Time Hypothesis

Question

Algorithm accuracy and execution time

The correctness of the algorithm depends on the input. Therefore, to get the desired result, you need to provide the input that the algorithm expects. Otherwise, it will take a long time to run. Even though the execution time of the algorithm is correct, it usually increases or increases with the input size, but it can also change. Examples of execution times include constant, linear, exponential, logarithmic execution time, and quadratic execution time.

(I). Constant execution time – This means that regardless of the input size provided to the function, its time complexity remains the same.

(ii) Linear execution time increases linearly with input size.

(iii) Its operation is expressed as 2^n, where n is the input size, so the exponential execution time increases exponentially.

2^n.n^o(1)

n≧3…. (2^3)((3^o(1))

Since the distance traveled is the input and the time taken is the output, it is possible to draw a distance versus time curve. In the above seller scenario, you should know that this algorithm implements both exponential and constant execution time. Therefore, time is not constant for the traveling salesman, and exponential travel time prevails. Therefore, runtime as output is not effectively false or trusted input. The number of cities he visits does not adjust the travel time, resulting in an exponential curve. Still, the exponential plot suggests that the execution time is the worst case, since the time complexity is not easily compromised regardless of the number of cities visited. a) Create a CNF that computes d(x,y,z).

In computer science, most problems are solved using Boolean formulas in associative and disjunctive normal form. The normal form of the subjunctive expresses expressions as a combination of clauses using AND or OR. When the negation of a false truth assignment occurs, we assume a conjunction (^). This is a negation that represents the usual form of disjunction, representing the disjunction (v) of all satisfied truth assignments.

Let’s express it as d(x,y,z)=xy+yz

You’ll need to find DNF here and disable it later…

-d=(x^-y^z)v(x^-y^-z)v(-x^-y^z) DNF

∆CNF of d= -(DNF)…

Deny DNF and find CNF

CNF=(-x+y-z)^(-x+y+z)^(x+y-z)…then solve to find the subjunctive literal.

CNF=1

B). The first step is to derive a function of ‘f’ whose variables are (y,z,x).

Next, let “x” be a constant.

d(xy)/dx=y

d(xy)=ydx

/ ̄d(xy)=/ ̄ydx

Since x.y=y _/ ̄dx, x.y is the final output of d(y,x).

Δy_/ ̄dx=-(y_/ ̄dx)

Derivation: y_/ ̄dx=yx^x

C).

Here we need to find the satisfiability element and equate it to that variable.

{d,0}

CNF=x^y….Vi=_/ ̄dxy

_/ ̄{d,0,3}

d3=C1^C3…

Δd3=(x1+x2+x3)^(x2+y1)

Sun 3-Sat… Possibility: Var(d3)=(x1+x3+y1)^n/3. 3. Note that the size of a CNF is the number of occurrences of its literal. The size of the smallest CNF that computes the Boolean function f is the smallest

a).For fixed Boolean inputs, show that f(x,y,z)=0 if VLj=0 for some j=1…m.

Find the derivative of f(y,z,x).

d(y,z,x)/dz=yx

d(z,y,z))=y.x.dz….This happens to be the first equation (i).

We need to decompose and solve its satisfiable values ​​using f(jklm).

Let f(jklm)=jk+lm…expand.

=jk+lm=(j+l)^(j+m)^(k+l)^(k+m)

=(z1+z2)^(z1<->jk)^(z2<->lm)

=(z1+z2)^(z1->jk)^(jk->z1)^(z2->lm)^(lm->z2)

B). (x.-(y+z)+u=f(x,y,z).

However, f(x,y,z)=y.x.dz

DNF= -1(y.x.dz)

=-x(y+z)+z(x+y)

=-x(y+z)+zx+yz

The logical product of (x,y,z) is (zx+yz)-x(y+z).

Solution = (z.x+y.z)-1(x.y+x.z)

In your own words, what does the exponential time hypothesis mean?

Time complexity is an algorithm used to represent the time it takes for an algorithm to complete its execution. Exponential time is a computational assumption that applies when finding literal Boolean expressions in associative and disjunctive normal form when polynomial-time problems are not equivalent to nondeterministic problems.

The exponential time hypothesis assumes that, in the worst case, nondeterministic polynomial completeness problems cannot be solved in quasi-exponential time. Therefore, if the exponential time hypothesis is true, it means that the polynomial is not equal to non-deterministic, but it is a strong enough statement to solve and prove the “three satisfiability” problem. will be called. This can be used to show that many computational problems are of comparable complexity, that is, they all work as long as one of them has a time less than or equal to an exponential function.

Similarly, to account for the exponential time hypothesis, we apply the satisfiability problem by bringing the Boolean expression ø into associative normal form when the clause is a conjunction of clauses that are disjuncts of literals . Each literal is either a boolean variable (x) or negation (-x). This algorithm consists of a “K-satisfiability problem”. K-satisfiability tests whether a Boolean expression in associative normal form with at most k variables per clause can be made true by assigning a Boolean value to that variable.

Similarly, K-satisfiability is a nondeterministic polynomial that is hard when k is greater than or equal to 3, so P≠PN indicates that there is no polynomial-time algorithm for k-satisfiability and k≥3. A satisfactory assignment to ø is one with a value of true or false.

Calculate the price of your order

Select your paper details and see how much our professional writing services will cost.

We`ll send you the first draft for approval by at
Price: $36
  • Freebies
  • Format
  • Formatting (MLA, APA, Chicago, custom, etc.)
  • Title page & bibliography
  • 24/7 customer support
  • Amendments to your paper when they are needed
  • Chat with your writer
  • 275 word/double-spaced page
  • 12 point Arial/Times New Roman
  • Double, single, and custom spacing
  • We care about originality

    Our custom human-written papers from top essay writers are always free from plagiarism.

  • We protect your privacy

    Your data and payment info stay secured every time you get our help from an essay writer.

  • You control your money

    Your money is safe with us. If your plans change, you can get it sent back to your card.

How it works

  1. 1
    You give us the details
    Complete a brief order form to tell us what kind of paper you need.
  2. 2
    We find you a top writer
    One of the best experts in your discipline starts working on your essay.
  3. 3
    You get the paper done
    Enjoy writing that meets your demands and high academic standards!

Samples from our advanced writers

Check out some essay pieces from our best essay writers before your place an order. They will help you better understand what our service can do for you.

Get your own paper from top experts

Order now

Perks of our essay writing service

We offer more than just hand-crafted papers customized for you. Here are more of our greatest perks.

  • Swift delivery
    Our writing service can deliver your short and urgent papers in just 4 hours!
  • Professional touch
    We find you a pro writer who knows all the ins and outs of your subject.
  • Easy order placing/tracking
    Create a new order and check on its progress at any time in your dashboard.
  • Help with any kind of paper
    Need a PhD thesis, research project, or a two-page essay? For you, we can do it all.
  • Experts in 80+ subjects
    Our pro writers can help you with anything, from nursing to business studies.
  • Calculations and code
    We also do math, write code, and solve problems in 30+ STEM disciplines.

Frequently asked questions

Get instant answers to the questions that students ask most often.

See full FAQ
    See full FAQ

    Take your studies to the next level with our experienced specialists

    Chat
    Chat
    Hello, we are online 24/7. Leave a message we will reply instantly