Sustainable Aqueous Phase Separation membranes prepared through mild pH shift induced polyelectrolyte complexation of PSS and PEI

pH shift induced Aqueous phase separation (APS) is a novel and more sustainable water-based approach to create microfiltration, ultrafiltration, and nanofiltration membranes. APS allows for control over membrane pore size and structure in ways analogous to traditional non-solvent induced phase separation (NIPS). Unfortunately, existing APS approaches require extreme pH shifts (from pH 14 to pH 1) to obtain successful membranes, limiting their applicability for large scale production. Here we demonstrate that APS membranes, with tunable pore sizes ranging from ~80 nm to dense nanofiltration type, can be prepared using a mild pH shift (pH 12 to pH 4) based on the complexation of poly(styrene sulfonate) (PSS) and branched polyethyleneimine (PEI) in acetate buffer coagulation baths. The molecular weight of PEI, the concentration and the pH value of the buffer solution, and the concentration of glutaraldehyde cross-linking agent were systematically varied to control and optimize the membrane fabrication conditions. It was found that tight nanofiltration membranes having a molecular weight cut-off of ~200 g mol (cid:0) 1 and excellent salt (97% MgCl 2 ) and micropollutant retentions (~96%) could be prepared alongside ultra/microfiltration type membranes with an average pore size of ~60 nm. These results indicate that APS membranes with tunable pore sizes can be prepared under mild pH conditions with excellent control over separation properties.


Introduction
Non-solvent induced phase separation, commonly referred to as NIPS, is by far the most commonly employed technique to prepare polymeric membranes. It is a versatile technique that allows the production of various different types of membranes in a simple one-step process whereby a liquid polymer solution is transformed into a solid porous membrane via controlled precipitation [1]. The phase separation rate can be controlled to obtain different membrane morphologies. A slower precipitation rate typically leads to the formation of sponge-like structures with dense top layers that exhibit high salt retentions and low water fluxes. On the other hand, a faster precipitation rate typically results in asymmetric membranes having macrovoids and more porous top layers that show high water fluxes [2]. In addition, the polymer concentration of the casting/dope solution along with the coagulation bath conditions dictate the final structure of the membranes. A higher polymer concentration increases the solution's viscosity thereby slowing down the precipitation rate resulting in denser membranes [3]. The wide range of polymers available and numerous tuning parameters means that membranes for microfiltration, ultrafiltration, nanofiltration, reverse osmosis, and gas separation can be produced using NIPS [4]. Such proven control over the pore size and structure enabled NIPS to be the foremost and preferred technique for commercial polymeric membrane production.
A major downside of NIPS is that the most commonly used solvent in this technique, N-methylpyrrolidone (NMP), has been proven to be reprotoxic [5]. Consequently, NMP has been restricted for use in the European Union through the Regulation (EC) No. (EU) 2018/588 of the European Parliament and the Council on the Registration, Evaluation, Authorization, and Restriction of Chemicals (REACH) [6,7]. The search for greener solvents for membrane fabrication predates the EU restriction. In 2014 Figoli et al. reviewed several alternate solvents that have been used to produce NIPS and thermally induced phase separation (TIPS) membranes [8][9][10]. Some of these 'green' solvents include Cyrene™, ionic liquids, ethyl lactate, and super critical CO 2 . However, tuning the pore size of the membrane for desired application still remained a major challenge. A different approach was first introduced by de Vos that utilized water as a solvent to prepare Aqueous Phase Separation (APS) membranes using polyelectrolytes [11]. Polyelectrolytes are polymers that carry a charge on their repeating unit along with small counter-ions. As a result, the polyelectrolytes are readily soluble in water. De Vos demonstrated that a weak polyelectrolyte such as poly (4-vinylpyridine), which is soluble in water only at low pH conditions can be precipitated at high pH conditions to form porous films [11]. However these membranes exhibited limited mechanical stability and relatively poor control over the pore size [12]. Another interesting approach was polyelectrolyte complex (PEC) membranes, where a casting solution of a weak and strong polyelectrolyte was precipitated in coagulation baths at low pH conditions to obtain porous membranes [11]. A PEC is formed when two oppositely charged polyelectrolytes are mixed together whereby the driving force for complexation is provided by the entropy gain due to the release of the counter-ions [13,14]. Polyelectrolytes have long been used to prepare PEC membranes and free-standing capsules and their numerous applications have been reported in literature [15][16][17]. In our previous work, we have demonstrated the versatility of APS method by fabricating microfiltration, ultrafiltration, and nanofiltration PEC membranes [18]. In that version of APS, a homogeneous solution of a strong polyelectrolyte poly(sodium 4-styrenesulfonate) PSS, and a weak polyelectrolyte polyallylamine hydrochloride (PAH) was prepared at ~ pH 14 and precipitated in a ~pH 1 coagulation bath. Several parameters such as the molecular weight of the polyelectrolytes, solution concentration, pH of the bath, salinity of the bath, and the amount of cross-linker can be tuned to obtain desirable membrane pore sizes [18,19]. However, the extreme pH conditions required to prepare the PSS-PAH membranes are far from ideal for larger scale membrane production as they can for example lead to corrosion of the equipment. One attempt to resolve this problem is a salinity change induced APS, where the casting solution, composed of two polyelectrolytes dissolved at high salt concentrations, is precipitated in deionized water (or even tap water) to obtain PEC membranes [20][21][22]. Salinity change induced APS is indeed a promising alternate to the pH switch induced APS, however, in one version it gives limited control over the membrane pore size in addition to low water permeabilites [21,22], and in another version it is rather laborious [20]. A truly sustainable alternative to NIPS that has the similar control over the membrane pore size still remains a major challenge.
In this work, we will demonstrate that pH switch induced APS is possible at much milder pH conditions, while retaining excellent control over pore size and membrane structure. Here, the weak polycation polyethyleneimine (PEI) is used in its branched form in combination with the strong polyanion PSS. The combination of PSS and PEIhas already been successfully applied as polyelectrolyte multilayer coatings on polymeric support membranes for nanofiltration applications [23,24]. PSS-PEI multilayer coated membranes have shown excellent divalent ion retentions with a water permeability of ~5 L m − 2 ⋅h − 1 ⋅bar − 1 [24]. Herein, we demonstrate that PSS-PEI solutions can be mixed directly without any additives (i.e. no added base) to form a homogeneous casting solutions, which can subsequently be cast as thin films and precipitated in much less extreme pH (3.6-5) acetate buffer baths to obtain PEC membranes. The molecular weight of PEI, the concentration and pH value of the acetate buffer, as well as the concentration of the cross-linking agent were all varied in order to study their effect on membrane structure and morphology. These parameters were fine-tuned and allowed for control over the pore size of the membranes. The findings of this work offer insight into the PSS-PEI system as one of the most promising APS approaches for the production of a wide variety of sustainable membranes.

