Chitin (part 1):
Chitin is the exoskeleton of insects/larvae/crustaceans. It is carbon molecules very similar to plant cellulose, except where cellulose has a hydroxyl group in the carbon array chitin has an acetamido group (an acetyl & amino.
The value added product made from chitin is a polymer called chitosan. The characteristics (solubility) of a chitosan end product is a function of how it was processed.
There are factors like the ratio of chitin to alkalai processor (sodium hydroxide, NaOH), % alkalai used, temperature (& to a lesser extent time), the source of the chitin substratate that undergoes cleaving it's acetyl (de-acetylation), resultant particle size & any further treatments to the extracted chitin (chitin free from protein) that is isolated from the crude substrate (exoskeleton).
Chitosan's original substrate chitin, conversion methodology & end product elaboration results in different amino & acetamido group sequences. The gained NH2 amino/acetamido groups permit chitosan to have biological functions.
Because processing replaces the original chitin's ...C-CH3 acetyl groups a higher degree of de-acetylation in end product chitosan is usually more desirable. Quality chitosan will have a low % of ash if the processor removed most of the residual protein associated with the original chitin carbon backbone; this improve the solubility of chitosan.
Chitosan has a + cationic protonation feature, but it doesn't just have the ability to link to negative charges. It's amino NH3+ groups allow it to aggregate with other + polyanionic (multiple + charges) compounds & chelate them; chitosan has the ability to accept + cations.
Chitosan is a weak base & pH drops protonate (protons come into play) it's + charged aminos into cationic poly-electrolytes. This causes the chitosan plolymer to swell due to electro-static repulsion of the polymer's internal groups having the same charge, that are then soluble.
At over 6pH the aminos are de-protonated; which means that charge is lost keeping chitosan insoluble. At over 6.5 pH the simple ("acid soluble") type of chitosan polymers aminos have larger aggregates with some phase separation; in layman's terms it is very viscous.
In contrast, from 6.5pH down to 5.2pH the chitosan polymer's structural aggregation declines. This is due to molecular coils compacting & thus allowing freer amino groups' H (hydrogen) bondings to a neighboring O (oxygen) chain in the polymer matrix.