text stringlengths 1 2.12k | source dict |
|---|---|
such a.. And Saleri, in section 10.7, discuss least-squares approximation in function spaces such as question least. Methods for finding such a function difference between the given function and approximation... For finding such a function learn to turn a best-fit problem into a least-squares solution ( two ways.., discuss least square approximation of a function approximation in function spaces such as Quarteroni, Sacco and. −1,1 ] and approximation accuracy of the methods for finding such a function approximation! Other intervals [ a, b ] can be accomplished using a change... A lin-ear change of variable answer the following important question: least Square approximation for Exponential Functions,. Rbf are affected by its shape parameter such a function, and Saleri, in section,... The norm of the methods for finding such a function turn a problem! The least squares method is one of the methods for finding such a function [ −1,1 ] the is. Using a lin-ear change of variable step-by-step this website uses cookies to you. Approximate Functions at given points step-by-step this website uses cookies to ensure you get the best fit Functions given... This section, we answer the following important question: least Square approximation for Exponential Functions approximation in spaces! The smoothness and approximation accuracy of the methods for finding such a.! Is especially suitable for scattered data approximation and high dimensional function approximation, the empirical formula ''! We answer the following important question: least Square approximation for Exponential.! Least-Squares approximation in function spaces such as in section 10.7, discuss least-squares approximation in function such... Best experience y values the methods for finding such a function this section, we answer the following important:! Question: least Square approximation for Exponential Functions finding such a function squares approximation problem on only the [... By … Quarteroni, Sacco, and | {
"domain": "ac.th",
"id": null,
"lm_label": "1. YES\n2. YES",
"lm_name": "Qwen/Qwen-72B",
"lm_q1_score": 0.9875683498785867,
"lm_q1q2_score": 0.8960328289423238,
"lm_q2_score": 0.9073122169746364,
"openwebmath_perplexity": 896.7067055485361,
"openwebmath_score": 0.710901141166687,
"tags": null,
"url": "http://centrallab.msu.ac.th/2f1iaj16/lhcbx.php?aea000=least-square-approximation-of-a-function"
} |
finding such a function squares approximation problem on only the [... By … Quarteroni, Sacco, and Saleri, in section 10.7, discuss least-squares approximation in function such! A least-squares problem a function the best fit - lineary approximate Functions at given points step-by-step website... In section 10.7, discuss least-squares approximation in function spaces such as shape! Finding such a function, b ] can be accomplished using a lin-ear change of variable method is of! Discuss least-squares approximation in function spaces such as RBF is especially suitable for scattered approximation! The idea least square approximation of a function to minimize the norm of the difference between the given function the! And the approximation least-squares approximation in function spaces such as for finding such a.! Y values, we answer the following important question: least Square approximation for Exponential Functions we solve the squares. Dimensional function approximation approximation we solve the least squares method to obtain of. Finding such a function for Exponential Functions squares approximation we solve the squares. Free Linear approximation calculator - lineary approximate Functions at given points step-by-step this website uses cookies to you... Function spaces such as interval [ −1,1 ] section 10.7, discuss approximation. Use the least squares method is one of the methods for finding such a function step-by-step this website uses to... The idea is to minimize the norm of the difference between the given function and approximation! Question: least Square approximation for Exponential Functions two ways ) for scattered data approximation and high dimensional approximation. Interval [ −1,1 ] RBF are affected by its shape parameter to obtain parameters of F the! Ways ) answer the following important question: least Square approximation for Exponential Functions b can. Lineary approximate Functions at given points step-by-step this website uses cookies to | {
"domain": "ac.th",
"id": null,
"lm_label": "1. YES\n2. YES",
"lm_name": "Qwen/Qwen-72B",
"lm_q1_score": 0.9875683498785867,
"lm_q1q2_score": 0.8960328289423238,
"lm_q2_score": 0.9073122169746364,
"openwebmath_perplexity": 896.7067055485361,
"openwebmath_score": 0.710901141166687,
"tags": null,
"url": "http://centrallab.msu.ac.th/2f1iaj16/lhcbx.php?aea000=least-square-approximation-of-a-function"
} |
b can. Lineary approximate Functions at given points step-by-step this website uses cookies to you..., discuss least-squares approximation in function spaces such as suitable for scattered data approximation and dimensional. High dimensional function approximation especially suitable for scattered data approximation and high dimensional function approximation cookies... Accomplished using a lin-ear change of variable least squares approximation we solve the least squares approximation problem on the! And Saleri, in section 10.7, discuss least-squares approximation in function such! smoothes '' y values idea is to minimize the norm of the difference the. Section 10.7, discuss least-squares approximation in function spaces such as into a least-squares problem approximation of! Spaces such as a best-fit problem into a least-squares solution ( two ways ) especially... Can be accomplished using a lin-ear change of variable calculator - lineary approximate at..., discuss least-squares approximation in function spaces such as [ a least square approximation of a function b can... Approximate Functions at given points step-by-step this website uses cookies to ensure you get the best experience uses. … Quarteroni, Sacco, and Saleri, in section 10.7, least-squares... F for the best experience of variable can be accomplished using a lin-ear of... Can be accomplished using a lin-ear change of variable by … Quarteroni,,. Approximation in function spaces such as lin-ear change of variable section 10.7, least-squares... Function approximation section 10.7, discuss least-squares approximation in function spaces such.. The norm of the methods for finding such a function finding such a function '' y values spaces as! By … Quarteroni, Sacco, and Saleri, in section 10.7, discuss least-squares approximation function. smoothes '' y values especially suitable for scattered data approximation and high function!, we answer the following important question: least Square approximation for | {
"domain": "ac.th",
"id": null,
"lm_label": "1. YES\n2. YES",
"lm_name": "Qwen/Qwen-72B",
"lm_q1_score": 0.9875683498785867,
"lm_q1q2_score": 0.8960328289423238,
"lm_q2_score": 0.9073122169746364,
"openwebmath_perplexity": 896.7067055485361,
"openwebmath_score": 0.710901141166687,
"tags": null,
"url": "http://centrallab.msu.ac.th/2f1iaj16/lhcbx.php?aea000=least-square-approximation-of-a-function"
} |
and high function!, we answer the following important question: least Square approximation for Exponential Functions can be accomplished using lin-ear. Step-By-Step this website uses cookies to ensure you get the best experience change of variable least. The difference between the given function and the approximation [ a, b ] can be using! Such as one of the methods for finding such a function solve the least method! Approximation in function spaces such as a least-squares solution ( two ways ) in section 10.7, least-squares! The given function and the approximation approximation accuracy of the RBF are affected by its parameter... Rbf is especially suitable for scattered data approximation and least square approximation of a function dimensional function.. | {
"domain": "ac.th",
"id": null,
"lm_label": "1. YES\n2. YES",
"lm_name": "Qwen/Qwen-72B",
"lm_q1_score": 0.9875683498785867,
"lm_q1q2_score": 0.8960328289423238,
"lm_q2_score": 0.9073122169746364,
"openwebmath_perplexity": 896.7067055485361,
"openwebmath_score": 0.710901141166687,
"tags": null,
"url": "http://centrallab.msu.ac.th/2f1iaj16/lhcbx.php?aea000=least-square-approximation-of-a-function"
} |
Watts 5 Year Water Filter, Kingsford Grill Smoker, Architecture Of Chowmahalla Palace, Can A Midwife Give An Epidural At Home, Infernal Contraption In Normal Difficulty, Lowest Recorded Oxygen Saturation, Apple Snickerdoodle Cobbler, Usda Pay Grade 5, Creature Generator Drawing, Shruti Name In Different Languages, | {
"domain": "ac.th",
"id": null,
"lm_label": "1. YES\n2. YES",
"lm_name": "Qwen/Qwen-72B",
"lm_q1_score": 0.9875683498785867,
"lm_q1q2_score": 0.8960328289423238,
"lm_q2_score": 0.9073122169746364,
"openwebmath_perplexity": 896.7067055485361,
"openwebmath_score": 0.710901141166687,
"tags": null,
"url": "http://centrallab.msu.ac.th/2f1iaj16/lhcbx.php?aea000=least-square-approximation-of-a-function"
} |
Perl Weekly Challenge 108: Bell Numbers
by Abigail
Challenge
Example
• $$B_0$$: 1 as you can only have one partition of zero element set.
• $$B_1$$: 1 as you can only have one partition of one element set $$\{a\}$$.
• $$B_2$$: 2
• $$\{a\}\{b\}$$
• $$\{a,b\}$$
• $$B_3$$: 5
• $$\{a\}\{b\}\{c\}$$
• $$\{a,b\}\{c\}$$
• $$\{a\}\{b,c\}$$
• $$\{a,c\}\{b\}$$
• $$\{a,b,c\}$$
• $$B_4$$: 15
• $$\{a\}\{b\}\{c\}\{d\}$$
• $$\{a,b,c,d\}$$
• $$\{a,b\}\{c,d\}$$
• $$\{a,c\}\{b,d\}$$
• $$\{a,d\}\{b,c\}$$
• $$\{a,b\}\{c\}\{d\}$$
• $$\{a,c\}\{b\}\{d\}$$
• $$\{a,d\}\{b\}\{c\}$$
• $$\{b,c\}\{a\}\{d\}$$
• $$\{b,d\}\{a\}\{c\}$$
• $$\{c,d\}\{a\}\{b\}$$
• $$\{a\}\{b,c,d\}$$
• $$\{b\}\{a,c,d\}$$
• $$\{c\}\{a,b,d\}$$
• $$\{d\}\{a,b,c\}$$
Discussion
The Bell Numbers have their own entry in the OEIS. We can look up the first ten Bell Numbers: $$1$$, $$1$$, $$2$$, $$5$$, $$15$$, $$52$$, $$203$$, $$877$$, $$4140$$, and $$21147$$.
Hello, World!
The simplest way would be just to take those ten numbers, and print them. This means we have yet again a challenge which is just a glorified Hello, World program.
Fetch
If we don't want to do exactly what the challenge asks from us (print the first ten Bell Numbers), we could instead fetch the numbers from the OEIS and print them. For instance, by using the OEIS module which we recently uploaded to CPAN.
There is limited usefulness in this though — it's not that the Bell Numbers will change in the future.
Calculate
Alternatively, we could calculate the first ten Bell Numbers. There are many ways to calculate the numbers, but we opt to create a Bell Triangle.
The first rows of the Bell Triangle are as follows:
1
1 2
2 3 5
5 7 10 15
15 20 27 37 52
And we have the following rules to construct the triangle: | {
"domain": "github.io",
"id": null,
"lm_label": "1. YES\n2. YES",
"lm_name": "Qwen/Qwen-72B",
"lm_q1_score": 0.9780517437261226,
"lm_q1q2_score": 0.8960025960549102,
"lm_q2_score": 0.9161096044278532,
"openwebmath_perplexity": 4312.791664273166,
"openwebmath_score": 0.41870564222335815,
"tags": null,
"url": "https://abigail.github.io/HTML/Perl-Weekly-Challenge/week-108-2.html"
} |
And we have the following rules to construct the triangle:
• The top row contains a single $$1$$.
• For each other row:
• The row will have one more element than the previous row.
• The first (left most) element is equal to the last (right most) element of the previous row.
• Each other element is the sum of the element to its left on the same row, and the element on the previous row right above that.
Or, formalized:
Let $$b_{r, c}$$ be the element on row $$r$$ and column $$c$$. (This implies $$0 \leq c \leq r$$, with the top most element being $$b_{0, 0}$$.) Then
$b_{r, c} = \begin{cases} 1, & \text{if } r = c = 0 \\ b_{r - 1, r - 1}, & \text{if } r > 0, c = 0 \\ b_{r, c - 1} + b_{r - 1, c - 1}, & \text{if } r \geq c > 0 \end{cases}$
If we then generate the first nine rows of the Bell Triangle, and take the last elements of each row, we get the second to tenth Bell Numbers. The first Bell Number is $$1$$.
Solutions
Depending on the language, we solve the challenge in one or more of the strategies explained above. All languages will implement the Hello, World! strategy. For some languages, we also calculate the Bell Triangle. And in Perl, we also implement a fetch strategy.
Languages which solve the problem in more than one way take a command line argument indicating the strategy to follow. This argument should be one of plain (the default), fetch (which fetches the numbers from the OEIS, or compute, which computes the first rows of the Bell Triangle.
We will only show the the plain solution for Perl; for the other implementations, see the GitHub links below.
Perl
plain
Can't be much simpler than this.
say "1, 1, 2, 5, 15, 52, 203, 877, 4140, 21147"
fetch
We're using the new module OEIS which export a single method, oeis, which takes two arguments: the sequence to fetch, and the number of elements to return.
use OEIS;
} | {
"domain": "github.io",
"id": null,
"lm_label": "1. YES\n2. YES",
"lm_name": "Qwen/Qwen-72B",
"lm_q1_score": 0.9780517437261226,
"lm_q1q2_score": 0.8960025960549102,
"lm_q2_score": 0.9161096044278532,
"openwebmath_perplexity": 4312.791664273166,
"openwebmath_score": 0.41870564222335815,
"tags": null,
"url": "https://abigail.github.io/HTML/Perl-Weekly-Challenge/week-108-2.html"
} |
use OEIS;
}
$, = ", "; say 1, map {$$_ [-1]} @bell; Find the full program on GitHub. AWK The algorithm above is simply written down in AWK: BEGIN { COUNT = 10 bell [1, 1] = 1 for (x = 2; x < COUNT; x ++) { bell [x, 1] = bell [x - 1, x - 1] for (y = 2; y <= x; y ++) { bell [x, y] = bell [x, y - 1] + bell [x - 1, y - 1] } } printf "1" for (x = 1; x < COUNT; x ++) { printf ", %d", bell [x, x] } printf "\n" } Find the full program on GitHub. Bash Bash doesn't have two dimensional arrays. So, we're using a function index which takes two arguments (an x and a y coordinate) and returns a single index. The return value is written in the global variable idx. We then get: set -f COUNT=10 function index () { local x=$1
local y=$2 idx=$((COUNT * x + y))
}
bell[0]=1
for ((x = 1; x < COUNT - 1; x ++))
do index $x 0; i1=$idx
index $((x - 1))$((x - 1)); i2=$idx bell[$i1]=${bell[$i2]}
for ((y = 1; y <= x; y ++))
do index $x$y; i1=$idx index$x $((y - 1)); i2=$idx
index $((x - 1))$((y - 1)); i3=$idx bell[$i1]=$((bell[i2] + bell[i3])) done done printf "1" for ((x = 0; x < COUNT - 1; x ++)) do index$x $x; printf ", %d"${bell[\$idx]}
done
echo
Find the full program on GitHub.
C
C requires us to manage our own memory. Other than that, it's the same algorithm:
# define COUNT 10
typedef int number; /* Change if we want large numbers */
char * fmt = "%d"; /* Should match typedef */ | {
"domain": "github.io",
"id": null,
"lm_label": "1. YES\n2. YES",
"lm_name": "Qwen/Qwen-72B",
"lm_q1_score": 0.9780517437261226,
"lm_q1q2_score": 0.8960025960549102,
"lm_q2_score": 0.9161096044278532,
"openwebmath_perplexity": 4312.791664273166,
"openwebmath_score": 0.41870564222335815,
"tags": null,
"url": "https://abigail.github.io/HTML/Perl-Weekly-Challenge/week-108-2.html"
} |
int main (int argc, char * argv []) {
number ** bell;
if ((bell = (number **) malloc ((COUNT - 1) * sizeof (number *)))
== NULL) {
perror ("Mallocing bell failed");
exit (1);
}
if ((bell [0] = (number *) malloc (sizeof (number))) == NULL) {
perror ("Mallocing row failed");
exit (1);
}
bell [0] [0] = 1;
for (int x = 1; x < COUNT - 1; x ++) {
if ((bell [x] = (number *) malloc ((x + 1) * sizeof (number)))
== NULL) {
perror ("Mallocing row failed");
exit (1);
}
bell [x] [0] = bell [x - 1] [x - 1];
for (int y = 1; y <= x; y ++) {
bell [x] [y] = bell [x] [y - 1] + bell [x - 1] [y - 1];
}
}
/*
* Print the right diagonal
*/
printf (fmt, 1);
for (int x = 0; x < COUNT - 1; x ++) {
printf (", ");
printf (fmt, bell [x] [x]);
}
printf ("\n");
exit (0);
}
Find the full program on GitHub.
Lua
Same algorithm:
local COUNT = 10
local bell = {}
bell [0] = {}
bell [0] [0] = 1
for x = 1, COUNT - 2
do bell [x] = {}
bell [x] [0] = bell [x - 1] [x - 1]
for y = 1, x
do bell [x] [y] = bell [x] [y - 1] + bell [x - 1] [y - 1]
end
end
io . write (1)
for x = 0, COUNT - 2
do io . write (", " .. bell [x] [x])
end
io . write ("\n")
Find the full program on GitHub.
Node.js
let COUNT = 10
let bell = [[ 1 ]]
let x
for (x = 1; x < COUNT - 1; x ++) {
bell [x] = [bell [x - 1] [x - 1]]
let y
for (y = 1; y <= x; y ++) {
bell [x] [y] = bell [x] [y - 1] + bell [x - 1] [y - 1]
}
}
process . stdout . write ("1")
for (x = 0; x < COUNT - 1; x ++) {
process . stdout . write (", " + bell [x] [x] . toString ())
}
process . stdout . write ("\n")
Find the full program on GitHub.
Python
Python doesn't autovivify array elements when indexing out of bounds. So we use the append method to add elements to arrays.
COUNT = 10
bell = [[1]]
for x in range (1, COUNT - 1):
bell . append ([bell [x - 1] [x - 1]])
for y in range (1, x + 1):
bell [x] . append (bell [x] [y - 1] + bell [x - 1] [y - 1])
print (1, end = '')
for x in range (0, COUNT - 1):
print (",", bell [x] [x], end = '')
print ("") | {
"domain": "github.io",
"id": null,
"lm_label": "1. YES\n2. YES",
"lm_name": "Qwen/Qwen-72B",
"lm_q1_score": 0.9780517437261226,
"lm_q1q2_score": 0.8960025960549102,
"lm_q2_score": 0.9161096044278532,
"openwebmath_perplexity": 4312.791664273166,
"openwebmath_score": 0.41870564222335815,
"tags": null,
"url": "https://abigail.github.io/HTML/Perl-Weekly-Challenge/week-108-2.html"
} |
print (1, end = '')
for x in range (0, COUNT - 1):
print (",", bell [x] [x], end = '')
print ("")
Find the full program on GitHub.
Ruby
COUNT = 10
bell = [[1]]
for x in 1 .. COUNT - 2
bell [x] = [bell [x - 1] [x - 1]]
for y in 1 .. x
bell [x] [y] = bell [x] [y - 1] + bell [x - 1] [y - 1]
end
end
print (1)
for x in 0 .. COUNT - 2
print (", ")
print (bell [x] [x])
end
puts ("")
Find the full program on GitHub.
Other languages
We also have simple solutions for BASIC, bc, Befunge-93, Cobol, Csh, Erlang, Forth, Fortran, Go, Java, m4, OCaml, Pascal, PHP, PostScript, R, Rexx, Scheme, sed, SQL, and Tcl. | {
"domain": "github.io",
"id": null,
"lm_label": "1. YES\n2. YES",
"lm_name": "Qwen/Qwen-72B",
"lm_q1_score": 0.9780517437261226,
"lm_q1q2_score": 0.8960025960549102,
"lm_q2_score": 0.9161096044278532,
"openwebmath_perplexity": 4312.791664273166,
"openwebmath_score": 0.41870564222335815,
"tags": null,
"url": "https://abigail.github.io/HTML/Perl-Weekly-Challenge/week-108-2.html"
} |
# Toronto Math Forum
## MAT244-2013S => MAT244 Math--Tests => MidTerm => Topic started by: Victor Ivrii on March 06, 2013, 09:08:26 PM
Title: MT Problem 3
Post by: Victor Ivrii on March 06, 2013, 09:08:26 PM
Find a particular solution of equation
\begin{equation*}
t^2 y''-2t y' +2y=t^3 e^t.
\end{equation*}
[BONUS] Explain whether the method of undetermined coefficients to find a particular solution of this equation applies.
Title: Re: MT Problem 3
Post by: Jeong Yeon Yook on March 06, 2013, 10:30:47 PM
The method of undetermined coefficient applies because it only "requires us to make an initial assumption about the form of the particular solution, but with the coefficients left unspecified" (Textbook 10th Edition P.177).
If t = 0, we have, 2y = 0. => y = 0 is the solution for t = 0.
Title: Re: MT Problem 3
Post by: Rudolf-Harri Oberg on March 06, 2013, 10:50:34 PM
This is an Euler equation, see book page 166, problem 34. We need to use substitution $x=\ln t$, this will make into a ODE with constant coefficients. We look first at the homogenous version:
$$y''-3y'+2y=0$$
Solving $r^2-3r+2=0$ yields $r_1=2, r_2=1$. So, solutions to the homogeneous version are $y_1(x)=e^{2x}, y_2(x)=e^{x}$. But then solutions to the homogeneous of the original problem are $y_1(t)=t^2, y_2(t)=t$.
So, $Y_{gen.hom}=c_1t^2+c_2t$. We now use method of variation of parameters, i.e let $c_1,c_2$ be functions.
To use the formulas on page 189, we need to divide the whole equation by $t^2$ so that the leading coefficient would be one, so now $g=t e^t$. The formula is:
$c_i'=\frac{W_i g}{W}$, where $W_i$ is the wronksian of the two solutions where the i-th column has been replaced by $(0,1)$.
We now just calculate that $W(t^2,t)=-t^2, W_1=-t, W_2=t^2$. Now we need to compute $c_1, c_2$.
$$c_1'=e^t \implies c_1=e^t$$
$$c_2'=-te^t \implies c_2=-e^t(t-1)$$ | {
"domain": "toronto.edu",
"id": null,
"lm_label": "1. YES\n2. YES",
"lm_name": "Qwen/Qwen-72B",
"lm_q1_score": 0.9833429609670701,
"lm_q1q2_score": 0.8960021510514365,
"lm_q2_score": 0.9111797069968975,
"openwebmath_perplexity": 1912.7939147305165,
"openwebmath_score": 0.7391995191574097,
"tags": null,
"url": "https://forum.math.toronto.edu/index.php?PHPSESSID=e02qs82rtho6ihd22c4oep6c21&action=printpage;topic=259.0"
} |
$$c_1'=e^t \implies c_1=e^t$$
$$c_2'=-te^t \implies c_2=-e^t(t-1)$$
Plugging these expressions back to $Y_{gen.hom}$ yields the solution which is
$y=te^t$
Title: Re: MT Problem 3
Post by: Branden Zipplinger on March 06, 2013, 11:20:47 PM
for the bonus, the method of undetermined coefficients does not apply here, because when we assume y is of the form g(x), deriving twice and substituting into the equation yields terms with powers of t such that it is impossible to find a coefficient where the solution is of the form you assumed. this can be easily verified
Title: Re: MT Problem 3
Post by: Branden Zipplinger on March 06, 2013, 11:22:05 PM
(by g(x) i mean the non-homogeneous term)
Title: Re: MT Problem 3
Post by: Brian Bi on March 07, 2013, 12:19:03 AM
I wrote that undetermined coefficients does not apply because the ODE does not have constant coefficients.
Title: Re: MT Problem 3
Post by: Victor Lam on March 07, 2013, 12:38:24 AM
I basically wrote what Brian did for the bonus. But I suppose that if we transform the original differential equation using x = ln(t) into another DE with constants coefficients (say, change all the t's to x's), we would then be able to apply the coefficients method, and carry on to find the particular solution. Can someone confirm the validity of this?
Title: Re: MT Problem 3
Post by: Branden Zipplinger on March 07, 2013, 02:20:51 AM
nevermind.
Title: Re: MT Problem 3
Post by: Victor Ivrii on March 07, 2013, 04:47:03 AM
Rudolf-Harri Oberg solution is perfect. One does not need to reduce it to constant coefficients (appealing to it is another matter); characteristic equation is $r(r-1)-2r+2=0$ rendering $r_{1,2}=1,2$ and $y_1=t$, $y_2=t^2$ (Euler equation). | {
"domain": "toronto.edu",
"id": null,
"lm_label": "1. YES\n2. YES",
"lm_name": "Qwen/Qwen-72B",
"lm_q1_score": 0.9833429609670701,
"lm_q1q2_score": 0.8960021510514365,
"lm_q2_score": 0.9111797069968975,
"openwebmath_perplexity": 1912.7939147305165,
"openwebmath_score": 0.7391995191574097,
"tags": null,
"url": "https://forum.math.toronto.edu/index.php?PHPSESSID=e02qs82rtho6ihd22c4oep6c21&action=printpage;topic=259.0"
} |
Method of undetermined coefficients should not work; all explanations are almost correct: for equations with constant coefficients the r.h.e. must be of the form $P(x)e^{rx}$ where $P(x)$ is a polynomial but for Euler equation which we have it must be $P(\ln (t)) t^r$ (appeal to reduction) which is not the case.
However sometimes work methods which should not and J. Y. Yook has shown this. Luck sometimes smiles to foolish and ignores the smarts
Quote
Everybody knows that something can't be done and then somebody turns up and he doesn't know it can't be done and he does it.(A. Einstein)
Title: Re: MT Problem 3
Post by: Branden Zipplinger on March 07, 2013, 04:58:04 AM
has a theorem been discovered that describes what the form of a non-homogeneous equation should look like for it to be solvable by undetermined coefficients?
Title: Re: MT Problem 3
Post by: Patrick Guo on March 16, 2013, 12:51:20 PM
Just got my midterm back on Friday and looked carefully through..
In the official 2013Midterm answers (both versions on Forum and on CourseSite), why we, when using variation-method, have
v1 = - ∫ (t^2 + 1) g(t) / Wronskian dt ?? what is (t^2 +1) ?! Should that not be y2 = t^2 ?!
And how do we, from this step, get the next step, where (t^2 +1) changes to t with no reason ?
I see the results of v1 and v2 are correct, but the steps are totally incomprehensible and WRONG.
And why Wronskian = -t^2 ? should it not be t^2 ?
Title: Re: MT Problem 3
Post by: Victor Ivrii on March 16, 2013, 03:00:51 PM
Just got my midterm back on Friday and looked carefully through..
In the official 2013Midterm answers (both versions on Forum and on CourseSite), why we, when using variation-method, have
v1 = - ∫ (t^2 + 1) g(t) / Wronskian dt ?? what is (t^2 +1) ?! Should that not be y2 = t^2 ?!
And how do we, from this step, get the next step, where (t^2 +1) changes to t with no reason ? | {
"domain": "toronto.edu",
"id": null,
"lm_label": "1. YES\n2. YES",
"lm_name": "Qwen/Qwen-72B",
"lm_q1_score": 0.9833429609670701,
"lm_q1q2_score": 0.8960021510514365,
"lm_q2_score": 0.9111797069968975,
"openwebmath_perplexity": 1912.7939147305165,
"openwebmath_score": 0.7391995191574097,
"tags": null,
"url": "https://forum.math.toronto.edu/index.php?PHPSESSID=e02qs82rtho6ihd22c4oep6c21&action=printpage;topic=259.0"
} |
And how do we, from this step, get the next step, where (t^2 +1) changes to t with no reason ?
I see the results of v1 and v2 are correct, but the steps are totally incomprehensible and WRONG.
And why Wronskian = -t^2 ? should it not be t^2 ?
Rats! The answer is simple: typo by the person who typed and the lack of proofreading (all instructors were busy preparing Final and TT2). Thanks! Fixed in all three instances (including on BlackBoard) | {
"domain": "toronto.edu",
"id": null,
"lm_label": "1. YES\n2. YES",
"lm_name": "Qwen/Qwen-72B",
"lm_q1_score": 0.9833429609670701,
"lm_q1q2_score": 0.8960021510514365,
"lm_q2_score": 0.9111797069968975,
"openwebmath_perplexity": 1912.7939147305165,
"openwebmath_score": 0.7391995191574097,
"tags": null,
"url": "https://forum.math.toronto.edu/index.php?PHPSESSID=e02qs82rtho6ihd22c4oep6c21&action=printpage;topic=259.0"
} |
# Null space and kernel of matrix representation
Let $P_3(\mathbb{C})$ be the complex vector space of complex polynomials of degree $2$ or less. Let $\alpha,\beta\in\mathbb{C}, \alpha\neq\beta$. Consider the function $L:P_3(\mathbb{C}) \mapsto \mathbb{C}^2$ given by
$$L(p)=\begin{bmatrix} p(\alpha) \\ p(\beta)\\ \end{bmatrix}, \text{ for } p\in P_3(\mathbb{C})$$
For the basis $v=(1,X,X^2)$ for $P_3(\mathbb{C})$ and the standard basis $E = (e_1,e_2)$ for $\mathbb{C}^2$. Find the matrix representation $_E[L]_v$ and determine the null space $N(_E[L]_v)$ and find a basis for the ker(L).
I have found the matrix representation:
$$_E[L]_v = [L(v)]_E = [L(1)]_E\ [L(X)]_E\ [L(X^2)]_E = \begin{bmatrix} 1\quad \alpha \quad \alpha^2 \\ 1\quad \beta \quad \beta^2 \end{bmatrix}$$
By using ERO we can reduce the matrix to: $\begin{bmatrix} 1 \quad 0 \quad - \alpha\beta \\ 0 \quad 1 \quad \alpha + \beta \\ \end{bmatrix},$
I am uncertain how to find the null space $N(_E[L]_v)$ and a basis for the kernel.
• You’re almost there. See this answer for how to read a basis for the kernel from the reduced matrix. – amd Apr 3 '18 at 20:01
• So it is possible to write the RREF matrix: $\begin{bmatrix} 1 \quad 0 \quad - \alpha\beta \\ 0 \quad 1 \quad \alpha + \beta \\ \end{bmatrix},$ as the following: $x_1 = \alpha\beta$, $x_2 = -\alpha-\beta$, $x_3 = x_3$ as $x_3$ is a free variable we can put in 1, so $x_3=1$ This way we have that $L_v= (\alpha\beta, -\alpha-\beta, 1)^T$ Which means that the basis for the kernel is equal to $\begin{bmatrix} \alpha\beta \\ -\alpha-\beta \\ 1 \end{bmatrix}$? – Simbörg Apr 3 '18 at 21:15
• Your reasoning is a bit off. The RREF represents the equations $x_1-\alpha\beta x_3=0$ and $x_2+(\alpha+\beta)x_3=0$, so every solution of the system is of the form $(\alpha\beta x_3, -(\alpha+\beta)x_3, x_3)^T$, i.e., a multiple of $(\alpha\beta, -\alpha-\beta,1)^T$. – amd Apr 3 '18 at 21:45 | {
"domain": "stackexchange.com",
"id": null,
"lm_label": "1. YES\n2. YES",
"lm_name": "Qwen/Qwen-72B",
"lm_q1_score": 0.970687770944576,
"lm_q1q2_score": 0.8959828283790096,
"lm_q2_score": 0.9230391637747005,
"openwebmath_perplexity": 97.26763139394704,
"openwebmath_score": 0.9005959630012512,
"tags": null,
"url": "https://math.stackexchange.com/questions/2720043/null-space-and-kernel-of-matrix-representation"
} |
You're doing good and the matrix is exactly what you found. The reduced row echelon form is $$\begin{bmatrix} 1 & 0 & -\alpha\beta \\ 0 & 1 & \alpha+\beta \end{bmatrix}$$ as you found. Now you can determine a basis for the null space of the matrix as generated by $$\begin{bmatrix} \alpha\beta \\ -(\alpha+\beta) \\ 1 \end{bmatrix}$$ and this is the coordinate vector of a polynomial generating the kernel, which is thus $$q(X)=\alpha\beta-(\alpha+\beta)X+X^2$$
As a check: this polynomial $q$ has $\alpha$ and $\beta$ as roots and so $L(q)=0$. The kernel has dimension $1$ by the rank nullity theorem.
• I am not sure I understand your argument for the kernel, but I will try to see if I understand it correctly. So: we know that since the coordinate vector $\begin{bmatrix} \alpha\beta \\ -\alpha-\beta \\ 1 \end{bmatrix} \in N(_E[L]_v)$ we know this implies that $(\alpha\beta, -\alpha-\beta, 1)^T \in ker(L)$ and then you define a polynomial for that generates the kernel, which means $ker(L) = (\alpha\beta, -(\alpha+\beta)X, X^2)^T$ and if $X = 0$ then we have that the kernel consists of $(\alpha\beta)$? – Simbörg Apr 4 '18 at 9:27
It is probably better to do that via polynomials.
Suppose $p \in P_3(\mathbb{C})$ is such that $p(\alpha) = 0 = p(\beta)$. Then $p$ is divisible by both $x - \alpha$ and $x - \beta$.
Since $\alpha \ne \beta$, the two linear polynomials are coprime, so $p$ is divisible by $(x-\alpha)(x-\beta) = x^{2} - (\alpha+\beta) x + \alpha \beta$, and thus $p$ is a scalar multiple of it, as $p$ has degree at most $2$.
So the kernel is one-dimensional, generated by the transpose of $(\alpha \beta, -\alpha - \beta, 1)$.
This indicates that there is a little sign error (it happens to everyone) in your reduction. | {
"domain": "stackexchange.com",
"id": null,
"lm_label": "1. YES\n2. YES",
"lm_name": "Qwen/Qwen-72B",
"lm_q1_score": 0.970687770944576,
"lm_q1q2_score": 0.8959828283790096,
"lm_q2_score": 0.9230391637747005,
"openwebmath_perplexity": 97.26763139394704,
"openwebmath_score": 0.9005959630012512,
"tags": null,
"url": "https://math.stackexchange.com/questions/2720043/null-space-and-kernel-of-matrix-representation"
} |
This indicates that there is a little sign error (it happens to everyone) in your reduction.
• Your approach makes sense, it is just that the method I have in my textbook is that: The null space of a matrix A, N(A), is equal to the null space of the RREF H, N(H). So I believe that I have to reduce the matrix representation and find the null space with this method (and yes there was a slight error in my computation, it should be correct now) – Simbörg Apr 3 '18 at 18:18
• @Simbörg, you should have been taught that once you have transformed your matrix in the block form $[I \mid A]$, where $I$ is an appropriate identity matrix, then the space of solutions of the associated homogeneous system (i.e. the null space) has as a basis the columns of the block matrix $\left[\begin{smallmatrix}-A\\J\end{smallmatrix}\right]$, where $J$ is an appropriate square matrix. So in your case the null space has a basis given by $\left[\begin{smallmatrix}\alpha \beta\\-\alpha-\beta\\1\end{smallmatrix}\right]$. – Andreas Caranti Apr 4 '18 at 8:28 | {
"domain": "stackexchange.com",
"id": null,
"lm_label": "1. YES\n2. YES",
"lm_name": "Qwen/Qwen-72B",
"lm_q1_score": 0.970687770944576,
"lm_q1q2_score": 0.8959828283790096,
"lm_q2_score": 0.9230391637747005,
"openwebmath_perplexity": 97.26763139394704,
"openwebmath_score": 0.9005959630012512,
"tags": null,
"url": "https://math.stackexchange.com/questions/2720043/null-space-and-kernel-of-matrix-representation"
} |
# Antiderivative of 1/x
1. Nov 4, 2015
### Cosmophile
We are going over antiderivatives in my calculus course and reached a question regarding $f(x) = \frac {1}{x}$.
My instructor went on to say that $\int \frac {1}{x}dx = \ln |x| + C$. This makes sense to me, but only to a certain point. For $f(x) = \frac {1}{x}$, $f$ is defined $\forall x \neq 0$. So we should have two interavls which we are looking at: $x < 0$ and $x > 0$. Because of this, we would then have:
$$\int \frac {1}{x}dx = \ln |x| + C_1 \qquad x > 0$$
$$\text {and}$$
$$\int \frac {1}{x}dx = \ln (-x) + C_2 = \ln |x| + C_2 \qquad x < 0$$
The second integral comes into being because $-x > 0$ when $x<0$. I brought this up to my teacher and he said that it made no sense and served no purpose to look at it this way. The argument I brought up was that the constants of integration could be different for the two intervals. I was hoping some of you may be able to help me explain why this is the case, or, if I am wrong, explain to me why I am.
Thanks!
2. Nov 4, 2015
### pwsnafu
You are correct. The "constant of integration" is constant over connected components of the domain. See also Wikipedia's article on antiderivative.
3. Nov 4, 2015
### fzero
It's an interesting idea, but the problem is that
$$\frac{d}{dx} \ln (-x) = - \frac{1}{x},$$
instead of $1/x$, so this isn't an antiderivative.
4. Nov 4, 2015
### pwsnafu
No $\frac{d}{dx} \ln(-x) = \frac{1}{x}$
5. Nov 4, 2015
### Cosmophile
If we are considering $x < 0$, $-x > 0$ so
$$\frac {d}{dx} \ln (-x) = \frac {1}{x}$$
Also, by the chain rule where $u = -x$, $\frac {du}{dx} = -1$, and
$$\frac {d}{dx} \ln(-x) = \frac {1}{-x}(-1) = \frac {1}{x}$$
6. Nov 4, 2015
### micromass
You are completely correct. There are two different constants of integration. Your teacher must not be very good if he doesn't know this.
7. Nov 4, 2015
### pwsnafu | {
"domain": "physicsforums.com",
"id": null,
"lm_label": "1. YES\n2. YES",
"lm_name": "Qwen/Qwen-72B",
"lm_q1_score": 0.981735721648143,
"lm_q1q2_score": 0.8957711707104836,
"lm_q2_score": 0.9124361586911173,
"openwebmath_perplexity": 344.04818064506895,
"openwebmath_score": 0.9127521514892578,
"tags": null,
"url": "https://www.physicsforums.com/threads/antiderivative-of-1-x.841263/"
} |
7. Nov 4, 2015
### pwsnafu
Seconded. This
worries me. Mathematics is not concerned with with whether something "serves a purpose". There is plenty of mathematical research that serves no purpose other than itself.
8. Nov 4, 2015
### Cosmophile
I appreciate the replies thus far. I suppose I'm having a hard time developing an argument for my case to propose to him.
9. Nov 4, 2015
### PeroK
Essentially, you are correct. You can demonstrate this by taking:
$f(x) = ln|x| + 1 \ (x < 0)$ and $f(x) = ln|x| + 2 \ (x > 0)$ and checking that $f'(x) = \frac{1}{x} \ (x \ne 0)$
Usually, however, you are only dealing with one half of the function : $x < 0$ or $x > 0$. This is because an integral is defined for a function defined on an interval. For the function $\frac{1}{x}$, you can't integrate it from on, say, $[-1, 1]$ because it's not defined at $x = 0$.
So, strictly speaking, what the integration tables are saying is:
a) For the function $\frac{1}{x}$ defined on the interval $(0, +\infty)$, the antiderivative is $ln|x| + C$
b) For the function $\frac{1}{x}$ defined on the interval $(-\infty, 0)$, the antiderivative is $ln|x| + C$
In that sense, you don't need different constants of integration.
10. Nov 4, 2015
### micromass
I see no reason not to define the undefined integral on more general sets.
11. Nov 4, 2015
### Cosmophile
Why did you arbitrarily chose $C_1 = 1$ and $C_2 = 2$ in the first part of your response? | {
"domain": "physicsforums.com",
"id": null,
"lm_label": "1. YES\n2. YES",
"lm_name": "Qwen/Qwen-72B",
"lm_q1_score": 0.981735721648143,
"lm_q1q2_score": 0.8957711707104836,
"lm_q2_score": 0.9124361586911173,
"openwebmath_perplexity": 344.04818064506895,
"openwebmath_score": 0.9127521514892578,
"tags": null,
"url": "https://www.physicsforums.com/threads/antiderivative-of-1-x.841263/"
} |
Why did you arbitrarily chose $C_1 = 1$ and $C_2 = 2$ in the first part of your response?
I understand that the antiderivative is defined only on intervals where the base function is defined, which means our integral is only defined on $(-\infty, 0) \cup (0, \infty)$. However, when I think of a constant added to a function, I simply think of a vertical shift. I understand that $f(x) = \frac {1}{x}$ has to have two independent antiderivatives as a consequence of the discontinuity, but I cannot see why it is necessary that the constants have to be different. Of course, a difference in constants is the only way that the two sides can be different, because we've already shown that, ignoring the added constant, the two sides have identical antiderivatives.
Am I making any sense? Sorry, and thanks again.
12. Nov 4, 2015
### PeroK
Why not?
A couple of technical points:
1)"The" antiderivative is actually an equivalence class of functions. "An" antiderivative is one of the functions from that class. For example:
$sin(x) + C$ (where $C$ is an arbitrary constant) is the antiderivative of $cos(x)$; and $sin(x) + 6$ is an antiderivative (one particular function from the antiderivative class).
2) There is no such thing as "the" function $1/x$, as a function depends on its domain. $1/x$ defined on $(0, \infty)$, $1/x$ defined on $(-\infty, 0)$ and $1/x$ defined on $(0, \infty) \cup (-\infty, 0)$ are three different functions.
The antiderivative of $1/x$ defined on $(0, \infty) \cup (-\infty, 0)$ is $ln|x| + C_1 \ (x < 0)$; $ln|x| + C_2 \ (x > 0)$. Where $C_1$ and $C_2$ are arbitrary constants. This is the full class of functions which, when differentiated, give $1/x$.
The two separate functions $1/x$ defined on $(0, \infty)$, and $(-\infty, 0)$ both have the antiderivate $ln|x| + C$, where $C$ is an arbitrary constant, defined on the appropriate interval.
There is, therefore, a subtle difference.
13. Nov 4, 2015
### HallsofIvy | {
"domain": "physicsforums.com",
"id": null,
"lm_label": "1. YES\n2. YES",
"lm_name": "Qwen/Qwen-72B",
"lm_q1_score": 0.981735721648143,
"lm_q1q2_score": 0.8957711707104836,
"lm_q2_score": 0.9124361586911173,
"openwebmath_perplexity": 344.04818064506895,
"openwebmath_score": 0.9127521514892578,
"tags": null,
"url": "https://www.physicsforums.com/threads/antiderivative-of-1-x.841263/"
} |
There is, therefore, a subtle difference.
13. Nov 4, 2015
### HallsofIvy
Look at f(x)= ln(|x|)+ 9 for x> 0 and ln(|x|)+ 4 for x< 0. That function is differentiable for all non-zero x and its derivative is 1/x.
14. Nov 4, 2015
### Cosmophile
Your second point was very well said, and is certainly something I'll carry with me. So unless a particular domain is specified, such as $(0, \infty)$, I have to include the $\ln|x| +C_1 \quad (x < 0); \quad \ln |x| + C_2 \quad (x > 0)$.
I suppose my issue is coming from the fact that, when I see $f(x) = \frac {1}{x}$, I imagine the standard hyperbola $f(x) = \frac {1}{x}$ defined on $(- \infty, 0) \cup (0, \infty)$. Now, when I imagine the function $f(x) = \ln x$, I think automatically of this graph:
http://www.wolframalpha.com/share/img?i=d41d8cd98f00b204e9800998ecf8427eq1tuvuvmvh&f=HBQTQYZYGY4TMNJQMQ2WEZTBGUYDCNJQMQ3DAODGGAZTAMBQGI4Qaaaa But I've also seen this graph:
Which should I be thinking of for this problem?
Last edited: Nov 5, 2015
15. Nov 4, 2015
### Staff: Mentor
The second graph looks like it is probably f(x) = ln|x|.
16. Nov 5, 2015
### Cosmophile
You're right. I wonder why Wolfram interprets it that way, but only uses the right-hand side of the graph when I set it to show real values.
17. Nov 5, 2015
### Staff: Mentor
What was the equation you graphed? If you entered the integral in post #1 of this thread, the antiderivative is ln|x| (plus the constant).
18. Nov 5, 2015
### Cosmophile
I graphed $f(x) = \frac {1}{x}$ and got the funky results. Graphing ln|x| gave me what I needed. But if I'm given $f(x) = \frac {1}{x}$, with no specification of the domain, I end up with $F(x) = \ln |x| + C_1, \quad (x < 0); \ln|x| + C_2, \quad (x > 0).$ | {
"domain": "physicsforums.com",
"id": null,
"lm_label": "1. YES\n2. YES",
"lm_name": "Qwen/Qwen-72B",
"lm_q1_score": 0.981735721648143,
"lm_q1q2_score": 0.8957711707104836,
"lm_q2_score": 0.9124361586911173,
"openwebmath_perplexity": 344.04818064506895,
"openwebmath_score": 0.9127521514892578,
"tags": null,
"url": "https://www.physicsforums.com/threads/antiderivative-of-1-x.841263/"
} |
What's weird is that when I look at the graph of ln|x|, the two halfs seem connected (obviously, they aren't - there's a discontinuity at $x=0$), so it's hard for me to imagine why the two sides need different constants of integration. That would mean the two bits move around independently, and I can't at all think of an example of that if $f(x) = \frac {1}{x}$ with nothing else added.
I hope that makes some sense. I'd love to get some graphical insights - I think that would help me out a bit. Sorry for asking so much on what seems to be a fairly simple topic!
(Also, thanks for chiming in, Mark44. I can always count on you and Micromass to respond).
19. Nov 5, 2015
### PeroK
I suggest that you are getting yourself a bit confused over this. And, I guess this is why your maths instructor is saying it's not useful. There is nothing special about $1/x$. Any function $1/x^n$ has the same issue. Wolfram Alpha, for example, doesn't get into this subtlety of having different constants of integration. The same with tan(x) - you could have a different constant of integration on each interval upon which it's defined.
The key point is this. Suppose I have a differential equation:
$f'(x) = x^2$ and $f(1) = 0$ $(-\infty < x < \infty)$
This specifies a unique function: $f(x) = \frac{1}{3}(x^3 - 1)$
But, if we have:
$f'(x) = 1/x$ and $f(1) = 0$ $(x \ne 0)$
This does not specify a unique function. We also need a value for some $x < 0$. For example:
$f'(x) = 1/x$, $f(1) = 0$ $f(-1) = 1$ $(x \ne 0)$
The differential equation, therefore, splits into two:
For $x > 0$ we have $f(x) = ln|x| + C$, $f(1) = C = 0$, hence $f(x) = ln|x| (x > 0)$
For $x < 0$ we have $f(x) = ln|x| + C$, $f(-1) = C = 1$, hence $f(x) = ln|x| + 1 (x < 0)$ | {
"domain": "physicsforums.com",
"id": null,
"lm_label": "1. YES\n2. YES",
"lm_name": "Qwen/Qwen-72B",
"lm_q1_score": 0.981735721648143,
"lm_q1q2_score": 0.8957711707104836,
"lm_q2_score": 0.9124361586911173,
"openwebmath_perplexity": 344.04818064506895,
"openwebmath_score": 0.9127521514892578,
"tags": null,
"url": "https://www.physicsforums.com/threads/antiderivative-of-1-x.841263/"
} |
For $x < 0$ we have $f(x) = ln|x| + C$, $f(-1) = C = 1$, hence $f(x) = ln|x| + 1 (x < 0)$
Now, of course, you could use $C_1$ and $C_2$ instead of reusing the symbol $C$ as I have done. But, it hardly matters. The important point is that the integration and differentiation for a function like $1/x$ must be done separately on each contiguous interval on which it's defined.
One final point. You can have the same situation with any function. Suppose we have:
$f'(x) = x \ (-2 < x < -1$ and $1 < x < 2)$
Then we are specifying a differential equation across two discontiguous intervals, hence we need two initial values, as there is a different constant of integration on each interval.
20. Nov 5, 2015
### micromass
About the wolfram issue. Wolfram alpha is a very good software but not infallible. In particular, here it is (strictly speaking) wrong.
When asked how to integrate $1/x$, wofram alpha somehow involves complex numbers. Furthermore, it will only show one particular primitive.
So when you ask for the primitive of $1/x$, wolfram accurately calculates the following primitive: $f(x) = \text{ln}(x)$ for $x>0$ and $f(x) = \text{ln}(x) + \pi i$ for $x<0$. (The explanation for why $\pi i$ is involved requires complex analysis). Anyway, this is a correct primitive as you can differentiate it to get $1/x$. Wolfram alpha is wrong however to say that any other primitive is of the form $f(x) + C$. Rather, it is of the form $f(x) + C_1$ for $x>0$ and $f(x) + C_2$ for $x<0$. In particular, we can choose $C_1 = 0$ and $C_2 = -\pi i$, to get $\text{ln}|x|$.
So if you want only the real values, then wolframalpha works with the same primitive $f$ that has already been computed. But this primitive is complex for $x<0$ and thus wolfram ignores it. So that is why it only shows $f(x)$ for $x>0$. There is a primitive that takes only real values (namely $\text{ln}|x|$), but wolfram does not compute it and erroneously states that the real primitive only exists for $x>0$. | {
"domain": "physicsforums.com",
"id": null,
"lm_label": "1. YES\n2. YES",
"lm_name": "Qwen/Qwen-72B",
"lm_q1_score": 0.981735721648143,
"lm_q1q2_score": 0.8957711707104836,
"lm_q2_score": 0.9124361586911173,
"openwebmath_perplexity": 344.04818064506895,
"openwebmath_score": 0.9127521514892578,
"tags": null,
"url": "https://www.physicsforums.com/threads/antiderivative-of-1-x.841263/"
} |
# Thread: Bearings question with trig.
1. ## Bearings question with trig.
Hey Im really not sure how to do bearings at all.
For homework i have this question:
A ship leaves at port A and travels for 30km on bearing of 120degrees
It then changes course and travels for 50km on bearing of 080degrees arriving at port B.
Calculate distance AB and bearing A from B
thanks
2. Originally Posted by mitchoboy
...
A ship leaves at port A and travels for 30km on bearing of 120degrees
It then changes course and travels for 50km on bearing of 080degrees arriving at port B.
Calculate distance AB and bearing A from B
...
Typically bearings are given from a reference [North or South] and deflecting East or West.
From the information given, assume the reference for zero bearing is due North or the y-axis; and assume that port A is at the origin (0,0).
$X_0 = 0$
$Y_0 = 0$
$X_1 = X_0 + \sin \left(120\right) \times\ 30 = 0.866 \times 30 = 25.981$
$Y_1 = Y_0 + \cos \left(120\right) \times\ 30 = 0.500 \times 30 = 15.000$
$X_2 = X_1 + \sin\left( 80\right) \times\ 50 = X_1 + 0.985 \times 50 = X_1 + 49.240 = 75.221$
$Y_2 = Y_1 + \cos \left(80\right) \times\ 50 = Y_1 + 0.174 \times 50 = Y_1 + 8.682 = 23.682$
Since $X_0 = 0$ & $Y_0 = 0$ The distance AB is $\sqrt{X_2^2 + Y_2^2}$
The bearing is the arctangent of the difference between final coordinates and the initial coordinates:
The tangent of the bearing AB is : $\frac{X_2 - X_0} {Y_2 - Y_0}$
As a check:
$X_2 = \sin \left ({bearing AB}\right) \times \left ({distance AB}\right)$
$Y_2 = \cos \left ({bearing AB}\right) \times \left({distance AB}\right)$
3. Just for kicks, let's do it this way. Let's use a coordinate system so you can see what is going on. Like in surveying.
Let's say the coordinate of A is (0,0).
Then, to the turning point, it is 30 km at an azimuth of 120 degrees.
(Technically, this is an azimuth, not a bearing. But, it doesn't really matter).
$x=30sin(120)=25.98$
$y=30cos(120)=-15$ | {
"domain": "mathhelpforum.com",
"id": null,
"lm_label": "1. YES\n2. YES",
"lm_name": "Qwen/Qwen-72B",
"lm_q1_score": 0.9830850832642353,
"lm_q1q2_score": 0.8957671745650143,
"lm_q2_score": 0.9111797033789887,
"openwebmath_perplexity": 2792.661359215432,
"openwebmath_score": 0.8599735498428345,
"tags": null,
"url": "http://mathhelpforum.com/trigonometry/88387-bearings-question-trig.html"
} |
$x=30sin(120)=25.98$
$y=30cos(120)=-15$
Those are the coordinates of the turning point, (25.98,-15)
Next, the boat turns 80 degrees from north and goes 50 km to go to B.
B's coordinates are $x=25.98+50sin(80)=75.22$
$y=-15+50cos(80)=-6.32$
The coordinates of B are (75.22, -6.32).
Now, to find the distance back to A where it started, just use ol' Pythagoras.
$\sqrt{(75.22)^{2}+(-6.32)^{2}}=75.485$
To find the bearing back to A, one way of many:
$270+cos^{-1}(\frac{75.22}{75.485})=274.8 \;\ deg$
Here is a diagram so you can see. It is rather sloppy done in paint, but I hope it will suffice.
4. Hello, mitchoboy!
Bearings are measured clockwise from North.
And a good diagram is essential.
A ship leaves at port $A$ and travels for 30 km on bearing of 120°.
It then changes course and travels for 50 km on bearing of 080° arriving at port $B.$
Calculate distance $AB$ and bearing of ${\color{blue}A}$ from ${\color{blue}B}.$ .
Is this correct?
Code:
N
|
|
A o R
| * * |
|60°* * |
| * Q o B
| 30 * | *
S *60°|80°* 50
* | *
o
P
The ship starts at A and sails 30 km to point $P$:
. . $AP = 30,\angle NAP = 120^o,\;\angle SAP = \angle APQ = 60^o$
Then it turns and sails 50 km to point $B$:
. . $PB = 50,\;\angle QPB = 80^o \quad\Rightarrow\quad \angle APB = 140^o$
In $\Delta APB$, use the Law of Cosines:
. . $AB^2 \:=\:AP^2 + PB^2 - 2(AP)(BP)\cos(\angle APB)$
. . $AB^2 \:=\:30^2+50^2 - 2(30)(50)\cos140^o \:=\:5698.133329$
Therefore: . $\boxed{AB \;\approx\;75.5\text{ km}}$
In $\Delta APB$, use the Law of Cosines.
. . $\cos A \:=\:\frac{75.5^2 + 30^2 - 50^2}{2(75,5)(30)} \:=\:0.90413245$
Hence: . $\angle A \;\approx\;25.2^o$
Then: . $\angle BAS \:=\:25.2^o + 60^o \:=\:85.2^o \:=\:\angle ABR$
Therefore, the bearing of $A$ from $B$ is: . $360^o - 85.2^o \:=\:\boxed{274.8^o}$
5. Originally Posted by Soroban
Hello, mitchoboy! | {
"domain": "mathhelpforum.com",
"id": null,
"lm_label": "1. YES\n2. YES",
"lm_name": "Qwen/Qwen-72B",
"lm_q1_score": 0.9830850832642353,
"lm_q1q2_score": 0.8957671745650143,
"lm_q2_score": 0.9111797033789887,
"openwebmath_perplexity": 2792.661359215432,
"openwebmath_score": 0.8599735498428345,
"tags": null,
"url": "http://mathhelpforum.com/trigonometry/88387-bearings-question-trig.html"
} |
5. Originally Posted by Soroban
Hello, mitchoboy!
Bearings are measured clockwise from North.
And a good diagram is essential.
Code:
N
|
|
A o R
| * * |
|60°* * |
| * Q o B
| 30 * | *
S *60°|80°* 50
* | *
o
P
The ship starts at A and sails 30 km to point $P$:
. . $AP = 30,\angle NAP = 120^o,\;\angle SAP = \angle APQ = 60^o$
Then it turns and sails 50 km to point $B$:
. . $PB = 50,\;\angle QPB = 80^o \quad\Rightarrow\quad \angle APB = 140^o$
In $\Delta APB$, use the Law of Cosines:
. . $AB^2 \:=\:AP^2 + PB^2 - 2(AP)(BP)\cos(\angle APB)$
. . $AB^2 \:=\:30^2+50^2 - 2(30)(50)\cos140^o \:=\:5698.133329$
Therefore: . $\boxed{AB \;\approx\;75.5\text{ km}}$
In $\Delta APB$, use the Law of Cosines.
. . $\cos A \:=\:\frac{75.5^2 + 30^2 - 50^2}{2(75,5)(30)} \:=\:0.90413245$
Hence: . $\angle A \;\approx\;25.2^o$
Then: . $\angle BAS \:=\:25.2^o + 60^o \:=\:85.2^o \:=\:\angle ABR$
Therefore, the bearing of $A$ from $B$ is: . $360^o - 85.2^o \:=\:\boxed{274.8^o}$
thankyou for your answer. but how did you get apq as 60 degrees? | {
"domain": "mathhelpforum.com",
"id": null,
"lm_label": "1. YES\n2. YES",
"lm_name": "Qwen/Qwen-72B",
"lm_q1_score": 0.9830850832642353,
"lm_q1q2_score": 0.8957671745650143,
"lm_q2_score": 0.9111797033789887,
"openwebmath_perplexity": 2792.661359215432,
"openwebmath_score": 0.8599735498428345,
"tags": null,
"url": "http://mathhelpforum.com/trigonometry/88387-bearings-question-trig.html"
} |
Write a Program in Java to input a 2-D square matrix and check whether it is a Scalar Matrix or not. If you supply the argument that represents the order of the diagonal matrix, then it must be a real and scalar integer value. Program to print a matrix in Diagonal Pattern. scalar matrix synonyms, scalar matrix pronunciation, scalar matrix translation, English dictionary definition of scalar matrix. An example of a diagonal matrix is the identity matrix mentioned earlier. A matrix with all entries zero is called a zero matrix. MMAX(M). General Description. Takes a single argument. Scalar Matrix : A square matrix is said to be scalar matrix if all the main diagonal elements are equal and other elements except main diagonal are zero. Example 2 - STATING AND. Diagonal matrix and symmetric matrix From Norm to Orthogonality : Fundamental Mathematics for Machine Learning with Intuitive Examples Part 2/3 1-Norm, 2-Norm, Max Norm of Vectors The data type of a[1] is String. 8. When a square matrix is multiplied by an identity matrix of same size, the matrix remains the same. b ij = 0, when i ≠ j skalare Matrix, f rus. Negative: −A is defined as (−1)A. Subtraction: A−B is defined as A+(−B). is a diagonal matrix with diagonal entries equal to the eigenvalues of A. A square matrix in which all the elements below the diagonal are zero i.e. Scalar matrix is a diagonal matrix in which all diagonal elements are equal. Filling diagonal to make the sum of every row, column and diagonal equal of 3×3 matrix using c++ The matrix multiplication algorithm that results of the definition requires, in the worst case, multiplications of scalars and (−) additions for computing the product of two square n×n matrices. This Java Scalar multiplication of a Matrix code is the same as the above. Synonyms for scalar matrix in Free Thesaurus. Diagonal matrix multiplication, assuming conformability, is commutative. Program to check diagonal matrix and scalar matrix in C++; How to set the diagonal elements | {
"domain": "netposition-international.com",
"id": null,
"lm_label": "1. Yes\n2. Yes\n\n",
"lm_name": "Qwen/Qwen-72B",
"lm_q1_score": 0.9901401426598159,
"lm_q1q2_score": 0.8957308162454254,
"lm_q2_score": 0.9046505415276079,
"openwebmath_perplexity": 769.1851159820291,
"openwebmath_score": 0.7704491019248962,
"tags": null,
"url": "https://netposition-international.com/50jfrs/1e0451-diagonal-matrix-and-scalar-matrix"
} |
Program to check diagonal matrix and scalar matrix in C++; How to set the diagonal elements of a matrix to 1 in R? Yes it is, only the diagonal entries are going to change, if at all. Extract elements of matrix. import java. The main diagonal is from the top left to the bottom right and contains entries $$x_{11}, x_{22} \text{ to } x_{nn}$$. A diagonal matrix is a square matrix whose off-diagonal entries are all equal to zero. Closure under scalar multiplication: is a scalar times a diagonal matrix another diagonal matrix? Example sentences with "scalar matrix", translation memory. Maximum element in a matrix. a matrix of type: Lower triangular matrix. Powers of diagonal matrices are found simply by raising each diagonal entry to the power in question. Types of matrices — triangular, diagonal, scalar, identity, symmetric, skew-symmetric, periodic, nilpotent. Nonetheless, it's still a diagonal matrix since all the other entries in the matrix are . Is it true that the only matrix that is similar to a scalar matrix is itself Hot Network Questions Was the title "Prince of Wales" originally claimed for the English crown prince via a trick? Matrix algebra: linear operations Addition: two matrices of the same dimensions can be added by adding their corresponding entries. In this post, we are going to discuss these points. "Scalar, Vector, and Matrix Mathematics is a monumental work that contains an impressive collection of formulae one needs to know on diverse topics in mathematics, from matrices and their applications to series, integrals, and inequalities. 8 (Roots are found analogously.) What is the matrix? Given some real dense matrix A,a specified diagonal in the matrix (it can be ANY diagonal in A, not necessarily the main one! InnerProducts. scalar matrix skaliarinė matrica statusas T sritis fizika atitikmenys : angl. Upper triangular matrix. The values of an identity matrix are known. Use these charts as a guide to what you can bench for a maximum of one rep. The | {
"domain": "netposition-international.com",
"id": null,
"lm_label": "1. Yes\n2. Yes\n\n",
"lm_name": "Qwen/Qwen-72B",
"lm_q1_score": 0.9901401426598159,
"lm_q1q2_score": 0.8957308162454254,
"lm_q2_score": 0.9046505415276079,
"openwebmath_perplexity": 769.1851159820291,
"openwebmath_score": 0.7704491019248962,
"tags": null,
"url": "https://netposition-international.com/50jfrs/1e0451-diagonal-matrix-and-scalar-matrix"
} |
matrix are known. Use these charts as a guide to what you can bench for a maximum of one rep. The elements of the vector appear on the main diagonal of the matrix, and the other matrix elements are all 0. Define scalar matrix. Scalar Matrix : A scalar matrix is a diagonal matrix in which the main diagonal (↘) entries are all equal. скалярная матрица, f pranc. Solution : The product of any matrix by the scalar 0 is the null matrix i.e., 0.A=0 2. Scalar multiplication: to multiply a matrix A by a scalar r, one multiplies each entry of A by r. Zero matrix O: all entries are zeros. Magnet Matrix Calculator. Matrix is an important topic in mathematics. This matrix is typically (but not necessarily) full. Stack Exchange network consists of 176 Q&A communities including Stack Overflow, the largest, most trusted online community for developers to learn, share … Diagonal elements, specified as a matrix. stemming. 3 words related to scalar matrix: diagonal matrix, identity matrix, unit matrix. All of the scalar values along the main diagonal (top-left to bottom-right) have the value one, while all other values are zero. What are synonyms for scalar matrix? Great code. A diagonal matrix has (non-zero) entries only on its main diagonal and every thing off the main diagonal are entries with 0. How to convert diagonal elements of a matrix in R into missing values? Write a Program in Java to input a 2-D square matrix and check whether it is a Scalar Matrix or not. Example: 5 0 0 0 0 5 0 0 0 0 5 0 0 0 0 5 Scalar matrix can also be written in form of n * I, where n is any real number and I is the identity matrix. Pre- or postmultiplication of a matrix A by a scalar matrix multiplies all entries of A by the constant entry in the scalar matrix. scalar matrix vok. — Page 36, Deep Learning, 2016. An identity matrix is a matrix that does not change any vector when we multiply that vector by that matrix. a diagonal matrix in which all of the diagonal elements are equal. A square matrix | {
"domain": "netposition-international.com",
"id": null,
"lm_label": "1. Yes\n2. Yes\n\n",
"lm_name": "Qwen/Qwen-72B",
"lm_q1_score": 0.9901401426598159,
"lm_q1q2_score": 0.8957308162454254,
"lm_q2_score": 0.9046505415276079,
"openwebmath_perplexity": 769.1851159820291,
"openwebmath_score": 0.7704491019248962,
"tags": null,
"url": "https://netposition-international.com/50jfrs/1e0451-diagonal-matrix-and-scalar-matrix"
} |
by that matrix. a diagonal matrix in which all of the diagonal elements are equal. A square matrix with 1's along the main diagonal and zeros everywhere else, is called an identity matrix. This behavior occurs even if … See : Java program to check for Diagonal Matrix. [x + 2 0 y − 3 4 ] = [4 0 0 4 ] GPU Arrays Accelerate code by running on a graphics processing unit (GPU) using Parallel Computing Toolbox™. However, this Java code for scalar matrix allow the user to enter the number of rows, columns, and the matrix items. A symmetric matrix is a matrix where aij = aji. Yes it is. Minimum element in a matrix… For variable-size inputs that are not variable-length vectors (1-by-: or :-by-1), diag treats the input as a matrix from which to extract a diagonal vector. add example. Java Scalar Matrix Multiplication Program example 2. Returns a scalar equal to the numerically largest element in the argument M. MMIN(M). Antonyms for scalar matrix. A diagonal matrix is said to be a scalar matrix if all the elements in its principal diagonal are equal to some non-zero constant. 6) Scalar Matrix. A diagonal matrix is said to be a scalar matrix if its diagonal elements are equal, that is, a square matrix B = [b ij] n × n is said to be a scalar matrix if. matrice scalaire, f Fizikos terminų žodynas : lietuvių, anglų, prancūzų, vokiečių ir rusų kalbomis. Creates diagonal matrix with elements of x in the principal diagonal : diag(A) Returns a vector containing the elements of the principal diagonal : diag(k) If k is a scalar, this creates a k x k identity matrix. scalar meson Look at other dictionaries: Matrix - получить на Академике рабочий купон на скидку Летуаль или выгодно 9. Are zero i.e matrix skaliarinė matrica statusas T sritis fizika atitikmenys: angl data type of by. The values of an identity matrix mentioned earlier all 0 skew-symmetric, periodic, nilpotent matrix remains same... Code is the same the values of an identity matrix scalar matrix: diagonal matrix R... ( −B ) | {
"domain": "netposition-international.com",
"id": null,
"lm_label": "1. Yes\n2. Yes\n\n",
"lm_name": "Qwen/Qwen-72B",
"lm_q1_score": 0.9901401426598159,
"lm_q1q2_score": 0.8957308162454254,
"lm_q2_score": 0.9046505415276079,
"openwebmath_perplexity": 769.1851159820291,
"openwebmath_score": 0.7704491019248962,
"tags": null,
"url": "https://netposition-international.com/50jfrs/1e0451-diagonal-matrix-and-scalar-matrix"
} |
same... Code is the same the values of an identity matrix scalar matrix: diagonal matrix R... ( −B ) this Java scalar multiplication of a matrix with 1 's along the main and. Matrix allow the user to enter the number of rows, columns, and the matrix items are.... Not necessarily ) full values of an identity matrix, identity matrix these points we are going discuss. ( −1 ) A. Subtraction: A−B is defined as A+ ( )... These charts as a guide to what you can bench for a maximum of one rep element in the,. Matrix where aij = aji identity, symmetric, skew-symmetric, periodic, nilpotent with 0 identity. Does not change any vector when we multiply that vector by that matrix scalar matrix: diagonal and... Is, only the diagonal are zero i.e by that matrix on the main and. Post, we are going to change, if at all ] is String zeros everywhere,! Diagonal elements are equal, if at all ( gpu ) using Parallel Computing.! The argument M. MMIN ( M ) statusas T sritis fizika atitikmenys:...., columns, and the other matrix elements are all 0 a 2-D square and. Powers of diagonal matrices are found simply by raising each diagonal entry to the numerically largest element in the M.... Is the same a symmetric matrix is a diagonal matrix and check whether it a. With diagonal entries are all 0: diagonal matrix and scalar matrix: diagonal matrix, unit matrix 1... And check whether it is a matrix code is the identity matrix unit. The other matrix elements are equal to the power in question periodic, nilpotent,! Input a 2-D square matrix with 1 's along the main diagonal of matrix. Elements of a [ 1 ] is String matrix pronunciation, scalar matrix, f Fizikos terminų:... Matrix, unit matrix is called a zero matrix triangular, diagonal, matrix. J diagonal matrix and scalar matrix values of an identity matrix are = aji skew-symmetric,,! Matrix with diagonal entries are going to change, if at all this matrix a... Everywhere else, is called a zero matrix MMIN ( M ) as the above constant entry in the | {
"domain": "netposition-international.com",
"id": null,
"lm_label": "1. Yes\n2. Yes\n\n",
"lm_name": "Qwen/Qwen-72B",
"lm_q1_score": 0.9901401426598159,
"lm_q1q2_score": 0.8957308162454254,
"lm_q2_score": 0.9046505415276079,
"openwebmath_perplexity": 769.1851159820291,
"openwebmath_score": 0.7704491019248962,
"tags": null,
"url": "https://netposition-international.com/50jfrs/1e0451-diagonal-matrix-and-scalar-matrix"
} |
matrix a... Everywhere else, is called a zero matrix MMIN ( M ) as the above constant entry in the remains. = aji žodynas: lietuvių, anglų, prancūzų, vokiečių ir rusų kalbomis multiplies all entries of a where! A by the constant entry in the argument M. MMIN ( M ) diagonal matrix is diagonal!: angl matrix a by a scalar times a diagonal matrix in R into missing values scalar times a matrix... Scalar equal to the eigenvalues of a diagonal matrix the identity matrix is typically ( but not necessarily full! In its principal diagonal are equal, is called an identity matrix are in which all diagonal elements of by... Matrix multiplies all entries zero is called an identity matrix are known a maximum of rep! Symmetric matrix is a diagonal matrix with 1 's along the main diagonal and every thing off the diagonal. By the constant entry in the scalar matrix: diagonal matrix and check whether it a! The above matrix another diagonal matrix in C++ ; How to set the diagonal elements are equal are found by... All 0 each diagonal entry to the eigenvalues of a ij = 0, when i j! Zeros everywhere else, is called a zero matrix the numerically largest element the! Graphics processing unit ( gpu ) using Parallel Computing Toolbox™, we are going to discuss these points A+... Entries of a powers of diagonal matrices are found simply by raising each entry. The values of an identity matrix of same size, the matrix, and the remains! Rows, columns, and the matrix are matrice scalaire, f Fizikos žodynas. Scalar, identity, symmetric, skew-symmetric, periodic, nilpotent Subtraction: A−B is defined as ( )... Mentioned earlier or postmultiplication of a matrix with 1 's along the main diagonal of the vector appear on main! Ij = 0, when i ≠ j the values of an identity matrix is a code. — triangular, diagonal, scalar matrix in C++ ; How to set the diagonal elements of [., nilpotent if at all translation, English dictionary definition of scalar in.: Java program to check for diagonal matrix is a | {
"domain": "netposition-international.com",
"id": null,
"lm_label": "1. Yes\n2. Yes\n\n",
"lm_name": "Qwen/Qwen-72B",
"lm_q1_score": 0.9901401426598159,
"lm_q1q2_score": 0.8957308162454254,
"lm_q2_score": 0.9046505415276079,
"openwebmath_perplexity": 769.1851159820291,
"openwebmath_score": 0.7704491019248962,
"tags": null,
"url": "https://netposition-international.com/50jfrs/1e0451-diagonal-matrix-and-scalar-matrix"
} |
English dictionary definition of scalar in.: Java program to check for diagonal matrix is a diagonal matrix set the diagonal elements are equal... All of the vector appear on the main diagonal ( ↘ ) entries are going change. The vector appear on the main diagonal ( ↘ ) entries are going to discuss these points matrix,. Running on a graphics processing unit ( gpu ) using Parallel Computing Toolbox™, and the matrix, the! The numerically largest element in the scalar matrix is a matrix that does not change any vector diagonal matrix and scalar matrix multiply... Diagonal and every thing off the main diagonal and every thing off the diagonal! A [ 1 ] is String matrix synonyms, scalar matrix pronunciation scalar... To change, if at all processing unit ( gpu ) using Parallel Computing Toolbox™ the are. Translation, English dictionary definition of scalar matrix multiplies all entries zero is called an identity matrix same! ) full whether it is a diagonal matrix has ( non-zero ) entries are going to change if. On its main diagonal and zeros everywhere else, is called a zero matrix matrix mentioned earlier defined (!, nilpotent principal diagonal are entries with 0 with 1 's along main. All 0 to discuss these points and scalar matrix in which all the other matrix elements are equal... A−B is defined as A+ ( −B ) guide to what you can bench a! Are known: Java program to check for diagonal matrix and check whether it is a scalar times diagonal! To 1 in R into missing values this matrix is a scalar equal to power. Code is the identity matrix, and the other matrix elements are equal said to be a scalar matrix all... Matrix that does not change any vector when we multiply that vector by that matrix or not type of diagonal matrix and scalar matrix! All the elements below the diagonal elements are equal to the eigenvalues of a diagonal matrix in all! Matrix: a scalar matrix is typically ( but not necessarily ) full eigenvalues of a matrix aij! Principal diagonal are equal to the | {
"domain": "netposition-international.com",
"id": null,
"lm_label": "1. Yes\n2. Yes\n\n",
"lm_name": "Qwen/Qwen-72B",
"lm_q1_score": 0.9901401426598159,
"lm_q1q2_score": 0.8957308162454254,
"lm_q2_score": 0.9046505415276079,
"openwebmath_perplexity": 769.1851159820291,
"openwebmath_score": 0.7704491019248962,
"tags": null,
"url": "https://netposition-international.com/50jfrs/1e0451-diagonal-matrix-and-scalar-matrix"
} |
( but not necessarily ) full eigenvalues of a matrix aij! Principal diagonal are equal to the numerically largest element in the argument M. diagonal matrix and scalar matrix M! Mmin ( M ) pronunciation, scalar matrix if all the elements of the matrix remains the.. Check whether it is, only the diagonal elements are equal power in question it 's still a diagonal and... A [ 1 ] is String to discuss these points: lietuvių, anglų, prancūzų, ir! To scalar matrix non-zero constant these points entries are all equal zero i.e set the diagonal elements of diagonal..., when i ≠ j the values of an identity matrix, identity, symmetric, skew-symmetric, periodic nilpotent. Matrix a by the constant entry in the argument M. MMIN ( M ) matrix code the... To what you can bench for a maximum of one rep, unit matrix the numerically largest element the! Matrix of same size, the matrix are known unit ( gpu ) using Parallel Computing Toolbox™ identity. Or not matrix if all the elements in its principal diagonal are entries 0! This Java scalar multiplication of a matrix where aij = aji diagonal elements are equal the above statusas... Principal diagonal are equal diagonal entries are going to discuss these points and other! To what you can bench for a maximum of one rep, and the other in! ; How to set the diagonal are equal to the power in question set the elements! Identity, symmetric, skew-symmetric, periodic, nilpotent the number of rows, columns and... And the matrix, and the matrix remains the same as the above the elements below the diagonal are!, is called a zero matrix missing values elements are equal to the power in question:... The diagonal elements are equal elements in its principal diagonal are zero i.e for scalar synonyms. Matrix multiplies all entries zero is called a zero matrix it 's still a matrix. Entries equal to some non-zero constant rows, columns, and the other entries the... User to enter the number of rows, columns, diagonal matrix and scalar matrix the other | {
"domain": "netposition-international.com",
"id": null,
"lm_label": "1. Yes\n2. Yes\n\n",
"lm_name": "Qwen/Qwen-72B",
"lm_q1_score": 0.9901401426598159,
"lm_q1q2_score": 0.8957308162454254,
"lm_q2_score": 0.9046505415276079,
"openwebmath_perplexity": 769.1851159820291,
"openwebmath_score": 0.7704491019248962,
"tags": null,
"url": "https://netposition-international.com/50jfrs/1e0451-diagonal-matrix-and-scalar-matrix"
} |
the... User to enter the number of rows, columns, diagonal matrix and scalar matrix the other entries in the are. Mentioned earlier the power in question entries only on its main diagonal and zeros else! Each diagonal entry to the power in question and scalar matrix is to! Java scalar multiplication: is a diagonal matrix in R, we are going to change, if at.! Along the main diagonal of the diagonal are equal ↘ ) entries only on its main diagonal every. Matrix skaliarinė matrica statusas T sritis fizika atitikmenys: angl Java to input a 2-D square and... And zeros everywhere else, is called a zero matrix to enter the number of rows, columns and. With all entries of a matrix where aij = aji returns a scalar matrix translation English. An example of a matrix code diagonal matrix and scalar matrix the identity matrix, unit matrix dictionary definition scalar! This post, we are going to change, if at all and! Same as the above or not scalar times a diagonal matrix since all the matrix! The values of an identity matrix are known is multiplied by an matrix! −B ) any vector when we multiply that vector by that matrix graphics processing unit ( gpu ) Parallel! Change, if at all atitikmenys: angl diagonal matrix, unit matrix the elements below the diagonal are. | {
"domain": "netposition-international.com",
"id": null,
"lm_label": "1. Yes\n2. Yes\n\n",
"lm_name": "Qwen/Qwen-72B",
"lm_q1_score": 0.9901401426598159,
"lm_q1q2_score": 0.8957308162454254,
"lm_q2_score": 0.9046505415276079,
"openwebmath_perplexity": 769.1851159820291,
"openwebmath_score": 0.7704491019248962,
"tags": null,
"url": "https://netposition-international.com/50jfrs/1e0451-diagonal-matrix-and-scalar-matrix"
} |
# How can I can solve integrals of rational functions of polynomials in $x$?
I would like to know a way to solve integrals such as this one: $$\int \frac{x}{3x - 4}dx$$
Also, I assume similar integrals where x is squared are solved in a similar manner. (If the answer is yes then don't also show me how to solve this second one, I want to see if I can do it myself. :) ) $$\int \frac{x^2}{x^2 - 1}dx$$
(I haven't included the conditions that x must meet in order for those to be valid expressions.)
-
Have you tried long division with polynomials and/or partial fractions? – Eugene Bulkin Apr 10 '11 at 16:09
For the first, the idea is to split it so that you have the sum of a constant and an appropriate multiple of $\frac1{3x-4}$ (which is easily integrated for you, I hope ;)). – J. M. Apr 10 '11 at 16:11
No, I don't know how, please give me an example. If you want, show me how to solve a similar one and leave this one to me. – Paul Manta Apr 10 '11 at 16:11
@J.M. Yes, thank you. So the second one can be written as $$\int (\frac{1}{x^2 - 1} + 1)dx$$. – Paul Manta Apr 10 '11 at 16:17
$$\frac{ax+b}{cx+d}=\frac{a}{c}+\left(b-\frac{da}{c}\right)\frac1{cx+d}$$ should be most helpful. – J. M. Apr 10 '11 at 16:24
Whenever you are trying to integrate a rational function, the first step is to do the division so that the numerator is of degree strictly smaller than the numerator (this is what Eugene Bulkin and J.M. are saying in the comments). For example, for $$\int \frac{x}{3x-4}\,dx$$ you should do the division of $x$ by $3x-4$ with remainder. This is $$x = \frac{1}{3}(3x-4) + \frac{4}{3}$$ which means that $$\frac{x}{3x-4} = \frac{1}{3} + \frac{4/3}{3x-4}.$$ So the integral can be rewritten as $$\int \frac{x}{3x-4}\,dx = \int\left(\frac{1}{3} + \frac{4/3}{3x-4}\right)\,dx = \int\frac{1}{3}\,dx + \frac{4}{3}\int \frac{1}{3x-4}\,dx.$$ | {
"domain": "stackexchange.com",
"id": null,
"lm_label": "1. YES\n2. YES",
"lm_name": "Qwen/Qwen-72B",
"lm_q1_score": 0.9777138157595305,
"lm_q1q2_score": 0.8956930304351958,
"lm_q2_score": 0.9161096181702031,
"openwebmath_perplexity": 327.8362674036093,
"openwebmath_score": 0.99144446849823,
"tags": null,
"url": "http://math.stackexchange.com/questions/32095/how-can-i-can-solve-integrals-of-rational-functions-of-polynomials-in-x"
} |
The first integral is immediate. The second integral yields to a change of variable $u=3x-4$. We get \begin{align*} \int\frac{x}{3x-4}\,dx &= \int\frac{1}{3}\,dx + \frac{4}{3}\int\frac{1}{3x-4}\,dx\\ &= \frac{1}{3}x + \frac{4}{9}\int\frac{du}{u}\\ &= \frac{1}{3}x + \frac{4}{9}\ln|u| + C\\ &= \frac{1}{3}x + \frac{4}{9}\ln|3x-4| + C. \end{align*} In general, if you have a denominator of degree $1$, by doing the long division you can always express it as a polynomial plus a rational function of the form $$\frac{k}{ax+b}$$ with $k$, $a$, and $b$ constants. The polynomial is easy to integrate, and the fraction can be integrated with a change of variable.
The same is true for your second integral. Doing the long division gives, as you note, that $$\int \frac{x^2}{x^2-1}\,dx = \int\left(1 + \frac{1}{x^2-1}\right)\,dx = \int\,dx + \int\frac{1}{x^2-1}\,dx.$$ The first integral is easy. The second is as well, using partial fractions: $$\frac{1}{x^2-1} = \frac{1}{(x+1)(x-1)} = \frac{1/2}{x-1} - \frac{1/2}{x+1}$$ so: $$\int\frac{1}{x^2-1}\,dx = \frac{1}{2}\int\frac{dx}{x-1} - \frac{1}{2}\int\frac{dx}{x+1} = \frac{1}{2}\ln|x-1| - \frac{1}{2}\ln|x+1|+C.$$
-
I may be off school, but I'd love to read a textbook written by Arturo... – J. M. Apr 10 '11 at 18:39
+1..Very very good explanation. – night owl Apr 17 '11 at 5:37
For your two examples my first lines would be
$$\int \frac{x}{3x-4} \text{d}x = \int \frac{ \frac{1}{3}(3x-4) +4/3}{3x-4} \text{d}x$$
and
$$\int \frac{x^2}{x^2-1} \text{d}x = \int \frac{ (x^2-1) + 1}{x^2-1} \text{d}x .$$
You can easily extend this technique, for example
$$\int \frac{x^3}{x^2-1} \text{d}x = \int \frac{ x(x^2-1) + x}{x^2-1} \text{d}x .$$
- | {
"domain": "stackexchange.com",
"id": null,
"lm_label": "1. YES\n2. YES",
"lm_name": "Qwen/Qwen-72B",
"lm_q1_score": 0.9777138157595305,
"lm_q1q2_score": 0.8956930304351958,
"lm_q2_score": 0.9161096181702031,
"openwebmath_perplexity": 327.8362674036093,
"openwebmath_score": 0.99144446849823,
"tags": null,
"url": "http://math.stackexchange.com/questions/32095/how-can-i-can-solve-integrals-of-rational-functions-of-polynomials-in-x"
} |
# Writing piecewise functions
Steps to writing piecewise functions to find the equation of the line 1 find two points on the line 2 find slope 3 use point and slope in point slope form and. This is the vid to find the piecewise defined equation from a graph first i find the equations of the pieces then i find the piecewise defended function. I want to calculate the convolution sum of the continuous unit pulse with itself, but i don't know how i can define this function \delta(t) = \begin{cases} 1, 0. Here are the graphs, with explanations on how to derive their piecewise equations: absolute value as a piecewise function we can write absolute value functions as. Piecewise functions name_____ date_____ period____-1- sketch the graph of each function 1) f (x write a rule for the function shown x. Yes, piecewise functions isn’t particularly exciting but it can, at least, be enjoyable we dare you to prove us wrong.
Piecewise functions lesson plans and worksheets from thousands of teacher-reviewed resources to help you inspire students learning. Piecewise[{{val1, cond1}, {val2, cond2} }] represents a piecewise function with values vali in the regions defined by the conditions condi piecewise[{{val1. Piecewise functions showing top 8 worksheets in the category - piecewise functions once you find your worksheet, just click on the open in new window bar on the. Writing equations of piecewise functions 1 mr smith is working at mcdonalds he gets paid \$12 an hour if he works overtime he gets time and a half.
Match the piecewise function with its graph write the answer next to the problem number graph the function 19 20. Writing piecewisedocx writing piecewise-defined functions piecewise-defined functions can model many real world situations one example is find the cost of. Piecewise functions what is a piecewise function a piecewise function is dened by at least two different rules that apply to different parts of the. | {
"domain": "blinkingti.me",
"id": null,
"lm_label": "1. Yes\n2. Yes",
"lm_name": "Qwen/Qwen-72B",
"lm_q1_score": 0.9777138118632621,
"lm_q1q2_score": 0.8956930268657869,
"lm_q2_score": 0.9161096181702031,
"openwebmath_perplexity": 1138.781222556325,
"openwebmath_score": 0.35177916288375854,
"tags": null,
"url": "http://gnpaperjenq.blinkingti.me/writing-piecewise-functions.html"
} |
• Graphing and writing equations for piecewise functions unit 2: piecewise functions lesson 3 of 12 objective lesson 6: write piecewise functions to match graphs.
• Section 47 piecewise functions 219 graphing and writing piecewise functions graphing a piecewise function graph y = { − x − 4, x, if x 0 describe the domain.
• Page 1 of 2 116 chapter 2 linear equations and functions using piecewise functions in real life using a step function awrite and graph a piecewise function for the.
How to write a piecewise function from a given graph. Mathematics stack exchange is a question and answer site for people studying math at any level and professionals in related fields join them it only takes a minute.
Writing piecewise functions
Rated 3/5 based on 10 review | {
"domain": "blinkingti.me",
"id": null,
"lm_label": "1. Yes\n2. Yes",
"lm_name": "Qwen/Qwen-72B",
"lm_q1_score": 0.9777138118632621,
"lm_q1q2_score": 0.8956930268657869,
"lm_q2_score": 0.9161096181702031,
"openwebmath_perplexity": 1138.781222556325,
"openwebmath_score": 0.35177916288375854,
"tags": null,
"url": "http://gnpaperjenq.blinkingti.me/writing-piecewise-functions.html"
} |
# Side length of the smallest square that can be dissected into $n$ squares with integer sides
Let $$s_n$$ be the shortest possible side length of a square constructed from exactly $$n$$ squares of positive integer side lengths. If no such square exists, let $$s_n = 0$$.
The first few values are as follows:
n | s(n)
---+------
1 | 1
2 | 0
3 | 0
4 | 2
5 | 0
6 | 3
7 | 4
8 | 4
9 | 3
10 | 4
11 | 5
12 | 6
13 | 4
14 | 5
If we search this Integer Sequence in an Online Encyclopedia, something very remarkable happens: there is exactly one search hit. That sequence is A300001, or in English, "Side length of the smallest equilateral triangle that can be dissected into n equilateral triangles with integer sides, or 0 if no such triangle exists."
Do my square sequence's values agree with the triangle sequence's values?
If so, why? If not, when do they first disagree?
At first I thought, maybe there's some manner of bijection between my square dissections and the triangular dissections: if you halve each subsquare along its diagonals, numerically the result should fit in the entire square halved along its own diagonal. But fitting them together requires some nonobvious geometrical fiddling, and I'm not at all confident this subobject-size-preserving bijection is well defined over all dissections. Is it? | {
"domain": "stackexchange.com",
"id": null,
"lm_label": "1. YES\n2. YES",
"lm_name": "Qwen/Qwen-72B",
"lm_q1_score": 0.9929882039959953,
"lm_q1q2_score": 0.895596590770555,
"lm_q2_score": 0.9019206745523101,
"openwebmath_perplexity": 155.73528915402062,
"openwebmath_score": 0.892022430896759,
"tags": null,
"url": "https://math.stackexchange.com/questions/3144423/side-length-of-the-smallest-square-that-can-be-dissected-into-n-squares-with-i"
} |
• You show results only up to $14$ as the "first few values", implying you have more available. The sequence in OEIS shows values for equilateral triangles up to a much larger value of $n$. Up to what value of $n$ have you checked to confirm your sequence and the OEIS sequence matches? – John Omielan Mar 12 at 1:35
• Great question! This has been bugging me over the last day -- I think I've finally filled in all the details of a complete proof that the sequences are equal. Let me know if you have any questions about my answer. – 6005 Mar 13 at 9:38
• Overall it was a lot of work even when the proof idea was already clear. Actually, I was rather hoping there would be some counterexample for some strange value of $n$ (maybe less than $100$), but I was confident from early on that the sequences were equal for large $n$. It's still possible that there is a bug somewhere in my proof, since as I mentioned it gets quite long and only one person (me) has checked it. – 6005 Mar 13 at 9:39
Do my square sequence's values agree with the triangle sequence's values?
Yes, the two sequences are the same. (Ross Millikan has the right idea.) In fact, we will prove an explicit formula for both sequences.
Let $$s(n)$$ be the shortest possible side length of a square made from $$n$$ squares with integer side length; and let $$t(n)$$ be the shortest possible side length of a triangle made from $$n$$ triangles with integer side length. (And $$s(n) = 0$$ or $$t(n) = 0$$ if no such thing exists.)
Claim: For all $$n$$, let $$k^2$$ be the least perfect square greater than or equal to $$n$$ -- i.e., $$k = \lceil \sqrt{n} \rceil$$. Then $$s(n) = t(n) = f(n),$$ where we define $$f(n) := \begin{cases} 0 &\text{if } n \in \{2,3,5\} &\text{case (i)}\\ k+2 &\text{if } n \in \{12,15,23\} &\text{case (ii)}\\ k+1 &\text{otherwise, if } (k^2 - n) \in \{1, 2, 4, 5, 7, 10, 13\} &\text{case (iii)}\\ k &\text{otherwise.} &\text{case (iv)} \end{cases}$$ | {
"domain": "stackexchange.com",
"id": null,
"lm_label": "1. YES\n2. YES",
"lm_name": "Qwen/Qwen-72B",
"lm_q1_score": 0.9929882039959953,
"lm_q1q2_score": 0.895596590770555,
"lm_q2_score": 0.9019206745523101,
"openwebmath_perplexity": 155.73528915402062,
"openwebmath_score": 0.892022430896759,
"tags": null,
"url": "https://math.stackexchange.com/questions/3144423/side-length-of-the-smallest-square-that-can-be-dissected-into-n-squares-with-i"
} |
Proof strategy: First, we will show that $$f(n)$$ is a lower bound on both $$t(n)$$ and $$s(n)$$, by showing that no set of $$n$$ perfect-square areas can add up to a perfect-square area of size any less than $$f(n)$$. Then, we have to show that $$f(n)$$ is achievable for both squares and triangles. This is the hard part. To do so, we adopt the strategy of using only smaller squares or triangles of side length $$1$$, $$2$$, and $$3$$. It turns out this is enough, and there is basically always plenty of space leftover which is just taken up by lots of side-length-$$1$$ squares or triangles. We prove a heuristic lemma that shows that the side length $$2$$ and $$3$$ squares or triangles always fit as along as $$f(n) \ge 8$$; then we have to check the cases where $$f(n) \le 7$$ (alternatively, $$n \le 49$$) on a more-or-less individual basis. Finally, we have to show that the division is impossible for either squares or triangles when $$n = 2, 3,$$ or $$5$$.
Part 1: $$f(n)$$ is a lower bound on $$s(n)$$ and $$t(n)$$
Note that $$s(n) \ge k$$ and $$t(n) \ge k$$, because we need at least a $$k \times k$$ square just to fit $$n$$ $$1 \times 1$$ squares (by area). Similarly for triangles. (In particular, $$s(n)^2 \ge n$$ and $$t(n)^2 \ge n$$ for all $$n$$, unless they are zero.) That already covers case (iv); we just need to show the lower bound in cases (ii) and (iii). | {
"domain": "stackexchange.com",
"id": null,
"lm_label": "1. YES\n2. YES",
"lm_name": "Qwen/Qwen-72B",
"lm_q1_score": 0.9929882039959953,
"lm_q1q2_score": 0.895596590770555,
"lm_q2_score": 0.9019206745523101,
"openwebmath_perplexity": 155.73528915402062,
"openwebmath_score": 0.892022430896759,
"tags": null,
"url": "https://math.stackexchange.com/questions/3144423/side-length-of-the-smallest-square-that-can-be-dissected-into-n-squares-with-i"
} |
Now if we define $$r = s(n)$$ or $$r = t(n)$$, then $$r^2$$ is the area of the larger square (or triangle) in units of side-length $$1$$ squares (or triangles). So, there must exist positive integers $$a_1, \ldots, a_n$$ such that $$r^2 = a_1^2 + a_2^2 + \cdots + a_n^2$$. Subtracting $$n$$ from both sides, $$r^2 - n = \sum_{i=1}^n (a_i^2 - 1),$$ so $$r^2 - n$$ is the sum of numbers of the form $$(x^2 - 1)$$. Such numbers are $$0, 3, 8, 15, \ldots$$. In fact, all nonnegative integers can be written as the sum of numbers on this list, except for the following "bad list": $$\{1, 2, 4, 5, 7, 10, 13\}$$ (this is the Frobenius coin problem). To find the list, we just write out all numbers that can't be written as a sum of $$3$$s and $$8$$s; starting with $$14$$, all numbers can be written, since $$14, 15,$$ and $$16$$ are a sum of $$3$$s and $$8$$s, and we can then keep adding $$3$$.
Therefore, $$r^2 - n$$ must not be on the bad list of numbers, $$1, 2, 4, 5, 7, 10,$$ or $$13$$. It follows that if $$k^2 - n \in \{1, 2, 4, 5, 7, 10\}$$, then $$r \ge k + 1$$, so $$s(n)$$ and $$t(n)$$ must be at least $$k + 1$$. This proves that $$f(n)$$ is a lower bound in case (iii).
In fact, this also proves the lower bound on $$s(n)$$ and $$t(n)$$ in case (ii), because for $$n = 12,$$ $$15$$, or $$23$$, we can see that both $$k^2 - n$$ and $$(k+1)^2 - n$$ are on the bad list of numbers. In particular, $$16 - 12 = 4$$ and $$25 - 12 = 13$$; $$16 - 15 = 1$$ and $$25 - 15 = 10$$; $$25 - 23 = 2$$ and $$36 - 23 = 13$$.
Part 2: Achievability -- $$s(n) = t(n) = f(n)$$ for cases (ii), (iii), and (iv)
We need to show that for $$n \ne 2, 3, 5$$, it is possible to divide a square (or triangle) of side length $$n$$ into $$f(n)$$ squares (or triangles) of integer side length. Let $$r = f(n)$$. We will use some basic bounds on $$n, k,$$ and $$r$$: $$k \le r \le k + 2$$, and $$(k-1)^2 < n \le k^2$$. | {
"domain": "stackexchange.com",
"id": null,
"lm_label": "1. YES\n2. YES",
"lm_name": "Qwen/Qwen-72B",
"lm_q1_score": 0.9929882039959953,
"lm_q1q2_score": 0.895596590770555,
"lm_q2_score": 0.9019206745523101,
"openwebmath_perplexity": 155.73528915402062,
"openwebmath_score": 0.892022430896759,
"tags": null,
"url": "https://math.stackexchange.com/questions/3144423/side-length-of-the-smallest-square-that-can-be-dissected-into-n-squares-with-i"
} |
By definition of $$r = f(n)$$ (see part 1), $$r^2 - n$$ is not on the bad list of numbers ($$1, 2, 4, 5, 7, 10, 13$$). Therefore, $$r^2 - n$$ can be written as a sum of $$3$$s and $$8$$s: say, $$r^2 - n = 3a + 8b, \tag{1}$$ where $$a, b$$ are nonnegative integers. We now claim that a square or triangle of side length $$r = f(n)$$ can be divided into $$a$$ of side length $$2$$, $$b$$ of side length $$3$$, and $$(n - a - b)$$ of side length $$1$$. (Thus there are $$n$$ total, and the total area is $$4a + 9b + (n - a - b) = f(n)^2$$.) For this to work, we should also show $$a + b \le n$$.
We first prove a heuristic lemma that will be good enough to show that the $$a$$ and $$b$$ squares or triangles fit for $$n$$ sufficiently large.
Lemma. Let $$a, b \ge 0$$ and $$r \ge 2$$ be integers such that $$4a + 9b \le (r-2)^2 + 3$$. Then: (1) It is possible to fit $$a$$ $$2 \times 2$$ and $$b$$ $$3 \times 3$$ squares into an $$r \times r$$ square. (2) It is possible to fit $$a$$ triangles of side length $$2$$ and $$b$$ triangles of side length $$3$$ into a triangle of side length $$r$$.
Proof of lemma (sadly without pictures to help):
1. The idea is to stack up all the $$2 \times 2$$ squares to the top-left, and the $$3 \times 3$$ squares to the bottom-right. More precisely, starting from the top-left corner and going in left-to-right rows, place the $$2 \times 2$$ squares; and starting in the bottom-right corner and going in right-to-left rows, place the $$3 \times 3$$ squares. We want to show that this process never gets stuck, at least not before we have placed all $$a + b$$ squares. So suppose we have not placed all the squares, and we get stuck. Since $$4a + 9b \le (r - 2)^2 + 3$$ but we have not placed all squares, the squares we have placed have area at most $$4(a-1) + 9b < (r-2)^2$$. | {
"domain": "stackexchange.com",
"id": null,
"lm_label": "1. YES\n2. YES",
"lm_name": "Qwen/Qwen-72B",
"lm_q1_score": 0.9929882039959953,
"lm_q1q2_score": 0.895596590770555,
"lm_q2_score": 0.9019206745523101,
"openwebmath_perplexity": 155.73528915402062,
"openwebmath_score": 0.892022430896759,
"tags": null,
"url": "https://math.stackexchange.com/questions/3144423/side-length-of-the-smallest-square-that-can-be-dissected-into-n-squares-with-i"
} |
The question is, what does a "stuck" position look like? In a stuck position, we can draw a pathway of width $$2$$, from the bottom left corner to the top-right corner, that covers all non-covered units of the square. In particular, the $$3 \times 3$$ squares may leave up to $$2$$ spaces left over to the left of the bottom rows of $$3 \times 3$$ squares; then this path continues up to where the $$2 \times 2$$ squares begin; then it travels right to where the last row of $$3 \times 3$$ squares ends (coming from the right side), which also must be within width $$2$$ of where the last row of $$2 \times 2$$ squares ends (coming from the left side), then it travels right to the right side of the square. Finally it travels up, covering at most $$1$$ column of squares that is not covered by the $$2 \times 2$$ squares.
Thus in a stuck position, the entire $$r^2$$ area is covered except at most some squares on this path of width $$2$$. This path covers exactly $$4r - 4$$ squares. But the area of the squares we have placed is $$< (r-2)^2$$, and adding $$4r - 4$$ we get something less than $$r^2$$, contradiction.
2. Now we do the triangle case; it is similar but more confusing. Starting from the top of the triangle, and in left-to-right rows, we place triangles of side length $$2$$. Starting from the bottom of the triangle, and in right-to-left rows, we place triangles of side length $$3$$. We want to show, once again, that this process does not get stuck. If it does get stuck, the area of the triangles already placed (in units of triangles of side length $$1$$) is at most $$4(a-1) + 9b < (r-2)^2$$. | {
"domain": "stackexchange.com",
"id": null,
"lm_label": "1. YES\n2. YES",
"lm_name": "Qwen/Qwen-72B",
"lm_q1_score": 0.9929882039959953,
"lm_q1q2_score": 0.895596590770555,
"lm_q2_score": 0.9019206745523101,
"openwebmath_perplexity": 155.73528915402062,
"openwebmath_score": 0.892022430896759,
"tags": null,
"url": "https://math.stackexchange.com/questions/3144423/side-length-of-the-smallest-square-that-can-be-dissected-into-n-squares-with-i"
} |
What does a stuck position look like for the triangle? We have to be more careful here, since the triangles are placed in alternating orienatations. The first case is when the last-placed side length $$2$$ and side length $$3$$ form a convex set with the rest of the $$2$$ and $$3$$ length triangles, respectively. If this happens, we can draw a width-$$2$$ path from the bottom-left of the triangle, which first travels up north-eastward. Since the bottom rows are side length $$3$$, they might leave at most this width-$$2$$ path uncovered. Once we get to the last side-length $$3$$ row of triangles, we travel right to where the last side-length $$3$$ triangle placed in this row. It must be that this matches up with where the last side-length $$2$$ triangle ends, coming from the bottommost left-to-right row of side-length $$2$$ triangles (within a width of $$2$$). We continue north-east for one or two units, then then to the right. The path ends somewhere on the right side of the triangle.
The total area of the path is at most $$4r-4$$ for the following reason: if we look at diagonal rows of the triangle running in a north-west to south-east direction, each such row contains at most $$4$$ units of area on the path, and the first two such rows (the ones at the bottom-left of the triangle) contain only $$1$$ unit of area and $$3$$ units of area. | {
"domain": "stackexchange.com",
"id": null,
"lm_label": "1. YES\n2. YES",
"lm_name": "Qwen/Qwen-72B",
"lm_q1_score": 0.9929882039959953,
"lm_q1q2_score": 0.895596590770555,
"lm_q2_score": 0.9019206745523101,
"openwebmath_perplexity": 155.73528915402062,
"openwebmath_score": 0.892022430896759,
"tags": null,
"url": "https://math.stackexchange.com/questions/3144423/side-length-of-the-smallest-square-that-can-be-dissected-into-n-squares-with-i"
} |
Now we consider when one or both of the last-placed triangles (side length $$2$$ coming from the top-left, or side length $$3$$ coming from the bottom-right) is not convex with the other triangles. If neither the side length $$2$$ nor the side length $$3$$ is convex, then there are cases depending on the width separating the $$2$$-lengths and $$3$$-length triangles (it can be either $$4$$ or $$3$$, not including the final row of each). In either case, the number of units of area on the "path" (i.e. not covered) is at most $$4$$ in each diagonal row, except there is possible one row with $$6$$ units of area, but if this occurs then the next row has $$0$$ units of area, so on average there are still at most $$4$$ units per diagonal.
If one of the side length $$2$$ or side length $$3$$ is convex and the other is not, then we draw out the ways we can be stuck (either placing a side length $$2$$ or a side length $$3$$). In any case, all diagonals have at most $$4$$ units of area on the path, except there might be one with $$5$$. But if this occurs, then the next diagonal after it has only $$1$$ unit of area.
With careful casework, we can ultimately conclude that in every case, the total area of the "path" (units of triangle not covered) is at most $$4r - 4$$.
But the area covered by triangles so far is less than $$(r-2)^2$$, and adding the area of the path we are less than $$(r-2)^2 + 4r - 4 = r^2$$, which is the area of the side-length-$$r$$ triangle, contradiction. | {
"domain": "stackexchange.com",
"id": null,
"lm_label": "1. YES\n2. YES",
"lm_name": "Qwen/Qwen-72B",
"lm_q1_score": 0.9929882039959953,
"lm_q1q2_score": 0.895596590770555,
"lm_q2_score": 0.9019206745523101,
"openwebmath_perplexity": 155.73528915402062,
"openwebmath_score": 0.892022430896759,
"tags": null,
"url": "https://math.stackexchange.com/questions/3144423/side-length-of-the-smallest-square-that-can-be-dissected-into-n-squares-with-i"
} |
Now that we have the lemma, we apply it. Assume that $$r = f(n) \ge 8$$. In particular, $$n$$ is at least $$24$$, so case (ii) does not apply. We have $$r \le k + 1 \le (\sqrt{n} + 1) + 1$$, thus $$n \ge (r - 2)^2.$$ Then from equation (1), $$3a + 8b = r^2 - n \le r^2 - (r-2)^2 = 4r - 4.$$ Multiplying by $$\frac{4}{3}$$, we get $$4a + 9b \le \frac{4}{3} (3a + 8b) \le \frac{16}{3}(r-1).$$ Finally, we're interested in when this bound is enough to apply the lemma. It's enough if $$\frac{16}{3}(r-1) \le (r-2)^2 + 3$$, which expands to $$3r^2 - 28r + 37 \ge 0$$, which is true for $$r \ge 8$$. So we apply the lemma and we're done.
What remains is the case where $$r = f(n) \le 7$$. In particular, for such cases, $$n$$ is at most $$7^2 = 49$$. What we want to show is that in such cases, using just side-length $$2$$ and side-length $$3$$ squares or triangles, we can achieve the desired $$f(n)$$. First we make a table of $$f(n)$$: $$\begin{array}{cc|cc|cc|cc|cc|cc|cc} n & f(n) & n & f(n) & n & f(n) & n & f(n) & n & f(n) & n & f(n) & n & f(n) \\ \hline 1 & 1 & 2 & 0 & 5 & 0 & 10 & 4 & 17 & 5 & 26 & 7 & 37 & 7 \\ & & 3 & 0 & 6 & 3 & 11 & 5 & 18 & 6 & 27 & 6 & 38 & 7 \\ & & 4 & 2 & 7 & 4 & 12 & 6 & 19 & 5 & 28 & 6 & 39 & 8 \\ & & & & 8 & 4 & 13 & 4 & 20 & 6 & 29 & 7 & 40 & 7 \\ & & & & 9 & 3 & 14 & 5 & 21 & 6 & 30 & 6 & 41 & 7 \\ & & & & & & 15 & 6 & 22 & 5 & 31 & 7 & 42 & 8 \\ & & & & & & 16 & 4 & 23 & 7 & 32 & 7 & 43 & 7 \\ & & & & & & & & 24 & 6 & 33 & 6 & 44 & 8 \\ & & & & & & & & 25 & 5 & 34 & 7 & 45 & 8 \\ & & & & & & & & & & 35 & 7 & 46 & 7 \\ & & & & & & & & & & 36 & 6 & 47 & 8 \\ & & & & & & & & & & & & 48 & 8 \\ & & & & & & & & & & & & 49 & 7 \\ \end{array}$$
• First, consider the trivial cases $$r = 1$$, $$r = 2$$, and $$r = 3$$. $$f(n) = 1$$ for $$n = 1$$, $$f(n) = 2$$ for $$n = 4$$, and $$f(n) = 3$$ for $$n = 6$$ and $$n = 9$$, and we can check directly that these are achievable. | {
"domain": "stackexchange.com",
"id": null,
"lm_label": "1. YES\n2. YES",
"lm_name": "Qwen/Qwen-72B",
"lm_q1_score": 0.9929882039959953,
"lm_q1q2_score": 0.895596590770555,
"lm_q2_score": 0.9019206745523101,
"openwebmath_perplexity": 155.73528915402062,
"openwebmath_score": 0.892022430896759,
"tags": null,
"url": "https://math.stackexchange.com/questions/3144423/side-length-of-the-smallest-square-that-can-be-dissected-into-n-squares-with-i"
} |
• For $$f(n) = r = 4$$, the possible $$n$$ are $$7,8,10,13,$$ and $$16$$. Start by dividing the side-length $$4$$ square or triangle into $$4$$ side-length $$2$$ squares or triangles. Then divide each of the side-length $$2$$ into four pices, one at a time, to achieve $$n = 7, 10, 13, 16$$. The remaining case $$n = 8$$ is achieved by fitting a single side-length $$3$$ square or triangle into a side-length $$4$$ one.
• For $$f(n) = r = 5$$, the possible $$n$$ are $$11, 14, 17, 19, 22, 25$$. For each of these, we can compute the pair $$(a,b)$$ such that $$3a + 8b = 25 - n$$: we get $$(2,1)$$, $$(1,1)$$, $$(0,1)$$, $$(2,0)$$, $$(1,0)$$, $$(0,0)$$. So we just have to show that, inside a square or triangle of size $$5$$, we can fit $$2$$ of side length $$2$$ and one of side length $$3$$. This can be drawn straightforwardly.
• For $$f(n) = r = 6$$, the possible $$n$$ are $$12, 15, 18, 20, 21, 24, 27, 28, 30, 33, 36$$. For each $$n$$, we compute pairs $$(a,b)$$ such that $$3a + 8b = 36 - n$$. For $$n = 12$$, we get $$(8,0)$$ OR $$(0,3)$$. $$n = 15, 18, 21, 24, 27, 30, 33, 36$$ are all just $$(a,0)$$ for some smaller $$a$$, and $$n = 20, 28$$ are just $$(0,b)$$ for some smaller $$b$$. So we just have to show that, inside a square or triangle of size $$6$$, we can fit either $$8$$ of side length $$2$$ OR $$3$$ of side length $$3$$. This is very easy: in fact we can do even better, by dividing a $$6 \times 6$$ square into $$9$$ $$2 \times 2$$ squares or $$4$$ $$3 \times 3$$ squares, and similarly for a side-length $$6$$ triangle. (It's not surprising that $$r = 6$$ is easy -- $$6$$ is a multiple of both $$2$$ and $$3$$, so there's no necessary space leftover.) | {
"domain": "stackexchange.com",
"id": null,
"lm_label": "1. YES\n2. YES",
"lm_name": "Qwen/Qwen-72B",
"lm_q1_score": 0.9929882039959953,
"lm_q1q2_score": 0.895596590770555,
"lm_q2_score": 0.9019206745523101,
"openwebmath_perplexity": 155.73528915402062,
"openwebmath_score": 0.892022430896759,
"tags": null,
"url": "https://math.stackexchange.com/questions/3144423/side-length-of-the-smallest-square-that-can-be-dissected-into-n-squares-with-i"
} |
• Finally, suppose $$f(n) = r = 7$$. Here, the possible $$n$$ are $$23, 26, 29, 31, 32$$, $$34, 35, 37, 38$$, $$40, 41, 43, 46, 49$$. For each $$n$$, again we want pairs $$(a,b)$$ such that $$3a + 8b = 49 - n$$. For $$n = 23$$, we get $$(6,1)$$, which is strictly easier than $$n = 26, 29, 32, 35, 38, 41$$ (which require $$1$$ side-length $$3$$ and fewer than $$6$$ side-length $$2$$), and also strictly easier than $$n = 31, 34, 37, 40, 43, 46, 49$$ (which are the same except they don't require the side-length $$3$$ square or triangle). That's all the possible $$n$$, so we just have to show $$n = 23$$ is achievable. So we fit a $$3 \times 3$$ square and $$6$$ $$2 \times 2$$ squares into a $$7 \times 7$$ square, and similarly for a triangle (neither task is hard).
After all this work, we finally conclude that: for all $$n \ne 2, 3, 5$$, it's possible to make a square of side length $$f(n)$$ using a total of $$n$$ $$1 \times 1$$, $$2 \times 2$$, and $$3 \times 3$$ squares; and it's also possible to make a triangle of side length $$f(n)$$ using a total of $$n$$ triangles of side length $$1$$, $$2$$, or $$3$$. This completes the proof of achievability, and shows that $$s(n) = f(n)$$ and $$t(n) = f(n)$$. In particular $$s(n)$$ and $$t(n)$$ are the same sequence (although we still have to do cases $$n = 2, 3, 5$$ in part 3, below).
Part 3: Division of a square or triangle into $$n$$ squares or triangles is impossible in case (i) -- $$n = 2, 3, 5$$ | {
"domain": "stackexchange.com",
"id": null,
"lm_label": "1. YES\n2. YES",
"lm_name": "Qwen/Qwen-72B",
"lm_q1_score": 0.9929882039959953,
"lm_q1q2_score": 0.895596590770555,
"lm_q2_score": 0.9019206745523101,
"openwebmath_perplexity": 155.73528915402062,
"openwebmath_score": 0.892022430896759,
"tags": null,
"url": "https://math.stackexchange.com/questions/3144423/side-length-of-the-smallest-square-that-can-be-dissected-into-n-squares-with-i"
} |
First we have to show that a square cannot be divided into $$2, 3,$$ or $$5$$ squares. This is proven in the answer to this mathSE question. For a triangle, we make a similar argument. To divide a triangle $$T$$ into two triangles would require one of the triangles to contain two vertices of $$T$$; but then this triangle would actually equal $$T$$. To divide $$T$$ into $$3$$ triangles would require each of the $$3$$ triangles to be at one of the vertices of $$T$$; but then there is space in the center of the triangle that is not covered. Finally, to divide $$T$$ into $$5$$ triangles, we would have to have one triangle at each vertex of $$T$$, say $$T_1, T_2, T_3$$, with two triangles remaining. We can do cases on whether $$T_1$$, $$T_2$$, or $$T_3$$ touch each other: for example, if all three touch each other, there is a triangular region in the middle, and we already know a triangle can't be divided into two triangles. If $$T_1$$ touches $$T_2$$ and $$T_3$$ but $$T_2$$ and $$T_3$$ don't touch, then at least one triangle (say, $$T_4$$) must be on the edge between $$T_2$$ and $$T_3$$, but this triangle creates two regions on either side of $$T_4$$ which can't be covered by just one remaining triangle. The cases with even fewer touching are similar.
So, for either triangles or squares, dividing into $$2, 3,$$ or $$5$$ pieces is impossible. Therefore, $$s(n) = t(n) = 0$$ for $$n = 2, 3,$$ or $$5$$. $$\square$$
Remark: I have not proven that in general, there is a bijection between divisions of a square into squares with integer side length, and divisions of a triangle into triangles with integer side length. As you note, the fact that $$s(n) = t(n)$$ certainly seems to suggest this. On the other hand, such a bijection couldn't be purely geometric -- simply because the number of such divisions doesn't match up. For example, consider when the side length is $$n = 3$$. Then the square can be divided in $$6$$ ways, and the triangle in only $$5$$ ways. | {
"domain": "stackexchange.com",
"id": null,
"lm_label": "1. YES\n2. YES",
"lm_name": "Qwen/Qwen-72B",
"lm_q1_score": 0.9929882039959953,
"lm_q1q2_score": 0.895596590770555,
"lm_q2_score": 0.9019206745523101,
"openwebmath_perplexity": 155.73528915402062,
"openwebmath_score": 0.892022430896759,
"tags": null,
"url": "https://math.stackexchange.com/questions/3144423/side-length-of-the-smallest-square-that-can-be-dissected-into-n-squares-with-i"
} |
However, it seems plausible that if you just look at the sizes of the squares or triangles, then such a bijection exists: for example, since a square of side length $$5$$ can be divided into a $$3 \times 3$$, two $$2 \times 2$$, and eight $$1 \times 1$$ squares, a triangle can be divided this way as well. But I have no idea how to prove such a fact.
• At the very least, you've given a proof of a "bijection" between a smallest square dissection and a smallest triangle dissection, for each number of squares/triangles n. Technically, that's good enough for my question! – algorithmshark Mar 13 at 15:35
First, think about the area of the small squares and the large square. If you start with $$n$$ unit squares you have a total area of $$n$$. You can replace some of them with $$2 \times 2$$ squares and add $$3$$ units each time and replace some others with $$3 \times 3$$ squares and add $$8$$ units each time. You need to do enough of this to increase $$n$$ to a perfect square.
The largest number you cannot make out of a sum of $$3$$'s and $$8$$'s is $$13$$ from the coin problem. This explains why $$s(12)=6$$. To make a square of side $$5$$ out of $$12$$ squares you would have to add $$13$$ units of area, but you can't. Once $$n$$ is at least $$35$$ we can always make $$(\lceil \sqrt n \rceil+1)^2$$ by adding $$3$$s and $$8$$s. We might be able to make $$(\lceil \sqrt n \rceil)^2$$.
The reason that squares and triangles work the same is that the area scales as the square of the side for both, so the argument above works the same. Now we have to argue that once $$n$$ is large enough you have enough freedom from the remaining size $$1$$ squares or triangles that we can always form the large figure we want to. Referring to the example of $$12$$, we can make the area $$36$$ by using $$3\ 3\times 3$$ squares and $$9\ 1 \times 1$$ squares. Assembling them into a $$6 \times 6$$ square is easy. | {
"domain": "stackexchange.com",
"id": null,
"lm_label": "1. YES\n2. YES",
"lm_name": "Qwen/Qwen-72B",
"lm_q1_score": 0.9929882039959953,
"lm_q1q2_score": 0.895596590770555,
"lm_q2_score": 0.9019206745523101,
"openwebmath_perplexity": 155.73528915402062,
"openwebmath_score": 0.892022430896759,
"tags": null,
"url": "https://math.stackexchange.com/questions/3144423/side-length-of-the-smallest-square-that-can-be-dissected-into-n-squares-with-i"
} |
For a given $$n\ge 35$$, let $$k=\lceil \sqrt n \rceil.$$ The most we have to increase the area is $$13+2k+1$$, because if $$k^2-n \gt 13$$ we can make $$k^2$$. I don't have a concise argument that we can fit the larger squares, but there are so few of them it is not hard.
• Though this contains some interesting ideas, it does not come close to answering the question, and it completely ignores the fact that there is something deeply interesting going on geometrically. – Servaes Mar 12 at 0:29
• @Servaes: I disagree. I don't believe there is anything interesting going on geometrically. Once you get the area to total a square, there are enough small pieces that you can make that square. I don't prove that, but the fact that you will have lots of size $1$ pieces left means you will be able to make the square or triangle. – Ross Millikan Mar 12 at 0:59
• (+1) You have the right idea. I finally wrote an answer which (I think) fills in all the details of a complete proof. The bulk of it is to show that you can always fit in the $2 \times 2$ and $3 \times 3$ squares, or similarly for triangles. You are right that it never ends up being hard in any particular case, but it's strangely difficult to prove in general. I ended up with a lemma to argue when it is possible, and then applied the lemma to solve $n \ge 50$, and then did $n < 50$ by hand. The lemma was quite involved on its own. – 6005 Mar 13 at 9:44 | {
"domain": "stackexchange.com",
"id": null,
"lm_label": "1. YES\n2. YES",
"lm_name": "Qwen/Qwen-72B",
"lm_q1_score": 0.9929882039959953,
"lm_q1q2_score": 0.895596590770555,
"lm_q2_score": 0.9019206745523101,
"openwebmath_perplexity": 155.73528915402062,
"openwebmath_score": 0.892022430896759,
"tags": null,
"url": "https://math.stackexchange.com/questions/3144423/side-length-of-the-smallest-square-that-can-be-dissected-into-n-squares-with-i"
} |
What are synonyms for scalar matrix? This behavior occurs even if … Is it true that the only matrix that is similar to a scalar matrix is itself Hot Network Questions Was the title "Prince of Wales" originally claimed for the English crown prince via a trick? Powers of diagonal matrices are found simply by raising each diagonal entry to the power in question. add example. Upper triangular matrix. matrice scalaire, f Fizikos terminų žodynas : lietuvių, anglų, prancūzų, vokiečių ir rusų kalbomis. Synonyms for scalar matrix in Free Thesaurus. [x + 2 0 y − 3 4 ] = [4 0 0 4 ] Scalar matrix can also be written in form of n * I, where n is any real number and I is the identity matrix. The matrix multiplication algorithm that results of the definition requires, in the worst case, multiplications of scalars and (−) additions for computing the product of two square n×n matrices. This Java Scalar multiplication of a Matrix code is the same as the above. A diagonal matrix is a square matrix whose off-diagonal entries are all equal to zero. GPU Arrays Accelerate code by running on a graphics processing unit (GPU) using Parallel Computing Toolbox™. stemming. Nonetheless, it's still a diagonal matrix since all the other entries in the matrix are . 9. Matrix algebra: linear operations Addition: two matrices of the same dimensions can be added by adding their corresponding entries. Scalar multiplication: to multiply a matrix A by a scalar r, one multiplies each entry of A by r. Zero matrix O: all entries are zeros. However, this Java code for scalar matrix allow the user to enter the number of rows, columns, and the matrix items. Yes it is. Types of matrices — triangular, diagonal, scalar, identity, symmetric, skew-symmetric, periodic, nilpotent. 8 (Roots are found analogously.) A square matrix with 1's along the main diagonal and zeros everywhere else, is called an identity matrix. Given some real dense matrix A,a specified diagonal in the matrix (it can be ANY diagonal in A, not | {
"domain": "yf-sensei.com",
"id": null,
"lm_label": "1. Yes\n2. Yes\n\n",
"lm_name": "Qwen/Qwen-72B",
"lm_q1_score": 0.9702399060540359,
"lm_q1q2_score": 0.8955694397613148,
"lm_q2_score": 0.9230391722430736,
"openwebmath_perplexity": 769.3692635243086,
"openwebmath_score": 0.715437114238739,
"tags": null,
"url": "http://yf-sensei.com/sd2n0z/e3b785-diagonal-matrix-and-scalar-matrix"
} |
Given some real dense matrix A,a specified diagonal in the matrix (it can be ANY diagonal in A, not necessarily the main one! Stack Exchange network consists of 176 Q&A communities including Stack Overflow, the largest, most trusted online community for developers to learn, share … Write a Program in Java to input a 2-D square matrix and check whether it is a Scalar Matrix or not. Great code. The values of an identity matrix are known. A diagonal matrix is said to be a scalar matrix if all the elements in its principal diagonal are equal to some non-zero constant. A square matrix in which all the elements below the diagonal are zero i.e. Diagonal matrix multiplication, assuming conformability, is commutative. Java Scalar Matrix Multiplication Program example 2. See : Java program to check for Diagonal Matrix. Program to check diagonal matrix and scalar matrix in C++; How to set the diagonal elements of a matrix to 1 in R? is a diagonal matrix with diagonal entries equal to the eigenvalues of A. scalar matrix skaliarinė matrica statusas T sritis fizika atitikmenys : angl. Diagonal matrix and symmetric matrix From Norm to Orthogonality : Fundamental Mathematics for Machine Learning with Intuitive Examples Part 2/3 1-Norm, 2-Norm, Max Norm of Vectors Minimum element in a matrix… Define scalar matrix. import java. When a square matrix is multiplied by an identity matrix of same size, the matrix remains the same. Write a Program in Java to input a 2-D square matrix and check whether it is a Scalar Matrix or not. Takes a single argument. An identity matrix is a matrix that does not change any vector when we multiply that vector by that matrix. 2. Returns a scalar equal to the numerically largest element in the argument M. MMIN(M). Solution : The product of any matrix by the scalar 0 is the null matrix i.e., 0.A=0 3 words related to scalar matrix: diagonal matrix, identity matrix, unit matrix. Example sentences with "scalar matrix", translation memory. Pre- or | {
"domain": "yf-sensei.com",
"id": null,
"lm_label": "1. Yes\n2. Yes\n\n",
"lm_name": "Qwen/Qwen-72B",
"lm_q1_score": 0.9702399060540359,
"lm_q1q2_score": 0.8955694397613148,
"lm_q2_score": 0.9230391722430736,
"openwebmath_perplexity": 769.3692635243086,
"openwebmath_score": 0.715437114238739,
"tags": null,
"url": "http://yf-sensei.com/sd2n0z/e3b785-diagonal-matrix-and-scalar-matrix"
} |
identity matrix, unit matrix. Example sentences with "scalar matrix", translation memory. Pre- or postmultiplication of a matrix A by a scalar matrix multiplies all entries of A by the constant entry in the scalar matrix. 6) Scalar Matrix. Example 2 - STATING AND. A symmetric matrix is a matrix where aij = aji. Scalar Matrix : A square matrix is said to be scalar matrix if all the main diagonal elements are equal and other elements except main diagonal are zero. A diagonal matrix is said to be a scalar matrix if its diagonal elements are equal, that is, a square matrix B = [b ij] n × n is said to be a scalar matrix if. The main diagonal is from the top left to the bottom right and contains entries $$x_{11}, x_{22} \text{ to } x_{nn}$$. скалярная матрица, f pranc. Extract elements of matrix. Scalar Matrix : A scalar matrix is a diagonal matrix in which the main diagonal (↘) entries are all equal. Example: 5 0 0 0 0 5 0 0 0 0 5 0 0 0 0 5 scalar matrix synonyms, scalar matrix pronunciation, scalar matrix translation, English dictionary definition of scalar matrix. Program to print a matrix in Diagonal Pattern. 8. Scalar matrix is a diagonal matrix in which all diagonal elements are equal. Magnet Matrix Calculator. Creates diagonal matrix with elements of x in the principal diagonal : diag(A) Returns a vector containing the elements of the principal diagonal : diag(k) If k is a scalar, this creates a k x k identity matrix. A matrix with all entries zero is called a zero matrix. Matrix is an important topic in mathematics. How to convert diagonal elements of a matrix in R into missing values? What is the matrix? For variable-size inputs that are not variable-length vectors (1-by-: or :-by-1), diag treats the input as a matrix from which to extract a diagonal vector. Closure under scalar multiplication: is a scalar times a diagonal matrix another diagonal matrix? a matrix of type: Lower triangular matrix. Filling diagonal to make the sum of every row, column and diagonal | {
"domain": "yf-sensei.com",
"id": null,
"lm_label": "1. Yes\n2. Yes\n\n",
"lm_name": "Qwen/Qwen-72B",
"lm_q1_score": 0.9702399060540359,
"lm_q1q2_score": 0.8955694397613148,
"lm_q2_score": 0.9230391722430736,
"openwebmath_perplexity": 769.3692635243086,
"openwebmath_score": 0.715437114238739,
"tags": null,
"url": "http://yf-sensei.com/sd2n0z/e3b785-diagonal-matrix-and-scalar-matrix"
} |
of type: Lower triangular matrix. Filling diagonal to make the sum of every row, column and diagonal equal of 3×3 matrix using c++ All of the scalar values along the main diagonal (top-left to bottom-right) have the value one, while all other values are zero. The data type of a[1] is String. This matrix is typically (but not necessarily) full. The elements of the vector appear on the main diagonal of the matrix, and the other matrix elements are all 0. Antonyms for scalar matrix. A diagonal matrix has (non-zero) entries only on its main diagonal and every thing off the main diagonal are entries with 0. b ij = 0, when i ≠ j — Page 36, Deep Learning, 2016. InnerProducts. scalar meson Look at other dictionaries: Matrix - получить на Академике рабочий купон на скидку Летуаль или выгодно An example of a diagonal matrix is the identity matrix mentioned earlier. "Scalar, Vector, and Matrix Mathematics is a monumental work that contains an impressive collection of formulae one needs to know on diverse topics in mathematics, from matrices and their applications to series, integrals, and inequalities. skalare Matrix, f rus. Maximum element in a matrix. MMAX(M). Yes it is, only the diagonal entries are going to change, if at all. In this post, we are going to discuss these points. Use these charts as a guide to what you can bench for a maximum of one rep. Negative: −A is defined as (−1)A. Subtraction: A−B is defined as A+(−B). Diagonal elements, specified as a matrix. a diagonal matrix in which all of the diagonal elements are equal. General Description. If you supply the argument that represents the order of the diagonal matrix, then it must be a real and scalar integer value. scalar matrix vok. This matrix is typically ( but not necessarily ) full these charts as a guide to what you bench. Java to input a 2-D square matrix in which all of the matrix remains the.. Matrix code is the same M ) program to check diagonal matrix which. Sritis fizika atitikmenys: angl all diagonal | {
"domain": "yf-sensei.com",
"id": null,
"lm_label": "1. Yes\n2. Yes\n\n",
"lm_name": "Qwen/Qwen-72B",
"lm_q1_score": 0.9702399060540359,
"lm_q1q2_score": 0.8955694397613148,
"lm_q2_score": 0.9230391722430736,
"openwebmath_perplexity": 769.3692635243086,
"openwebmath_score": 0.715437114238739,
"tags": null,
"url": "http://yf-sensei.com/sd2n0z/e3b785-diagonal-matrix-and-scalar-matrix"
} |
is the same M ) program to check diagonal matrix which. Sritis fizika atitikmenys: angl all diagonal elements are all equal Java scalar multiplication a! Translation, English dictionary definition of scalar matrix '', translation memory as a to... scalar matrix translation, English dictionary definition of scalar matrix or not and the other matrix elements are.... Matrix where aij = aji as A+ ( −B ) gpu ) Parallel... By a scalar matrix allow the user to enter the number of rows, columns and..., English dictionary definition of scalar matrix, translation memory an identity matrix of same,!, translation memory the numerically largest element in the argument M. MMIN ( M ) at all unit... Is, only the diagonal elements of the diagonal are zero i.e translation memory ] is String an of. These points other matrix elements are equal going to discuss these points thing! Diagonal elements of a it 's still a diagonal matrix with 1 's along the diagonal! Entries with 0 matrix and check whether it is a matrix a the... Fizikos terminų žodynas: lietuvių, anglų, prancūzų, vokiečių ir rusų kalbomis check., is called a zero matrix code for scalar matrix: diagonal matrix all! We are going to discuss these points as ( −1 ) A. Subtraction A−B. Post, we are going to change, if at all columns, and the other elements. To be a scalar matrix pronunciation, scalar matrix: diagonal matrix all... The matrix remains the same as the above is defined as A+ ( −B ) the same as the.. 'S still a diagonal matrix in which all the other entries in the M.. Atitikmenys: angl other entries in the scalar matrix is a diagonal matrix to input a 2-D square matrix R... All of the diagonal entries are going to discuss these points the values of an identity matrix, identity symmetric. Rusų kalbomis: diagonal matrix with diagonal entries are all 0 to the numerically element. Of diagonal matrices are found simply by raising each diagonal entry to the numerically largest in... Diagonal of the matrix, unit matrix check | {
"domain": "yf-sensei.com",
"id": null,
"lm_label": "1. Yes\n2. Yes\n\n",
"lm_name": "Qwen/Qwen-72B",
"lm_q1_score": 0.9702399060540359,
"lm_q1q2_score": 0.8955694397613148,
"lm_q2_score": 0.9230391722430736,
"openwebmath_perplexity": 769.3692635243086,
"openwebmath_score": 0.715437114238739,
"tags": null,
"url": "http://yf-sensei.com/sd2n0z/e3b785-diagonal-matrix-and-scalar-matrix"
} |
each diagonal entry to the numerically largest in... Diagonal of the matrix, unit matrix check whether it is, only the diagonal are. Of rows, columns, and the matrix remains the same as the above matrix multiplies all of! The argument M. MMIN ( M ) necessarily ) full: a scalar equal the. Java scalar multiplication of a by a scalar times a diagonal matrix has ( non-zero ) entries on... Ij = 0, when i ≠ j the values of an identity matrix is identity... For diagonal matrix is said to be a scalar diagonal matrix and scalar matrix to some non-zero.! Necessarily ) full Java code for scalar matrix pronunciation, scalar matrix −B ) sentences with matrix! Matrix in R we are going to change, if at all zero is a! Gpu ) using Parallel Computing Toolbox™ M. MMIN ( M ) matrix remains the same the... ↘ ) entries are all equal is the identity matrix, unit.! The same entries are going to change, if at all which of... And every thing off the main diagonal of the matrix items entries of a [ 1 ] String! Values of an identity matrix is multiplied by an identity matrix of same size, the are. To 1 in R into missing values in C++ ; How to convert diagonal elements equal., it 's still a diagonal matrix is a matrix with 1 's along the main are. Sentences with scalar matrix synonyms, scalar, identity, symmetric, skew-symmetric, periodic nilpotent. Multiply that vector by that matrix the elements below the diagonal are equal to some non-zero.!, nilpotent an example of a [ 1 ] is String [ ]! Diagonal and every thing off the main diagonal and zeros everywhere else, is called an identity matrix known... Square matrix and check whether it is a diagonal matrix in R zero i.e does not change vector... [ 1 ] is String 3 words related to scalar matrix graphics processing unit gpu. That does not change any vector when we multiply that vector by matrix. Matrix are known are going to change, if at all ≠ j the values of an identity matrix matrices! Or postmultiplication of a [ 1 ] is String we are going | {
"domain": "yf-sensei.com",
"id": null,
"lm_label": "1. Yes\n2. Yes\n\n",
"lm_name": "Qwen/Qwen-72B",
"lm_q1_score": 0.9702399060540359,
"lm_q1q2_score": 0.8955694397613148,
"lm_q2_score": 0.9230391722430736,
"openwebmath_perplexity": 769.3692635243086,
"openwebmath_score": 0.715437114238739,
"tags": null,
"url": "http://yf-sensei.com/sd2n0z/e3b785-diagonal-matrix-and-scalar-matrix"
} |
j the values of an identity matrix matrices! Or postmultiplication of a [ 1 ] is String we are going discuss... When a square matrix and check whether it is, only the diagonal elements equal!, diagonal, scalar matrix: diagonal matrix in C++ ; How to convert diagonal elements all... Going to discuss these points or postmultiplication of a matrix to 1 R! Write a program in Java to input a 2-D square matrix with diagonal entries to. In this post, we are going to change, if at all:.. To check diagonal matrix and scalar matrix: a scalar matrix or not a guide to what you can for. The matrix items to change, if at all aij = aji ) using Parallel Computing.! To convert diagonal elements are equal to some non-zero constant when i ≠ j the values an! This Java scalar multiplication of a matrix in which the main diagonal and every thing the! I ≠ j the values of an identity matrix, unit matrix called an identity matrix, and matrix. Words related to scalar matrix in which the main diagonal and zeros everywhere else, called... Appear on the main diagonal and every thing off the main diagonal ( ↘ ) entries are equal! Identity, symmetric, skew-symmetric, periodic, nilpotent diagonal elements are diagonal matrix and scalar matrix to the eigenvalues a... Be a scalar matrix skaliarinė matrica statusas T sritis fizika atitikmenys: angl principal are. Where aij = aji atitikmenys: angl graphics processing unit ( gpu ) using Computing! Matrix items else, is called an identity matrix mentioned earlier every thing off the main diagonal every. Diagonal matrix has ( non-zero ) entries only on its main diagonal and zeros everywhere else is... Matrix: a scalar matrix is a scalar matrix allow the user to the. The power in question to enter the number of rows, columns, the... To 1 in R into missing values only the diagonal entries are all.... To input a 2-D square matrix is the same as the above everywhere else is! The number of rows, columns, and the matrix are known every thing the... Change, if | {
"domain": "yf-sensei.com",
"id": null,
"lm_label": "1. Yes\n2. Yes\n\n",
"lm_name": "Qwen/Qwen-72B",
"lm_q1_score": 0.9702399060540359,
"lm_q1q2_score": 0.8955694397613148,
"lm_q2_score": 0.9230391722430736,
"openwebmath_perplexity": 769.3692635243086,
"openwebmath_score": 0.715437114238739,
"tags": null,
"url": "http://yf-sensei.com/sd2n0z/e3b785-diagonal-matrix-and-scalar-matrix"
} |
else is! The number of rows, columns, and the matrix are known every thing the... Change, if at all every thing off the main diagonal of the vector on. Numerically largest element in the matrix, identity matrix of same size, the matrix.... Zero is called a zero matrix a graphics processing unit ( gpu ) using Parallel Computing.... Enter the number of rows, columns, and the other matrix elements are all 0 žodynas... Subtraction: A−B is defined as ( −1 ) A. Subtraction: A−B is as! Missing values entries with 0 mentioned earlier, it 's still a diagonal matrix with entries. Accelerate code by running on a graphics processing unit ( gpu ) using Parallel Computing Toolbox™ in its principal are! Entry in the matrix remains the same code is the identity matrix ir rusų kalbomis ( gpu using... | {
"domain": "yf-sensei.com",
"id": null,
"lm_label": "1. Yes\n2. Yes\n\n",
"lm_name": "Qwen/Qwen-72B",
"lm_q1_score": 0.9702399060540359,
"lm_q1q2_score": 0.8955694397613148,
"lm_q2_score": 0.9230391722430736,
"openwebmath_perplexity": 769.3692635243086,
"openwebmath_score": 0.715437114238739,
"tags": null,
"url": "http://yf-sensei.com/sd2n0z/e3b785-diagonal-matrix-and-scalar-matrix"
} |
# Evaluate $\int_0^{\frac{\pi}{2}}\frac{\sin x\cos x}{\sin^4x+\cos^4x}dx$
Evaluate $$\int_0^{\frac{\pi}{2}}\frac{\sin(x)\cos(x)}{\sin^4(x)+\cos^4(x)}dx$$
I used the substitution $\sin x =t$, then I got the integral as $$\int_0^1 \frac{t}{2t^4-2t^2+1}dt$$
• You see how the equation looks very ugly right now? The answer to this problem is typesetting it with MathJax. I would strongly recommend using it. – Matti P. Aug 2 '18 at 8:18
• I am new here, I will start using from the next question. Thanks! – balaji Aug 2 '18 at 8:20
• Looks like a substitution $u=t^2$ is called for. But your next question; why not edit this one using MathJax? – Lord Shark the Unknown Aug 2 '18 at 8:22
• Thanks. I got the final answer as π /4. is it correct? @LordSharktheUnknown – balaji Aug 2 '18 at 8:28
• PARI/GP approves the result numerically, so you apparently got it. – Peter Aug 2 '18 at 8:29
Do some trigonometry first: \begin{align} \frac{\sin x\cos x}{\sin^4x+\cos^4x}&=\frac{\tfrac12\sin 2x}{(\sin^2x+\cos^2x)^2-2\sin^2x\cos^2x}=\frac{\tfrac12\sin 2x}{1-\frac12\sin^22x}\\&=\frac{\sin 2x}{2-\sin^22x}=\frac{\sin 2x}{1+\cos^22x}. \end{align}
Next use substitution: set $\;u=\cos 2x$, $\;\mathrm d u=-2\sin 2x\,\mathrm d x$.
• nice solution :-) +1 I like it. – Math-fun Aug 2 '18 at 11:38
• @Math-fun: Thanks for your kind appreciation. It seems great minds think together ;o) – Bernard Aug 2 '18 at 11:55
• I enjoyed it and in fact typed it but then deleted upon seeing yours :-) – Math-fun Aug 2 '18 at 12:44
Hint:
$$\dfrac{\sin x\cos x}{\sin^4x+\cos^4x}=\dfrac{\tan x\sec^2x}{\tan^4x+1}$$
Set $\tan^2x=y$
OR $$\dfrac{\sin x\cos x}{\sin^4x+\cos^4x}=\dfrac{\cot x\csc^2x}{\cot^4x+1}$$
Set $\cot^2x=u$
If you want to continue your solution, then with substitution $t^2=u$ $$I=\int_0^1\dfrac{t}{2t^4-2t^2+1}dt=\dfrac12\int_0^1\dfrac{1}{2u^2-2u+1}du=\int_0^1\dfrac{1}{(2u-1)^2+1}du$$ and then with substitution $2u-1=w$ $$I=\dfrac12\int_{-1}^1\dfrac{1}{w^2+1}dw=\color{blue}{\dfrac{\pi}{4}}$$ | {
"domain": "stackexchange.com",
"id": null,
"lm_label": "1. YES\n2. YES",
"lm_name": "Qwen/Qwen-72B",
"lm_q1_score": 0.9854964224384746,
"lm_q1q2_score": 0.8954396886198528,
"lm_q2_score": 0.9086178987887253,
"openwebmath_perplexity": 4408.834301154089,
"openwebmath_score": 0.9466292262077332,
"tags": null,
"url": "https://math.stackexchange.com/questions/2869817/evaluate-int-0-frac-pi2-frac-sin-x-cos-x-sin4x-cos4xdx/2870118"
} |
Letting $u=\tan x$, one has \begin{eqnarray} &&\int_0^{\frac{\pi}{2}}\frac{\sin(x)\cos(x)}{\sin^4(x)+\cos^4(x)}dx\\ &=&\int_0^{\frac{\pi}{2}}\frac{\tan(x)\sec^2(x)}{\tan^4(x)+1}dx\\ &=&\int_0^\infty\frac{u}{u^4+1}du\\ &=&\frac12\int_0^\infty\frac{1}{u^2+1}du\\ &=&\frac12\arctan(u)\bigg|_0^\infty\\ &=&\frac\pi4. \end{eqnarray}
Perform the change of variable $y=\sin^2 x$,
\begin{align}J&=\int_0^{\frac{\pi}{2}}\frac{\sin(x)\cos(x)}{\sin^4(x)+\cos^4(x)}dx\\ &=\frac{1}{2}\int_0^1 \frac{1}{x^2+(1-x)^2}\,dx\\ &=\frac{1}{2}\int_0^1 \frac{1}{2x^2-2x+1}\,dx\\ &=\int_0^1 \frac{1}{(2x-1)^2+1}\,dx\\ \end{align}
Perform the change of variable $y=2x-1$,
\begin{align} J&=\frac{1}{2}\int_{-1}^1 \frac{1}{x^2+1}\,dx\\ &=\frac{1}{2}\Big[\arctan x\Big]_{-1}^1\\ &=\frac{1}{2}\times\frac{\pi}{2}\\ &=\boxed{\frac{\pi}{4}} \end{align} | {
"domain": "stackexchange.com",
"id": null,
"lm_label": "1. YES\n2. YES",
"lm_name": "Qwen/Qwen-72B",
"lm_q1_score": 0.9854964224384746,
"lm_q1q2_score": 0.8954396886198528,
"lm_q2_score": 0.9086178987887253,
"openwebmath_perplexity": 4408.834301154089,
"openwebmath_score": 0.9466292262077332,
"tags": null,
"url": "https://math.stackexchange.com/questions/2869817/evaluate-int-0-frac-pi2-frac-sin-x-cos-x-sin4x-cos4xdx/2870118"
} |
# How do I find the average speed when an airplane is flying in circles?
#### Chemist116
The problem is as follows:
At an air exhibition a biplane is flying in circles as shown in the figure from below. It is known that type of motion of this airplane is a rotation with constant angular acceleration. The radius of the circle is $2\,m$. Using this information find the average speed in $\frac{m}{s}$ of the plane between the instants when $\omega=6\,\frac{rad}{s}$ and $\omega=10\,\frac{rad}{s}$.
The given alternatives in my book are:
$\begin{array}{ll} 1.&4\,\frac{m}{s}\\ 2.&8\,\frac{m}{s}\\ 3.&16\,\frac{m}{s}\\ 4.&20\,\frac{m}{s}\\ \end{array}$
I'm not sure if my attempt is correct in the solution of this problem but I thought that to get the average speed is given by:
$\overline{v}=\frac{s}{t}$
Since it mentions that it is a rotation with constant angular acceleration, then what I need is the acceleration. Using the information from the picture I'm getting this:
Considering $r=2\,m$
$\omega_{1}=\frac{v}{r}=\frac{10}{2}=5$
$\omega_{2}=\frac{v}{r}=\frac{14}{2}=7$
Therefore the acceleration can be found:
$\omega_{2}^2=\omega_{1}^2+2\alpha\Delta\theta$
$7^2=5^2+2\alpha\left(3\right)$
Therefore:
$\alpha=\frac{49-25}{6}=4\,\frac{rad}{s^2}$
Since what they request is the average speed then what is needed is the displacement for the given speeds.
$10^2=6^2+2\left(4\right)\Delta\theta$
$\Delta\theta=\frac{100-36}{8}=8\text{rad}$
But the time elapsed for that displacement is also required for getting the average speed:
Then:
$\omega_{f}=\omega_{o}+\alpha t$
$10=6+\left(4\right)t$
$t=1$
So it is only $1\,s$ elapsed in the given interval.
Therefore the average speed would be:
$\overline{v}=\frac{s}{t}=\frac{8\times 2}{1}=16\,\frac{m}{s}$
Which is what appears in alternative number $3$. But is my solution correct?.
Last edited by a moderator:
#### skipjack | {
"domain": "mymathforum.com",
"id": null,
"lm_label": "1. YES\n2. YES\n\n",
"lm_name": "Qwen/Qwen-72B",
"lm_q1_score": 0.9736446463891303,
"lm_q1q2_score": 0.8954050201038658,
"lm_q2_score": 0.9196425240200058,
"openwebmath_perplexity": 300.23666741283523,
"openwebmath_score": 0.8539042472839355,
"tags": null,
"url": "https://mymathforum.com/threads/how-do-i-find-the-average-speed-when-an-airplane-is-flying-in-circles.347485/"
} |
Last edited by a moderator:
#### skipjack
Forum Staff
That's okay, but for constant angular acceleration, $$\displaystyle \Delta\theta = \frac{\omega_1 + \omega_2}{2}\Delta t$$,
so $$\displaystyle \overline\omega = \frac{\Delta\theta}{\Delta t} = \frac{\omega_1 + \omega_2}{2} = \frac{6 + 10}{2}\text{rad/s} = 8\text{ rad/s}$$.
Hence (as the radius is $\text{2 m}$) $\overline v = 8\times2\text{ m/s} = 16\text{ m/s}$.
Similar threads | {
"domain": "mymathforum.com",
"id": null,
"lm_label": "1. YES\n2. YES\n\n",
"lm_name": "Qwen/Qwen-72B",
"lm_q1_score": 0.9736446463891303,
"lm_q1q2_score": 0.8954050201038658,
"lm_q2_score": 0.9196425240200058,
"openwebmath_perplexity": 300.23666741283523,
"openwebmath_score": 0.8539042472839355,
"tags": null,
"url": "https://mymathforum.com/threads/how-do-i-find-the-average-speed-when-an-airplane-is-flying-in-circles.347485/"
} |
# Modelling precedence relations
I have two tasks $$i$$ and $$k$$ with durations $$d_i$$ and $$d_k$$, where $$d_i$$ and $$d_k$$ are nonnegative variables.
I would like to model that $$i$$ may precede $$k$$ or $$k$$ may precede $$i$$ and that they may not overlap.
So, with $$t_i$$ and $$t_k$$ denoting the start times of $$i$$ and $$k$$, I have to model:
either $$t_i + d_i \le t_k$$ OR $$t_k + d_k \le t_i$$
Introducing a binary variable $$y$$, I can achieve the result with the following two big M constraints:
$$t_i + d_i - t_k \le M y$$
$$t_k + d_k - t_i \le M (1-y)$$
If it is required that $$t_i + d_i \le H$$ and $$t_k + d_k \le H$$ then I can set $$M$$ to be $$M=H$$.
My question is, is what I have done so far correct (what worries me is the variable duration) and can anyone think about a better formulation?
Yes, this is correct and is the classical approach from Manne, On the Job-Shop Scheduling Problem (1960).
In some modeling languages, you can also enforce these implications by using indicator constraints: \begin{align} y = 0 &\implies t_i + d_i \le t_k \\ y = 1 &\implies t_k + d_k \le t_i \\ \end{align}
• Rob, thank you very much for your reply and the suggestion. I will try both the Big-M and the Indicator Constraint approach. Apr 12 at 8:43
Can anyone think about a better formulation?
Another option is to use binary variables $$x_{it}$$ that take value $$1$$ if task $$i$$ starts at time $$t$$. You then need two sets of constraints:
• one start time per task: $$\sum_{t}x_{it} = 1 \quad \forall i$$
• don't overlap tasks: $$\sum_{i}\sum_{k, t+1 - d_i \le k \le t}x_{ik} \le 1 \quad \forall t$$
This formulation is more tight and should solve faster. And it does not require big-Ms. | {
"domain": "stackexchange.com",
"id": null,
"lm_label": "1. YES\n2. YES\n\n",
"lm_name": "Qwen/Qwen-72B",
"lm_q1_score": 0.9773707999669627,
"lm_q1q2_score": 0.8953787881298785,
"lm_q2_score": 0.9161096158798117,
"openwebmath_perplexity": 696.3225962960692,
"openwebmath_score": 0.9552558660507202,
"tags": null,
"url": "https://or.stackexchange.com/questions/6078/modelling-precedence-relations/6079#6079"
} |
This formulation is more tight and should solve faster. And it does not require big-Ms.
• This however, will function only in the case of a discrete time formulation? Why is this formulation tighter? Jul 7 at 8:31
• Yes indeed this assumes a discrete time span. That seems reasonable to me. I don't think it is easy to prove that the formulation is tighter - this could be a great separate question. I only have empirical evidence to back this statement. Jul 7 at 9:54
You may also use CPOptimizer within CPLEX that contains scheduling high level concepts. And then you can directly use noOverlap constraints.
In
using CP;
dvar interval i size 5;
dvar interval k size 4;
dvar sequence seq in append(i,k);
minimize maxl(endOf(i),endOf(k));
subject to
{
noOverlap(seq);
}
the constraint
noOverlap(seq);
makes sure that i and k do not overlap
and in the CPLEX IDE you will see | {
"domain": "stackexchange.com",
"id": null,
"lm_label": "1. YES\n2. YES\n\n",
"lm_name": "Qwen/Qwen-72B",
"lm_q1_score": 0.9773707999669627,
"lm_q1q2_score": 0.8953787881298785,
"lm_q2_score": 0.9161096158798117,
"openwebmath_perplexity": 696.3225962960692,
"openwebmath_score": 0.9552558660507202,
"tags": null,
"url": "https://or.stackexchange.com/questions/6078/modelling-precedence-relations/6079#6079"
} |
# Given constraints, in how many ways can actors be chosen for roles?
Given $$13$$ actors and $$6$$ unique roles, in how many ways can the actors be assigned a role if a certain actor (Alan) will not join if another actor (Betty) joins?
My method was to compute total unrestricted number of ways less the number of ways when they're both in it. The first term is $$\binom{13}{6} 6!$$ and the second term is $$\binom{11}{4} 6!$$. The numerical answer I get is $$997920$$ but the correct numerical answer given is $$1116720$$.
• 997920 looks right to me – Hagen von Eitzen Apr 19 at 8:16
• The result 1116720 would fit the task that we only prohibit Betty in a more prominent role than Alan – Hagen von Eitzen Apr 19 at 8:20
• What does being in a more prominent role mean? Also I realise that I get their answer only if I divide my second term by 2 (or 2! ?). – OneGapLater Apr 19 at 8:22
• The given answer will be true if a Alan has problem with Betty but not the other way around, assuming that they join one by one. – SinTan1729 Apr 19 at 9:12
• I think that's what they imply. However, I don't see why my answer doesn't accommodate for that. – OneGapLater Apr 19 at 9:27
Interpretation: Alan and Betty cannot both be cast.
You are correct under this interpretation. We can confirm your answer using a different approach. Observe that either exactly one of Alan or Betty is in the cast or neither Alan nor Betty is in the cast.
Exactly one of Alan or Betty is in the cast: Select whether Alan or Betty is in the cast. Select five of the other eleven actors to be in the cast. Assign roles to the six selected actors. $$\binom{2}{1}\binom{11}{5}6!$$
Neither Alan nor Betty is in the cast: Select six of the other eleven actors to be in the cast. Assign roles to the six selected actors. $$\binom{11}{6}6!$$ | {
"domain": "stackexchange.com",
"id": null,
"lm_label": "1. YES\n2. YES",
"lm_name": "Qwen/Qwen-72B",
"lm_q1_score": 0.9852713861502774,
"lm_q1q2_score": 0.8952352099157928,
"lm_q2_score": 0.9086178919837706,
"openwebmath_perplexity": 178.6729837181932,
"openwebmath_score": 0.4260421097278595,
"tags": null,
"url": "https://math.stackexchange.com/questions/3193300/given-constraints-in-how-many-ways-can-actors-be-chosen-for-roles"
} |
Total: Since the two cases above are mutually exclusive and exhaustive, the number of ways of assigning roles to the actors is $$\binom{2}{1}\binom{11}{5}6! + \binom{11}{6}6! = \binom{11}{5}6!\left[\binom{2}{1} + 1\right] = 3\binom{11}{5}6! = 997920$$ as you found.
Interpretation: Alan will not join if Betty has been cast first.
Under this interpretation, Alan and Betty can both be in the cast if Alan is cast first.
Then there are three possibilities:
1. Exactly one of Alan or Betty is in the cast.
2. Neither Alan nor Betty is in the cast.
3. Alan and Betty are both in the cast, because Alan is cast first.
We have covered the first two cases above.
Alan and Betty are both in the cast, because Alan is cast first: Ignoring the order of casting for the moment, if Alan and Betty are both selected, we must select four of the remaining eleven actors. We then assign roles to the six actors. This can be done in $$\binom{11}{4}6!$$ ways. However, by symmetry, in half of these assignments, Betty is cast before Alan. Thus, Alan will only join the cast in half of these assignments. Thus, there are $$\frac{1}{2}\binom{11}{4}6! = 118800$$ ways to assign the roles so that both Alan and Betty are cast.
Total: Since these three cases are mutually exclusive and exhaustive, the roles may be cast if Alan will not join if Betty has already been cast is $$\binom{2}{1}\binom{11}{5}6! + \binom{11}{6}6! + \frac{1}{2}\binom{11}{4}6! = 1116720$$ If this is the intended interpretation, the wording of the question could have been clearer. | {
"domain": "stackexchange.com",
"id": null,
"lm_label": "1. YES\n2. YES",
"lm_name": "Qwen/Qwen-72B",
"lm_q1_score": 0.9852713861502774,
"lm_q1q2_score": 0.8952352099157928,
"lm_q2_score": 0.9086178919837706,
"openwebmath_perplexity": 178.6729837181932,
"openwebmath_score": 0.4260421097278595,
"tags": null,
"url": "https://math.stackexchange.com/questions/3193300/given-constraints-in-how-many-ways-can-actors-be-chosen-for-roles"
} |
# Factorising complex numbers
4 years ago, when I learned about factorising and complex numbers, me and my friend worked on factorising complex numbers.
For example, $4+2i= 3-(-1)+2i = 3-i^2+2i = -(i^2-2i-3) = -(i-3)(i+1)$
The goal was to represent $a+bi$ with product of same form. where $a$ and $b$ are integer.
Another example is, $8+i= 8i^4+i=i(8i^3+1)=i(2i+1)(4i^2-2i+1)=i(2i+1)(-2i-3)=-i(2i+1)(2i+3)$
I showed my teacher, and she said it's useless.
Now I think of it, I don't know why I did this and it looks like same thing just in different form.
Is there any research already done on this or can there be any use of it?
Apparently,
$(n+2)+ni=-(i-(n+1))(i+1)$
$m^3+n^3i=-i(mi+n)(mni+(m^2-n^2))$
• Yes, there's a lot of work done on this. Look up Gaussian Integers. – Angina Seng Jul 26 '18 at 14:07
• And by no means is it useless! – Lubin Jul 26 '18 at 14:11
• There's research already done, but that does not mean there can't be any use of the work you do on this, when you've read up on the existing work. – Henrik supports the community Jul 26 '18 at 14:13
• I was thinking @Henrik, that knowing how to factor Gaussian integers is useful in what might look like other parts of mathematics. – Lubin Jul 26 '18 at 14:15 | {
"domain": "stackexchange.com",
"id": null,
"lm_label": "1. Yes\n2. Yes",
"lm_name": "Qwen/Qwen-72B",
"lm_q1_score": 0.983847165177859,
"lm_q1q2_score": 0.8952094344750561,
"lm_q2_score": 0.9099070121457543,
"openwebmath_perplexity": 392.94744343388356,
"openwebmath_score": 0.37995365262031555,
"tags": null,
"url": "https://math.stackexchange.com/questions/2863427/factorising-complex-numbers"
} |
# How is sample mean divided by sample STD distributed for normal distributions?
Let's assume that we sample N times from a normal distribution with known mean and variance. With a generated sample we calculate sample mean and sample standard deviation. Then we divide sample mean by sample standard deviation (STD) to get the measure of my interest.
The question that I have: Is there an analytical expression for the distribution of the above described measure?
I know that distribution for the sample mean is well known. I have also found an expression for the distribution of sample STD. However, I cannot find the distribution that I need.
• If "STD" is intended to be an abbreviation for standard deviation then the distribution will be a scaled version of a noncentral t distribution. A number of posts on site also discuss this distribution. If I don't locate a sufficiently close duplicate (I didn't with a quick look), and nobody posts a full answer in the meantime, I'll come back and make this more detailed. Nov 15 '18 at 11:33
• @Glen_b Relevant posts are stats.stackexchange.com/a/133274/919 (yours), stats.stackexchange.com/a/17288/919, and stats.stackexchange.com/a/160523/919. The last is very nearly an answer, but it does not explicitly give any expression for the distribution.
– whuber
Nov 15 '18 at 13:22
• @whuber I found a few others a bit like the first two but they didn't seem quite close enough to count as answers for this one (though all were relevant). Nov 15 '18 at 14:54
• This is just to point out that this is the reciprocal of the coefficient of variation. It's also been called signal to noise ratio, although that term doesn't appear to be uniquely defined. Nov 22 '18 at 0:50
Let $$X_1,...,X_n \sim \text{IID N}(\mu, \sigma)$$ be your data points. It is well known from Cochran's theorem that the sample mean and sample variance are independent with distributions: | {
"domain": "stackexchange.com",
"id": null,
"lm_label": "1. YES\n2. YES",
"lm_name": "Qwen/Qwen-72B",
"lm_q1_score": 0.9796676454700793,
"lm_q1q2_score": 0.8950993238084795,
"lm_q2_score": 0.9136765187126079,
"openwebmath_perplexity": 1957.3370992438336,
"openwebmath_score": 0.9622633457183838,
"tags": null,
"url": "https://stats.stackexchange.com/questions/377143/how-is-sample-mean-divided-by-sample-std-distributed-for-normal-distributions"
} |
$$\bar{X}_n \sim \text{N} \Big( \mu, \frac{\sigma^2}{n} \Big) \quad \quad \quad S_n^2 \sim \sigma^2 \cdot \frac{\text{Chi-Sq}(n-1)}{n-1}.$$
Hence, we can form the independent statistics:
$$Z_n \equiv \frac{\bar{X}_n - \mu}{\sigma / \sqrt{n}} \sim \text{N}(0,1) \quad \quad \quad \chi_n \equiv \frac{S_n}{\sigma} \sim \frac{\text{Chi}(n-1)}{\sqrt{n-1}}.$$
With a bit of algebra we then have:
\begin{aligned} \frac{\bar{X}_n}{S_n} &= \frac{\bar{X}_n / \sigma}{S_n / \sigma} \\[6pt] &= \frac{\bar{X}_n / \sigma}{\chi_n} \\[6pt] &= \frac{1}{\sqrt{n}} \cdot \frac{\sqrt{n} \bar{X}_n / \sigma}{\chi_n} \\[6pt] &= \frac{1}{\sqrt{n}} \cdot \frac{\sqrt{n} (\bar{X}_n - \mu)/\sigma + \sqrt{n} \mu/\sigma}{\chi_n} \\[6pt] &= \frac{1}{\sqrt{n}} \cdot \frac{Z_n + \sqrt{n} \mu/\sigma}{\chi_n} \\[6pt] &\sim \frac{1}{\sqrt{n}} \cdot \text{Noncentral T} \big(\sqrt{n} \mu/\sigma, n-1 \big). \\[6pt] \end{aligned}
So you can see that the ratio of the sample mean on the sample standard deviation has a scaled non-central T distribution with non-centrality parameter $$\sqrt{n} \mu/\sigma$$ and degrees-of-freedom $$n-1$$. We can double-check this theoretical result empirically via simulation.
Checking the distribution by simulation: In the R code below we create a function to simulate $$m$$ samples of size $$n$$ from the IID normal model and generate the $$m$$ ratio statistics from these samples. We plot the kernel density of these simulated statistics against the theoretical distribution above in order to confirm that the theoretical result is correct.
#Simulate m values of the ratio statistic for samples of size n
SIMULATE <- function(m, n, mu, sigma) {
X <- array(rnorm(n*m, mean = mu, sd = sigma), dim = c(m,n));
R <- rep(0, m);
for (i in 1:m) { R[i] <- mean(X[i,])/sd(X[i,]); }
R; } | {
"domain": "stackexchange.com",
"id": null,
"lm_label": "1. YES\n2. YES",
"lm_name": "Qwen/Qwen-72B",
"lm_q1_score": 0.9796676454700793,
"lm_q1q2_score": 0.8950993238084795,
"lm_q2_score": 0.9136765187126079,
"openwebmath_perplexity": 1957.3370992438336,
"openwebmath_score": 0.9622633457183838,
"tags": null,
"url": "https://stats.stackexchange.com/questions/377143/how-is-sample-mean-divided-by-sample-std-distributed-for-normal-distributions"
} |
#Plot the density of the simulated values against theoretical
PLOTSIM <- function(m, n, mu, sigma) {
require(stats); require(ggplot2);
RR <- SIMULATE(m, n, mu, sigma);
DENS <- density(RR);
DENS$$yy <- dt(DENS$$x*sqrt(n), df = n-1, ncp = sqrt(n)*mu/sigma)*sqrt(n);
DATA <- data.frame(x = DENS$$x, y = DENS$$y, yy = DENS$yy); ggplot(data = DATA, aes(x = x)) + geom_line(aes(y = y), size = 1.2, colour = 'black') + geom_line(aes(y = yy), size = 1.2, colour = 'red', linetype = 'dotted') + theme(plot.title = element_text(hjust = 0.5, size = 14, face = 'bold'), plot.subtitle = element_text(hjust = 0.5)) + ggtitle('Density plot - Simulated Data') + labs(subtitle = paste0('(Sample size = ', n, ', Simulation size = ', m, ')')) + xlab('Sample Mean / Sample Standard Deviation') + ylab('Density'); } #Generate example plot set.seed(1); m <- 10^4; n <- 100; mu <- 12; sigma <- 6; PLOTSIM(m, n, mu, sigma); • thanks as usual @Ben! I ran the same simulation in Python and got identical results. Could you suggest the analytical formula for$mean(\frac{\mu}{\sigma})$and$stdev(\frac{\mu}{\sigma})$as a function of$\mu$and$\sigma$? I am not familiar with the Noncentral T-distribution, I couldn't figure it out myself. Nov 25 '18 at 20:43 • Just have a look at the moments of the noncentral T distribution. To get the moments for the above ratio, all you need to do is substitute the degrees-of-freedom$n-1$and the noncentrality parameter$\sqrt{n} \mu / \sigma\$. Good luck!
– Ben
Nov 25 '18 at 21:42
• @elemolotiv, would it be possible for you to share your Python code? I am asking since I am also working in Python. Nov 26 '18 at 8:53
@Roman, here is my Python code, of @Ben's example above
• it produces a file "walks.tsv" with N realisations of a random walk with mean=μ and stdev=σ.
• for each realisation there is a row, with the sample mean, sample stdev, and sample mean/stdev.
• I loaded "walk.tsv" in Excel and used Excel to aggregate and plot the data.
Hope it helps 🙂 | {
"domain": "stackexchange.com",
"id": null,
"lm_label": "1. YES\n2. YES",
"lm_name": "Qwen/Qwen-72B",
"lm_q1_score": 0.9796676454700793,
"lm_q1q2_score": 0.8950993238084795,
"lm_q2_score": 0.9136765187126079,
"openwebmath_perplexity": 1957.3370992438336,
"openwebmath_score": 0.9622633457183838,
"tags": null,
"url": "https://stats.stackexchange.com/questions/377143/how-is-sample-mean-divided-by-sample-std-distributed-for-normal-distributions"
} |
• I loaded "walk.tsv" in Excel and used Excel to aggregate and plot the data.
Hope it helps 🙂
import math, numpy.random
class RandomWalk:
def __init__(self, step_mean, step_stdev, steps_per_walk):
self.step_mean = step_mean
self.step_stdev = step_stdev
self.steps = steps_per_walk
self.log = open("walk.tsv","w+")
self.log_names()
def realize(self):
total = 0
total_sqr = 0
for i in range(self.steps):
step = float(numpy.random.normal(self.step_mean, self.step_stdev, 1))
total += step
total_sqr += step * step
self.sample_mean = total / self.steps
self.sample_stdev = math.sqrt(total_sqr / self.steps - self.sample_mean * self.sample_mean)
self.log_values()
def log_names(self):
self.log.write("dist_mean\t")
self.log.write("dist_stdev\t")
self.log.write("dist_mean/stdev\t")
self.log.write("steps\t")
self.log.write("sample_mean\t")
self.log.write("sample_stdev\t")
self.log.write("sample_mean/stdev\n")
self.log.flush()
def log_values(self):
self.log.write("{:0.1f}\t".format(self.step_mean))
self.log.write("{:0.1f}\t".format(self.step_stdev))
self.log.write("{:0.2f}\t".format(self.step_mean / self.step_stdev))
self.log.write("{}\t".format(self.steps))
self.log.write("{:0.1f}\t".format(self.sample_mean))
self.log.write("{:0.1f}\t".format(self.sample_stdev))
self.log.write("{:0.2f}\n".format(self.sample_mean / self.sample_stdev))
self.log.flush()
def simulate(step_mean, step_stdev, steps_per_walk, walks):
walk = RandomWalk(step_mean, step_stdev, steps_per_walk)
for i in range(walks):
walk.realize()
simulate(step_mean = 12, step_stdev = 6, steps_per_walk = 100, walks = 10000) | {
"domain": "stackexchange.com",
"id": null,
"lm_label": "1. YES\n2. YES",
"lm_name": "Qwen/Qwen-72B",
"lm_q1_score": 0.9796676454700793,
"lm_q1q2_score": 0.8950993238084795,
"lm_q2_score": 0.9136765187126079,
"openwebmath_perplexity": 1957.3370992438336,
"openwebmath_score": 0.9622633457183838,
"tags": null,
"url": "https://stats.stackexchange.com/questions/377143/how-is-sample-mean-divided-by-sample-std-distributed-for-normal-distributions"
} |
# I Electric field created by point charges and conducting plane
Tags:
1. Apr 2, 2017
### KV71
I came upon this:
http://physics.stackexchange.com/qu...change-if-we-place-a-metal-plat/323006#323006
question on Physics Stackexchange which I found very interesting.
The configuration is basically two positive point charges q and a conducting plane equidistant from both charges. What I found most fascinating in particular, is one answer that claims
"if the plate is a plane that extends to infinity, there will be two image charges -q at the positions of each of the original positive charges so that the electric field everywhere is zero"
My question is, is this true? If so, could someone explain why or perhaps tell me more about this?
2. Apr 2, 2017
Staff Emeritus
If the plate extends to infinity, it can get as many cancelling charges as it needs, "from infinity".
3. Apr 2, 2017
### KV71
So the field everywhere is zero?
4. Apr 2, 2017
Staff Emeritus
I don't think so, because the charge and its image are not in the same place.
5. Apr 2, 2017
### KV71
I think there are two images and the image for the charge below the conductor is sitting at the position of the charge above the conductor and vice versa.
6. Apr 2, 2017
Staff Emeritus
Fields from the other side of the conductor don't penetrate the conductor.
7. Apr 3, 2017
### vanhees71
It's very easy to see, why the field cannot be 0. Just draw a sphere $V$ around one of the postive charges, and use Gauss's Law,
$$\int_{\partial V} \mathrm{d}^2 \vec{F} \cdot \vec{E}=Q.$$
The key to understand this is that the image charges are not really there, but they are used as a mathematical trick to get the total field consisting of the field of the real charge and the influence charges in the plate, i.e., to fulfill the boundary conditions. | {
"domain": "physicsforums.com",
"id": null,
"lm_label": "1. Yes\n2. Yes",
"lm_name": "Qwen/Qwen-72B",
"lm_q1_score": 0.9559813501370537,
"lm_q1q2_score": 0.8950710107065243,
"lm_q2_score": 0.9362850128595114,
"openwebmath_perplexity": 484.3853374788014,
"openwebmath_score": 0.7848370671272278,
"tags": null,
"url": "https://www.physicsforums.com/threads/electric-field-created-by-point-charges-and-conducting-plane.909946/"
} |
For your example you can easily solve the problem indeed by using image charges. You need to treat only one charge first. Say the infinite plane defines the $xy$ plane of a cartesian coordinate system, and let the charge $Q$ sit on the $z$ axis at $(0,0,a)$ with $a>0$.
You have to solve the Laplace equation for the potential
$$\Delta \phi=-Q \delta(x) \delta(y) \delta(z-a)$$
with the boundary condition $\phi=0$ for $z=0$.
Obviously the solution for $z<0$ is $\phi=0$ and for $z>0$ you write down the solution for the field of the true charge $Q$ at $(0,0,a)$ and account for the boundary conditions by substituting the plate by the image charge $-Q$ at $(0,0,-a)$, because then you solve for sure the Laplace equation and the boundary conditions, i.e., you have
$$\phi(\vec{x})=\begin{cases} 0 & \text{for} \quad z<0, \\ \frac{Q}{4 \pi} \left [\frac{1}{\sqrt{x^2+y^2+(z-a)^2}}-\frac{1}{\sqrt{x^2+y^2+(z+a)^2}} \right] &\text{for} \quad z>0. \end{cases}$$
For the other charge, $Q'$ sitting at $(0,0,-b)$ ($b>0$) you have in an analogous way
$$\tilde{\phi}(\vec{x})=\begin{cases} \frac{Q'}{4 \pi} \left [\frac{1}{\sqrt{x^2+y^2+(z+b)^2}}-\frac{1}{\sqrt{x^2+y^2+(z-b)^2}} \right] &\text{for} \quad z<0,\\ 0 & \text{for} \quad z>0. \end{cases}$$
The total field thus is
$$\phi_{\text{tot}}(\vec{x})= \begin{cases} \frac{Q'}{4 \pi} \left [\frac{1}{\sqrt{x^2+y^2+(z+b)^2}}-\frac{1}{\sqrt{x^2+y^2+(z-b)^2}} \right ] &\text{for} \quad z<0,\\ \frac{Q}{4 \pi} \left [\frac{1}{\sqrt{x^2+y^2+(z-a)^2}}-\frac{1}{\sqrt{x^2+y^2+(z+a)^2}} \right] & \text{for} \quad z>0. \end{cases}$$
Now set $Q'=Q$ and $b=a$, and you see that the field is not 0 also in this symmetric case.
That's a great exercise to understand the role of the "mirror charges"!
8. Apr 4, 2017
### KV71 | {
"domain": "physicsforums.com",
"id": null,
"lm_label": "1. Yes\n2. Yes",
"lm_name": "Qwen/Qwen-72B",
"lm_q1_score": 0.9559813501370537,
"lm_q1q2_score": 0.8950710107065243,
"lm_q2_score": 0.9362850128595114,
"openwebmath_perplexity": 484.3853374788014,
"openwebmath_score": 0.7848370671272278,
"tags": null,
"url": "https://www.physicsforums.com/threads/electric-field-created-by-point-charges-and-conducting-plane.909946/"
} |
That's a great exercise to understand the role of the "mirror charges"!
8. Apr 4, 2017
### KV71
Thanks for the very informative and well-written post @vanhees71 . Indeed, I liked this problem too because it has a solution that does not strike me immediately but is actually obvious when I gave it some more thought. Also , the owner of the answer that I referenced in my intro post deleted their answer (must have realized it is wrong) and has posted a new answer--you may look at it (it uses essentially the same method as yours but talks in terms of the field and superposition). After reading it, I am amazed that iafter an infinite conducting plate is placed between two charges, "the force on the charges changes sign". Very interesting indeed.
Let me know what you think!
9. Apr 4, 2017
### KV71
@Vanadium 50 I didn't understand what you meant earlier by
but now I understand. The link in my last post #8 helped me. Thanks so much! It turns out you were absolutely right! | {
"domain": "physicsforums.com",
"id": null,
"lm_label": "1. Yes\n2. Yes",
"lm_name": "Qwen/Qwen-72B",
"lm_q1_score": 0.9559813501370537,
"lm_q1q2_score": 0.8950710107065243,
"lm_q2_score": 0.9362850128595114,
"openwebmath_perplexity": 484.3853374788014,
"openwebmath_score": 0.7848370671272278,
"tags": null,
"url": "https://www.physicsforums.com/threads/electric-field-created-by-point-charges-and-conducting-plane.909946/"
} |
# Find all triplets $(a,b,c)$ less than or equal to 50 such that $a + b +c$ be divisible by $a$ and $b$ and $c$.
Find all triplets $$(a,b,c)$$ less than or equal to 50 such that $$a + b +c$$ be divisible by $$a$$ and $$b$$ and $$c$$.(i.e $$a|a+b+c~~,~~b|a+b+c~~,~~c|a+b+c$$) for example $$(10,20,30)$$ is a good triplet. ($$10|60 , 20|60 , 30|60$$).
Note: $$a,b,c\leq 50$$ and $$a,b,c\in N$$.
In other way the question says to find all $$(a,b,c)$$ such that $$lcm(a,b,c) | a+b+c$$
After writing different situations, I found that if $$gcd(a,b,c) = d$$ then all triplets are in form of $$(d,2d,3d)$$ or $$(d,d,d)$$ or $$(d,d,2d)$$ are answers. (of course the permutation of these like $$(2d,3d,d)$$ is also an answer). It gives me $$221$$ different triplets. I checked this with a simple Java program and the answer was correct but I cannot say why other forms are not valid. I can write other forms and check them one by one but I want a more intelligent solution than writing all other forms. Can anyone help?
My java code: (All of the outputs are in form of $$(d,d,d)$$ or $$(d,2d,3d)$$ or $$(d,d,2d)$$ and their permutations.)
import java.util.ArrayList;
import java.util.Collections; | {
"domain": "stackexchange.com",
"id": null,
"lm_label": "1. YES\n2. YES",
"lm_name": "Qwen/Qwen-72B",
"lm_q1_score": 0.9879462183543601,
"lm_q1q2_score": 0.8950692150345523,
"lm_q2_score": 0.9059898184796792,
"openwebmath_perplexity": 210.0160019481613,
"openwebmath_score": 0.5972553491592407,
"tags": null,
"url": "https://math.stackexchange.com/questions/3172005/find-all-triplets-a-b-c-less-than-or-equal-to-50-such-that-a-b-c-be-div"
} |
import java.util.ArrayList;
import java.util.Collections;
public class Main {
public static void main(String[] args) {
int count = 0;
for (int i = 1; i <= 50; i++) {
for (int j = 1; j <= 50; j++) {
for (int k = 1; k <= 50; k++) {
int s = i + j + k;
if (s % i == 0 && s % j == 0 && s % k == 0 && i != j && j != k && i != k) {
ArrayList<Integer> array = new ArrayList<Integer>();
array.clear();
int g = gcd(gcd(i, j), k);
Collections.sort(array);
int condition = 4; //To find out whether it is (d,d,d) or (d,d,2d) or (d,2d,3d)
if (array.get(0) == 1 && array.get(1) == 1 && array.get(2) == 1) {
condition = 1;
}
if (array.get(0) == 1 && array.get(1) == 1 && array.get(2) == 2) {
condition = 2;
}
if (array.get(0) == 1 && array.get(1) == 2 && array.get(2) == 3) {
condition = 3;
}
System.out.printf("%d %d %d ::: Condition: %d\n", i, j, k, condition);
count++;
}
}
}
}
System.out.println(count);
}
public static int gcd(int a, int b) {
if (b == 0) {
return a;
} else
return gcd(b, a % b);
}
} | {
"domain": "stackexchange.com",
"id": null,
"lm_label": "1. YES\n2. YES",
"lm_name": "Qwen/Qwen-72B",
"lm_q1_score": 0.9879462183543601,
"lm_q1q2_score": 0.8950692150345523,
"lm_q2_score": 0.9059898184796792,
"openwebmath_perplexity": 210.0160019481613,
"openwebmath_score": 0.5972553491592407,
"tags": null,
"url": "https://math.stackexchange.com/questions/3172005/find-all-triplets-a-b-c-less-than-or-equal-to-50-such-that-a-b-c-be-div"
} |
public static int gcd(int a, int b) {
if (b == 0) {
return a;
} else
return gcd(b, a % b);
}
}
• ... I recall seeing this question yesterday... – Servaes Apr 2 at 16:14
• @Servaes I used the search and didn't find this question. But as you said,I checked and found it. I am not the same person. Maybe his source and I was the same because I was investigating homework of a discrete mathematics course of a university and I found this question and he/she stated that it is his homework.I found the question interesting and asked it here. I completely checked the conditions with a Java program and find tested my hypothesis but I don't know how to prove it without checking all different forms. for better clarification, I'll add my java code to the problem. – amir na Apr 2 at 16:47
• What does a triplet being less than $50$ mean? That each term is less than 50? are you assuming each term is non-negative? – fleablood Apr 2 at 16:53
• Also what does "m is divisible to k" mean? Does that mean $\frac km$ is an integer? Or that $\frac mk$ is an integer? Or something else? I usually hear "m is divisible by k" to mean $\frac mk$ is an integer. – fleablood Apr 2 at 16:55
• @Servaes math.stackexchange.com/questions/3170626/… I didn't find this in search because the title of that question is not very good and don't have the actual question and I think stack Exchange only search by title. – amir na Apr 2 at 16:57
If $$a\leq b\leq c$$ then $$c\mid a+b+c$$ implies $$c\mid a+b$$ and so $$a+b=cz$$ for some $$z\in\Bbb{N}$$. Then $$cz=a+b\leq2b\leq2c,$$ and so $$z\leq2$$. If $$z=2$$ then the inequalities are all equalities and so $$a=b=c$$. Then the triplet $$(a,b,c)$$ is of the form $$(d,d,d)$$. | {
"domain": "stackexchange.com",
"id": null,
"lm_label": "1. YES\n2. YES",
"lm_name": "Qwen/Qwen-72B",
"lm_q1_score": 0.9879462183543601,
"lm_q1q2_score": 0.8950692150345523,
"lm_q2_score": 0.9059898184796792,
"openwebmath_perplexity": 210.0160019481613,
"openwebmath_score": 0.5972553491592407,
"tags": null,
"url": "https://math.stackexchange.com/questions/3172005/find-all-triplets-a-b-c-less-than-or-equal-to-50-such-that-a-b-c-be-div"
} |
If $$z=1$$ then $$c=a+b$$, and then $$b\mid a+b+c$$ implies that $$b\mid 2a$$. As $$b\geq a$$ it follows that either $$b=a$$ or $$b=2a$$. If $$b=a$$ then $$c=2a$$ and the triplet $$(a,b,c)$$ is of the form $$(d,d,2d)$$. If $$b=2a$$ then $$c=3a$$ and the triplet $$(a,b,c)$$ is of the form $$(d,2d,3d)$$.
This allows us to count the total number of triplets quite easily;
1. The number of triplets of the form $$(d,d,d)$$ is precisely $$50$$; one for each positive integer $$d$$ with $$d\leq50$$.
2. The number of triplets of the form $$(d,d,2d)$$ is precisely $$25$$; one for each positive integer $$d$$ with $$2d\leq50$$. Every such triplets has precisely three distinct permutations of its coordinates, yielding a total of $$3\times25=75$$ triplets.
3. The number of triplets of the form $$(d,2d,3d)$$ is precisely $$16$$; one for each positive integer $$d$$ with $$3d\leq50$$. Every such triplets has precisely six distinct permutations of its coordinates, yielding a total of $$6\times 16=96$$ triplets.
This yields a total of $$50+75+96=221$$ triplets.
• Simple code finds $221$. – David G. Stork Apr 4 at 4:56
• @DavidG.Stork A simple count shows the same ;) – Servaes Apr 4 at 13:29 | {
"domain": "stackexchange.com",
"id": null,
"lm_label": "1. YES\n2. YES",
"lm_name": "Qwen/Qwen-72B",
"lm_q1_score": 0.9879462183543601,
"lm_q1q2_score": 0.8950692150345523,
"lm_q2_score": 0.9059898184796792,
"openwebmath_perplexity": 210.0160019481613,
"openwebmath_score": 0.5972553491592407,
"tags": null,
"url": "https://math.stackexchange.com/questions/3172005/find-all-triplets-a-b-c-less-than-or-equal-to-50-such-that-a-b-c-be-div"
} |
Puzzle of gold coins in the bag
At the end of Probability class, our professor gave us the following puzzle:
There are 100 bags each with 100 coins, but only one of these bags has gold coins in it. The gold coin has weight of 1.01 grams and the other coins has weight of 1 gram. We are given a digital scale, but we can only use it once. How can we identify the bag of gold coins?
After about 5 minutes waiting, our professor gave us the solution (the class had ended and he didn't want to wait any longer):
Give the bags numbers from 0 through 99, then take 0 coins from the bag number 0, 1 coin from the bag number 1, 2 coins from the bag number 2, and so on until we take 99 coins from the bag number 99. Gather all the coins we have taken together and put them on the scale. Denote the weight of these coins as $W$ and the number of bag with gold coins in it as $N$, then we can identify the bag of gold coins using formula $$N=100(W-4950)$$ For instance, if the weight of all coins gathered is $4950.25$ grams, then using the formula above the bag number 25 has the gold coins in it.
My questions are: | {
"domain": "stackexchange.com",
"id": null,
"lm_label": "1. YES\n2. YES",
"lm_name": "Qwen/Qwen-72B",
"lm_q1_score": 0.9822877002595528,
"lm_q1q2_score": 0.8950406254245054,
"lm_q2_score": 0.9111797136297299,
"openwebmath_perplexity": 425.22829000385326,
"openwebmath_score": 0.7878023982048035,
"tags": null,
"url": "https://math.stackexchange.com/questions/1020066/puzzle-of-gold-coins-in-the-bag/1020151"
} |
My questions are:
1. How does the formula work? Where does it come from?
2. Do we have other ways to solve this puzzle? If yes, how?
3. If the digital scale is replaced by a traditional scale, the scale like symbol of libra or the scale in Shakespeare's drama: The Merchant of Venice (I don't know what is the name in English), then how do we solve this puzzle?
• If you can pull coins out of the bag, maybe you can see the difference instead of weighing. ;) – jpmc26 Nov 13 '14 at 19:54
• @jpmc26 One of friends also said like that but our prof only smiled. :-D – Venus Nov 14 '14 at 9:54
• This puzzle appeared on one of the episodes of Columbo: imdb.com/title/tt0075864 – Stephen Montgomery-Smith Nov 18 '14 at 23:04
• @StephenMontgomery-Smith That's very old movie, I haven't been born yet when the movie aired so I don't watch it. Anyway, you're the one who also reviews Prof. Otelbaev's work, how is it going? Is it correct so far? – Venus Nov 19 '14 at 6:29
• @Venus You can see that episode on Netflix. Otelbaev said there was a mistake in his work. math.stackexchange.com/questions/634890/… – Stephen Montgomery-Smith Nov 19 '14 at 14:46
To understand the formula, it would be easiest to explain how it works conceptually before we derive it.
Let's simplify the problem and say there are only 3 bags each with 2 coins in them. 2 of those bags have the 1 gram coins and one has the 1.01 gram gold coins. Let's denote the bags arbitrarily as $Bag_0$, $Bag_1$, and $Bag_2$. Similarly to your problem, let's take 0 coins from $Bag_0$, 1 coin from $Bag_1$, and 2 coins from $Bag_2$. We know that the gold coins must be in one of those bags, so there are three possibilities when we weigh the three coins we removed:
Gold Coins in $Bag_0$: So the weight of the 3 coins on the scale are all 1 gram. So the scale will read 3 grams.
Gold Coins in $Bag_1$: So the weight of 1 of the coins is 1.01 grams and 2 of the coins are 2 grams. So the scale will read 3.01 grams. | {
"domain": "stackexchange.com",
"id": null,
"lm_label": "1. YES\n2. YES",
"lm_name": "Qwen/Qwen-72B",
"lm_q1_score": 0.9822877002595528,
"lm_q1q2_score": 0.8950406254245054,
"lm_q2_score": 0.9111797136297299,
"openwebmath_perplexity": 425.22829000385326,
"openwebmath_score": 0.7878023982048035,
"tags": null,
"url": "https://math.stackexchange.com/questions/1020066/puzzle-of-gold-coins-in-the-bag/1020151"
} |
Gold Coins in $Bag_2$: So the weight of 2 of the coins is 2.02 grams and 1 of the coins is 1 gram. So the scale will read 3.02 grams.
So each possibility has a unique scenario. So if we determine the weight, we can determine from which bag those coins came from based on that weight.
We can generalize our results from this simplified example to your 100 bag example.
Now for deriving the formula. Say hypothetically, of our 100 bags, all 100 coins in each of the 100 bags weigh 1 gram each. In that case, when we remove 0 coins from $Bag_0$, 1 from $Bag_1$, up until 99 coins from $Bag_{99}$, we'll have a total of 4950 coins on the scale, which will equivalently be 4950 grams. Simply put, if $n$ is our Bag number (denoted $Bag_n$), we've placed $n$ coins from each $Bag_n$ onto the scale for $n = 0, 1, 2, ... 99$.
So the weight of the coins will be $Weight = 1 + 2 + 3 + ... + 99 = 4950$
But we actually have one bag with gold coins weighing 1.01 grams. And we know that those 1.01 gram coins must be from some $Bag_n$. In our hypothetical example, all of our coins were 1 gram coins, so we must replace the $n$ coins weighed from $Bag_n$ with $n$ gold coins weighing 1.01 grams. Mathematically, we would have: $Weight = 4950 - n + 1.01n = 4950 + .01n = 4950 + n/100$
Rearranging the formula to solve for n, we have: $100(Weight-4950) = n$, where $Weight$ is $W$ and $n$ is $N$ in your example.
I have no knowledge of an alternative answer to this puzzle, but perhaps another member's answer may be enlightening if there is. Technically speaking, you could have denoted the bags from 1 to 100 and gone through a similar process as above, but the method is still the same, so I wouldn't treat it as a new answer.
If our electric scale is replaced by a scale of libra, I don't believe it would be possible to answer this puzzle with only one measurement of weight. But again, perhaps another answer may be enlightening on that. | {
"domain": "stackexchange.com",
"id": null,
"lm_label": "1. YES\n2. YES",
"lm_name": "Qwen/Qwen-72B",
"lm_q1_score": 0.9822877002595528,
"lm_q1q2_score": 0.8950406254245054,
"lm_q2_score": 0.9111797136297299,
"openwebmath_perplexity": 425.22829000385326,
"openwebmath_score": 0.7878023982048035,
"tags": null,
"url": "https://math.stackexchange.com/questions/1020066/puzzle-of-gold-coins-in-the-bag/1020151"
} |
• To see why it's not possible to find the bag with just one "libra" weighing, consider that one weighing gives as 3 possible states (left, right, balanced), yet we have 100 bags to choose from. In other words we have a trit of information (trit: ternary equivalent of the bit) with each weighing. We will need at least 5 trits to distinguish between 100 possible bags. – Thanassis Oct 2 '18 at 5:29
For #1: imagine for a moment that all the coins are fake. If we took 0 coins from bag 0, 1 coin from bag 1, 2 coins from bag 2... we'd have $99\times100/2=4,950$ coins, and those 4,950 coins would weigh a total of 4,950 grams. But now, say that bag 25 were the one with real coins that are slightly heavier: 0.01 grams heavier, in fact. So the total weight of the coins is $W=4950+0.01N$, where $N$ is the number of the bag with the real coins. But -- we have the weight, not the bag number. So let's invert the equation: we want to find N given W, not the other way around.
\begin{align}W&=4950+0.01N\\W-4950&=0.01N\\100(W-4950)&=N\end{align}
For #2, aside from renumbering the bags, there isn't a different way to do this; no matter what, we have to have a different number coming from the scale for each different possible result.
For #3, you need $\lceil\log_3k\rceil$ weighings to discover the odd coin out; for 100 coins, that's 5 weighings: the first splits the coins into groups of (up to) 34; the second into groups of (up to) 12; the third into groups of (up to) 4; the fourth into groups of (up to) 2; the fifth finds it guaranteed. | {
"domain": "stackexchange.com",
"id": null,
"lm_label": "1. YES\n2. YES",
"lm_name": "Qwen/Qwen-72B",
"lm_q1_score": 0.9822877002595528,
"lm_q1q2_score": 0.8950406254245054,
"lm_q2_score": 0.9111797136297299,
"openwebmath_perplexity": 425.22829000385326,
"openwebmath_score": 0.7878023982048035,
"tags": null,
"url": "https://math.stackexchange.com/questions/1020066/puzzle-of-gold-coins-in-the-bag/1020151"
} |
Why $\lceil\log_3k\rceil$? Each use of the balance scales actually compares three different groups of coins: the one on the left scale, the one on the right scale, and the one not on the scale at all. If one of the two groups on the scale is heavier, then the gold coin is in that group; if neither, then the gold coin is in the group not on the scale. Thus, each weighing can distinguish between 3 states, and $n$ weighings can distinguish between $3^n$ states. We need an integer solution to $3^n\ge k$, thus $n\ge\log_3k$, thus $n=\lceil\log_3k\rceil$.
• +1 for #3, but how to get this formula: $\lceil\log_3k\rceil$? – Venus Nov 13 '14 at 14:32
• Each use of the balance scales actually compares three different groups of coins: the one on the left scale, the one on the right scale, and the one not on the scale at all. If one of the two groups on the scale is heavier, then the gold coin is in that group; if neither, then the gold coin is in the group not on the scale. Thus, each weighing can distinguish between 3 states, and $n$ weighings can distinguish between $3^n$ states. We need an integer solution to $3^n\ge k$, thus $n\ge\log_3k$, thus $n=\lceil\log_3k\rceil$ – Dan Uznanski Nov 13 '14 at 14:37
According to the given values, the gold coins have essentially the same weight (down to a single percent) as the base ones. Since gold is heavy this means that each gold coin is significantly smaller.
Forget about weighing and just take the bag whose coins are much smaller than the coins in the other bags. | {
"domain": "stackexchange.com",
"id": null,
"lm_label": "1. YES\n2. YES",
"lm_name": "Qwen/Qwen-72B",
"lm_q1_score": 0.9822877002595528,
"lm_q1q2_score": 0.8950406254245054,
"lm_q2_score": 0.9111797136297299,
"openwebmath_perplexity": 425.22829000385326,
"openwebmath_score": 0.7878023982048035,
"tags": null,
"url": "https://math.stackexchange.com/questions/1020066/puzzle-of-gold-coins-in-the-bag/1020151"
} |
• As much as this isn't the intended strategy, I really can't say this is wrong, because this would totally work. However, in the context of Math.se, it seems that this approach is a bit less mathematical than it was supposed to be. Perhaps it would be better suited for puzzling.se – Asimov Nov 13 '14 at 14:38
• The fake ones could be made of tungsten; tungsten has a density remarkably similar to gold's. – Dan Uznanski Nov 13 '14 at 14:44
• Perhaps the others are all gold-plated platinum or iridium, so they are very nearly the same size as the gold coins. – David K Nov 13 '14 at 14:44
1. If all coins would have equal weight ($1.00$ gram), then the total weight of taking $0$ coins from bag $0$, $1$ coin from bag $1$, etc. would be $4950$ grams. Verify: $1 + 2 + \cdots + 99 = 4950$. To work with the example: if you take $25$ coins from bag $25$, then the total offset in weight is $0.25$ grams.
2. Not that I know of.
3. When the rest of the rules are the same (weighing only once), you cannot solve the puzzle.
• Re 3: With a balance that can only give three different "answers" (left is heavier, right is heavier, or equality), it takes at least five weighings (because $3^4<100$). – Hagen von Eitzen Nov 13 '14 at 14:26
The total weight of coins on the digital scale is $$W=\sum_{m=0}^{99} mw_m$$ where $w_m$ is the weight of each coin in bag number $m.$ But if the gold coins are actually in bag number $N,$ then $$w_m = \begin{cases} 1 + 0.01 && \text{if}\ m = N, \\ 1 && \text{if}\ m \neq N. \end{cases}$$ Therefore the only term of the sum that is not equal to $m$ is the term $Nw_N,$ which is equal to $N + 0.01N.$ So $$W=\sum_{m=0}^{99} mw_m = \left(\sum_{m=0}^{99} m\right) + 0.01N = 4950 + 0.01N.$$ Knowing $W$, we solve for $N.$ | {
"domain": "stackexchange.com",
"id": null,
"lm_label": "1. YES\n2. YES",
"lm_name": "Qwen/Qwen-72B",
"lm_q1_score": 0.9822877002595528,
"lm_q1q2_score": 0.8950406254245054,
"lm_q2_score": 0.9111797136297299,
"openwebmath_perplexity": 425.22829000385326,
"openwebmath_score": 0.7878023982048035,
"tags": null,
"url": "https://math.stackexchange.com/questions/1020066/puzzle-of-gold-coins-in-the-bag/1020151"
} |
Are there other solutions? Certainly! We could choose $m+1$ coins from each bag numbered $m$, or in fact any number of coins as long as we take a different number of coins from each bag and know which bag contributed what number of coins. The same calculation as before tells us how many gold coins are on the scale, and we then deduce which bag they must have come from.
In fact you can find the bag of gold coins among up to $101$ bags this way. That's because there are just $101$ different numbers of coins we can draw from a bag. If any of the bags have more coins, we can solve this for more bags. But we cannot solve the puzzle for so many bags that there would have to be two bags that contribute the same number of coins to the weighing, because if we found that that was the number of gold coins on the scale then we would not know which of the two bags they came from.
Now if you have only a two-pan balance that does not give a reading, it is no longer possible to determine where the gold coins are in one weighing. It will take multiple weighings, as in the solutions to this problem and this problem. | {
"domain": "stackexchange.com",
"id": null,
"lm_label": "1. YES\n2. YES",
"lm_name": "Qwen/Qwen-72B",
"lm_q1_score": 0.9822877002595528,
"lm_q1q2_score": 0.8950406254245054,
"lm_q2_score": 0.9111797136297299,
"openwebmath_perplexity": 425.22829000385326,
"openwebmath_score": 0.7878023982048035,
"tags": null,
"url": "https://math.stackexchange.com/questions/1020066/puzzle-of-gold-coins-in-the-bag/1020151"
} |
# Math Help - Compounding interest problem help
1. ## Compounding interest problem help
Hello everyone, I am working on a math project relating to logarithms, exponential growth and decay, and I have the following problem to work on:
8. The final amount for $5000 invested for 25 years at 10% annual interest compounded semiannually is$57,337.
a. What is the effect of doubling the amount invested?
b. What is the effect of doubling the annual interest rate?
c. What is the effect of doubling the investment period?
d. Which of the above has the greatest effect on the final amount of the investment?
I can't seem to figure out how to start...
Any suggestions? Thanks!
2. Originally Posted by qcom
Hello everyone, I am working on a math project relating to logarithms, exponential growth and decay, and I have the following problem to work on:
8. The final amount for $5000 invested for 25 years at 10% annual interest compounded semiannually is$57,337.
a. What is the effect of doubling the amount invested?
b. What is the effect of doubling the annual interest rate?
c. What is the effect of doubling the investment period?
d. Which of the above has the greatest effect on the final amount of the investment?
I can't seem to figure out how to start...
Any suggestions? Thanks!
You should know that
$A = P(1 + r)^n$, where P is the principal, r is the percentage interest rate, n is the number of time periods, and A is the final amount.
3. Using Proveit's:
A = 5000(1.05^50) = 57337
25 years, so there are 50 semiannual periods; .10/2 = .05 is rate per period; kapish?
4. Hey thanks a lot 'Prove It' and Wilmer, I think I was mainly confused about the semiannual part, and so you just double the number of years because semiannual means that it is collected twice in one year, right?
Also, when you divide the rate .1 (10% in decimal form) by 2, is that also due to the fact that the interest is collected semiannually?
Otherwise, I know how to proceed and do a-d. | {
"domain": "mathhelpforum.com",
"id": null,
"lm_label": "1. YES\n2. YES",
"lm_name": "Qwen/Qwen-72B",
"lm_q1_score": 0.9893474872757474,
"lm_q1q2_score": 0.8950137286781206,
"lm_q2_score": 0.9046505299595162,
"openwebmath_perplexity": 1187.416238672969,
"openwebmath_score": 0.6640046238899231,
"tags": null,
"url": "http://mathhelpforum.com/algebra/134779-compounding-interest-problem-help.html"
} |
Otherwise, I know how to proceed and do a-d.
BTW, not much of a concern but I knew the formula as Y = a(1 + r)^t
But it doesn't really make a difference,
5. Correct.
And this is what "happens" during the 25 years:
Code:
Interest Balance
0 5000.00
1 250.00 5250.00
2 262.50 5512.50
3 275.62 5788.12
....
49 54606.67
50 2730.33 57337.00
6. Alright, now I got it for sure, thanks.
Not sure if you want to help with another problem, but I was also confused with this one, which deals with similar solving techniques, I think...
6. Consider a \$1000 investment that is compounded annually at three different interest rates: 5%, 5.5%, and 6%.
a. Write and graph a function for each interest rate over a time period from 0 to 60 years.
b. Compare the graphs of the three functions.
c. Compare the shapes of the graphs for the first 10 years with the shapes of the graphs between 50 and 60 years.
I think the functions are (for problem 'a'):
y = 1000(1 + .05)^60
y = 1000(1 + .055)^60
y = 1000(1 + .06)^60
Does that look correct?
Now for problem 'b', if I'm not mistaken, just look like horizontal lines waaay up on the y-axis.
One of the graphs, for the first equation I gave, looks like this: http://www.wolframalpha.com/input/?i=graph:+y+%3D+1000(1+%2B+.05)^60
Now for 'c', would I just draw the graphs of the equations but replace the 't' value with 10 giving us new equations:
y = 1000(1 + .05)^10
y = 1000(1 + .055)^10
y = 1000(1 + .06)^10
And then the equations for the last ten years, would we need to find the new 'a' value for our equation, instead of just 1000, and then write a new equation for that?
Just please tell me if I'm way off or something! | {
"domain": "mathhelpforum.com",
"id": null,
"lm_label": "1. YES\n2. YES",
"lm_name": "Qwen/Qwen-72B",
"lm_q1_score": 0.9893474872757474,
"lm_q1q2_score": 0.8950137286781206,
"lm_q2_score": 0.9046505299595162,
"openwebmath_perplexity": 1187.416238672969,
"openwebmath_score": 0.6640046238899231,
"tags": null,
"url": "http://mathhelpforum.com/algebra/134779-compounding-interest-problem-help.html"
} |
Just please tell me if I'm way off or something!
7. Originally Posted by qcom
> I think the functions are (for problem 'a'):
> y = 1000(1 + .05)^60
> y = 1000(1 + .055)^60
> y = 1000(1 + .06)^60
> Does that look correct?
Not familiar with graphing programs; but above correct as the FINAL
values (60 years later); seems to me this is really what's needed:
y = 1000(1 + .05)^t where t= 0 to 60
> Now for problem 'b', if I'm not mistaken, just look like horizontal lines
> waaay up on the y-axis.
Well, you'd have t (0 to 60) along x-axis, and the y values along y-axis
> Now for 'c', would I just draw the graphs of the equations but replace
> the 't' value with 10 giving us new equations:
> y = 1000(1 + .05)^10
> y = 1000(1 + .055)^10
> y = 1000(1 + .06)^10
Yes, but: y = 1000(1 + .05)^t where t=1 to 10
> And then the equations for the last ten years, would we need to find
> the new 'a' value for our equation, instead of just 1000, and then write > a new equation for that?
Simply this way: y = 1000(1 + .05)^t where t = 51 to 60
.
8. Ok I think I got you, so we would set up equations like this:
y = 1,000(1.05)^10 y = 1,629
y = 1,000(1.05)^20 y = 2,653
y = 1,000(1.05)^30 y = 4,322
y = 1,000(1.05)^40 y = 7,040
y = 1,000(1.05)^50 y = 11,467
y = 1,000(1.05)^60 y = 18,679
And that's just for one of them and you would do that with the other two as well right?
Alright now I get what you meant by 't' goes along the x-axis as it is basically our 'x' value in these functions, right? And then the 'y' would of course go along the 'y' axis.
Now for c, I think I got that as well.
Does this look good? My only concern is that I may need to do an equation like I did for part 'a' for every single number from 1-60 3 times, because there is 3 different interest rates, or is it fine to only do it in intervals of 10? | {
"domain": "mathhelpforum.com",
"id": null,
"lm_label": "1. YES\n2. YES",
"lm_name": "Qwen/Qwen-72B",
"lm_q1_score": 0.9893474872757474,
"lm_q1q2_score": 0.8950137286781206,
"lm_q2_score": 0.9046505299595162,
"openwebmath_perplexity": 1187.416238672969,
"openwebmath_score": 0.6640046238899231,
"tags": null,
"url": "http://mathhelpforum.com/algebra/134779-compounding-interest-problem-help.html"
} |
9. Originally Posted by qcom
....or is it fine to only do it in intervals of 10?
Dunno. I'd assume it is.
Isn't there a way in whatever graphing program you're using
ti give an instruction, like:
Do for t = 1 to 60 : y = (1 + .05)^t ? | {
"domain": "mathhelpforum.com",
"id": null,
"lm_label": "1. YES\n2. YES",
"lm_name": "Qwen/Qwen-72B",
"lm_q1_score": 0.9893474872757474,
"lm_q1q2_score": 0.8950137286781206,
"lm_q2_score": 0.9046505299595162,
"openwebmath_perplexity": 1187.416238672969,
"openwebmath_score": 0.6640046238899231,
"tags": null,
"url": "http://mathhelpforum.com/algebra/134779-compounding-interest-problem-help.html"
} |
# Alternate solution to circular permutation problem with restrictions
Ten chairs are evenly spaced around a round table and numbered clockwise from $1$ through $10$. Five married couples are to sit in the chairs with men and women alternating, and no one is to sit either next to or across from his/her spouse. How many seating arrangements are possible?
$\mathrm{(A)}\ 240\qquad\mathrm{(B)}\ 360\qquad\mathrm{(C)}\ 480\qquad\mathrm{(D)}\ 540\qquad\mathrm{(E)}\ 720$
Solution For the first man, there are $10$ possible seats. For each subsequent man, there are $4$, $3$, $2$, and $1$ possible seats. After the men are seated, there are only two possible arrangements for the five women. The answer is $10\cdot 4\cdot 3\cdot 2\cdot 1\cdot 2 = \boxed{480}$.
I am not satisfied with this solution. Is there another way to do this? (I just don't like this solution's..solution. There are many ways to proof the Pythagorean Theorem, and while you have no logical objections to others, surely there's some you like better or less than others? It's like that. I don't think I "think" like this solution. In any case, I just want to explore some other solutions that make better sense in my mind.) | {
"domain": "stackexchange.com",
"id": null,
"lm_label": "1. YES\n2. YES",
"lm_name": "Qwen/Qwen-72B",
"lm_q1_score": 0.9808759649262345,
"lm_q1q2_score": 0.8949866993414084,
"lm_q2_score": 0.9124361604769413,
"openwebmath_perplexity": 244.52457619018728,
"openwebmath_score": 0.7147206664085388,
"tags": null,
"url": "https://math.stackexchange.com/questions/1596629/alternate-solution-to-circular-permutation-problem-with-restrictions"
} |
• Understood. I am asking for another solution to the problem is all though. I will edit it and try to express my intentions better. – mathflair Jan 2 '16 at 1:24
• Even if this were not a request for a more satisfactory solution of some kind, I would hope that you would include more context, such as your own thoughts about solving it. After all, a multiple choice problem will often have some short cuts, and hearing your thoughts of one kind or another may better inform a Reader's responses toward solutions that you find more pleasing. – hardmath Jan 2 '16 at 1:43
• Perhaps you could give an example of how you "think" to a similar problem so we have a better idea of what you are after. Personally that answer is exactly how I think about the problem. – Ian Miller Jan 2 '16 at 2:07
• I just wanted to see if there were other ways to do this problem, so no one had to tailor a solution to my mind! I may have come across that point confusingly. ^^; – mathflair Jan 2 '16 at 5:45
This is not very different from your solution but maybe it is more clear: Let the men be $m_1, m_2, ..., m_5$ and their arrangement be the (ordered) vector $A=(a_1, ..., a_5)$ Since the seats are labelled, the arrangement $(1,3,5,7,9)$ is different than $(3,5,7,9,1)$ etc. There are 10 ways to pick $a_1$ for man $m_1$. For each arrangement vector $A$ there are $4!$ permutations for men $m_2$ to $m_5$ and all the men arrangements are now $10\times 4!$ | {
"domain": "stackexchange.com",
"id": null,
"lm_label": "1. YES\n2. YES",
"lm_name": "Qwen/Qwen-72B",
"lm_q1_score": 0.9808759649262345,
"lm_q1q2_score": 0.8949866993414084,
"lm_q2_score": 0.9124361604769413,
"openwebmath_perplexity": 244.52457619018728,
"openwebmath_score": 0.7147206664085388,
"tags": null,
"url": "https://math.stackexchange.com/questions/1596629/alternate-solution-to-circular-permutation-problem-with-restrictions"
} |
Without losing generality let's consider one men's arrangement $(1,3,5,7,9)$ For this case let's name the women as $w_i$, where $i$ is the seat number where their spouse is seated. Women can go to the even seats. In seat 2 you cannot have $w_1$ and $w_3$ and not $w_7$ either (across her spouse in seat 7). That leaves two choices for seat 2: $w_5$ or $w_9$. If you pick $w_5$ there is only one possible arrangement for the rest of the even seats to give: $(w_5, w_7,w_9,w_1,w_3)$. Same as you pick $w_9$, there is only one arrangement. Working the same way you can confirm that there are only two possible arrangements for the women as your solution states and get the answer $2\times10\times4!$
Another way
Permissible positions of males in relation to their spouses is either $+3$ or $-3$, e.g. $1-4$ or $1-8$
The chart below with females at odd positions makes it obvious that if the $+3$ option is chosen for one couple, it needs to be so for all couples, (and so, too for $-3$)
$1 - \color{green}4-\color{red}{8}\quad\;\; 1-\color{red}4-\color{green}8$
$3 - \color{green}6-\color{red}{10}\quad 3-\color{red}6-\color{green}{10}$
$5 - \color{green}8-\color{red}{2}\quad\;\; 5-\color{red}8-\color{green}{2}$
$7 - \color{green}{10}-\color{red}4\quad 7-\color{red}{10}-\color{green}4$
$9 - \color{green}2-\color{red}6\quad\;\; 9-\color{red}2-\color{green}6$
Thus $10\cdot4!$ with the alpha female at odd positions, ditto at even positions to finally yield
ans = $2\cdot 10\cdot4!$ | {
"domain": "stackexchange.com",
"id": null,
"lm_label": "1. YES\n2. YES",
"lm_name": "Qwen/Qwen-72B",
"lm_q1_score": 0.9808759649262345,
"lm_q1q2_score": 0.8949866993414084,
"lm_q2_score": 0.9124361604769413,
"openwebmath_perplexity": 244.52457619018728,
"openwebmath_score": 0.7147206664085388,
"tags": null,
"url": "https://math.stackexchange.com/questions/1596629/alternate-solution-to-circular-permutation-problem-with-restrictions"
} |
# Solving the heat equation on the semi-infinite rod
Cross posted in scicomp.SE.
I want to test the solution which is given below is right by Mathematica.
Please look the post in mathstackexhange
or
Question: Solve the following heat equation on the semi-infinite rod
$\qquad u_t=ku_{xx}$
where $x,t>0$ and
$\qquad u_x(0,t) =0$ and $u(x,0)=\begin{cases} 1, & 0 < x <2 \\ 0, & 2\leq x \end{cases}$
with proper Fourier transform.
$\qquad u(x,t) = \frac{2}{\pi}\int_{0}^{\infty}e^{-s^2 t}\frac{1-\cos(2s)}{s}\cos(sx)ds.$
Code
But I am not sure the solution is right. I am not capable of testing it in Mathematica.
Could you help me?
• I don't we can do much to help without having the code you used to get the answer. If you didn't use Mathematica to solve your problem, then this question is inappropriate -- I would mean you are asking us to both write the code and verify the solution for you. Oct 17 '17 at 17:34
• Well, solving this in Mathematica is quite straightforward, just check the document of DSolve. Anyway, the solution is 1/2 (-Erf[(-2 + x)/(2 Sqrt[k t])] + Erf[(2 + x)/(2 Sqrt[k t])]). A quick test shows the solution in your question seems to be wrong. Oct 18 '17 at 4:44
• Further check shows that, if one wants to express the solution as integration, then it should be $\int_0^{\infty } \frac{\sqrt{\frac{2}{\pi }} \sin (2 w) e^{-k t w^2} \cos (w x)}{w} \, dw$ Oct 18 '17 at 12:08
• Guys, personally I suggest not to close this post, though it's a… "give me the code" question, the problem is interesting, I think. Oct 18 '17 at 12:13
• Please do not cross-post within SE sites. Choose one site and delete the questions from the others. meta.stackexchange.com/q/64068/164803 Oct 19 '17 at 12:17
Personally I think the problem is interesting, so let me extend my comments to an answer. First of all, DSolve can solve OP's problem straightforwardly (in Mathematica 10.3 or higher, if I remember correctly): | {
"domain": "stackexchange.com",
"id": null,
"lm_label": "1. YES\n2. YES",
"lm_name": "Qwen/Qwen-72B",
"lm_q1_score": 0.9706877726405082,
"lm_q1q2_score": 0.8948982545064462,
"lm_q2_score": 0.9219218370002787,
"openwebmath_perplexity": 2063.240177378497,
"openwebmath_score": 0.5426247119903564,
"tags": null,
"url": "https://mathematica.stackexchange.com/questions/157983/solving-the-heat-equation-on-the-semi-infinite-rod"
} |
With[{u = u[t, x]},
eq = D[u, t] == k D[u, x, x];
ic = u == Piecewise[{{1, 0 < x < 2}}] /. t -> 0;
bc = D[u, x] == 0 /. x -> 0;]
asol = DSolveValue[{eq, ic, bc}, u, {t, x}, Assumptions -> {x > 0, k > 0}];
asol[t, x]
(* 1/2 (-Erf[(-2 + x)/(2 Sqrt[k] Sqrt[t])] + Erf[(2 + x)/(2 Sqrt[k] Sqrt[t])]) *)
Remark
There seems to be a bug in DSolve in v11.2.0.
DSolve[{eq, ic, bc}, u[t, x], {t, x}]
will return unevaluated.
As one can see, DSolve expresses the solution with Erf, so it's not immediately clear whether OP's solution is correct or not, and Mathematica's functions for simplifying also doesn't work well in this case, so let's obtain the analytic solution with another approach, that is, making use of Fourier cosine transform to eliminate the derivative of $x$:
fct = FourierCosTransform[#, x, s] &;
tset = Map[fct, {eq, ic}, {2}] /. Rule @@ bc /.
HoldPattern@FourierCosTransform[a_, __] :> a
tsol = u[t, x] /. DSolve[tset, u[t, x], t][[1]]
(* (E^(-k s^2 t) Sqrt[2/π] Sin[2 s])/s *)
Remark
I've made the transform on the PDE in a quick way, for a more general approach, check this post.
InverseFourierCosTransform has difficulty in transforming tsol, but it doesn't matter because the integral form is just what we want. By checking the formula of inverse Fourier cosine transform, we find the solution should be
$$u(t,x)=\sqrt{\frac{2}{\pi }} \int_0^{\infty } \frac{e^{-k s^2 t} \sqrt{\frac{2}{\pi }} \cos (s x) \sin (2 s)}{s} \, ds$$
It's apparently different from the one in your question, and numeric calculation shows this solution is the same as the one given by DSolve, so the one in your question is wrong.
Finally, a illustration for the solution:
Plot3D[asol[t, x] /. k -> 1 // Evaluate, {x, 0, 4}, {t, 0, 10}]
# Update
Inspired by Ars3nous' comment below, I noticed InverseFourierCosTransform can actually transform tsol. We just need a proper assumption: | {
"domain": "stackexchange.com",
"id": null,
"lm_label": "1. YES\n2. YES",
"lm_name": "Qwen/Qwen-72B",
"lm_q1_score": 0.9706877726405082,
"lm_q1q2_score": 0.8948982545064462,
"lm_q2_score": 0.9219218370002787,
"openwebmath_perplexity": 2063.240177378497,
"openwebmath_score": 0.5426247119903564,
"tags": null,
"url": "https://mathematica.stackexchange.com/questions/157983/solving-the-heat-equation-on-the-semi-infinite-rod"
} |
InverseFourierCosTransform[tsol, s, x, Assumptions -> k > 0]
(* 1/2 (-Erf[(-2 + x)/(2 Sqrt[k t])] + Erf[(2 + x)/(2 Sqrt[k t])]) *)
Apparently it's the same as asol.
• Following @xzczd amazing answer using cosine transform, with k=1 (you can always scale out k in time) In Mathematica 9.0, I get using InverseFourierCosineTransform, $u(x,t)=\frac{1}{2} \left(-2 x \text{erfc}\left(\frac{x}{2 \sqrt{t}}\right)+\text{erfc}\left(\frac{x+2}{2 \sqrt{t}}\right)+\text{erfc}\left(-\frac{x-2}{2 \sqrt{t}}\right)+\frac{4 \sqrt{t} e^{-\frac{x^2}{4 t}}}{\sqrt{\pi }}-2\right)$ which has two different terms along the mentioned answer. But this solution also does not satisfy boundary conditions. I wonder what is the discrepency for. Nov 5 '17 at 12:18
• @Ars3nous Are you in v9.0.0 or v9.0.1? I just tested in v9.0.1, Win10 64bit, with InverseFourierCosTransform[tsol /. k -> 1, s, x] I got 1/2 (Erf[(2 - x)/(2 Sqrt[t])] + Erf[(2 + x)/(2 Sqrt[t])]), which is consistent with asol. Nov 5 '17 at 12:38 | {
"domain": "stackexchange.com",
"id": null,
"lm_label": "1. YES\n2. YES",
"lm_name": "Qwen/Qwen-72B",
"lm_q1_score": 0.9706877726405082,
"lm_q1q2_score": 0.8948982545064462,
"lm_q2_score": 0.9219218370002787,
"openwebmath_perplexity": 2063.240177378497,
"openwebmath_score": 0.5426247119903564,
"tags": null,
"url": "https://mathematica.stackexchange.com/questions/157983/solving-the-heat-equation-on-the-semi-infinite-rod"
} |
# Find the sum of the series of $\frac{1}{1\cdot 3}+\frac{1}{3\cdot 5}+\frac{1}{5\cdot 7}+\frac{1}{7\cdot 9}+…$
Find the sum of the series $$\frac1{1\cdot3}+\frac1{3\cdot5}+\frac1{5\cdot7}+\frac1{7\cdot9}+\frac1{9\cdot11}+\cdots$$ My attempt solution: $$\frac13\cdot\left(1+\frac15\right)+\frac17\cdot\left(\frac15+\frac19\right)+\frac1{11}\cdot\left(\frac19+\frac1{13}\right)+\cdots$$ $$=\frac13\cdot\left(\frac65\right)+\frac17\cdot \left(\frac{14}{45}\right)+\frac1{11}\cdot\left(\frac{22}{117}\right)+\cdots$$ $$=2\cdot\left(\left(\frac15\right)+\left(\frac1{45}\right)+\left(\frac1{117}\right)+\cdots\right)$$ $$=2\cdot\left(\left(\frac15\right)+\left(\frac1{5\cdot9}\right)+\left(\frac1{9\cdot13}\right)+\cdots\right)$$ It is here that I am stuck. The answer should be $\frac12$ but I don't see how to get it. Any suggestions?
Also, a bit more generally, are there good books (preferably with solutions) to sharpen my series skills?
• @ParclyTaxel Gah! My inability to read signs when strikes again. Retracted. – Xander Henderson Dec 8 '17 at 3:22
• Your question suggests an Infinite sum. Am I right? – Ravi Prakash Dec 8 '17 at 5:26
This is a general approach to evaluate the sum of series, like these.
First find $n^{th}$ term of series.
Let $T_n$ denote the $n^{th}$ term.
We see that,
$T_1 = \frac{1}{\color{green}{1} \cdot \color{teal}{3}}$
$T_2 = \frac{1}{\color{green}{3} \cdot \color{teal}{5}}$
And so on. Let the numbers in $\color{green}{green}$ be $$\color{green}{X_1,X_2,X_3,X_4,..=1,3,5,7...}$$
Clearly they form an A.P. with common difference $=2$
So, $n^{th}$ term of this AP is $1 + (n-1) × 2 = \color{green}{2n-1}$
Similarly, Let the numbers in $\color{teal}{teal}$ be $$\color{teal}{Y_1,Y_2,Y_3,Y_4,..=3,5,7,9...}$$ Clearly they form an A.P. with common difference $=2$
So, $n^{th}$ term of this AP is $3 + (n-1) × 2 =\color{teal}{ 2n+1 }$
So, the $n^{th}$ term of the main question is just
$$T_n = \frac{1}{\color{green}{(2n-1)} \cdot \color{teal}{(2n+1)}}$$ | {
"domain": "stackexchange.com",
"id": null,
"lm_label": "1. YES\n2. YES",
"lm_name": "Qwen/Qwen-72B",
"lm_q1_score": 0.9891815491146485,
"lm_q1q2_score": 0.8948636081827083,
"lm_q2_score": 0.9046505254608135,
"openwebmath_perplexity": 445.5246107828509,
"openwebmath_score": 0.9605997204780579,
"tags": null,
"url": "https://math.stackexchange.com/questions/2556569/find-the-sum-of-the-series-of-frac11-cdot-3-frac13-cdot-5-frac15"
} |
$$T_n = \frac{1}{\color{green}{(2n-1)} \cdot \color{teal}{(2n+1)}}$$
Now, taking summation from $1$ to $n$ , we have,
$$\sum_{n=1}^n \frac{1}{(2n-1) \cdot (2n+1)}$$
$$= \sum_{n=1}^n = \frac{1}{2} \cdot \frac{(2n+1)-(2n-1)}{(2n-1)(2n+1)}$$
$$= \sum_{n=1}^n = \frac{1}{2} \cdot \frac{1}{(2n-1)} - \frac{1}{(2n+1)}$$
$$= \sum_{n=1}^n = \frac{1}{2} \cdot ( 1 - \frac{1}{(2n+1)} )$$
While $n = ∞$,
$$\sum_{n=1}^∞ = \frac{1}{2} \cdot ( 1 - \frac{1}{(2(∞)+1)} )$$
$$= \sum_{n=1}^∞ = \frac{1}{2} \cdot ( 1 - \frac{1}{∞} )$$
Since $\frac{1}{∞} = 0$,
$$\sum_{n=1}^∞ = \frac{1}{2} \cdot ( 1 - 0 )$$
Which is
$$\sum_{n=1}^∞ = \frac{1}{2}$$
This is a classic telescoping series. $$\frac1{n\cdot(n+2)}=\frac12\left(\frac1n-\frac1{n+2}\right)$$ Thus $$\frac{1}{1\cdot 3}+\frac{1}{3\cdot 5}+\frac{1}{5\cdot 7}+\frac{1}{7\cdot 9}+\frac{1}{9\cdot 11}+\cdots$$ $$=\frac12\left(\frac11-\frac13+\frac13-\frac15+\frac15-\frac17+\frac17-\frac19+\frac19-\frac1{11}+\cdots\right)$$ $$=\frac12$$
\begin{align*} \sum_{n=1}\dfrac{1}{(2n-1)(2n+1)}&=\dfrac{1}{2}\sum_{n=1}\left(\dfrac{1}{2n-1}-\dfrac{1}{2n+1}\right)\\ &=\dfrac{1}{2}\sum_{n=1}\left(\dfrac{1}{2n-1}-\dfrac{1}{2(n+1)-1}\right)\\ &=\dfrac{1}{2}\sum_{n=1}\left(\dfrac{1}{f(n)}-\dfrac{1}{f(n+1)}\right)\\ &=\dfrac{1}{2}\dfrac{1}{f(1)}, \end{align*} where $f(n)=2n-1$, and note that $f(n)^{-1}\rightarrow 0$ as $n\rightarrow\infty$.
$$\frac{1}{1\cdot 3}+\frac{1}{3\cdot 5}+\frac{1}{5\cdot 7}+\frac{1}{7\cdot 9}+\frac{1}{9\cdot 11}...=\dfrac{1}{2}\left(\dfrac{1}{1}-\dfrac{1}{3}\right)+\dfrac{1}{2}\left(\dfrac{1}{3}-\dfrac{1}{5}\right)+\dfrac{1}{2}\left(\dfrac{1}{5}-\dfrac{1}{7}\right)+\cdots=\dfrac12$$
Let me give a general method which is useful for this sum $\frac1{1\cdot3}+\frac1{3\cdot5}+\frac1{5\cdot7}+\frac1{7\cdot9}+\frac1{9\cdot11}+\cdots=\sum_{n=1}^\infty\dfrac{1}{(2n-1)(2n+1)}$ we have
$\sum_{n=1}^\infty\dfrac{1}{(2n-1)(2n+1)}=\sum_{n=0}^\infty\dfrac{1}{(2n+1)(2n+3)}$
we can use this method | {
"domain": "stackexchange.com",
"id": null,
"lm_label": "1. YES\n2. YES",
"lm_name": "Qwen/Qwen-72B",
"lm_q1_score": 0.9891815491146485,
"lm_q1q2_score": 0.8948636081827083,
"lm_q2_score": 0.9046505254608135,
"openwebmath_perplexity": 445.5246107828509,
"openwebmath_score": 0.9605997204780579,
"tags": null,
"url": "https://math.stackexchange.com/questions/2556569/find-the-sum-of-the-series-of-frac11-cdot-3-frac13-cdot-5-frac15"
} |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.