Answer:
<E1, E2>.
Explanation:
So, in the question above we are given that the Two Electric field vectors E1 and E2 are perpendicular to each other. Thus, we are going to have the i and the j components for the two Electric Field that is E1 and E2 respectively. That is to say the addition we give us a resultant E which is an arbitrary vector;
E = |E| cos θi + |E| sin θj. -------------------(1).
Therefore, if we make use of the components division rule we will have something like what we have below;
x = |E2|/ |E| cos θ and y = |E1|/|E| sin θ
Therefore, we will now have;
E = x |E2| i + y |E1| j.
The base vectors is then Given as <E1, E2>.
Create an abstract class DiscountPolicy. It should have a single abstract method computeDiscount that will return the discount for the purchase of a given number of a single item. The method has two parameters, count and itemCost. 2. Derive a class BulkDiscount from DiscountPolicy, as described in the previous exercise. It should have a constructor that has two parameters, minimum and percent. It should define the method computeDiscount so that if the quantity purchased of an item is more than minimum, the discount is percent percent. 3. Derive a class BuyNItemsGetOneFree from DiscountPolicy, as described in Exercise 1. The class should have a constructor that has a single parameter n. In addition, the class should define the method computeDiscount so that every nth item is free. For example, the following table gives the discount for the purchase of various counts of an item that costs $10, when n is 3: count 1 2 3 4 5 6 7 Discount 0 0 10 10 10 20 20
4. Derive a class CombinedDiscount from DiscountPolicy, as described in Exercise 1. It should have a constructor that has two parameters of type DiscountPolicy. It should define the method computeDiscount to return the maximum value returned by computeDiscount for each of its two private discount policies. The two discount policies are described in Exercises 2 and 3. 5. Define DiscountPolicy as an interface instead of the abstract class described in Exercise 1.
Answer:
Java Code was used to define classes in the abstract discount policy,The bulk discount, The buy items get one free and the combined discount
Explanation:
Solution
Code:
Main.java
public class Main {
public static void main(String[] args) {
BulkDiscount bd=new BulkDiscount(10,5);
BuyNItemsGetOneFree bnd=new BuyNItemsGetOneFree(5);
CombinedDiscount cd=new CombinedDiscount(bd,bnd);
System.out.println("Bulk Discount :"+bd.computeDiscount(20, 20));
System.out.println("Nth item discount :"+bnd.computeDiscount(20, 20));
System.out.println("Combined discount :"+cd.computeDiscount(20, 20));
}
}
discountPolicy.java
public abstract class DiscountPolicy
{
public abstract double computeDiscount(int count, double itemCost);
}
BulkDiscount.java
public class BulkDiscount extends DiscountPolicy
{
private double percent;
private double minimum;
public BulkDiscount(int minimum, double percent)
{
this.minimum = minimum;
this.percent = percent;
}
at Override
public double computeDiscount(int count, double itemCost)
{
if (count >= minimum)
{
return (percent/100)*(count*itemCost); //discount is total price * percentage discount
}
return 0;
}
}
BuyNItemsGetOneFree.java
public class BuyNItemsGetOneFree extends DiscountPolicy
{
private int itemNumberForFree;
public BuyNItemsGetOneFree(int n)
{
itemNumberForFree = n;
}
at Override
public double computeDiscount(int count, double itemCost)
{
if(count > itemNumberForFree)
return (count/itemNumberForFree)*itemCost;
else
return 0;
}
}
CombinedDiscount.java
public class CombinedDiscount extends DiscountPolicy
{
private DiscountPolicy first, second;
public CombinedDiscount(DiscountPolicy firstDiscount, DiscountPolicy secondDiscount)
{
first = firstDiscount;
second = secondDiscount;
}
at Override
public double computeDiscount(int count, double itemCost)
{
double firstDiscount=first.computeDiscount(count, itemCost);
double secondDiscount=second.computeDiscount(count, itemCost);
if(firstDiscount>secondDiscount){
return firstDiscount;
}else{
return secondDiscount;
}
}
}
A steady green traffic light means
Answer:
Its C. you may proceed, but only if the path is clear
Explanation:
I just gave Quiz and its correct
A refrigerator uses refrigerant-134a as the working fluid and operates on the ideal vapor-compression refrigeration cycle except for the compression process. The refrigerant enters the evaporator at 120 kPa with a quality of 34 percent and leaves the compressor at 70°C. If the compressor consumes 450 W of power, determine (a) the mass flow rate of the refrigerant, (b) the condenser pressure, and (c) the COP of the refrigerator
Answer:
(a) 0.0064 kg/s
(b) 800 KPa
(c) 2.03
Explanation:
The ideal vapor compression cycle consists of following processes:
Process 1-2 Isentropic compression in a compressor
Process 2-3 Constant-pressure heat rejection in a condenser
Process 3-4 Throttling in an expansion device
Process 4-1 Constant-pressure heat absorption in an evaporator
For state 4 (while entering compressor):
x₄ = 34% = 0.34
P₄ = 120 KPa
from saturated table:
h₄ = hf + x hfg = 22.4 KJ/kg + (0.34)(214.52 KJ/kg)
h₄ = 95.34 KJ/kg
For State 1 (Entering Compressor):
h₁ = hg at 120 KPa
h₁ = 236.99 KJ/kg
s₁ = sg at 120 KPa = 0.94789 KJ/kg.k
For State 3 (Entering Expansion Valve)
Since 3 - 4 is an isenthalpic process.
Therefore,
h₃ = h₄ = 95.34 KJ/kg
Since this state lies at liquid side of saturation line, therefore, h₃ must be hf. Hence from saturation table we find the pressure by interpolation.
P₃ = 800 KPa
For State 2 (Leaving Compressor)
Since, process 2-3 is at constant pressure. Therefore,
P₂ = P₃ = 800 KPa
T₂ = 70°C (given)
Saturation temperature at 800 KPa is 31.31°C, which is less than T₂. Thus, this is super heated state. From super heated property table:
h₂ = 306.9 KJ/kg
(a)
Compressor Power = m(h₂ - h₁)
where,
m = mass flow rate of refrigerant.
m = Compressor Power/(h₂ - h₁)
m = (0.450 KJ/s)/(306.9 KJ/kg - 236.99 KJ/kg)
m = 0.0064 kg/s
(b)
Condenser Pressure = P₂ = P₃ = 800 KPa
(c)
The COP of ideal vapor compression cycle is given as:
COP = (h₁ - h₄)/(h₂ - h₁)
COP = (236.99 - 95.34)/(306.9 - 236.99)
COP = 2.03
The Ph diagram is attached
(a) Show how two 2-to-1 multiplexers (with no added gates) could be connected to form a 3-to-1 MUX. Input selection should be as follows: If AB = 00, select I0 If AB = 01, select I1 If AB = 1− (B is a don’t-care), select I2 (b) Show how two 4-to-1 and one 2-to-1 multiplexers could be connected to form an 8-to-1 MUX with three control inputs. (c) Show how four 2-to-1 and one 4-to-1 multiplexers could be connected to form an 8-to-1 MUX with three control inputs
Answer:
Explanation:
a) Show how two 2-to-1 multiplexers (with no added gates) could be connected to form a 3-to-1 MUX. Input selection should be as follows: If AB = 00, select I0 If AB = 01, select I1 If AB = 1− (B is a don’t-care), select I2
We are to show how Two-2-to -1 multiplexers could be connected to form 3-to-1 MUX
If AB = 00 select [tex]I_o[/tex]
If AB = 01 select [tex]I_1[/tex]
If AB = 1_(B is don't care), select [tex]I_2[/tex]
However, the truth table is attached and shown in the first file below.
Also, the free- body diagram for 2- to - 1 MUX is shown in the second diagram attached below.
b) We are show how two 4-to-1 and one 2-to-1 multiplexers could be connected to form an 8-to-1 MUX with three control inputs.
The perfect illustration showing how they are connected in displayed in the third free-body diagram attached below.
Where ; [tex]I_o , I_1, I_2, I_3, I_4, I_5, I_6, I_7[/tex] are the inputs of the multiplexer and Z is the output.
c) Show how four 2-to-1 and one 4-to-1 multiplexers could be connected to form an 8-to-1 MUX with three control inputs.
For four 2-to-1 and one 4-to-1 multiplexers could be connected to form an 8-to-1 MUX with three control inputs, we have a perfect illustration of the diagram in the last( which is the fourth) diagram attached below.
Where ; [tex]I_o , I_1, I_2, I_3, I_4, I_5, I_6, I_7[/tex] are the inputs of the multiplexer and Z is the output
This question is a multiplexer which is a topic in digital circuit.
Multiplexer is a type of combination circuit that consist of a maximum of [tex]2^n[/tex] data inputs 'n' selection lines and single output line. One of these data inputs will be connected to the output based on the values of selection lines. Another name for multiplexers is MUX.
If we have 'n' selection lines, we will get [tex]2^n[/tex] possible combinations zero and ones. Each combination will select a maximum of only one data input.
a)
Two 2-to-1 multiplexers to form a 3-to-1 MUX.
If AB = 00, select [tex]I_o[/tex]
If AB = 01, select [tex]I_1[/tex]
If AB = 1- (B is don't care) select I
The truth table for the above scenario is in the attached document below.
Figure 1 and 2 represents the solution to this question.
b).
Two 4-to-1 multiplexers and one 2-to-1 multiplexers and one 2-to-1 multiplexers are used to form an 8-to-1 MUX.
In the attached diagram, figure 3 shows a comprehensive detail of how it is structured.
Where [tex]I_o[/tex] to [tex]I_7[/tex] are the inputs of the multiplexer and Z is the output.
c) Four 2-to-1 multiplexers and one 4-to -1 multiplexer are used to form 8-to-1 MUX.
In the attached diagram, figure 4 shows how it is structured.
We would see that [tex]I_o[/tex] to [tex]I_7[/tex] are the inputs of the multiplexer and Z is the output in the system.
Learn more about multiplexers here;
https://brainly.com/question/25953942