Preparation of casting solutions
Two sets of casting solutions were prepared in this work based on the molecular weights (M w ) of PEI (25 and 750 kDa). The casting solutions were prepared using the following scheme. First, PEI was diluted using deionized water to obtain 25 wt% aqueous solution. Afterwards, PSS (25 wt%) and PEI (25 wt%) were mixed together in a PSS:PEI monomer molar mixing ratio of 1:2 to obtain a 25 wt% casting solution. The molar ratio was calculated based on the molecular weights of the monomers; PSS = 206.21 g mol − 1 and PEI = 43.04 g mol − 1 (per ethylenimine unit). The resultant casting solutions were continuously stirred until they became homogeneous. The PSS-PEI casting solutions were also prepared in other ratios of PSS to PEI such as 4:1, 2:1, 1:1, 1:3, and 1:4. The casting solutions having the monomer mixing ratios of 4:1 and 2:1 did not result in a precipitate rather formed a soft gel-like material. In comparison, the ratios 1:1, 1:3, and 1:4 formed a precipitate however, did not result in membranes with adequate mechanical strength. The final compositions of the two different sets of casting solutions used in this work are shown in Table 1.
The casting solutions prepared using 1000 kDa PSS and 25 kDa PEI are referred to as PSS-PEI (25 kDa) and similarly, the solutions prepared using 1000 kDa PSS and 750 kDa PEI will be referred to as PSS-PEI (750 kDa). The number inside the parenthesis represents the molecular weight of PEI (kDa) used to prepare the casting solutions.
The viscosity of all the casting solutions was measured on a HAAKE™ Viscotester™ 550 Rotational Viscometer (ThermoFisher Scientific, USA). Approximately 20 mL casting solution was poured into the SV-DIN spindle cylinder assembly and mounted on the Viscotester. The dynamic viscosity was obtained at 20 • C as a function of increasing shear rate (24.9 s − 1 to 1000 s − 1 ). The dynamic viscosity is reported at 24.9 s − 1 shear rate. Two samples were tested for each composition of casting solution and the average value with standard deviation is reported.

Membrane casting
The PSS-PEI (25 kDa) solutions were first cast on a glass plate as thin film using a casting bar with a gap height of 0.5 mm. The glass plate was immediately immersed in a coagulation bath at pH 1, adjusted using HCl, with the addition of 0.01 wt% glutaraldehyde (GA). The amount of the GA cross-linker in wt% was calculated based on the total weight of the coagulation bath.
In addition, the PSS-PEI (25 kDa) solutions were also cast as 0.5 mm thin films in different concentrations of acetic acidsodium acetate buffer baths at pH 4, i.e. 0.1 M − 0.5 M. Furthermore the effect of the pH of 0.5 M acetate buffer bath on the membrane structure was studied by varying the pH from 3.6 to pH 5. This was achieved by varying the amounts of acetic acid and sodium acetate that was added to the bath. Following the same protocol, PSS-PEI (750 kDa) solutions were cast on glass plates as 0.5 mm thin films and immediately immersed in 0.5 M acetate baths at different values of pH (3.6-5).
Similarly, 0.5 M acetate buffer baths were prepared at different values of pH, i.e. pH 3.6 to pH 5, but this time, with the addition of 0.01 wt% GA. PSS-PEI (25 kDa) and PSS-PEI (750 kDa) solutions were then cast and immersed in these baths to obtain cross-linked membranes. The precipitated membranes were removed from the glutaraldehydecontaining coagulation bath after 24 h and stored in deionized water for further processing.

