In any electric circuit (AC or DC), the electric power is one of the major electrical quantity. The electrical power is broadly classified into three types namely active power, reactive power and apparent power. These three types of electric powers are measured in different units. Where, the active power is measured in Watts (W), the reactive power is measured in Volt Ampere Reactive (VAR) and the apparent power is measured in Volt Ampere (VA). But in practice, these powers are measured in larger units, i.e., kW (kilo-Watt), kVAR (kilo Volt Ampere Reactive), and kVA (kilo Volt Ampere). Read through this ... Read More
The terms diode and rectifier are extensively used in electronics engineering. Sometimes, both these terms seam similar because they perform similar functions. However, there are many differences between a diode and a rectifier. This article is meant for explaining the differences between diode and rectifier. But before discussing the differences, it is advantageous to learn the basics of these two devices so it becomes easier to understand the differences between them. What is a Diode? A diode is a two terminal semiconductor device that allows the flow of electric current only in one direction. Therefore, the diode can ... Read More
There are two most popular MOS (Metal Oxide Semiconductor) technologies namely CMOS and NMOS which are widely used in the field electronics and power electronics such as in ASICs, memories, processors, etc. Nowadays, the CMOS technology is one of the leading semiconductor technology. It is because the CMOS technology dissipates less power when compared to the bipolar and NOMOS technology. In this tutorial, we will discuss the major differences between CMOS technology and NMOS technology. But before discussing the differences, let's get a brief overview of what the CMOS and NMOS technologies are. What is CMOS Technology? CMOS stands ... Read More
A power plant is an interconnected system of various electrical equipment that is used to generate electricity. The major components of a power plant include an alternator (or generator), a prime mover, control system, a generating transformer, etc. The prime mover is a mechanism that drives the alternator or generator to produce electrical energy. The control system governs the parameters such as voltage, power factor, reactive power, frequency, etc. of the generating system. The generating transformer is to step up the voltage of the generated power for transmission purpose. Nowadays, several types of power plants are being used for power ... Read More
In a semiconductor diode, the term breakdown implies the short circuit of the diode. As we know, the diode allows the flow of electric current in only one direction (forward direction) and blocks the flow of current in the reverse direction. But, when the applied voltage in the reverse direction exceeds a limit (called breakdown voltage), the diode starts conducting in the reverse direction as well. This stage is called the breakdown in the diode. The following two types of breakdowns take place in a PN-junction semiconductor diode − Zener Breakdown Avalanche Breakdown In this article, we shall ... Read More
Blade is a template engine that helps you to build your view display in laravel. It also helps you to use php code inside the template. The blade templates are saved as filename.blade.php and are stored inside resources/views/ folder. To understand the above question let us create a view calling the blade template. Example 1 Inside routes/web.php I have created the following route that is calling the view hello with data ['mymsg' => 'Welcome to Tutorialspoint']. Route::get('hello', function () { return view('hello', ['mymsg' => 'Welcome to Tutorialspoint']); }); The hello.blade.php is inside resources/views folder − {{$mymsg}} ... Read More
To get all the field values from the html form you can make use of the Request class. The class Illuminate\Http\Request; has to be included in your controller. Example 1 This example shows the student registration form and it has fields like name, email, age and address. Student Form @if (count($errors) > 0) @foreach ($errors->all() as $error) {{ $error }} @endforeach @endif Student Registration Name Email Age Address The StudentController class is as follows −
To validate data you can make use of the Validation class. The validation helps to validate data as well as to display error messages to the user. Example 1 In the example below the make() method is used. The first argument is the data to be validated and the second is the rule applied on the data : name. $validator = Validator::make( array('name' => 'Disha'), array('name' => 'required|min:5') ); As per the above the name assigned is Disha. As per the rule the name is mandatory and the minimum characters required is 5. ... Read More
To validate data you can make use of the Validation class. The validation helps to validate data as well as to display error messages to the user. To get the exact words to validate you can make use of Rule::in method available with laravel. Using Rule::in method whatever the values provided by this rule has to be matched otherwise it will fail. Example 1 working with Rule::in method To work with Rule::in method you need to include the class : use Illuminate\Validation\Rule; or use Rule; $input = [ 'category' => ['ABC', 'XYZ'], ]; Validator::make($input, [ ... Read More
In laravel the routes are defined inside routes/ folder.The routes are defined inside web.php file. The file is created when the laravel installation is done. Laravel routes take in a URI and a closure function as shown below − use Illuminate\Support\Facades\Route; Route::get('/student', function () { return 'Hello Student'; }); The routes defined inside web/routes.php are assigned a web middleware group and they have session states and CSRF protection. You can also call your controller inside routes as shown below − use Illuminate\Support\Facades\Route; use App\Http\Controllers\StudentController; Route::get('student', [StudentController::class, 'index']); Following are the route methods you can make ... Read More