Categories
Mastering Development

WebGL Point Lighting Issue

I have attempted to create a rotating cube in WebGL and texture it by using the texture mapping technique, which I think worked fine. The cube rotates so as to try and demonstrate the (point) lighting I have tried to implement, but it seems to act in an unexpected fashion and I’m not really sure […]

Categories
Ask Mathematics

Average of function defined on cantor set

Suppose we have $P: A\cap[0,1]\to\mathbb{R}$, where $A$ is the Cantor set. I want to define and find the average of $P$ to give a result between the infimum and supremum of $P$‘s range. Obviously we cannot use the Lebesgue measure, as the average would be zero. Instead, we need a new definition. My intuition is, […]

Categories
Mastering Development

Grouping data together based on specific increment

I have a 2D list in python as : [[‘Xzavier Kaska’, 1.04], [‘Brent Barnaby’, 1.13], [‘Alena Holoien’, 1.37], [‘Sam Surey’, 1.37], [‘Kash Nocella’, 1.55], [‘Ezequiel Gerraughty’, 1.57], [‘Myah Linsley’, 1.74], [‘Jaelynn Dzur’, 1.79], [‘Alfredo Andrew’, 1.83], [‘Skylar Movius’, 1.95], [‘Raphael Nocella’, 2.14], [‘Alondra Wallace’, 2.2], [‘Clark Loomis’, 2.3], [‘Skylar Cvek’, 2.36], [‘Carson Racugno’, 2.52], [‘Kathy […]

Categories
Ask Mathematics

Using subsets of R, give two examples of each of the above if-then statements, one satisfying, and one not satisfying

Let $X$ be a linearly ordered set with order <. Suppose $A \subset X$ is a nonempty set. Suppose A has a least upper bound $u_0$. If $u_0$ is in A, then it is the greatest element of A, and Suppose A has a greatest lower bound $l_0$. If $l_0$ is in A, then it […]

Categories
Ask Mathematics

Find all the elements in H and explain why some appear and some don’t

(Disclaimer I legit can find a way to answer this) Let α = (1,2) (3,4). Let H = {β∈S4 | αβ = βα} Find two elements of H. Explain why something is not in H I believe it has something to do with transposition but I just can’t seem to understand it well.

Categories
Ask Mathematics

Finding sequence of pairs with second element of previous pair matching first element of next pair

I am interested in efficient ways of doing certain problem. I have list of $n$ pairs, where $n$ is usually a few houndred thousands and each pair’s element is an integer (let’s assume it is integer from $0$ to $10000$) and I am trying to find a sequence such that it start and ends at […]

Categories
Mastering Development

Divide data by the preceding row and create new dataframe

I have a data set and I’m trying to calculate the rate of change between the rows. My input looks like this: foo = structure(list(date = structure(c(5L, 1L, 2L, 3L, 4L), .Label = c(“10/03/2020”, “11/03/2020”, “12/03/2020”, “13/03/2020”, “9/03/2020”), class = “factor”), A = c(0.60256322, 0.634543306, 0.022976661, 0.009839044, 0.319456765), B = c(45.42320826, 57.32689951, 32.49487759, 29.40804164, 54.33691346), […]

Categories
Ask Mathematics

Sequence of number pairs

Im trying to figure out which topic this falls under: Two numbers (x,y) where the next pair is generated by doubling the smaller one and subtracting the smaller from the larger so if x is smaller (x*2,y-x) There are number pairs where this will lead to x=y or y=x e.g (1,3) –> (2,2). And other […]

Categories
Ask Mathematics

Is it not a function?

My knowledge:The funcion must be bijective iff the function can be inversed. The question from the book said that “Let f: R⇒R have the rule $f(x)=⌊3x⌋-1.$Find $f^{-1}(S)$ Where $s=\{0\}$. we have $f(x)=y$,we can see that if x is $[1/3,2/3)$,then y is $0$, that means the function is not injective,also not bijective,we cannot inverse the function,how […]

Categories
Mastering Development

Backpropagation giving strange values in C++ neural network

I am trying to solve the iris data set with a neural network I wrote in C++ from scratch, which has 150 rows divided up into 3 different flowers with 4 columns and then a fifth for the flower type which I converted to a 0, 1 or 2. Problem: Whenever I run the network […]