Business
Jobs
  • About Us
  • Solutions
    • Job Postings
      Post your job and receive qualified candidates in 48h.
    • Candidate Assessments
      500+ technical and psychological tests, plus anti-fraud.
    • Headhunting
      Tailor-made executive search from start to finish.
    • Payroll + EOR
      Payroll dispersal and EOR across 15+ LATAM countries.
  • Pricing
  • Jobs

0

160
Views
Flujos infinitos en JavaScript (cómo multiplicar dos series que se representan como un flujo de coeficientes usando flujos)

Estoy tratando de crear una función que tome dos flujos de coeficientes y los multiplique. Por ejemplo, la serie 1+2x+3x^2 se representa como (1,2,3). Si tuviera las dos series 1+2x+3x^2 y 2+6x+9x^2 , la salida de esta función sería 2+10x+27x^2+36x^3+27x^4 o (2,10, 27,36,27,...).

Mi función addSeries es así:

 function addSeries(s,t){ if(s.toString() === "sempty" && t.toString() === "sempty"){ return sempty; } else if(s.toString() === "sempty"){ return snode(t.head(), memo0(() => addSeries(t.tail(),s))); } else if(t.toString() === "sempty"){ return snode(s.head(), memo0(() => addSeries(s.tail(),t))); } return snode(s.head() + t.head(), memo0(() => addSeries(s.tail(),t.tail()))); }

¿Cómo puedo usar este mismo principio para multiplicar dos flujos?

about 4 years ago · Juan Pablo Isaza
Answer question
Find remote jobs

Discover the new way to find a job!

Top jobs
Top job categories
Business
Post vacancy Pricing Sales
Legal
Terms and conditions Privacy policy
© 2026 PeakU Inc. All Rights Reserved.
Andres GPT
Show me some job opportunities
There's an error!