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
Sedaia [141]
3 years ago
14

1. Write a Python code to:

Computers and Technology
1 answer:
Ksenya-84 [330]3 years ago
5 0

Answer:

hope this help and do consider giving brainliest

Explanation:

1)

a)

import numpy as np

A=np.array([[1,4,3,2],[1,7,4,5],[2,5,3,1],[1,3,2,9]]);

print("Inverse is");

B=np.linalg.inv(A);

print(B);

print("A*A^-1=");

print(np.dot(A,B));

print("A^-1*A=");

print(np.dot(B,A));

2)

import numpy as np

A=np.array([[4,3,2],[5,6,3],[3,5,2]]);

B=np.array([[3,-1,2,6],[7,4,1,5],[5,2,4,1]]);

X=np.dot(np.linalg.inv(A),B);

print("X=");

print(X);

You might be interested in
Fill in the blank.He wrote me a love blank
saul85 [17]
A love poem. He wrote you a love poem.
3 0
3 years ago
Read 2 more answers
Which of the following software is unique to a Mac?
kherson [118]
Pages is owned by apple and thats what my mac has default
6 0
3 years ago
Read 2 more answers
Which of the following occurred in the 1990-2000 generation of computing? The mainframe era began. The interpersonal computing e
storchak [24]

Option C

The personal computer era ended and the interpersonal computing era began occurred in the 1990-2000 generation of computing

<h3><u>Explanation:</u></h3>

The World Wide Web grew publicly obtainable in 1991. The Internet developed speedily, and by 1996, it was portion of mass growing. By 1999 virtually every nation had a connection, and approximately half of Americans and personalities in various other countries practiced the Internet regularly.

Yet completely the 1990s, "getting online" necessitated complex configuration, and dial-up was the only connection variety affordable by unique users; the contemporary day mass Internet culture was not possible. The initial Wiki was introduced with WikiWikiWeb on 1999.

5 0
3 years ago
Which of the following is a dynamic lot-sizing technique that calculates the order quantity by comparing the carrying cost and t
Zarrin [17]

Answer:

C

Explanation:

Because

5 0
3 years ago
Design a program that asks the user to enter a month (in numeric form), a day, and a two-digit year. The program should then det
Irina-Kira [14]

Answer:

#include <iostream>

using namespace std;

int main()

{

   int mt, day, yr, magic;

   cout << "Enter a month(numeric form)"<< endl;

   cin >> mt;

   cout << "please enter a day"<<endl;

   cin >> day;

   cout << "please enter a year"<< endl;

   cin >> yr;

   // Input Validation

   if (mt<1 || mt>12){

       cout<<"Invalid Month";

   }

   else if (day<1||day>31){

       cout<<"Invalid Day";

   }

   else if (yr>99||yr<0){

       cout<<"Invalid Year";

   }

   else{

   // Calculates magic

   magic = (mt * day);

   if (magic == yr)

   {

   cout << "it is a magic year"<<endl;;

   }

   else

   cout << "It is not a magic year" << endl;

   }

   return 0;

}

Explanation:

Using C++ we request the user to enter values for Month, day and year (two digits). We carry out input validation to ensure the user enters a valid month, day and year. Using if/elseif/if statements we ensure the conditions given in the question.

7 0
3 years ago
Other questions:
  • Which line of code will generate a random integer between 7 and 77?
    10·1 answer
  • What is a utility application that monitors the network path of packet data sent to a remote computer?
    11·1 answer
  • What is the smallest group network
    9·1 answer
  • Which statement is correct about operating systems? They are hardware devices. They include programs that help people do certain
    15·1 answer
  • Which of the following is a way the operating system prevents unknown or unauthorized users from accessing the system?
    15·2 answers
  • Which extension is appropriate for Word document templates?
    10·2 answers
  • You can set a ________, which is automatically displayed in a field unless the user enters something different.
    14·1 answer
  • Which is a natural hazard that can cause extinctions? Choose all that apply.
    6·1 answer
  • Generally speaking, problems are rarely caused by motherboards. However, there are some instances in which a motherboard can fai
    12·1 answer
  • TOT al<br>Name TWO examples of these settings and utilities. (2)​
    12·1 answer
Add answer
Login
Not registered? Fast signup
Signup
Login Signup
Ask question!