# Using forkJoin with async pipe

A

#### Andrew Howard

##### Guest
Andrew Howard Asks: Using forkJoin with async pipe
I have 2 arrays (of objects) and I wish to combine them by id.

Array One:

Code:
arrayOne$= of([{id: 1, name: "Andrew"}, {id: 2, name: "Simon"}]) as Observable<any[]>; Array Two: Code: arrayTwo$ = of([{id: 1, age: 22}, {id: 2, age: 56}]) as Observable<any[]>;

So the desired end result will be:

Code:
[{id: 1, name: "Andrew", age: 22}, {id: 2, name: "Simon", age: 56}]

I have to get these results via 2 different apis so using the async pipe and forkJoin are required. However I'm now stuck on how to use forkJoin, do I need to use map to do this?

Stackblitz = Angular Ivy (forked) - StackBlitz

So far I have:

TS

Code:
combinedResults$= forkJoin([ this.arrayOne$,
this.arrayTwo$]) HTML Code: <div *ngIf="(combinedResults$ | async)?.length !== 0">
<p>Here is the combined list items:</p>
<ul>
<li *ngFor="let item of combinedResults$| async"> ID: {{item.id}}<br /> Name: {{item.name}}<br /> Age: {{item.age}} </li> </ul> </div> SolveForum.com may not be responsible for the answers or solutions given to any question asked by the users. All Answers or responses are user generated answers and we do not have proof of its validity or correctness. Please vote for the answer that helped you in order to help others find out which is the most helpful answer. Questions labeled as solved may be solved or may not be solved depending on the type of question and the date posted for some posts may be scheduled to be deleted periodically. Do not hesitate to share your thoughts here to help others. ## Unreplied Threads #### Vector fields$X$and$Y$commute on a closed set$K$. Do there exist commuting$\tilde X,\tilde Y$with$\tilde X=X$and$\tilde Y=Y$on$K$? Blake Asks: Vector fields$X$and$Y$commute on a closed set$K$. Do there exist commuting$\tilde X,\tilde Y$with$\tilde X=X$and$\tilde Y=Y$on$K$? I have a nice research idea whose proof hinges on the following question Suppose$X_p$and$Y_p$are vector fields in$\mathbb{R}^3$with$[X,Y]_p=0$for all$p$in some closed set$K\subset\mathbb{R}^3$. For each point in$p\in K$, does there a neighborhood$U$of$p$and a two dimensional foliation$\mathcal{F}$on$U$with the property that$T_qL_q=\text{span}(X_q,Y_q)$for each$q\in U\cap K$? Here$L_q$denotes the leaf of$\mathcal{F}$through$q$. At a first glance, I thought this was probably true: after all, if such a foliation existed, then the vector fields must commute on$K$. But the more I try and prove it, the more I am having second thoughts on whether this is true. My naive attempt at a proof involves mimicking the proof of the Frobenius theorem; i.e. my candidate for the foliation would be the coordinate change $$(t_1,t_2,t_3)\mapsto\theta_{t_1}\circ\psi_{t_2}(0,0,t_3),$$ where$\theta_t$and$\psi_t$denote the flows of$X$and$Y$respectively, but the details get a little hairy when the vector fields don't always commute. I imagine that this has been studied before, so I was hoping someone would know of a reference that studies this question. If this is not true in general, what additional hypotheses are required? Any help would be greatly appreciated. Thanks in advance. SolveForum.com may not be responsible for the answers or solutions given to any question asked by the users. All Answers or responses are user generated answers and we do not have proof of its validity or correctness. Please vote for the answer that helped you in order to help others find out which is the most helpful answer. Questions labeled as solved may be solved or may not be solved depending on the type of question and the date posted for some posts may be scheduled to be deleted periodically. Do not hesitate to share your thoughts here to help others. ####$\lim_\limits{x \to 0}|x| \cdot \cos{\frac{x-5}{|x^2-x|}}$simple calculation not actual proof required Adamrk Asks:$\lim_\limits{x \to 0}|x| \cdot \cos{\frac{x-5}{|x^2-x|}}$simple calculation not actual proof required calculate$\lim_\limits{x \to 0}|x| \cdot \cos{\frac{x-5}{|x^2-x|}}$I am trying to figure why it is is equal to zero , in a simple way no need for a proof just limit properties or a use heine series theorem$\cos{\frac{x-5}{|x^2-x|}}$does not exist because it will be$\lim_\limits{x \to 0}\cos{\frac{x-5}{|x^2-x|}}=\cos{\infty}$but$\lim_\limits{x \to 0}|x|=0$I believe it is equal to zero because "zero limit$\cdot$bounded limit=0" or because$\lim _\limits{n \to \infty} |a_n|=0 \iff \lim _\limits{n \to \infty} a_n=0 $since then we will get$\lim_\limits{x \to 0}|x| \cdot |\cos{\frac{x-5}{|x^2-x|}}|= \lim_\limits{x \to 0}|x| \cdot 1 =0$but I am not sure if I can use that here as$x \to 0$and not$\infty$thanks for any tips and help SolveForum.com may not be responsible for the answers or solutions given to any question asked by the users. All Answers or responses are user generated answers and we do not have proof of its validity or correctness. Please vote for the answer that helped you in order to help others find out which is the most helpful answer. Questions labeled as solved may be solved or may not be solved depending on the type of question and the date posted for some posts may be scheduled to be deleted periodically. Do not hesitate to share your thoughts here to help others. #### Bott Tu local constant presheaf math3341 Asks: Bott Tu local constant presheaf I´m reading Bott Tu Differential forms in algebraic topology and I have a question. In the page 169 we wnat calculate cohomology of a fiber bundle$\pi:E\to M$with fiber$F$, and we define the presheaf$\mathscr{H}^q:=H^q(\pi^{-1}(U))$en$M$. Then the book says that for a good cover$\mathfrak{U}$,$\mathscr{H}^q$is a locally constant presheaf on$\mathfrak{U}$with group$H^q(F)$. Anyone can explain me this? Please. In the next page (170), the book takes the trivial bundle$M\times F$and says that$\mathscr{H}^q(F)$is constant presheaf. Why? SolveForum.com may not be responsible for the answers or solutions given to any question asked by the users. All Answers or responses are user generated answers and we do not have proof of its validity or correctness. Please vote for the answer that helped you in order to help others find out which is the most helpful answer. Questions labeled as solved may be solved or may not be solved depending on the type of question and the date posted for some posts may be scheduled to be deleted periodically. Do not hesitate to share your thoughts here to help others. #### Curious Function Composition godlification Asks: Curious Function Composition Find all functions$f$such that$f^5=2022n$. SolveForum.com may not be responsible for the answers or solutions given to any question asked by the users. All Answers or responses are user generated answers and we do not have proof of its validity or correctness. Please vote for the answer that helped you in order to help others find out which is the most helpful answer. Questions labeled as solved may be solved or may not be solved depending on the type of question and the date posted for some posts may be scheduled to be deleted periodically. Do not hesitate to share your thoughts here to help others. #### What is this separation property of locales called Jonas Frey Asks: What is this separation property of locales called Trying to come up with a point-free formulation of the$T_1$axiom I thought of the following condition on a frame/locale$L$: $$\forall U \in L \, . \, U \wedge \bigwedge \{ V \in L : U \vee V = \top \} = \bot$$ It turns out that this condition is weaker than$T_1$for spatial locales since it holds eg for$T_1$spaces with non-$T_1$sobrification like$\mathbb N$with the cofinite topology, but at least it seems to exclude non-trivial Alexandroff locales. Does anybody know what this condition is called? SolveForum.com may not be responsible for the answers or solutions given to any question asked by the users. All Answers or responses are user generated answers and we do not have proof of its validity or correctness. Please vote for the answer that helped you in order to help others find out which is the most helpful answer. Questions labeled as solved may be solved or may not be solved depending on the type of question and the date posted for some posts may be scheduled to be deleted periodically. Do not hesitate to share your thoughts here to help others. #### Does Ricci flat with$b_1=0$imply fundamental group is finite? How Asks: Does Ricci flat with$b_1=0$imply fundamental group is finite? Let$(M,g)$be a Riemannian manifold with Ricci curvature vanishes, that is$\mathrm{Ric}(g)=0$. Now I want to show some topological result about$M$. Myers' theorem implies if$\mathrm{Ric}(g)>0$, then$\pi_1(M)$is finite. It's clear that this is false for$\mathrm{Ric}(g)=0$, for example we can consider$n$-torus. But I wonder if we require$b_1(M)=0$, that is first Betti number of$M$vanishes, does we have$\pi_1(M)\$ is finite?

