# ▸ Neural Networks - Representation :

1. Which of the following statements are true? Check all that apply.

1. Consider the following neural network which takes two binary-valued inputs
$\inline&space;x_1,x_2&space;\&space;\epsilon&space;\&space;\{0,1\}$ and outputs $\inline&space;h_\theta(x)$. Which of the following logical functions does it (approximately) compute?
• AND
This network outputs approximately 1 only when both inputs are 1.

• NAND (meaning “NOT AND”)

• OR

• XOR (exclusive OR)

1. Consider the following neural network which takes two binary-valued inputs
$\inline&space;x_1,x_2&space;\&space;\epsilon&space;\&space;\{0,1\}$ and outputs $\inline&space;h_\theta(x)$. Which of the following logical functions does it (approximately) compute?
• AND

• NAND (meaning “NOT AND”)

• OR
This network outputs approximately 1 when atleast one input is 1.

• XOR (exclusive OR)

1. Consider the neural network given below. Which of the following equations correctly computes the activation $\inline&space;a_1^{(3)}$? Note: $\inline&space;g(z)$ is the sigmoid activation
function.

1. You have the following neural network:

You’d like to compute the activations of the hidden layer $\inline&space;a^{(2)}&space;\&space;\epsilon&space;\&space;R^3$. One way to do
so is the following Octave code:

You want to have a vectorized implementation of this (i.e., one that does not use for loops). Which of the following implementations correctly compute ? Check all
that apply.

### Check-out our free tutorials on IOT (Internet of Things):

1. You are using the neural network pictured below and have learned the parameters $\inline&space;\theta^{(1)}&space;=&space;\begin{bmatrix}&space;1&space;&&space;1&space;&&space;2.4\\&space;1&space;&&space;1.7&space;&&space;3.2&space;\end{bmatrix}$ (used to compute $\inline&space;a^{(2)}$) and $\inline&space;\theta^{(2)}&space;=&space;\begin{bmatrix}&space;1&space;&&space;0.3&space;&&space;-1.2&space;\end{bmatrix}$ (used to compute $\inline&space;a^{(3)}$ as a function of $\inline&space;a^{(2)}$). Suppose you swap the parameters for the first hidden layer between its two units so $\inline&space;\theta^{(1)}&space;=&space;\begin{bmatrix}&space;1&space;&&space;1.7&space;&&space;3.2&space;\\&space;1&space;&&space;1&space;&&space;2.4&space;\end{bmatrix}$ and also swap the output layer so $\inline&space;\theta^{(2)}&space;=&space;\begin{bmatrix}&space;1&space;&&space;-1.2&space;&&space;0.3&space;\end{bmatrix}$. How will this change the value of the output $\inline&space;h_\theta(x)$?

&
Click here to see more codes for Raspberry Pi 3 and similar Family.
&
Click here to see more codes for NodeMCU ESP8266 and similar Family.
&
Click here to see more codes for Arduino Mega (ATMega 2560) and similar Family.

Feel free to ask doubts in the comment section. I will try my best to answer it.
If you find this helpful by any mean like, comment and share the post.
This is the simplest way to encourage me to keep doing such work.

Thanks & Regards,
- APDaga DumpBox