Membrane characterization
The structure and morphology of the membranes was examined using a scanning electron microscope, SEM (JSM-6010LA, JEOL, Japan) and Field Emission SEM (JSM-7610F, JEOL, Japan). The membrane samples for SEM imaging were first immersed in 20 wt% glycerol solution for 4 h followed by drying under constant air flow inside the fume hood. This was done to prevent the pore structure of the membranes from collapsing upon drying. For cross-section imaging, the glyceroldried membrane samples were immersed in liquid nitrogen for 10s and then carefully fractured to expose the cross-section. All the samples were then stored in a vacuum oven at 30 • C for 24 h before sputter coating them with a 5 nm thin layer of Pt/Pd alloy using Quorum Q150T ES (Quorum Technologies, Ltd., UK) sputter coater. The pores on the top surface SEM images of the membranes were measured manually using ImageJ software to determine the average pore size of the membranes.
The streaming potential of nanofiltration membranes was determined at pH 6 using SurPASS electrokinetic analyzer (Anton Paar, Graz, Austria) by measuring the streaming current versus pressure in a 5 mM KCl solution using equation (1).
The pure water permeability (PWP) of the membranes was determined on dead-end Amicon® cells. The membranes were first cut into a circular disk having a diameter of 25 mm followed by mounting them on the dead-end cell. The effective surface area of the membranes was approximately 3.8 cm 2 . Nitrogen gas was used to pressurize the vessel containing the feed water. The permeability tests were conducted at an applied water pressure of 4 bar. The permeate mass was automatically measured as a function of time using a weighing balance connected to a computer. The PWP was calculated using equation (2).
Where P is the pure water permeability in L⋅m − 2 ⋅h − 1 ⋅bar − 1 , J W is the water flux obtained from the change of permeate volume (L) per unit membrane area (3.8 cm 2 ) per unit time (h) and Δp is the pressure difference between feed and permeate side (bar). An oil in water emulsion was prepared to analyze the microfiltration performance of the membranes. For this purpose, n-hexadecane (100 mg L − 1 ) in sodium dodecyl sulfate (463 mg L − 1 ) with Oil red EGN (20 mg L − 1 ) emulsion was prepared using the protocol described by Dickhout et al. [25]. The average diameter of the oil droplet was 3-4 μm.
Oil red EGN is an oil-soluble dye that is used as a marker for oil droplets. The oil droplet retention tests were conducted at 0.4 bar of applied pressure on a dead-end cell under continuous stirring. The feed, permeate, and retentate were analyzed on a UV-vis spectrophotometer (Shimadzu UV-1800, Japan) at λ max = 521 nm which is the maximum absorbance wavelength of Oil red EGN. A calibration curve was first obtained with known concentrations of n-hexadecane in SDS emulsion. The retention R (%) was then calculated using equation (3). Three samples of each membranes were tested for their oil droplet retention and the average value is reported.
Where C p is the concentration in the permeate, C f is the concentration in the feed, and C r is the concentration in the retentate. Here, the average of C f and C r is taken because the retention experiments were conducted in a dead-end cell configuration where the concentration of feed is constantly changing above the membrane surface. Molecular weight cut-off (MWCO) of the nanofiltration type membranes was determined using an aqueous solution containing different Mw of PEGs. The solution was prepared by dissolving 200, 400, 600, 1500, and 2000 g⋅mol − 1 PEG, each with a concentration of 1 g L − 1 , in deionized water. The solution was then filtered through the membranes in a dead-end cell. The feed, permeate, and retentate were analyzed using Gel Permeation Chromatography (GPC, Agilent 1200/1260 Infinity GPC/SEC series, Polymer Standards Service data center and column compartment) using Milli-Q water eluent containing 50 mg L − 1 NaN 3 , at 1 mL min − 1 , through 1000 Å, 10 μm Polymer Standards Service Suprema 8 × 300 mm column and 30 Å, 10 μm column connected in series. The concentration of different PEGs was determined in the feed, retentate, and permeate samples via refractive index. The retention was then calculated using equation (3). A sieving curve of Retention (%) vs molecular weight (g⋅mol − 1 ) was obtained and the molecular weight cutoff was estimated.
The nanofiltration performance of the membranes was also analyzed by conducting the salt retention tests in a dead-end cell configuration. A 5 mM solution of MgCl 2 , NaCl, MgSO 4 , or Na 2 SO 4 was prepared and used as the feed. The salt solution was filtered through the membranes followed by testing the conductivity of the permeate and retentate streams using a handheld WTW™ Cond 3210™ conductivity meter (Xylem Analytics, Germany). A calibration curve was first made by measuring the conductivity of salt solutions with known concentrations. The retention was then calculated using the same equation (3).
A mixture containing eight different types of common micropollutants (M w ranging from 216 to 624 g mol − 1 ) was prepared by adding 3 mg L − 1 of each micropollutant in deionized water and adjusting the pH to 5.8 using 0.1 M NaOH. These micropollutants are commonly found in river waters and constitute of herbicides, endocrine disrupting chemicals, and pH indicators. The mixture solution was filtered through the membranes for at least 24 h to achieve steady state permeation and to eliminate the effects of adsorption. The permeate, retentate, and feed samples were collected once the steady state was achieved and analyzed using UltiMate 3000 UHPLC (ThermoFisher Scientific, USA). The separation was carried out using a 2.2 μm ACCLAIM RSLC C18 column (ThermoFisher Scientific, USA). A calibration curve was first created with known concentrations of the micropollutants in the cocktail mixture. The concentrations of the micropollutants in feed, permeate, and retentate were calculated based on the calibration curve. The retention was then estimated using equation (3).

Results and discussion
Here the formation of PSS-PEI based membranes through pH switch induced APS will be discussed in 5 distinct sections. Initially we focus on the conditions in the coagulation bath; varying the buffer concentration, pH and crosslinker content. Subsequently we study the effect of PEI M w in the casting solution. Finally we discuss the differences and similarities between the PSS/PEI systems studied here and the earlier studied PAH/ PSS membranes.

