What is the rationale of passing 0 (zero) to virtual functions in a base-class?

I see people doing stuff like

class StateBase {
  public:
    StateBase(Application &app)
        : m_pApplication(&app)
    {
    }

    virtual ~StateBase() = default;

    virtual void foo(Event e) = 0;
    virtual void bar() = 0;
   
  protected:
    Application *m_pApplication;
};

And then

class StateDerived: public StateBase {
  public:
    StateDerived(Application &app);

    void foo(Event e) override;
    void bar() override;

//...
};

Is this somehow equivalent to default initialization? Does it set void to a null pointer? This code snippet is particularly cryptic to me, not sure what it aims to achieve.

πŸ‘︎ 5
πŸ’¬︎
πŸ‘€︎ u/rdar1999
πŸ“…︎ Mar 22 2020
🚨︎ report
Adaptive control technique without tuning controller parameters, the idea based on substituting the Laplace variable in a transfer function by a strictly positive real transfer function of zero relative degree. G(s) = C(G0(s)) where G overall system transfer function, C controller and G0 plant v.redd.it/ls01ifjdg6f41
πŸ‘︎ 26
πŸ’¬︎
πŸ‘€︎ u/mus9977
πŸ“…︎ Feb 05 2020
🚨︎ report
My second sketch of zero two I know it’s bad but this is the second time I’ve touched a pencil in like a year I had carpal tunnel and drawing has been painful so I’m just getting advance wrist function back so I’m proud
πŸ‘︎ 27
πŸ’¬︎
πŸ‘€︎ u/JerseyxJerry
πŸ“…︎ Jul 26 2019
🚨︎ report
Researchers obtain Bose-Einstein condensate with nickel chloride: In the vicinity of absolute zero, the particles that make up the condensate behave like a single particle and can be described by a single wave function eurekalert.org/pub_releas…
πŸ‘︎ 161
πŸ’¬︎
πŸ‘€︎ u/DoremusJessup
πŸ“…︎ Apr 04 2017
🚨︎ report
How do you find the zero’s of a function without graphing on your calculator

Taking the Calc AB test tomorrow and have a Ti-84 there has to be an easier way than graphing to find x intercepts

πŸ‘︎ 3
πŸ’¬︎
πŸ‘€︎ u/DustyDraft
πŸ“…︎ May 14 2019
🚨︎ report
A Tale of Three Cosinesβ€”Identifying Peaks in Distributions of Zeros and Extrema of Almost-Periodic Functions blog.wolfram.com/2018/04/…
πŸ‘︎ 45
πŸ’¬︎
πŸ“…︎ Apr 24 2018
🚨︎ report
[College] Would like an explanation on zeros and poles of a Transfer Function

I was reading transfer function and how to find the number of infinite zeros. Is it possible that given a generic system = G(s), where G(s) = N(s)/D(s). What is the advantage or disadvantage of having a large number of infinite zeros? Also is it possible to have number of zeros greater than the number poles in system G(s)?

πŸ‘︎ 3
πŸ’¬︎
πŸ‘€︎ u/Tinymaple
πŸ“…︎ Feb 05 2019
🚨︎ report
[Grade 12] Identifying Roots and Zeros of a Polynomial Function

Just got to the chapter "Identifying Roots and Zeros of a Polynomial Function" and I'm getting pretty confused at one part. Heres a picture of the intro to the lesson https://imgur.com/a/9bhtl. The part that is confusing me the most is in the 4th paragraph.

Two of the questions to practice this is:

i) y=(x–1)^2 (x+3)

  • When I first look at this I can state the x-intercepts. Being 1 and -3. So if I understand this correctly y= (x-1)^2(x+3) = 0 has a double root (order 2) at x = 1 and a single root of (order 1) at x = -3.

ii) y=(x–1)^3

  • When I look at this I can see one x-intercept that being 1. So does y=(x-1)^3 has a triple root (order 3) at x = 1.

The thing that gets me more confused is that it then asks for "What is the relationship between the number of x-intercepts on the graph and the order of the zeros in the equation of the function?" I didn't know the answer so I looked at the given answer for this question and it was "The number of x-intercepts corresponds to the number of distinct zeros no matter what order each has." I have no idea what this means, the only guess I have is that for example question ii) it has a order of 3 but only has one x-intercept so how does the x-intercepts corresponds to the number of distinct zeros.

