Question about Applications 2 in Leon

In summary, Leon's example has an error where he is talking about the number of hits you get by setting all entries in a column vector to 1.
  • #1
schaefera
208
0
Hi all. I'm studying from Leon's Linear Algebra with Applications. I'm wondering if one of his examples has an error.

In Application 2, he's talking about searching databases. He says we should imagine a database of m documents and n possible search words. Then he says that this can be put into an mxn matrix in which each column represents a book-- the jth entry of the column is 1 if that book contains the word, 0 if it doesn't.

He then says a "search vector" lives in R^m, and it's a column vector whose jth entry is 1 if you are seraching for that word.

Does he have his m's and n's mixed up? It seems to me like if you have m documents and each column of the matrix represents one, you need an nxm matrix. Similarly, you can't search through n words by using a vector in R^m, correct? Does he mean you take an nxm matrix and multiply its transpose by the vector in R^n?
 
Physics news on Phys.org
  • #2
Any ideas?!
 
  • #3
I think he has it right: remember you have m records with n attributes so you have m rows (one row each record) and n columns (one column for each attribute).

Now let's say you have a column vector with some values set. If you want to find out how many words were successful, you simply add the number of positive hits you get and this is just a matrix multiplication with a column vector where if you want to search for n words, you simply set n entries in the column vector to 1 and the rest to zero and when you check the value of the multiplication, if you get > 0 then you got n hits.

This guy is basically checking it one at a time, so he sets one entry to 1 and the rest to zero and if you get a 1 in that entry it means the word was found and 0 means it wasn't.
 
  • #4
But if you have n search words, how can that be embedded in a vector in R^m?
 
  • #5
You either do n individual searches with n individual search vectors (with only 1 non-zero entry) or you can return the "number" of hits by flagging every term you are interested in as a 1 and keep everything else zero.

Imagine three terms: a normal search for the first term would be [1 0 0]^T. Do to three individual searches for each term you have [1 0 0]^T [0 1 0]^T [0 0 1]^T respectively. Do find out how many terms appear in each document by considering all terms, your vector will be [1 1 1]^T and if we have say 6 observations and we get the output [1 1 1 3 2 1]^T then it means that the fourth has all three, the fifth have 2 and the rest have only 1.
 

1. What is "Question about Applications 2 in Leon"?

Question about Applications 2 in Leon is a topic that involves asking and answering questions about the second application in the Leon software. It may include questions about its features, functions, or troubleshooting.

2. How do I access the second application in Leon?

To access the second application in Leon, you can either click on its icon on the desktop or navigate to it through the start menu. You can also use the search function to find it quickly.

3. What are the main features of the second application in Leon?

The second application in Leon has various features, including data analysis, data visualization, and data manipulation. It also has tools for creating charts, graphs, and reports based on the data.

4. Can I customize the interface of the second application in Leon?

Yes, you can customize the interface of the second application in Leon according to your preferences. You can change the color scheme, layout, and font size to make it more user-friendly.

5. Is there a way to troubleshoot issues with the second application in Leon?

Yes, if you encounter any issues with the second application in Leon, you can troubleshoot them by checking for updates, restarting the application, or contacting the support team for assistance.

Similar threads

  • Linear and Abstract Algebra
Replies
4
Views
869
  • Linear and Abstract Algebra
Replies
5
Views
882
Replies
4
Views
1K
  • Linear and Abstract Algebra
Replies
14
Views
2K
  • Linear and Abstract Algebra
Replies
9
Views
2K
  • Linear and Abstract Algebra
Replies
9
Views
1K
  • Calculus and Beyond Homework Help
Replies
14
Views
590
  • Linear and Abstract Algebra
Replies
15
Views
1K
  • Linear and Abstract Algebra
Replies
4
Views
2K
  • Linear and Abstract Algebra
Replies
2
Views
997
Back
Top