Effect of acetate buffer concentration
The PSS-PEI casting solution was prepared by mixing PSS (25%) and PEI (25%) solutions is a 1:2 ratio of PSS to PAH monomers. From previous work it is know that when combining a weak and a strong PE in APS approaches, and excess of the weak PE leads to the best results [18,26]. Initial investigations indicated the 1:2 ratio as optimal for PSS-PEI. The formed solution was completely clear and was found to have a pH of 12. Indeed at such a pH, PEI is expected to be uncharged as the pH is well above the pKa of the primary and secondary amines and just above the pKa of the tertiary amines that make up PEI, preventing complexation.
In previous work a coagulation bath of pH 1 was found be optimal for the formation of PSS-PAH membranes. Such a low pH in the coagulation bath was required to have sufficient driving force for a quick solvent (high pH) to non-solvent (low pH) exchange, to allow membrane formation. In this work we use an alternative aqueous non-solvent, a pH 4 acetate buffer. The buffer capacity of the acetate will still allow a high driving force for exchange, while an extreme pH is not required.
The PSS-PEI (25 kDa) solution was cast on glass plates using a casting bar of 0.5 mm gap height. Afterwards, the glass plates were immediately immersed in different concentrations of pH 4 acetate buffer, i.e. 0.1-0.5 M, to find an optimum concentration of buffer for the membrane fabrication. At pH 4, PEI is fully charged and consequently forms a polyelectrolyte complex (PEC) with PSS. The PEC is insoluble in water and precipitates as a white solid film. Fig. S1 shows the real time photos of the precipitation/phase separation process of these films in different concentrations of pH 4 acetate buffer bath. These snapshots distinctly show that the onset of phase separation is significantly different at different concentrations of the acetate buffer. At a concentration of 0.1 M, no phase separation is observed until 1 s after the immersion, see Fig. S1. On the other hand, the membrane prepared in 0.5 M acetate buffer bath immediately turned opaque/white indicating an instantaneous phase inversion. In addition to the onset of precipitation/phase separation, another important process is the precipitation rate which is essentially the time it takes for the film to become fully opaque once the phase separation has started. Therefore it is important to make a clear distinction between these two processes. It can be seen from Fig. S1 that both the onset of phase separation, and the precipitation rate is slower at the buffer concentration of 0.1 M. On the other hand, at the concentration of 0.5 M, the onset of phase separation is instantaneous and the precipitation rate is significantly faster than at 0.1 M. In conclusion, increasing the acetate buffer concentration results in immediate phase separation with a faster rate of precipitation. At higher concentrations the greater buffer capacity of the acetate buffer allows faster pH changes in the casted film leading to faster onset of precipitation and a faster precipitation rate as will also be discussed below. Fig. 1 shows the SEM images of the membranes prepared in different concentrations of acetate buffer. The membranes prepared at low concentrations, i.e. 0.1-0.3 M, were brittle, had cracks on the surface, and therefore, could not be used for any further tests. On the other hand, mechanically stable membranes were obtained when the acetate buffer concentration was 0.4 M or 0.5 M. Here, by suitable mechanical stability, we mean that the membranes could be cut into circular disks without them cracking and could be subjected to at least 4 bar of applied pressure during PWP measurements. The effect of different precipitation rates on the membrane structure are even more obvious when looking at the cross-section SEM images shown in Fig. 1a-e. Finger-like macrovoids appear only when the concentration of the acetate buffer exceeds 0.3 M. As explained earlier, the rate of precipitation increases with the increase in buffer concentration. This is in line with the traditional NIPS, where the finger-like macrovoids are formed as a result of a higher precipitation rates [2]. The same result was also observed in this version of APS, where higher precipitation rates led to asymmetric membranes with macrovoids. These results reveal that the concentration of the acetate buffer is an important parameter to control the structure of the membranes and their mechanical stability.
The top surface SEM images shown in Fig. 1a-e reveal that the membranes with relatively dense top layers are obtained when increasing the acetate buffer concentration. At 0.1 M-0.3 M acetate buffer concentration, the top surfaces have defects and small cracks (Fig. 1a-c). Increasing the acetate buffer concentration to 0.4 M and then further to 0.5 M resulted in densification of the top surface of the membranes. This is because at higher concentrations, the acetate buffer has a greater buffering capacity which readily acts to reduce the pH of the PSS-PEI cast film. At high buffer concentrations, the weak polycation PEI can acquire charge more readily which leads to a rapid formation of a white, solid, water-insoluble PSS-PEI polyelectrolyte complex. It can be seen from the photographs of the membranes shown in Fig. 1 that mechanically stable membranes were only obtained when the concentrations of the acetate buffer bath were 0.4 M and 0.5 M. Further increasing the acetate buffer concentration to 1 M resulted in even denser membranes that had a pure water permeability of 0.36 ± 0.01 L  Fig. S2. However in addition to a low water permeability, such a high concentration of buffer is not ideal for the large scale production of these membranes. Therefore, the concentration of the buffer bath was fixed at 0.5 M for all further experiments since this concentration resulted in dense and the most mechanically stable membranes. The membranes prepared in 0.4 M and 0.5 M buffer baths were tested for their PWP at 4 bar of applied pressure. The membranes prepared in 0.4 M acetate bath at pH 4 had a water permeability of ~32 ± 6 L m − 2 ⋅h − 1 ⋅bar − 1 while the ones prepared in 0.5 M bath had a permeability of ~4 ± 0.5 L m − 2 ⋅h − 1 ⋅bar − 1 . These initial results are very promising as they demonstrate that for the PSS-PEI system it is indeed possible to obtain membranes using just a mild pH switch (pH 12 to pH 4) by making use of a buffer based coagulation bath.

