1answer.
Ask question
Login Signup
Ask question
All categories
  • English
  • Mathematics
  • Social Studies
  • Business
  • History
  • Health
  • Geography
  • Biology
  • Physics
  • Chemistry
  • Computers and Technology
  • Arts
  • World Languages
  • Spanish
  • French
  • German
  • Advanced Placement (AP)
  • SAT
  • Medicine
  • Law
  • Engineering
Alex73 [517]
3 years ago
7

Let CFG G be the following grammar.

Engineering
2 answers:
adoni [48]3 years ago
6 0

Answer:

See Explanation Below

Explanation:

Given

S → aSb | bY | Y a

Y → bY | aY | ε

Giving a simple description of L(G) in English. The description is as follows;

This means that L(G) contains a string of a's and b's such that the following are true;

1. the string starts with n a’s and m b’s, where n and m can be zero, but not at the same time,and at least one of option 2 and option 3

2. and has any number of a’s or b’s followed by an a

3. ab followed by any number of a’s and b’s

Note that n and m represent numerical digits

Using the description to give a CFG for L(G), the complement of L(G) is written as L'(G)

L'G are elements not in L(G) and they are

L'(G) =a^n b (a∪b) * b^n ∪ a^n (a∪b) * ab^n

valentinak56 [21]3 years ago
4 0

Answer:

The answer in the explanation section

Explanation:

The context free grammar is equal to:

S → aSb|bY|Ya

Y → bY|aY|ε

The language L(G) is equal to:

Y → bY

Y → aY

Y → ε

S → aSb

S → bY

S → Ya

If S → Ya, thus:

S → ∈a

S → a

If S → bY:

S → ∈b

S → b

If S → aSb:

S → abYb

S → abbYb

If S → bY:

S → bbY

S → bb∈

S → bb

From all this cases, the languaje is the follow:

L(G)=[a,b,abbb,bb...]

The description of L(G) is:

-strings made up of a consecutive number of a length a, that can vary from 1 to infinity.

-strings made up of a consecutive number of a length b, that can vary from 1 to infinity.

-strings whose start symbol a is followed by number b

-strings whose start symbol b is followed by number a

-strings beginning with the symbol a and ending with the symbol b

-strings beginning with the symbol b and ending with the symbol a

The grammar for L(G) is equal to a^{i} b^{i} if i\geq 0\\

The CFG for L(G) is equal to:

S → aSb|∈

S → abb∈b

S → abbb

You might be interested in
Fix the code so the program will run correctly for MAXCHEESE values of 0 to 20 (inclusive). Note that the value of MAXCHEESE is
GarryVolchara [31]

Answer:

Code fixed below using Java

Explanation:

<u>Error.java </u>

import java.util.Random;

public class Error {

   public static void main(String[] args) {

       final int MAXCHEESE = 10;

       String[] names = new String[MAXCHEESE];

       double[] prices = new double[MAXCHEESE];

       double[] amounts = new double[MAXCHEESE];

       // Three Special Cheeses

       names[0] = "Humboldt Fog";

       prices[0] = 25.00;

       names[1] = "Red Hawk";

       prices[1] = 40.50;

       names[2] = "Teleme";

       prices[2] = 17.25;

       System.out.println("We sell " + MAXCHEESE + " kind of Cheese:");

       System.out.println(names[0] + ": $" + prices[0] + " per pound");

       System.out.println(names[1] + ": $" + prices[1] + " per pound");

       System.out.println(names[2] + ": $" + prices[2] + " per pound");

       Random ranGen = new Random(100);

       // error at initialising i

       // i should be from 0 to MAXCHEESE value

       for (int i = 0; i < MAXCHEESE; i++) {

           names[i] = "Cheese Type " + (char) ('A' + i);

           prices[i] = ranGen.nextInt(1000) / 100.0;

           amounts[i] = 0;

           System.out.println(names[i] + ": $" + prices[i] + " per pound");

       }        

   }

}

7 0
3 years ago
Can a 1½ " conduit, with a total area of 2.04 square inches, be filled with wires that total 0.93 square inches if the maximum f
Papessa [141]

Answer:

it is not possible to place the wires in the condui

Explanation:

given data

total area = 2.04 square inches