πŸ‘︎ 2
πŸ’¬︎
πŸ‘€︎ u/TYLERTHEGR88
πŸ“…︎ Sep 29 2017
🚨︎ report
A gradient based method will always converge in linear problems, independently of the cost function used (assuming its zero for the true values only) and initial points as long as the increments in each step are small enough and the variables that affect the system randomized. Is my intuition true?

Hi, I am estimating the parameters of a system which is linear. I have differential equations for the system but I discretize them so at the end I can represent the system such as:

U = A*p

where U is something I can measure, A is a matrix which coefficients I know and p are the unknown parameters.

Let length(U) <= length(p)

Then I hypotize that an optimization method that goes contrary to the gradient scaled will always converge to the true values of the system (p) as long as the magnitude of the changes in each iteration is small enough, independent of the starting points or cost functions used and also assuming I randomize the measurements so U and A change all the time.

I have proved this for different cost functions using the sum of the absolute errors and the sum of squares. I tried with different exponents in the cost functions such as sum((U'-U)^(2*n)) and the hypothesis always holded true as the gradient only became zero when the fit was perfect or in certain combinations of U and A and hence the added "and the variables that affect the system randomized".

I was curious if maybe this can be generalized for any cost function used. Maybe it can be easily proved playing a bit with the chain rule but I'm curious if something like this has been proved before.

πŸ‘︎ 7
πŸ’¬︎
πŸ‘€︎ u/eclipseadb
πŸ“…︎ Sep 26 2015
🚨︎ report
Hey spirits, what are the zeros of the function f(x)=-3x^2+1467x-86940?
πŸ‘︎ 2
πŸ’¬︎
πŸ‘€︎ u/sqrt-1_of_swag
πŸ“…︎ Nov 22 2019
🚨︎ report
As promised, the Pi-Tac 2.0 - A Raspberry Pi Zero W in a Tic-Tac box, with an Adafruit PiOLED display, and a Powerboost 1000C for push-button power, and safe shutdown on low battery. Now with updated display, new function buttons, and a retractable USB port. imgur.com/a/eoQ61
πŸ‘︎ 1k
πŸ’¬︎
πŸ‘€︎ u/deathonater
πŸ“…︎ Nov 03 2017
🚨︎ report
Battle of the schizos LOL: What is worse - being unmedicated hallucinating voices and seeing things that aren't there but you're full of energy and high functioning OR being medicated having only negative symptoms that make you a slow thinker with zero motivation for anything

3...2...1... FIGHT!!

πŸ‘︎ 103
πŸ’¬︎
πŸ‘€︎ u/SpaghetBurger
πŸ“…︎ Feb 13 2020
🚨︎ report
How to calculate Bessel function of order zero?

Hello everyone. I try to plot a figure of a journal article. I gave the equations, the expected figure and my incorrect figure in the attached image file. I wrote a code for that:

phi = linspace(0.001, 1000, 1000000);
v = 2;
lRp = sqrt((1./phi).*((v+1)^2-1));
I1 = besselj(1,lRp);
I0 = besselj(0,lRp);
h = 1 - 2./lRp*(I1/I0);
plot(phi,h)
set(gca, 'XScale', 'log')

But it doesn't work as expected. I obtain the figure on the right, given in the attached image file. May you help me to find my error? Thanks a lot!

https://preview.redd.it/o5h4c6bmnav41.png?width=1078&format=png&auto=webp&s=50a70f5b667eb0675f49ea51d875e779d849db78

πŸ‘︎ 6
πŸ’¬︎
πŸ‘€︎ u/mantras3
πŸ“…︎ Apr 27 2020
🚨︎ report
Bode plot of transfer function with one zero at s=0 and one pole at s=-1802

Hi there,

I'm trying to draw a Bode plot for the transfer function (-8.1899*10^(-3) * s) / (8.4732 * 10^(-4) * s + 1) .

I'm having the worst time trying to figure this out. How do I draw a Bode plot for a transfer function with a zero at zero? All the resources I can find online only give instructions for nonzero zeros. Also, how does the coefficient -8.1899*10^(-3) play into it? Does it even matter?

Thank you for your help.

πŸ‘︎ 26
πŸ’¬︎
πŸ“…︎ Oct 20 2019
🚨︎ report
[OC] Counting the number of Gaussian primes using the non-trivial zeros of L-functions (details in comments)
πŸ‘︎ 441
πŸ’¬︎
πŸ‘€︎ u/Not_in_Sciences
πŸ“…︎ May 17 2018
🚨︎ report
Why is the zeta function of the negative even integers equal to zero?

I tried to calculate zeta of -2 but I got something which is not zero (1/96) and I can't seem to find why or how it could be zero. Any kind of help is welcome.

πŸ‘︎ 8
πŸ’¬︎
πŸ‘€︎ u/DrTintedWindow
πŸ“…︎ Jul 28 2019
🚨︎ report
Can someone please help me prove that the real part of every nontrivial zero of this function is equal to half? TIA!
πŸ‘︎ 7
πŸ’¬︎
πŸ‘€︎ u/hsimms77
πŸ“…︎ Mar 25 2019
🚨︎ report
Physicists one step closer to solving the Riemann Hypothesis - Hamiltonian constructed that correspond to the zeros of the Riemann Zeta function quantamagazine.org/201704…
πŸ‘︎ 197
πŸ’¬︎
πŸ‘€︎ u/SamStringTheory
πŸ“…︎ Apr 19 2017
🚨︎ report
empty tamed island 30days after from zero.. all build single handed... 35plots only to have all important facilities to functions. feel free to drop a visit to my tamed its open for visit . asia 1. moon #2786 v.redd.it/l842elk9frp31
πŸ‘︎ 28
πŸ’¬︎
πŸ‘€︎ u/moon2786
πŸ“…︎ Sep 30 2019
🚨︎ report
Damn you Polar Vortex! Can’t even do the basic bodily functions because of the sub zero temp
πŸ‘︎ 35
πŸ’¬︎
πŸ‘€︎ u/chandu1256
πŸ“…︎ Jan 31 2019
🚨︎ report
[Pre-Calculus 12 - Exponential Functions] So, my textbook says that the graph A and question C are equal to one another. Is there a rule I'm missing? I only know that if the base is greater than 1, it is growth, and if it is in between one and zero, it is decay. Please help >~<
πŸ‘︎ 3
πŸ’¬︎
πŸ‘€︎ u/NeptuneWalker
πŸ“…︎ Jan 22 2020
🚨︎ report
[Grade 10: Math] If Ax + By = C is for non-zero constants, why is A, B, and C always a linear function?

bruh why do i have to do all of this. goddamn this is like school, so organized but unnecessary. so all I get is that x + y = some number, and x + y straight up can be anything.

so like this if i make a chart.

x y

1 100

2 69

3 21

so there, it's not a linear function cause the y doesnt make sense at all. its clearly not a same - for both, like im too lazy to calculate. ok fine its -31 then -48, so its not right. or do i not get what linear function means?

πŸ‘︎ 4
πŸ’¬︎
πŸ‘€︎ u/autisicautist
πŸ“…︎ Nov 20 2019
🚨︎ report
Magnitude of Frequency Reponse in Transfer Functions (Poles & Zeros)

Hi, I'm looking at the solution to one of the homework problems, and I saw this.

https://i.imgur.com/HLbINkp.png

If we want to boost the magnitude of the frequency response to 0dB, why do they add a pole (s+a)? I thought we would need to add zeros in the transfer function's numerator since we already have two poles that would make the system -40dB. I'm so confused right now. Thanks.

πŸ‘︎ 2
πŸ’¬︎
πŸ‘€︎ u/iScammed
πŸ“…︎ Oct 06 2019
🚨︎ report
How can a nation with zero inflation (or deflation) function?

I read when it was done in Japan in the 90s it led to reduced spending and more hoarding which led to reduced demand and layoffs.

But what I don't understand is how is that different than now? Too much inflation and everything is very hard to afford so those that can hoard still do and companies still layoff due to other factors.

Can marketing help an economy performing zero inflation or deflation?

ELI5 OR ELI16 as much as possible. I'd like to know if there are people with theories on how to reduce inflation. Because as far as I know, nothing can keep growing forever.

πŸ‘︎ 2
πŸ’¬︎
πŸ‘€︎ u/IGetHypedEasily
πŸ“…︎ Jul 31 2019
🚨︎ report
How can I fix my zero's appearing as '-'s when using a function?

For some context I'm subtracting the sums of two different ends of a table with =SUM(B22:H22) - SUM(I22:J22) - K22. It works, but my answers which should be coming out as zeros(For accounting purposes) appear as dashes. Please and thank you.

πŸ‘︎ 36
πŸ’¬︎
πŸ‘€︎ u/Lux_Aetheris
πŸ“…︎ Oct 15 2018
🚨︎ report
Trivial Normal Bundle iff Zero of functions?

Hi. In my smooth manifolds class, I believe the proffesor told me that a k codimensional submanifold will be the zero set of k functions if and only if the normal bundle is trivial. I wanted to make sure that I am remembering this correctly. I have been able to sketch a proof for the (zero set of functions implies trivial normal bundle) direction, involving Riemannian metrics (which I do not know a lot about), but have not made any way on the other direction, so I wanted to make sure I am not forgetting any hypothesises. Also, I am interested in weather or not something like this can be true in Algebraic Geometry. I am skeptical that it can be exactly the same, as every closed variety in an affine variety is the zero set of some functions, and practically no sub variety is the zero set of some functions for projective varieties.

πŸ‘︎ 4
πŸ’¬︎
πŸ‘€︎ u/newwilli22
πŸ“…︎ Apr 20 2019
🚨︎ report
Is there a way for someone with zero background in the stuff to get a sound making birthday card to function again?

Are they all essentially the same on the I side? My electrical knowledge consists of turning the lights on and off - but if someone could help me identify a piece that needs to be reconnected? Swap out a battery? String some tinfoil across to a new battery?

I’ve been cleaning house and found lots of these old cards, my 4yo loves them but most don’t work.

πŸ‘︎ 2
πŸ’¬︎
πŸ‘€︎ u/brownsquared
πŸ“…︎ Apr 08 2020
🚨︎ report
What does the distance between a functions zeros mean?

Say we have the function y=x^2 -x-12

Could someone please explain I cannot find anything by googling

πŸ‘︎ 3
πŸ’¬︎
πŸ‘€︎ u/aizver_muti
πŸ“…︎ Apr 26 2019
🚨︎ report
Zeros of the Riemann zeta function in the critical strip versus on the critical line

If critical zeros are in the critical strip 0 < Re(s) < 1, then what do you call zeros on the critical line Re(s) = 1/2? Supercritical?

What are the hypothetical non-trivial critical zeros off the critical line?

πŸ‘︎ 6
πŸ’¬︎
πŸ‘€︎ u/ziggurism
πŸ“…︎ Jul 02 2018
🚨︎ report
ELI5: How does an enzyme function just a little worse over its optimal temperature, and how does its functionality not just drop to zero?

Why is it that when an enzyme gets too hot, even though it's supposed to denature, its efficiency just goes down a little before really taking a dip? What is going on during that little temperature range where the efficiency slowly goes down but doesn't plummet if it is supposed to be being denatured?

πŸ‘︎ 2
πŸ’¬︎
πŸ‘€︎ u/unkownwoknu
πŸ“…︎ Dec 05 2019
🚨︎ report
Help with finding zeros to a function?

Hey! Can someone help me find the zeros to this equation algebraically? I used desmos to graph it and I got the zeros of x=1 and x=4 but I don't seem to be getting that result when I try to solve for x algebraically.

:9\left(\frac{\left(x-4\right)^3}{2.718}\right)+9x\left(\frac{3\left(x-4\right)^2}{2.718}\right) (if you wanted to graph it, it might work on desmos)

The function: f(x) = 9[(x-4)^(3) / 2.718] + 9x[3(x-4)^(2) / 2.718]

Thank you!

πŸ‘︎ 2
πŸ’¬︎
πŸ‘€︎ u/cenaplec
πŸ“…︎ Jun 15 2019
🚨︎ report
serverless-bundle: a zero-config way to generate optimized packages for Node.js Lambda functions. seed.run/blog/introducing…
πŸ‘︎ 2
πŸ’¬︎
πŸ‘€︎ u/v14j
πŸ“…︎ Jul 24 2019
🚨︎ report
I need a random number function that returns numbers on a half-bell curve peaking at zero

I have an array of names sorted in descending order by popularity, from John (at index 0) on down to Broderick (at index 1218). I need to choose one of the names randomly, but I want the more common names returned more often. So basically I need a function that returns numbers on a half-bell curve with lower numbers more often and higher numbers less often.

 Dim names As String() = My.Resources.mnames.Split(vbCrLf)
 Dim x As integer
 Dim pick As String
 
 x = RandomHalfBell(UBound(names))
 pick = names(x)

Something like that. So what does the RandomHalfBell function look like?

πŸ‘︎ 2
πŸ’¬︎
πŸ‘€︎ u/thudly
πŸ“…︎ Aug 07 2018
🚨︎ report

Please note that this site uses cookies to personalise content and adverts, to provide social media features, and to analyse web traffic. Click here for more information.