Effect of buffer pH in the bath
To further understand the influence of coagulation bath conditions on membrane structure, the PSS-PEI (25 kDa) solution was cast in 0.5 M acetate buffer coagulation baths at different pH values i.e. 3.6, 4, 4.5, and 5. The real time photographs of the precipitation are shown in Fig. S3. Here, the onset of phase separation was instantaneous irrespective of the pH of the bath while the rate of precipitation varied as the pH of the bath was decreased. At a bath pH of 3.6 and 4, the films immediately (<1 s) turned completely opaque/white indicating the formation of solid, porous films. In comparison, at pH 5, the films were relatively transparent after 1 s of immersion indicating a relatively slower precipitation rate. In addition, the rate of precipitation decreased with the increasing pH. Such precipitation behavior is intuitive because this version of APS relies on a change in pH to drive the precipitation, and the pH of the coagulation bath can be thought of as a driving force for polyelectrolyte complexation [18,19,26], as it can determine the degree of protonation (charge) of the weak polycation PEI. The branched PEI used in this work consists of 31% primary, 39% secondary, and 30% tertiary amines all of which have different pK a values, i.e. 4.5, 6.7, and 11.6, respectively [27,28]. Therefore, at pH values less than the pK a of primary amines (i.e. at pH < 4.5), PEI can exist in its fully protonated state resulting in stronger electrostatic interactions with PSS i.e. a higher density of ionic cross-links. As a result, the membranes prepared in pH 3.6 and pH 4 buffer precipitated faster and were mechanically stronger (see Fig. S4 for the photographs of the membranes). At pH 4.5 and 5, it is likely that not all the amine residues within PEI are protonated (charged) and therefore, the resulting polyelectrolyte complex has a lower density of ion pairing than at pH 3.6 and 4 and thus the films are mechanically weaker. Fig. 2 shows the top surface and cross-section SEM images of the membranes prepared at different buffer pH values. All the membranes exhibit the typical asymmetric morphology with denser top layers followed by porous sub-structures with finger-like macrovoids. At pH 3.6, the top surface of the resultant membranes had inhomogeneous structure and defects with a cross-section having typical finger-like macrovoids as shown in Fig. 2a. The inhomogeneity on the membrane top surface is most likely due to the relatively rapid rate of precipitation at pH 3.6 (compared to higher pH values), which does not give adequate time for the polyelectrolyte chains to rearrange, also resulting in relatively brittle membranes. At pH 4, the resultant membranes had smooth and dense top layers with relatively dense finger-like macrovoids in the support structure, see Fig. 2b. Increasing the pH of the acetate buffer bath to pH 4.5 and 5 resulted in membranes with porous top surfaces as can be seen in Fig. 2c and d. One possible reason for these porous top surfaces could be the lower degree of ionic cross-links caused by relatively lower degree of PEI protonation at pH 4.5 and pH 5. The membranes prepared in pH 4.5 and 5 baths were too brittle to be used for any applications, see the photographs in Fig. S4.
The PWP of the membranes prepared in pH 3.6 and pH 4 buffer baths was measured, with the former having a permeability of ~280 ± 30 L m − 2 ⋅h − 1 ⋅bar − 1 while the latter a permeability of ~4 ± 0.5 L m − 2 ⋅h − 1 ⋅bar − 1 . These values are in accordance with the top surface morphology of these membranes shown in Fig. 2a and b with the membranes prepared at pH 3.6 having a more porous and uneven top layer compared to the membranes prepared at pH 4. In addition, the membranes prepared at pH 3.6 were relatively brittle which may have resulted in the development of micro-cracks on the membrane surface while operating under elevated pressures, thereby increasing the pure water permeability. A denser structure obtained at pH 4 provides a greater resistance for water permeation.
The PSS-PEI (25 kDa) membranes prepared in pH 4 buffer bath were evaluated for their molecular weight cut-off (MWCO) which is one of the key parameters that determines the potential applicability of the membrane. The MWCO of these membranes as determined by the sieving curve shown in Fig. S5a, was 260 ± 60 g mol − 1 , which is in the range of typical nanofiltration type membranes (200-1000 g mol − 1 ) [29]. Fig. 3a shows the retention of four different types of salts by the membrane prepared in pH 4 bath. These salts were chosen because they consist of both monovalent and divalent anions and cations and thus providing insight into the charge and separation mechanism(s) of the membranes. Due to the excess of PEI in the membranes, it is expected that the membranes will be overall positively charged. This was confirmed by measuring the streaming potential of the membrane surface which was approximately +10 mV at pH 6. According to the Donnan exclusion mechanism, a membrane with fixed positively charged groups will repel cations and attract anions [30]. From Fig. 3a it is clear that the retention of salts containing divalent cations such as MgCl 2 and MgSO 4 is higher, 81% and 44% respectively, as compared to the retention of monovalent cations NaCl (27% retention) and Na 2 SO 4 (32%), revealing that the separation is largely based on charges. However, if Donnan exclusion was the only mechanism, Na 2 SO 4 should have been rejected less than NaCl, due to the attractive interactions between the membrane and the divalent anion SO 4 2− . Size exclusion, steric hindrance and dielectric effects are also known to determine the salt retentions of typical nanofiltration membranes [31].
In order to further evaluate the size exclusion and steric effects occurring during separation, a mixture of eight different types of micropollutants was filtered through the PSS-PEI (25 kDa) pH 4 membranes and the retentions are summarized in Fig. 3b. The positively charged Atenolol, with a M w of 266 g mol − 1 , was only retained 41% suggesting again that the retention of charged molecules is not only governed by Donnan exclusion but also by size exclusion and solutiondiffusion mechanism. This can be seen by looking at the retentions of negatively charged molecules such as Sulfamethoxazole (M w 256 g mol − 1 , 45% retention), Naproxen (M w 230 g mol − 1 , 87% retention), and Bezafibrate (M w 362 g mol − 1 , 64% retention). Here, Naproxen is retained more than Sulfamethoxazole even though the former has a lower molecular weight. This can be explained according to the solutiondiffusion mechanism which also takes into account the affinity of the micropollutant(s) for the membrane(s). In this case the affinity is related to the hydrophilicity/hydrophobicity of the micropollutant molecules. The octanol− water partition coefficient (log K OW ) is one measure of the hydrophilicity of a compound [32]. Sulfamethoxazole is hydrophilic with a log K OW of ~0.89 while Naproxen is a hydrophobic compound with log K OW ~3.18. Consequently, Sulfamethoxazole readily diffuses through the hydrophilic PEC membrane because of its higher affinity for the membrane and therefore, always shows lower retention than Naproxen.
The retention trend of the neutral molecules like Atrazine, Bisphenol A, Phenolphthalein, and Bromothymol Blue follow the size exclusion mechanism in accordance with the MWCO (260 g mol − 1 ) of the membrane such that Atrazine (216 g mol − 1 ) is retained only 53% while Bromothymol Blue (624 g mol − 1 ) is completely retained by the membrane. This high retention of Bromothymol Blue is important, as it also demonstrates the membrane to be completely defect free.