wires total area = 0.93 square inches

maximum fill conduit =  40%

to find out

Can it is possible place wire in conduit conduit

solution

we know maximum fill is 40%

so here first we get total area of conduit that will be

total area of conduit = 40% × 2.04

total area of conduit = 0.816 square inches

but this area is less than required area of wire that is 0.93 square inches

so we can say it is not possible to place the wires in the conduit

4 0
3 years ago
Birdie Par owns a company that makes golf gloves. She is thinking about introducing a new glove, which would require an addition
melamori03 [73]

Birdie's company will make a profit of $30,000 if she sells 3,000 gloves at the $15 price.

Step-by-step Solution:

Break even point= fixed cost/ selling price - variable cost

here the fixed cost is= $20,000

selling price= $15 and variable cost = $5

BEP= 20,000/ 15-5= 20,000/10= 2000 units

b. if they sell 3000 gloves, the contribution profit will be

total revenue= 3000*$15= $45,000

contribution= selling price- variable cost, 15-5= $10 per unit

the profit is= 3000*$10= $30,000

What is  variable cost?

A variable cost is one that varies in relation to either the volume of production or the number of services provided. There should be no variable costs if no production or services are provided. Variable costs should rise in tandem with increases in production or services.

To learn more about Profit Calculation, visit: brainly.com/question/28177180

#SPJ1

3 0
1 year ago
A gas turbine receives a mixture having the following molar analysis: 10% CO2, 19% H2O, 71% N2 at 720 K, 0.35 MPa and a volumetr
Sliva [168]

Answer:

2074.2 KW

Explanation:

<u>Determine power developed at steady state </u>

First step : Determine mass flow rate  ( m )

m / Mmax = ( AV )₁ P₁ / RT₁   -------------------- ( 1 )

<em> where : ( AV )₁ = 8.2 kg/s,  P₁ = 0.35 * 10^6 N/m^2,   R = 8.314 N.M / kmol , </em>

<em>  T₁  = 720 K . </em>

insert values into equation 1

m  = 0.1871  kmol/s  ( mix )

Next : calculate power developed at steady state ( using ideal gas tables to get the h values of the gases )

W( power developed at steady state )

W = m [ Yco2 ( h1 - h2 )co2

Attached below is the remaining  part of the detailed solution

4 0
3 years ago
If a vacuum gau ge reads 9.62 psi, it means that: a. the very highest column of mercury it could support would be 19.58 inches.
scZoUnD [109]

Answer:All of the above

Explanation:

9.62 psi means 497.49 mm of Hg pressure

for (a)19.58 inches is equals to 497.49 mm of Hg

(b)atmospheric pressure is 14.69 psi

vaccum gauge is 9.62psi

absolute pressure is=14.69-9.62=5.07

(c)vaccum means air is sucked and there is negative pressure so it tells about below atmospheric pressure.

thus all are correct

8 0
3 years ago
Other questions:
  • Explain how a CO2 cartridge powers the dragster you will be building. A good website to use is How Stuff Works. (howstuffworks.c
    5·2 answers
  • Refrigerant-134a enters a diffuser steadily as saturated vapor at 600 kPa with a velocity of 160 m/s, and it leaves at 700 kPa a
    10·2 answers
  • Wastewater flows into a _________ once it is released into a floor drain.
    8·1 answer
  • An ideal reheat Rankine cycle with water as the working fluid operates the boiler at 15,000 kPa, the reheater at 2000 kPa, and t
    13·1 answer
  • The information on a can of pop indicates that the can contains 360 mL. The mass of a full can of pop is 0.369 kg, while an empt
    14·1 answer
  • This elementary problem begins to explore propagation delayand transmission delay, two central concepts in data networking. Cons
    6·1 answer
  • For the Mohr's circle of a plane-strain element, which of the following changes as a result of shear strain change?
    7·1 answer
  • What type of fuel does a 2 cycle engine use
    5·1 answer
  • Alguém para conversa
    13·1 answer
  • Rivet gauge, or transverse pitch is the distance between the Group of answer choices heads of rivets in the same row. centers of
    11·1 answer
Add answer
Login
Not registered? Fast signup
Signup
Login Signup
Ask question!