SolveForum.com may not be responsible for the answers or solutions given to any question asked by the users. All Answers or responses are user generated answers and we do not have proof of its validity or correctness. Please vote for the answer that helped you in order to help others find out which is the most helpful answer. Questions labeled as solved may be solved or may not be solved depending on the type of question and the date posted for some posts may be scheduled to be deleted periodically. Do not hesitate to share your thoughts here to help others.

#### In many tv shows, why do characters "turn g*y" rather than be bisexual?

• Crafter
• Social
• Replies: 0
Crafter Asks: In many tv shows, why do characters "turn g*y" rather than be bisexual?
In many tv shows, there is this one trope that, while cam vary, boils down to this:

A character who once thought they were straight, ends up having feelings for someone of the same gender and/or biological sex. From there, the character then realizes they are g*y. However, this person, with previous partners of the opposite gender, had truly meaningful relationships.

Of course, if you are guessing right, the described character above is bisexual. However, in many tv shows, it is portrayed as "turning g*y", despite the fact that they had legit feelings in their heterosexual relationships. My question is: Why do TV shows do this trope, resulting in bi-erasure, than just saying that said character is bisexual?

SolveForum.com may not be responsible for the answers or solutions given to any question asked by the users. All Answers or responses are user generated answers and we do not have proof of its validity or correctness. Please vote for the answer that helped you in order to help others find out which is the most helpful answer. Questions labeled as solved may be solved or may not be solved depending on the type of question and the date posted for some posts may be scheduled to be deleted periodically. Do not hesitate to share your thoughts here to help others.