Effect of crosslinker
From earlier studies we know that glutaraldehyde (GA) crosslinking densifies the structure of the polyelectrolyte complex APS membranes [18] and improves the solute rejections in polyelectrolyte multilayer membranes [33,34]. This is because the GA readily reacts with amine groups under aqueous conditions to form imine bonds (-C--N-) via Schiff base reaction [35]. In case of PEI, the imine bonds are formed by the reaction of GA with the primary amines [36]. Therefore, GA was added as a crosslinking agent in the 0.5 M acetate buffer coagulation bath in order to further densify the membrane structure and improve overall mechanical strength. The PSS-PEI (25 kDa) solutions were cast and immersed in acetate buffer baths at different pH values (pH 3.6-5) with the addition of 0.01 wt% GA. The wt% concentration of GA is with respect to the total weight of the coagulation bath (i.e. 0.1 g GA per 1000 g of coagulation bath). GA concentration was kept as low as possible because it is a toxic chemical at higher concentrations [37], and a concentration of 0.01 wt% falls well below the standard lab safety conditions. Upon immersion of the cast films into the baths, the precipitation and the cross-linking reaction between the primary amine groups of PEI occur simultaneously [18]. It is difficult to determine the exact degree of crosslinking, but since the PSS:PEI monomer mixing ratio in the casting solution was 1:2, there is an excess of PEI that can readily react with GA to form the imine cross-links. As of the amines in PEI only the primary ones can react, and as there is a limited GA available in the coagulation bath, we know that the maximum degree of crosslinking (assuming full conversion) cannot exceed 23% of the PEI amines.
The onset of phase separation and the precipitation rates of these membranes were identical to the ones prepared without the addition of GA, i.e. similar to Fig. S3. Increasing the pH of the coagulation bath resulted in slower rates of precipitation and hence, less stable membranes as discussed in section 3.2, where the driving force for complexation as well as the protonation (charge) of PEI decreases with higher pH. As a result, the membranes prepared in pH 4.5 and 5 buffer baths were too brittle to be used for further processing. Fig. 4 shows the SEM images of the membranes prepared in acetate buffer baths with the addition of 0.01 wt% GA. All the membranes are asymmetric with relatively dense top layers and more open crosssections. At pH 3.6, the resultant membranes had a relatively porous top layer with typical finger-link macrovoids in the cross-section, Fig. 4a. The pore size of pH 3.6 membrane, estimated by ImageJ analysis of ×10,000 magnification SEM images, was approximately 200 ± 80 nm, Fig S6. It is important to mention that the pore size estimation via SEM images is not an accurate way to determine the pore size of the membranes rather it gives a reasonable estimation to compare different membranes. The top surface SEM image of pH 3.6 membrane prepared with 0.01 wt% GA shows that membrane surface is slightly denser compared to the membranes prepared at the same pH but without the addition of GA (compare Figs. 2a and 4a). Increasing the bath pH to 4 results in a much denser top layer and more compact cross-section, Fig. 4b. These SEM images are not that different to the image shown in Fig. 2b where the membranes were prepared without the GA. However, the GA crosslinking has indeed densified the membrane structure as will be seen by the permeability and retention tests. The FE-SEM images at even higher magnification (x50,000) shown in Fig. S7 reveal the defects on the pH 3.6 membrane and show that the pH 4 membrane is significantly denser as no defects or pores could be seen even at such magnifications. At pH 4.5 and 5, the membranes again show a typical asymmetric structure with cracks on the top surface but these membranes were unusable due to their brittle nature.
The mechanically stable membranes obtained in pH 3.6 and pH 4 acetate buffer baths were tested for their PWP. Since the top surface of the pH 3.6 membrane was relatively porous, it is not surprising that the PWP was approximately 32 ± 3 L m − 2 ⋅h − 1 ⋅bar − 1 . In comparison, the denser membrane obtained at pH 4 had a permeability of 1.7 ± 0.2 L m − 2 ⋅h − 1 ⋅bar − 1 . The MWCO of this membrane is 200 ± 2 g mol − 1 , see Fig. S5b.
To evaluate the nanofiltration performance of the membrane prepared in pH 4 acetate buffer with 0.01 wt% GA, the same range of monoand divalent salts as earlier were filtered through the membrane with the results shown in Fig. 5a. As expected for a positively charged membrane, MgCl 2 retention was the highest at ~97% followed by ~94% for MgSO 4 . In comparison, NaCl and Na 2 SO 4 retentions were ~66% and ~70%, respectively. These retention results confirm that this nanofiltration membrane functions by a combination of Donnan exclusion and size exclusion mechanisms. Fig. 5b shows the retention of the eight different micropollutants by the same membrane. This membrane showed excellent retention of all types of micropollutants tested; average micropollutant retention of ~96%. The positively charged Atenolol was 97% retained. The neutral molecules like Atrazine (M W ~216 g mol − 1 ), Bisphenol A (M W ~228 g mol − 1 ), Phenolphthalein (M W ~318 g mol − 1 ), and Bromothymol Blue (M W ~624 g mol − 1 ) showed a retention of 93%, 94%, 99%, and 100% respectively. These retentions are in accordance with the 200 g mol − 1 MWCO measured for this membrane. These results indicate that the PSS-PEI (25 kDa) membranes prepared in pH 4 acetate buffer with 0.01 wt% GA are excellent nanofiltration type membranes. Furthermore, the membrane exhibited stable performance over 5 days of continuous operation, see Fig. S8. Crosslinking with GA is thus clearly an excellent approach to further control the separation properties of the prepared PSS-PEI based membranes. The pH stability test of the membranes was conducted by keeping them in pH 1, pH 8, pH 10, and pH 12 aqueous solutions for 10 days and then removing and washing them with deionized water. The pure water permeability of the treated membranes was re-measured and compared with the untreated membranes. It was found that the membranes treated in pH 1 up to pH 8 showed the same water permeability as the untreated versions. However, the pH 10 and pH 12 treated membranes became unstable in the high pH solutions, see Fig. S9. At such a high pH, PEI becomes uncharged resulting in the possible de-complexation of the polyelectrolyte complex. Higher degrees of crosslinking would likely lead to increased stability at higher pH.

Effect of PEI molecular weight
The M w of PEI in the casting solution was increased to 750 kDa while keeping the M w of PSS constant at 1000 kDa. The PSS-PEI (750 kDa) solutions were then also cast on glass plates as 0.5 mm thin films and immersed in coagulation baths at different values of pH. The onset of precipitation was instantaneous in all the different pH baths, however, the rate of precipitation was slower at pH 4.5 compared to pH 4 and even slower at pH 5. The effect of bath pH on the rate of precipitation was  similar for PSS-PEI (25 kDa) and PSS-PEI (750 kDa) membranes, where higher pH (i.e. closer to pH of casting solution, thus a lower driving force for precipitation) slows down the rate of precipitation. The photographs of the resultant membranes are shown in Fig. S10. The membranes prepared in pH 4.5 bath showed an inhomogeneous structure while those prepared in pH 5 were too brittle to be used for any further processing. The reason for inhomogeneous surface is unclear. On possible reason could be that the larger molecular weight of PEI causes the chains to rearrange during the precipitation process due to the relatively slower rate of precipitation. As a result, the membrane surface has regions with different densities as can be seen in the photograph in Fig. S10. Similarly, at pH 5 the rate of precipitation is even more slower as compared to pH 4.5, causing the membrane to lose its structural integrity as it becomes brittle. The top surface and cross-section SEM images of the resultant membranes are shown in Fig. 6.
Top surface SEM images of the membranes prepared in pH 3.6 coagulation revealed small pores and defects in the top layer (Fig. 6a). Increasing the pH of the acetate buffer bath gives membranes with relatively larger pores as seen in Fig. 6b. Moreover, the number of pores also increases at pH 4. The pore sizes of these membranes was estimated from the SEM images and the average pore size of the pH 3.6 and pH 4 bath membranes was approximately 60 ± 45 nm and 80 ± 60 nm, respectively, see Fig. S11. Fig. 6c shows the top surface image of the membrane prepared in pH 4.5 bath. This membrane also had defects and small pores on the surface. Increasing the bath pH to 5 resulted in films with larger surface pores ranging from 50 nm to 650 nm, but as mentioned earlier this film was too brittle to be used any further. The cross-section images shown in Fig. 6 indicate very little difference in the morphology of the membranes prepared in pH 3.6-4.5; the membranes are asymmetric with finger-like macrovoids. In comparison, at pH 5 the membranes have a relatively open structure. The full cross-section morphology of the membranes prepared in different pH baths is shown in Fig S12.  Fig. 7 shows the pure water permeability and n-hexadecane oil droplet retention of the PSS-PEI (750 kDa) membranes prepared in acetate buffer baths at different values of pH. The PWP of the membranes prepared in pH 3.6 baths was ~65 ± 6 L m − 2 ⋅h − 1 ⋅bar − 1 with 100% retention of the oil droplets. Similarly, the membranes prepared in pH 4 buffer bath had a permeability of ~130 ± 25 L m − 2 ⋅h − 1 ⋅bar − 1 with 100% retention of oil droplets. Similar to the protocol followed for PSS-PEI (25 kDa), 0.01 wt% GA was added to the coagulation bath to investigate the effect on membrane structure and performance. Addition of the cross-linker in such amounts slightly reduced the pore sizes of the membranes as can be seen from the top surface SEM images shown in Fig S13. The average pore size of the pH 4 membranes was approximately ~60 nm, measured from SEM image using ImageJ software. Comparing the top surface images shown in Fig. 6a-d to the images shown in Fig. S13a-d, one can observe the reduction in porosity and slight densification of the membranes upon addition of GA. However, for microfiltration applications, it is desirable to have a more open and porous structure with high water permeability. Therefore, PSS-PEI (750 kDa) membranes prepared in baths with the addition of GA are not ideally suited for microfiltration applications.
It is known that polyelectrolyte molecular weight is a major control parameter for the pore size and morphology of the APS polyelectrolyte complexation membranes [18,21]. Paring two relatively low M w polyelectrolytes (PSS ~200 kDa and PAH ~17.5 kDa), yielded microfiltration type membranes with average pore sizes in the range of 80-230 nm. On the other hand, ultrafiltration (pore size ~4.5 nm) and relatively dense nanofiltration type membranes were obtained with higher molecular weight pairings (PSS ~1000 kDa and PAH ~150 kDa) [18]. There are several causes for this molecular weight dependent behavior. One is the viscosity of the casting solutions, which is directly dependent on the M w of the polyelectrolytes used. The effect of casting/dope solution viscosity is well-known from traditional NIPS where a lower solution viscosity typically results in relatively porous membranes with macrovoids due to a fast precipitation rate [38]. Similarly, a polymer solution with higher viscosity gives denser membranes with lower overall porosity. The M w of the polyelectrolytes used can also significantly affect the structure of the resultant polyelectrolyte complex [39,40].  However, for the PSS-PEI membranes prepared in this work, the effect of polyelectrolyte molecular weight is different to previous versions of APS and also to NIPS membranes. Here, we keep the M w of PSS fixed at 1000 kDa, and study two distinct branched PEI M w 's of ~25 kDa and ~750 kDa. The dynamic viscosity of both these casting solutions at 24.9 s − 1 shear rate is shown in Table 2.
The dynamic viscosity of a 25 wt% PSS-PEI (25 kDa) solution was ~1 Pa s, while for the same concentration of 25 wt% overall polymer, the viscosity of PSS-PEI (750 kDa) was ~2.1 Pa s. In both the cases, the resultant membranes prepared in pH 4 acetate buffer bath showed asymmetric structures with finger-like macrovoids, see Figs. 2b and 6b. This is because the onset of phase separation for both the films with different M w of PEI was almost instantaneous (<1s), see Fig S14. As mentioned above, these findings contradict the results of traditional NIPS as well as the PSS-PAH based APS membranes, where higher solution viscosities give denser membranes without macrovoids. The unexpected effect of polyelectrolyte M w for PSS-PEI membranes is likely due to the branched nature of PEI. The commercially available PEI having the M w ~25 kDa and ~750 kDa was characterized by von Harpe et al. [27] where they measured the relative ratio of secondary to tertiary amines which is essentially the ratio of linear to branched structures in one molecule. Their results indicated that for PEI having a M w of ~25 kDa, the ratio of secondary to tertiary amines was 1.3 while for PEI with M w ~750 kDa it was 1.13 [27], which means that the latter has more degree of branching. Therefore, we hypothesize that low M w chains of branched PEI (~25 kDa) are able to pack more closely together upon complexation with PSS. In comparison, higher M w chains of PEI (750 kDa), where branching plays a more significant role, form less compact (more open) structures upon complexation with PSS.
This section thus makes clear that by a simple change of PEI M w , we can transition from the dense membranes produced earlier to very relevant porous membranes.

Comparison with other APS membranes
The PSS-PEI membranes have numerous advantages over other PEC based APS membranes. For instance, as reported in our previous work on PSS-PAH membranes [18], the pH of the PAH solution has to be increased to ~ pH 14 i.e. beyond its pK a value of 9 by the addition of NaOH to obtain a homogeneous casting solution. As a consequence, extremely low pH values, such as a pH 1 coagulation bath, are required to neutralize the added NaOH for obtaining stable PSS-PAH membranes. On the other hand, the PSS-PEI solutions have an advantage that a clear casting solution can already be obtained at pH 12 without adding caustic NaOH. Consequently, extreme pH coagulation baths are not essential to precipitate PSS-PEI. As shown in this work, microfiltration and nanofiltration type PSS-PEI membranes with excellent performance can simply be obtained at benign conditions of pH 4, by making use of a buffer solution. This makes the PSS-PEI based APS approach to be a more sustainable and environmentally friendly version. Another advantage of the PSS-PEI is the lower dynamic viscosity of the casting solution used to obtain nanofiltration type membranes i.e. ~1 Pa s of PSS-PEI (25 kDa) as compared to ~48 Pa s of the PSS-PAH solution [18], even at higher polymer concentrations. This makes the former convenient to use for the production of flat sheet membranes. In addition, the nanofiltration type membranes obtained with PSS-PAH only showed an average of ~80% retention of the micropollutants and did not show any significant retentions of the four types of salts, indicating that the obtained membranes were not as dense as commercial nanofiltration type membranes [18]. On the other hand, the PSS-PEI (25 kDa) membranes prepared in 0.5 M acetate buffer bath at pH 4 showed an average of ~96% retention of organic micropollutants in addition to the excellent salt retentions in excess of 94% for MgCl 2 and MgSO 4 .
In contrast, the nanofiltration membranes prepared using the salinity change induced APS approach show relatively lower water permeabilities of ~0.1-1 L m − 2 ⋅h − 1 ⋅bar − 1 [21,22] when compared to the pH shift induced PSS-PAH and PSS-PEI membranes. Similarly, the nanofiltration type APS membranes prepared using the pH responsive polyelectrolytes, such as polystyrene-alt-maleic acid, show a lower pure water permeability of ~0.3-0.5 L m − 2 ⋅h − 1 ⋅bar − 1 [41,42]. Fig. 8 shows a comparison in terms of MWCO and MgSO 4 retention of different polyelectrolyte based APS membranes reported in literature so far. A membrane with a higher pure water permeability and salt retention combined with a lower molecular weight cut-off is ideal for nanofiltration applications. The graph shown in Fig. 8 clearly indicates that the PSS-PEI membranes reported in this work have higher pure water permeability with equivalent MWCO and MgSO 4 retention as compared to the other APS membranes.
Indeed the membranes obtained using PSS and PEI indeed prove the versatility of the APS technique. However, there are still a few challenges that remain. One of the challenges in case of PSS-PEI (750 kDa) membranes is the relatively smaller pore size of ~80 nm and lower water permeability of ~120 L m − 2 ⋅h − 1 ⋅bar − 1 . For most microfiltration membranes, the average pore size is in the range of 100 nm to 10 μm [29]. There exist a room for improvement here to obtain PSS-PEI membranes having comparable performances to most commercially available microfiltration membranes. Future efforts could also be devoted to increase the pure water permeability of the PSS-PEI (25 kDa) nanofiltration membranes and to obtain ultrafiltration types by tuning the pore size of the membranes.

Conclusions
In this study, pH shift induced Aqueous Phase Separation (APS) was employed to prepare tunable PSS-PEI polyelectrolyte complex (PEC) membranes by a more sustainable approach. Unlike the existing PEC based APS approaches, the polyelectrolyte PSS and PEI solutions can be directly mixed to obtain a homogeneous casting solution at pH 12 without any addition of acid/base or salt. Immersing this PSS-PEI solution in an acetate buffer bath at lower pH causes PEI to acquire charge thereby forming a polyelectrolyte complex with PSS. Several key parameters such as the molecular weight of PEI, the concentration and pH of the acetate buffer, and the concentration of GA crosslinker were varied to investigate the effect on membrane structure and morphology. The results show that the concentration of the acetate buffer is one of the most vital parameters that influences both the onset and the rate of precipitation of PSS-PEI membranes. A slower precipitation rate was observed at low buffer concentrations of 0.1 M − 0.3 M because of the lower buffering capacity, while at 0.4 M and 0.5 M concentrations, the buffering capacity increases causing rapid phase inversion of the membranes which resulted in asymmetric structures. pH of the acetate buffer bath is another key parameter that influences the charge on PEI and also effects the rate of precipitation by acting as a driving force for the polyelectrolyte complexation. At pH 3.6 and pH 4, PEI is fully charged resulting in rapid formation of stable PSS-PEI complex membranes. Conversely, PEI is not expected to be fully charged at pH 4.5 and 5 and as a result the membranes obtained in these pH baths precipitated at a slower rate and were mechanically unstable. The molecular weight of PEI is another tuning parameter that was found to significantly influence the resulting membrane pore sizes. Using relatively low molecular weight of PEI, such as ~25 kDa, nanofiltration type membranes in pH 4 bath with a molecular weight cut-off (MWCO) of ~260 g mol − 1 were made. These membranes had a pure water permeability of ~4 L m − 2 ⋅h − 1 ⋅bar − 1 and showed decent retentions for MgCl 2 (~81%) and Table 2 Dynamic viscosity of the polyelectrolyte casting solutions at 24.9 s − 1 shear rate. The casting solution concentration was 25 wt% overall polymer.

Membrane
Dynamic viscosity at 24.9 s − 1 shear rate (Pa⋅s) PSS-PEI (25 kDa) 1.0 ± 0.2 PSS-PEI (750 kDa) 2.1 ± 0.3 MgSO 4 (~44%). Furthermore, adding only 0.01 wt% glutaraldehyde in the bath significantly densified the membranes by forming imine crosslinks. The cross-linked membranes had a pure water permeability of ~1.7 L m − 2 ⋅h − 1 ⋅bar − 1 and had a MWCO of ~200 g mol − 1 with MgCl 2 and MgSO 4 retentions of ~97% and ~94%. These membranes also showed excellent micropollutant retentions in excess of 90%. On the other hand, using higher molecular weight of PEI i.e. ~750 kDa resulted in microfiltration type membranes in pH 4 baths with an average pore size of ~60 nm. These membranes had a pure water permeability of ~130 L m − 2 ⋅h − 1 ⋅bar − 1 and exhibited 100% retention of oil from an oilin-water emulsion. The findings of this work signify that PSS-PEI membranes with tunable pore sizes and excellent separation properties can be readily prepared using just a mild pH switch, further improving the sustainability of the highly promising APS technique.

Declaration of competing interest
The authors declare no conflicts of Interest.